Ë
‚Ö¦i9 ã ó„ — d Z ddlZg d¢Z G d„ dej « Z G d„ de« Z G d„ d e« Z G d
„ de« Zy)a Response 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 ‡ — e Zd ZdZˆ fd„Zd„ Zd„ Zd„ Zˆ xZS )r zOBase class for addinfo and addclosehook. Is a good idea for garbage collection.c ó@ •— t t | � |dd¬« || _ y )NzF)Údelete)Úsuperr Ú__init__Úfp)Úselfr Ú __class__s €ú(/usr/lib64/python3.12/urllib/response.pyr zaddbase.__init__ s! ø€ Ü
Œg˜Ñ& rÐ+>ÀuÐ&ÔMàˆ�ó c óh — d| j j ›dt | « ›d| j ›d�S )NÚ)r Ú__name__ÚidÚfile©r
s r Ú__repr__zaddbase.__repr__ s( � Ø-1¯^©^×-DÓ-DÜ-/°X°t·y³yðBð Br c óH — | j j rt d« ‚| S )NzI/O operation on closed file)r ÚclosedÚ
ValueErrorr s r Ú __enter__zaddbase.__enter__ s € Ø�7‰7�>Š>ÜÐ;Ó<Ð<؈r c ó$ — | j « y ©N)Úclose)r
ÚtypeÚvalueÚ tracebacks r Ú__exit__zaddbase.__exit__! s € Ø�
‰
�r ) r Ú
__module__Ú__qualname__Ú__doc__r r r r# Ú
__classcell__©r s @r r r s ø„ ÙYôò
Bòö
r r c ó, ‡ — e Zd ZdZˆ fd„Zˆ fd„Zˆ xZS )r z*Class to add a close hook to an open file.c óH •— t t | � |« || _ || _ y r )r
r r Ú closehookÚhookargs)r
r r+ r, r s €r r zaddclosehook.__init__( s ø€ Ü
Œl˜DÑ*¨2Ô.Ø"ˆŒØ ˆ�
r c ó´ •— | j }| j }|rd | _ d | _ ||Ž t t | � « y # t t | � « w xY wr )r+ r, r
r r )r
r+ r, r s €r r zaddclosehook.close- sN ø€ ð .ØŸ™ˆIØ—}‘}ˆHÙØ!%�”Ø $�”
Ù˜8Ñ$ä”, Ñ+Õ-øŒE”, Ñ+Õ-ús ƒ-A ÁA)r r$ r% r&