AlkantarClanX12
Current Path : /opt/alt/python39/lib64/python3.9/asyncio/__pycache__/ |
Current File : //opt/alt/python39/lib64/python3.9/asyncio/__pycache__/windows_utils.cpython-39.opt-2.pyc |
a R�f� � @ s� d dl Z e jdkred��d dlZd dlZd dlZd dlZd dlZd dlZd dl Z dZ dZejZej Z e�� Zdded�d d �ZG dd� d�ZG d d� dej�ZdS )� NZwin32z win32 only)�pipe�Popen�PIPE� PipeHandlei F)TT)�duplex� overlapped�bufsizec C s$ t jd�t�� tt��d�}| r>tj}tj tj B }|| }}ntj}tj }d| }}|tjO }|d rp|tj O }|d r�tj }nd}d } } z\t�||tjd||tjtj�} t�||dtjtj|tj�} tj| dd�}|�d� | | fW S | d u�rt�| � | d u�rt�| � � Y n0 d S )Nz\\.\pipe\python-pipe-{:d}-{:d}-)�prefixr � T�r )�tempfileZmktemp�format�os�getpid�next� _mmap_counter�_winapiZPIPE_ACCESS_DUPLEXZGENERIC_READZ GENERIC_WRITEZPIPE_ACCESS_INBOUNDZFILE_FLAG_FIRST_PIPE_INSTANCEZFILE_FLAG_OVERLAPPEDZCreateNamedPipeZ PIPE_WAITZNMPWAIT_WAIT_FOREVERZNULLZ CreateFileZ OPEN_EXISTINGZConnectNamedPipeZGetOverlappedResult�CloseHandle)r r r ZaddressZopenmode�accessZobsizeZibsizeZflags_and_attribsZh1Zh2Zov� r �:/opt/alt/python39/lib64/python3.9/asyncio/windows_utils.pyr sJ �� �� r c @ s^ e Zd Zdd� Zdd� Zedd� �Zdd� Zej d �d d�Z ejfdd �Z dd� Zdd� ZdS )r c C s || _ d S �N��_handle��self�handler r r �__init__V s zPipeHandle.__init__c C s2 | j d urd| j ��}nd}d| jj� d|� d�S )Nzhandle=�closed�<� �>)r � __class__�__name__r r r r �__repr__Y s zPipeHandle.__repr__c C s | j S r r �r r r r r ` s zPipeHandle.handlec C s | j d u rtd��| j S )NzI/O operation on closed pipe)r � ValueErrorr% r r r �filenod s zPipeHandle.fileno)r c C s | j d ur|| j � d | _ d S r r )r r r r r �closei s zPipeHandle.closec C s* | j d ur&|d| ��t| d� | �� d S )Nz unclosed )�source)r �ResourceWarningr( )r Z_warnr r r �__del__n s zPipeHandle.__del__c C s | S r r r% r r r � __enter__s s zPipeHandle.__enter__c C s | � � d S r )r( )r �t�v�tbr r r �__exit__v s zPipeHandle.__exit__N)r# � __module__�__qualname__r r$ �propertyr r'