%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/twisted/python/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/twisted/python/__pycache__/threadable.cpython-312.pyc

�

Ϫ�f�����dZddlmZGd�d�Zd�Zde_d�Zd�Zd	�Zd
�Z	dd�Z
e�Zd�Z
d
�Zd�Zdadadada	ddlZeZe
d�gd�Zy#e$rdZY�wxYw)zT
A module to provide some very basic threading primitives, such as
synchronization.
���wrapsc��eZdZdZd�Zy)�	DummyLockzF
    Hack to allow locks to be unpickled on an unthreaded system.
    c��tdfS�N���
unpickle_lock��selfs �;/usr/lib/python3/dist-packages/twisted/python/threadable.py�
__reduce__zDummyLock.__reduce__s
���r�"�"�N)�__name__�
__module__�__qualname__�__doc__rr	rrrrs���#rrc�6�t�
t�St�S�N)�threadingmodule�XLockrr	rrrrs���"��w���{�rTc���d|jvrMtj�d|jvrt�|jd<tj	�|j
j�y)N�_threadable_lock)�__dict__�_synchLockCreator�acquirer�releaserrs r�	_synchPrer!sU������.��!�!�#��T�]�]�2�05��D�M�M�,�-��!�!�#����!�!�#rc�8�|jj�yr)rrrs r�
_synchPostr!*s�����!�!�#rc�.��t���fd��}|S)Nc�j��t|�	�|g|��i|��t|�S#t|�wxYwr)rr!)r
�args�kwargs�functions   �r�syncz_sync.<locals>.sync/s2����$��	��D�2�4�2�6�2��t���J�t��s�%�
2r)�klassr&r's ` r�_syncr).s ���
�8�_�����Krc��t�?|D]9}|jD](}t||j|�}t	|||��*�;yy)a&
    Make all methods listed in each class' synchronized attribute synchronized.

    The synchronized attribute should be a list of strings, consisting of the
    names of methods that must be synchronized. If we are running in threaded
    mode these methods will be wrapped with a lock.
    N)r�synchronizedr)r�setattr)�klassesr(�
methodNamer's    r�synchronizer/:sT���"��	1�E�#�0�0�
1�
��U�E�N�N�:�$>�?����z�4�0�
1�	1�#rc��|r>ts7t�&daGd�dtj�at�aytd��ytrtd��y)zbInitialize threading.

    Don't bother calling this.  If it needs to happen, it will happen.
    NTc��eZdZd�Zy)rc��tdfSrr
rs rrzXLock.__reduce__Vs
�� -�r�2�2rN)rrrrr	rrrrUs��3rrz:Cannot initialize threading, platform lacks thread supportzCannot uninitialize threads)�threadedr�_RLockrr�RuntimeError)�with_threadss r�initr7IsZ�����*���3�O�2�2�3�%*�G�!�"�P������<�=�=�rc�V�t�tStj�jSr)r�_dummyID�current_thread�identr	rr�getThreadIDr<hs"�������)�)�+�1�1�1rc�$�tt�k(S)zCAre we in the thread responsible for I/O requests (the event loop)?)�ioThreadr<r	rr�isInIOThreadr?ns���{�}�$�$rc��t�ay)z8Mark the current thread as responsible for I/O requests.N)r<r>r	rr�registerAsIOThreadrAss���}�HrNF)r?rAr<r)�)r�	functoolsrrr�__safe_for_unpickling__rr!r)r/r7�objectr9r<r?rAr>r3rr�	threading�_threadingmoduler�ImportError�__all__r	rr�<module>rJs���
��#�#��)-�
�%�$�$�	�1��8�8��2�%�
����������(�'�O���J�I������O��s�A�A#�"A#

Zerion Mini Shell 1.0