ok

Mini Shell

Direktori : /opt/alt/python311/lib64/python3.11/urllib/__pycache__/
Upload File :
Current File : //opt/alt/python311/lib64/python3.11/urllib/__pycache__/response.cpython-311.pyc

�

�f9	���dZddlZgd�ZGd�dej��ZGd�de��ZGd�d	e��ZGd
�de��ZdS)aResponse classes used by urllib.

The base class, addbase, defines a minimal file-like interface,
including read() and readline().  The typical response object is an
addinfourl instance, which defines an info() method that returns
headers and a geturl() method that returns the url.
�N)�addbase�addclosehook�addinfo�
addinfourlc�4��eZdZdZ�fd�Zd�Zd�Zd�Z�xZS)rzOBase class for addinfo and addclosehook. Is a good idea for garbage collection.c�l��tt|���|dd���||_dS)Nz<urllib response>F)�delete)�superr�__init__�fp)�selfr�	__class__s  ��6/opt/alt/python311/lib64/python3.11/urllib/response.pyrzaddbase.__init__s4���
�g����&�&�r�+>�u�&�M�M�M������c�R�d|jj�dt|���d|j�d�S)N�<z at z whose fp = �>)r�__name__�id�file�r
s r�__repr__zaddbase.__repr__s3���-1�^�-D�-D�-D�-/��X�X�X�X�t�y�y�y�B�	Brc�<�|jjrtd���|S)NzI/O operation on closed file)r�closed�
ValueErrorrs r�	__enter__zaddbase.__enter__s"���7�>�	=��;�<�<�<��rc�.�|���dS�N)�close)r
�type�value�	tracebacks    r�__exit__zaddbase.__exit__!s���
�
�����r)	r�
__module__�__qualname__�__doc__rrrr#�
__classcell__�rs@rrrsn�������Y�Y������
B�B�B����
������rrc�,��eZdZdZ�fd�Z�fd�Z�xZS)rz*Class to add a close hook to an open file.c�t��tt|���|��||_||_dSr)r
rr�	closehook�hookargs)r
rr+r,rs    �rrzaddclosehook.__init__(s3���
�l�D�!�!�*�*�2�.�.�.�"��� ��
�
�
rc���	|j}|j}|rd|_d|_||�tt|�����dS#tt|�����wxYwr)r+r,r
rr)r
r+r,rs   �rrzaddclosehook.close-s}���	.���I��}�H��
%�!%��� $��
��	�8�$�$��,��%�%�+�+�-�-�-�-�-��E�,��%�%�+�+�-�-�-�-���s�#A�)A8)rr$r%r&rrr'r(s@rrr%sW�������4�4�!�!�!�!�!�
	.�	.�	.�	.�	.�	.�	.�	.�	.rrc�(��eZdZdZ�fd�Zd�Z�xZS)rz.class to add an info() method to an open file.c�f��tt|���|��||_dSr)r
rr�headers)r
rr0rs   �rrzaddinfo.__init__<s,���
�g�t���%�%�b�)�)�)�����rc��|jSr)r0rs r�infozaddinfo.info@s
���|�r)rr$r%r&rr2r'r(s@rrr9sM�������8�8������������rrc�F��eZdZdZd�fd�	Zed���Zd�Zd�Z�xZ	S)rz9class to add info() and geturl() methods to an open file.Nc�v��tt|���||��||_||_dSr)r
rr�url�code)r
rr0r5r6rs     �rrzaddinfourl.__init__Gs5���
�j�$���(�(��W�5�5�5������	�	�	rc��|jSr�r6rs r�statuszaddinfourl.statusLs
���y�rc��|jSrr8rs r�getcodezaddinfourl.getcodePs
���y�rc��|jSr)r5rs r�geturlzaddinfourl.geturlSs	���x�rr)
rr$r%r&r�propertyr9r;r=r'r(s@rrrDs|�������C�C�������
����X�����������rr)r&�tempfile�__all__�_TemporaryFileWrapperrrrr�rr�<module>rCs���������
>�
>�
>�������h�,����..�.�.�.�.�7�.�.�.�(�����g��������������r

Zerion Mini Shell 1.0