Viewing File: /usr/lib/python3.6/site-packages/pip/_vendor/idna/__pycache__/codec.cpython-36.opt-1.pyc

3

aj@sddlmZmZmZmZmZddlZddlZejdZ	Gdddej
Z
GdddejZGd	d
d
ej
ZGddde
ejZGd
dde
ejZddZdS))encodedecodealabelulabel	IDNAErrorNu[.。.。]c@s eZdZdddZdddZdS)	CodecstrictcCs.|dkrtdj||sdSt|t|fS)Nr	z Unsupported error handling "{0}"r)r
r)rformatrlen)selfdataerrorsr/usr/lib/python3.6/codec.pyr	s
zCodec.encodecCs.|dkrtdj||sdSt|t|fS)Nr	z Unsupported error handling "{0}"r
r)r
r)rrrr)r
rrrrrrs
zCodec.decodeN)r	)r	)__name__
__module____qualname__rrrrrrrs

rc@seZdZddZdS)IncrementalEncoderc	Cs|dkrtdj||sdStj|}d}|rV|dsDd}|d	=n|sV|d
=|rVd}g}d}x2|D]*}|jt||r|d7}|t|7}qdWdj||}|t|7}||fS)Nr	z Unsupported error handling "{0}"r
rr.)r
rrr)rr_unicode_dots_resplitappendrrjoin)	r
rrfinallabelstrailing_dotresultsizelabelrrr_buffer_encodes0

z!IncrementalEncoder._buffer_encodeN)rrrr"rrrrrsrc@seZdZddZdS)IncrementalDecoderc	Cs|dkrtdj||sdSt|tr4tj|}nt|}t|d|jd}d}|r~|d	sld}|d
=n|s~|d=|r~d}g}d}x2|D]*}|jt||r|d7}|t	|7}qWdj
||}|t	|7}||fS)Nr	z Unsupported error handling "{0}"r
rasciirr)r
rrrr)rr
isinstanceZunicoderrstrrrrr)	r
rrrrrrr r!rrr_buffer_decode?s8



z!IncrementalDecoder._buffer_decodeN)rrrr'rrrrr#>sr#c@seZdZdS)StreamWriterN)rrrrrrrr(gsr(c@seZdZdS)StreamReaderN)rrrrrrrr)jsr)c	Cs tjdtjtjttttdS)NZidna)namerrincrementalencoderincrementaldecoderstreamwriterstreamreader)	codecs	CodecInforrrrr#r(r)rrrrgetregentrymsr1)Zcorerrrrrr/recompilerrBufferedIncrementalEncoderrBufferedIncrementalDecoderr#r(r)r1rrrr<module>s
!)
Back to Directory File Manager