MINI MINI MANI MO

Path : /lib64/python3.6/encodings/__pycache__/
File Upload :
Current File : //lib64/python3.6/encodings/__pycache__/uu_codec.cpython-36.pyc

3


 \
@sdZddlZddlZddlmZdddZdd	d
ZGdddejZGd
ddejZGdddej	Z	Gdddeej
Z
GdddeejZddZdS)aPython 'uu_codec' Codec - UU content transfer encoding.

This codec de/encodes from bytes to bytes.

Written by Marc-Andre Lemburg (mal@lemburg.com). Some details were
adapted from uu.py which was written by Lance Ellinghouse and
modified by Jack Jansen and Fredrik Lundh.
N)BytesIOstrict<data>c	Cs|dkstt|}t}|j}|j}|d|d@|fjd|d}x|rf|tj||d}qJW|d|jt|fS)Nrzbegin %o %s
iascii-s 
end
)	AssertionErrorrreadwriteencodebinasciiZb2a_uugetvaluelen)	inputerrorsfilenamemodeinfileoutfiler	r
chunkr*/usr/lib64/python3.6/encodings/uu_codec.py	uu_encodesrc
Cs|dkstt|}t}|j}|j}x(|}|s:td|dddkr(Pq(Wx|}|sf|dkrhPytj|}WnRtjk
r}z4|ddd@d	dd
}	tj|d|	}WYdd}~XnX||qRW|std|jt	|fS)Nrz"Missing "begin" line in input datasbeginsend
r ?zTruncated input data)
rrreadliner

ValueErrorrZa2b_uuErrorr
r)
rrrrrr
sdatavnbytesrrr	uu_decode!s0$r%c@s eZdZdddZdddZdS)	CodecrcCs
t||S)N)r)selfrrrrrrCszCodec.encodecCs
t||S)N)r%)r'rrrrrdecodeFszCodec.decodeN)r)r)__name__
__module____qualname__rr(rrrrr&Bs
r&c@seZdZdddZdS)IncrementalEncoderFcCst||jdS)Nr)rr)r'rfinalrrrrJszIncrementalEncoder.encodeN)F)r)r*r+rrrrrr,Isr,c@seZdZdddZdS)IncrementalDecoderFcCst||jdS)Nr)r%r)r'rr-rrrr(NszIncrementalDecoder.decodeN)F)r)r*r+r(rrrrr.Msr.c@seZdZeZdS)StreamWriterN)r)r*r+bytescharbuffertyperrrrr/Qsr/c@seZdZeZdS)StreamReaderN)r)r*r+r0r1rrrrr2Tsr2c
CstjdttttttddS)NuuF)namerr(incrementalencoderincrementaldecoderstreamreaderstreamwriter_is_text_encoding)codecs	CodecInforr%r,r.r2r/rrrrgetregentryYsr<)rrr)r)
__doc__r:riorrr%r&r,r.r/r2r<rrrr<module>s

!

OHA YOOOO