�`^c@sndZddddgZddlZddlmZd�Zd �Zd
�Zd�Z d�Z
d
�ZdS(s Encodings and related functions.tencode_7or8bitt
encode_base64tencode_noopt
encode_quoprii�N(tencodestringcCs"t|dt�}|jdd�S(Nt quotetabst s=20(t
_encodestringtTruetreplace(tstenc((s$/sys/lib/python2.7/email/encoders.pyt_qencodescCsL|s
|S|ddk}tj|�}|rH|ddkrH|d S|S(Ni�s
(tbase64R(R
t
hasnewlinetvalue((s$/sys/lib/python2.7/email/encoders.pyt_bencodescCs3|j�}t|�}|j|�d|d<dS(slEncode the message's payload in Base64.
Also, add an appropriate Content-Transfer-Encoding header.
R
sContent-Transfer-EncodingN(tget_payloadRtset_payload(tmsgtorigtencdata((s$/sys/lib/python2.7/email/encoders.pyR's
cCs3|j�}t|�}|j|�d|d<dS(svEncode the message's payload in quoted-printable.
Also, add an appropriate Content-Transfer-Encoding header.
squoted-printablesContent-Transfer-EncodingN(RRR(RRR((s$/sys/lib/python2.7/email/encoders.pyR3s
cCsc|j�}|dkr&d|d<dSy|jd�Wntk
rTd|d<nXd|d<dS(s9Set the Content-Transfer-Encoding header to 7bit or 8bit.t7bitsContent-Transfer-EncodingNtasciit8bit(RtNonetencodetUnicodeError(RR((s$/sys/lib/python2.7/email/encoders.pyR?s
cCsdS(sDo nothing.N((R((s$/sys/lib/python2.7/email/encoders.pyRQs(t__doc__t__all__R
tquopriRRRRRRRR(((s$/sys/lib/python2.7/email/encoders.pyt<module>s
|