Psyduck - 可達鴨 之 鴨力山大2


Server : LiteSpeed
System : Linux premium217.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
User : alloknri ( 880)
PHP Version : 8.1.34
Disable Function : NONE
Directory :  /opt/alt/python37/lib64/python3.7/asyncio/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //opt/alt/python37/lib64/python3.7/asyncio/__pycache__/transports.cpython-37.pyc
B

� f�'�@s|dZdZGdd�d�ZGdd�de�ZGdd�de�ZGdd	�d	ee�ZGd
d�de�ZGdd
�d
e�ZGdd�de�ZdS)zAbstract Transport class.)�
BaseTransport�
ReadTransport�WriteTransport�	Transport�DatagramTransport�SubprocessTransportc@sDeZdZdZddd�Zddd�Zdd�Zd	d
�Zdd�Zd
d�Z	dS)rzBase class for transports.NcCs|dkri}||_dS)N)�_extra)�self�extra�r
�7/opt/alt/python37/lib64/python3.7/asyncio/transports.py�__init__szBaseTransport.__init__cCs|j�||�S)z#Get optional transport information.)r�get)r�name�defaultr
r
r�get_extra_infoszBaseTransport.get_extra_infocCst�dS)z2Return True if the transport is closing or closed.N)�NotImplementedError)rr
r
r�
is_closingszBaseTransport.is_closingcCst�dS)a
Close the transport.

        Buffered data will be flushed asynchronously.  No more data
        will be received.  After all buffered data is flushed, the
        protocol's connection_lost() method will (eventually) called
        with None as its argument.
        N)r)rr
r
r�closeszBaseTransport.closecCst�dS)zSet a new protocol.N)r)r�protocolr
r
r�set_protocol#szBaseTransport.set_protocolcCst�dS)zReturn the current protocol.N)r)rr
r
r�get_protocol'szBaseTransport.get_protocol)N)N)
�__name__�
__module__�__qualname__�__doc__rrrrrrr
r
r
rr	s


rc@s(eZdZdZdd�Zdd�Zdd�ZdS)	rz#Interface for read-only transports.cCst�dS)z*Return True if the transport is receiving.N)r)rr
r
r�
is_reading/szReadTransport.is_readingcCst�dS)z�Pause the receiving end.

        No data will be passed to the protocol's data_received()
        method until resume_reading() is called.
        N)r)rr
r
r�
pause_reading3szReadTransport.pause_readingcCst�dS)z�Resume the receiving end.

        Data received will once again be passed to the protocol's
        data_received() method.
        N)r)rr
r
r�resume_reading;szReadTransport.resume_readingN)rrrrrrrr
r
r
rr,src@sJeZdZdZddd�Zdd�Zdd�Zd	d
�Zdd�Zd
d�Z	dd�Z
dS)rz$Interface for write-only transports.NcCst�dS)a�Set the high- and low-water limits for write flow control.

        These two values control when to call the protocol's
        pause_writing() and resume_writing() methods.  If specified,
        the low-water limit must be less than or equal to the
        high-water limit.  Neither value can be negative.

        The defaults are implementation-specific.  If only the
        high-water limit is given, the low-water limit defaults to an
        implementation-specific value less than or equal to the
        high-water limit.  Setting high to zero forces low to zero as
        well, and causes pause_writing() to be called whenever the
        buffer becomes non-empty.  Setting low to zero causes
        resume_writing() to be called only once the buffer is empty.
        Use of zero for either limit is generally sub-optimal as it
        reduces opportunities for doing I/O and computation
        concurrently.
        N)r)r�high�lowr
r
r�set_write_buffer_limitsGsz&WriteTransport.set_write_buffer_limitscCst�dS)z,Return the current size of the write buffer.N)r)rr
r
r�get_write_buffer_size\sz$WriteTransport.get_write_buffer_sizecCst�dS)z�Write some data bytes to the transport.

        This does not block; it buffers the data and arranges for it
        to be sent out asynchronously.
        N)r)r�datar
r
r�write`szWriteTransport.writecCsd�|�}|�|�dS)z�Write a list (or any iterable) of data bytes to the transport.

        The default implementation concatenates the arguments and
        calls write() on the result.
        �N)�joinr#)rZlist_of_datar"r
r
r�
writelineshs
zWriteTransport.writelinescCst�dS)z�Close the write end after flushing buffered data.

        (This is like typing ^D into a UNIX program reading from stdin.)

        Data may still be received.
        N)r)rr
r
r�	write_eofqszWriteTransport.write_eofcCst�dS)zAReturn True if this transport supports write_eof(), False if not.N)r)rr
r
r�
can_write_eofzszWriteTransport.can_write_eofcCst�dS)z�Close the transport immediately.

        Buffered data will be lost.  No more data will be received.
        The protocol's connection_lost() method will (eventually) be
        called with None as its argument.
        N)r)rr
r
r�abort~szWriteTransport.abort)NN)rrrrr r!r#r&r'r(r)r
r
r
rrDs
		rc@seZdZdZdS)raSInterface representing a bidirectional transport.

    There may be several implementations, but typically, the user does
    not implement new transports; rather, the platform provides some
    useful transports that are implemented using the platform's best
    practices.

    The user never instantiates a transport directly; they call a
    utility function, passing it a protocol factory and other
    information necessary to create the transport and protocol.  (E.g.
    EventLoop.create_connection() or EventLoop.create_server().)

    The utility function will asynchronously create a transport and a
    protocol and hook them up by calling the protocol's
    connection_made() method, passing it the transport.

    The implementation here raises NotImplemented for every method
    except writelines(), which calls write() in a loop.
    N)rrrrr
r
r
rr�src@s"eZdZdZddd�Zdd�ZdS)rz(Interface for datagram (UDP) transports.NcCst�dS)aSend data to the transport.

        This does not block; it buffers the data and arranges for it
        to be sent out asynchronously.
        addr is target socket address.
        If addr is None use target address pointed on transport creation.
        N)r)rr"Zaddrr
r
r�sendto�szDatagramTransport.sendtocCst�dS)z�Close the transport immediately.

        Buffered data will be lost.  No more data will be received.
        The protocol's connection_lost() method will (eventually) be
        called with None as its argument.
        N)r)rr
r
rr)�szDatagramTransport.abort)N)rrrrr*r)r
r
r
rr�s

rc@s<eZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Zd
S)rcCst�dS)zGet subprocess id.N)r)rr
r
r�get_pid�szSubprocessTransport.get_pidcCst�dS)z�Get subprocess returncode.

        See also
        http://docs.python.org/3/library/subprocess#subprocess.Popen.returncode
        N)r)rr
r
r�get_returncode�sz"SubprocessTransport.get_returncodecCst�dS)z&Get transport for pipe with number fd.N)r)r�fdr
r
r�get_pipe_transport�sz&SubprocessTransport.get_pipe_transportcCst�dS)z�Send signal to subprocess.

        See also:
        docs.python.org/3/library/subprocess#subprocess.Popen.send_signal
        N)r)r�signalr
r
r�send_signal�szSubprocessTransport.send_signalcCst�dS)aLStop the subprocess.

        Alias for close() method.

        On Posix OSs the method sends SIGTERM to the subprocess.
        On Windows the Win32 API function TerminateProcess()
         is called to stop the subprocess.

        See also:
        http://docs.python.org/3/library/subprocess#subprocess.Popen.terminate
        N)r)rr
r
r�	terminate�szSubprocessTransport.terminatecCst�dS)z�Kill the subprocess.

        On Posix OSs the function sends SIGKILL to the subprocess.
        On Windows kill() is an alias for terminate().

        See also:
        http://docs.python.org/3/library/subprocess#subprocess.Popen.kill
        N)r)rr
r
r�kill�s	zSubprocessTransport.killN)	rrrr+r,r.r0r1r2r
r
r
rr�srcsVeZdZdZd�fdd�	Zdd�Zdd�Zd	d
�Zddd�Zdd
d�Z	dd�Z
�ZS)�_FlowControlMixinavAll the logic for (write) flow control in a mix-in base class.

    The subclass must implement get_write_buffer_size().  It must call
    _maybe_pause_protocol() whenever the write buffer size increases,
    and _maybe_resume_protocol() whenever it decreases.  It may also
    override set_write_buffer_limits() (e.g. to specify different
    defaults).

    The subclass constructor must call super().__init__(extra).  This
    will call set_write_buffer_limits().

    The user may call set_write_buffer_limits() and
    get_write_buffer_size(), and their protocol's pause_writing() and
    resume_writing() may be called.
    Ncs0t��|�|dk	st�||_d|_|��dS)NF)�superr�AssertionError�_loop�_protocol_paused�_set_write_buffer_limits)rr	Zloop)�	__class__r
rr�s
z_FlowControlMixin.__init__c
Csp|��}||jkrdS|jsld|_y|j��Wn:tk
rj}z|j�d|||jd��Wdd}~XYnXdS)NTzprotocol.pause_writing() failed)�message�	exception�	transportr)r!�_high_waterr7�	_protocolZ
pause_writing�	Exceptionr6�call_exception_handler)r�size�excr
r
r�_maybe_pause_protocols
z'_FlowControlMixin._maybe_pause_protocolc
Csh|jrd|��|jkrdd|_y|j��Wn:tk
rb}z|j�d|||jd��Wdd}~XYnXdS)NFz protocol.resume_writing() failed)r:r;r<r)r7r!�
_low_waterr>Zresume_writingr?r6r@)rrBr
r
r�_maybe_resume_protocolsz(_FlowControlMixin._maybe_resume_protocolcCs|j|jfS)N)rDr=)rr
r
r�get_write_buffer_limitssz)_FlowControlMixin.get_write_buffer_limitscCsj|dkr|dkrd}nd|}|dkr.|d}||krBdksZntd|�d|�d���||_||_dS)Ni��zhigh (z) must be >= low (z) must be >= 0)�
ValueErrorr=rD)rrrr
r
rr8"sz*_FlowControlMixin._set_write_buffer_limitscCs|j||d�|��dS)N)rr)r8rC)rrrr
r
rr 2sz)_FlowControlMixin.set_write_buffer_limitscCst�dS)N)r)rr
r
rr!6sz'_FlowControlMixin.get_write_buffer_size)NN)NN)NN)rrrrrrCrErFr8r r!�
__classcell__r
r
)r9rr3�s

r3N)	r�__all__rrrrrrr3r
r
r
r�<module>s#D4
Name
Size
Permissions
Options
__init__.cpython-37.opt-1.pyc
0.671 KB
-rw-r--r--
__init__.cpython-37.opt-2.pyc
0.616 KB
-rw-r--r--
__init__.cpython-37.pyc
0.671 KB
-rw-r--r--
base_events.cpython-37.opt-1.pyc
47.163 KB
-rw-r--r--
base_events.cpython-37.opt-2.pyc
38.447 KB
-rw-r--r--
base_events.cpython-37.pyc
47.384 KB
-rw-r--r--
base_futures.cpython-37.opt-1.pyc
2.05 KB
-rw-r--r--
base_futures.cpython-37.opt-2.pyc
1.714 KB
-rw-r--r--
base_futures.cpython-37.pyc
2.05 KB
-rw-r--r--
base_subprocess.cpython-37.opt-1.pyc
8.881 KB
-rw-r--r--
base_subprocess.cpython-37.opt-2.pyc
8.781 KB
-rw-r--r--
base_subprocess.cpython-37.pyc
8.973 KB
-rw-r--r--
base_tasks.cpython-37.opt-1.pyc
1.819 KB
-rw-r--r--
base_tasks.cpython-37.opt-2.pyc
1.819 KB
-rw-r--r--
base_tasks.cpython-37.pyc
1.819 KB
-rw-r--r--
constants.cpython-37.opt-1.pyc
0.574 KB
-rw-r--r--
constants.cpython-37.opt-2.pyc
0.574 KB
-rw-r--r--
constants.cpython-37.pyc
0.574 KB
-rw-r--r--
coroutines.cpython-37.opt-1.pyc
6.143 KB
-rw-r--r--
coroutines.cpython-37.opt-2.pyc
5.916 KB
-rw-r--r--
coroutines.cpython-37.pyc
6.226 KB
-rw-r--r--
events.cpython-37.opt-1.pyc
27.128 KB
-rw-r--r--
events.cpython-37.opt-2.pyc
18.081 KB
-rw-r--r--
events.cpython-37.pyc
27.233 KB
-rw-r--r--
format_helpers.cpython-37.opt-1.pyc
2.26 KB
-rw-r--r--
format_helpers.cpython-37.opt-2.pyc
2.021 KB
-rw-r--r--
format_helpers.cpython-37.pyc
2.26 KB
-rw-r--r--
futures.cpython-37.opt-1.pyc
10.39 KB
-rw-r--r--
futures.cpython-37.opt-2.pyc
7.152 KB
-rw-r--r--
futures.cpython-37.pyc
10.561 KB
-rw-r--r--
locks.cpython-37.opt-1.pyc
15.537 KB
-rw-r--r--
locks.cpython-37.opt-2.pyc
9.08 KB
-rw-r--r--
locks.cpython-37.pyc
15.537 KB
-rw-r--r--
log.cpython-37.opt-1.pyc
0.231 KB
-rw-r--r--
log.cpython-37.opt-2.pyc
0.193 KB
-rw-r--r--
log.cpython-37.pyc
0.231 KB
-rw-r--r--
proactor_events.cpython-37.opt-1.pyc
19.409 KB
-rw-r--r--
proactor_events.cpython-37.opt-2.pyc
19.019 KB
-rw-r--r--
proactor_events.cpython-37.pyc
19.614 KB
-rw-r--r--
protocols.cpython-37.opt-1.pyc
8.521 KB
-rw-r--r--
protocols.cpython-37.opt-2.pyc
3.118 KB
-rw-r--r--
protocols.cpython-37.pyc
8.521 KB
-rw-r--r--
queues.cpython-37.opt-1.pyc
7.979 KB
-rw-r--r--
queues.cpython-37.opt-2.pyc
5.346 KB
-rw-r--r--
queues.cpython-37.pyc
7.979 KB
-rw-r--r--
runners.cpython-37.opt-1.pyc
1.894 KB
-rw-r--r--
runners.cpython-37.opt-2.pyc
1.228 KB
-rw-r--r--
runners.cpython-37.pyc
1.894 KB
-rw-r--r--
selector_events.cpython-37.opt-1.pyc
27.724 KB
-rw-r--r--
selector_events.cpython-37.opt-2.pyc
26.114 KB
-rw-r--r--
selector_events.cpython-37.pyc
27.784 KB
-rw-r--r--
sslproto.cpython-37.opt-1.pyc
20.564 KB
-rw-r--r--
sslproto.cpython-37.opt-2.pyc
13.895 KB
-rw-r--r--
sslproto.cpython-37.pyc
20.758 KB
-rw-r--r--
streams.cpython-37.opt-1.pyc
19.541 KB
-rw-r--r--
streams.cpython-37.opt-2.pyc
13.449 KB
-rw-r--r--
streams.cpython-37.pyc
19.81 KB
-rw-r--r--
subprocess.cpython-37.opt-1.pyc
6.562 KB
-rw-r--r--
subprocess.cpython-37.opt-2.pyc
6.435 KB
-rw-r--r--
subprocess.cpython-37.pyc
6.591 KB
-rw-r--r--
tasks.cpython-37.opt-1.pyc
21.738 KB
-rw-r--r--
tasks.cpython-37.opt-2.pyc
14.681 KB
-rw-r--r--
tasks.cpython-37.pyc
21.793 KB
-rw-r--r--
transports.cpython-37.opt-1.pyc
11.893 KB
-rw-r--r--
transports.cpython-37.opt-2.pyc
6.364 KB
-rw-r--r--
transports.cpython-37.pyc
11.922 KB
-rw-r--r--
unix_events.cpython-37.opt-1.pyc
31.249 KB
-rw-r--r--
unix_events.cpython-37.opt-2.pyc
27.637 KB
-rw-r--r--
unix_events.cpython-37.pyc
31.586 KB
-rw-r--r--
windows_events.cpython-37.opt-1.pyc
22.524 KB
-rw-r--r--
windows_events.cpython-37.opt-2.pyc
21.44 KB
-rw-r--r--
windows_events.cpython-37.pyc
22.524 KB
-rw-r--r--
windows_utils.cpython-37.opt-1.pyc
4.213 KB
-rw-r--r--
windows_utils.cpython-37.opt-2.pyc
3.789 KB
-rw-r--r--
windows_utils.cpython-37.pyc
4.295 KB
-rw-r--r--