AlkantarClanX12

Your IP : 18.225.195.153


Current Path : /opt/alt/python33/lib64/python3.3/__pycache__/
Upload File :
Current File : //opt/alt/python33/lib64/python3.3/__pycache__/_dummy_thread.cpython-33.pyo

�
��f�c@s�dZdddddddgZdZeZid
d�Zdd�Zdd�Zd
d�Zddd�Z
Gdd�de�Zdadadd�ZdS(u/Drop-in replacement for the thread module.

Meant to be used as a brain-dead substitute so that threaded code does
not need to be rewritten for when the thread module is not present.

Suggested usage is::

    try:
        import _thread
    except ImportError:
        import _dummy_thread as _thread

uerrorustart_new_threaduexitu	get_identu
allocate_lockuinterrupt_mainuLockTypeiicCs�t|�tt��kr*td��nt|�tt��krTtd��nday|||�Wn/tk
rYnddl}|j�YnXdat
r�da
t�ndS(u�Dummy implementation of _thread.start_new_thread().

    Compatibility is maintained by making sure that ``args`` is a
    tuple and ``kwargs`` is a dictionary.  If an exception is raised
    and it is SystemExit (which can be done by _thread.exit()) it is
    caught and nothing is done; all other exceptions are printed out
    by using traceback.print_exc().

    If the executed function calls interrupt_main the KeyboardInterrupt will be
    raised when the function returns.

    u2nd arg must be a tupleu3rd arg must be a dictiNFT(utypeutupleu	TypeErrorudictuFalseu_mainu
SystemExitu	tracebacku	print_excuTrueu
_interruptuKeyboardInterrupt(ufunctionuargsukwargsu	traceback((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyustart_new_threads 

cCs
t�dS(u'Dummy implementation of _thread.exit().N(u
SystemExit(((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyuexit=scCsdS(u�Dummy implementation of _thread.get_ident().

    Since this module should only be used when _threadmodule is not
    available, it is safe to assume that the current process is the
    only thread.  Thus a constant can be safely returned.
    ii����((((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu	get_identAscCst�S(u0Dummy implementation of _thread.allocate_lock().(uLockType(((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu
allocate_lockJscCs|dk	rtd��ndS(u-Dummy implementation of _thread.stack_size().u'setting thread stack size not supportediN(uNoneuerror(usize((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu
stack_sizeNsu
stack_sizecBsb|EeZdZdZdd�Zd
ddd�ZeZdd�Zd	d
�Z	dd�Z
d
S(uLockTypeu�Class implementing dummy implementation of _thread.LockType.

    Compatibility is maintained by maintaining self.locked_status
    which is a boolean that stores the state of the lock.  Pickling of
    the lock, though, should not be done since if the _thread module is
    then used with an unpickled ``lock()`` from here problems could
    occur from this class not having atomic methods.

    cCs
d|_dS(NF(uFalseu
locked_status(uself((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu__init___suLockType.__init__icCse|dks|rd|_dS|js5d|_dS|dkr]ddl}|j|�ndSdS(u�Dummy implementation of acquire().

        For blocking calls, self.locked_status is automatically set to
        True and returned appropriately based on value of
        ``waitflag``.  If it is non-blocking, then the value is
        actually checked and not set if it is already acquired.  This
        is all done so that threading.Condition's assert statements
        aren't triggered and throw a little fit.

        iNTF(uNoneuTrueu
locked_statusutimeusleepuFalse(uselfuwaitflagutimeoututime((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyuacquirebs			uLockType.acquirecCs|j�dS(N(urelease(uselfutypuvalutb((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu__exit__|suLockType.__exit__cCs|jst�nd|_dS(uRelease the dummy lock.FT(u
locked_statusuerroruFalseuTrue(uself((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyureleases			uLockType.releasecCs|jS(N(u
locked_status(uself((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyulocked�suLockType.lockedNi����(u__name__u
__module__u__qualname__u__doc__u__init__uNoneuacquireu	__enter__u__exit__ureleaseulocked(u
__locals__((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyuLockTypeTs		cCstrt�ndadS(u^Set _interrupt flag to True to have start_new_thread raise
    KeyboardInterrupt upon exiting.NT(u_mainuKeyboardInterruptuTrueu
_interrupt(((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyuinterrupt_main�s	NlFT(u__doc__u__all__uTIMEOUT_MAXuRuntimeErroruerrorustart_new_threaduexitu	get_identu
allocate_lockuNoneu
stack_sizeuobjectuLockTypeuFalseu
_interruptuTrueu_mainuinterrupt_main(((u2/opt/alt/python33/lib64/python3.3/_dummy_thread.pyu<module>
s 	8