Tryag File Manager
Home
-
Turbo Force
Current Path :
/
usr
/
lib
/
python2.4
/
Upload File :
New :
File
Dir
//usr/lib/python2.4/mimetools.pyc
mò ‚=5Dc�����������@���sc��d��Z��d�k�Z�d�k�Z�d�k�Z�d�d�d�d�d�d�g�Z�d�e�i�f�d�„��ƒ��YZ�y �d�k�Z�Wn�e�j �o�d�k�Z�n�Xe�i �ƒ��Z �[�d �a�d �„��Z�d�a�d�„��Z�d�„��Z�d �„��Z�d�Z�h��d�e�<d�e�<d�e�<d�e�<d�d�<d�d�<Z�h��d�d�<d�d�<d�d�<d�d�<d�d�<d�d�<Z�d�„��Z�d�„��Z�d�„��Z�d�„��Z�d�S(���s<���Various tools used by MIME-reading or MIME-writing programs.Nt���Messaget���choose_boundaryt���encodet���decodet���copyliteralt ���copybinaryc�����������B���sk���t��Z�d��Z�d�d�„�Z�d�„��Z�d�„��Z�d�„��Z�d�„��Z�d�„��Z�d�„��Z �d �„��Z �d �„��Z�d�„��Z�RS(���sˆ���A derived class of rfc822.Message that knows about MIME headers and contains some hooks for decoding encoded and multipart messages.i���c���������C���sR���t��i�i�|��|�|�ƒ�|��i�d�ƒ�|��_�|��i�d�ƒ�|��_�|��i �ƒ��|��i �ƒ��d��S(���Ns���content-transfer-encodings���content-type(���t���rfc822R����t���__init__t���selft���fpt���seekablet ���getheadert���encodingheadert ���typeheadert ���parsetypet ���parseplist(���R���R ���R ���(����(����t���/usr/lib/python2.4/mimetools.pyR������s ���� c���������C���sß���|��i�}�|�d��j�o �d�}�n�d�|�j�o*�|�i�d�ƒ�}�|�|�|��_�|�|� }�n �d�|��_�|�i�d�ƒ�}�x4�t �t �|�ƒ�ƒ�D] �}�|�|�i�ƒ��i�ƒ��|�|�<q‚�Wd�i �|�ƒ�|��_�|�d�|��_�d�i �|�d�ƒ�|��_�d��S(���Ns ���text/plaint���;t����t���/i����i���(���R���R ���t���strt���Nonet���indext���it ���plisttextt���splitt���fieldst���ranget���lent���stript���lowert���joint���typet���maintypet���subtype(���R���R���R���R���(����(����R���R������s���� � c���������C���sÛ���|��i�}�g��|��_�xÂ�|�d� d�j�o°�|�d�}�d�|�j�o�|�i�d�ƒ�}�n �t�|�ƒ�}�|�|� }�d�|�j�o?�|�i�d�ƒ�}�|�|� i �ƒ��i �ƒ��d�|�|�d�i �ƒ��}�n�|��i�i�|�i �ƒ��ƒ�|�|�}�q�Wd��S(���Ni���R���t���=(���R���R���R���t���plistR���t���endR���t���fR���R���R���t���append(���R���R%���R&���R���R���(����(����R���R���)���s���� � 0c���������C���s���|��i�S(���N(���R���R$���(���R���(����(����R���t���getplist;���s����c���������C���sZ���|�i�ƒ��d�}�t�|�ƒ�}�x7�|��i�D],�}�|�|� |�j�o�t�i�|�|�ƒ�Sq&�q&�Wd��S(���NR#���( ���t���nameR���R���t���nR���R$���t���pR���t���unquoteR���(���R���R)���R*���R+���(����(����R���t���getparam>���s���� �c���������C���sU���g��}�xH�|��i�D]=�}�|�i�d�ƒ�}�|�d�j�o�|�i�|�|� i�ƒ��ƒ�q�q�W|�S(���NR#���i����(���t���resultR���R$���R+���t���findR���R'���R���(���R���R���R+���R.���(����(����R���t ���getparamnamesF���s���� � c���������C���s%���|��i�d��j�o�d�Sn�|��i�i�ƒ��S(���Nt���7bit(���R���R���R���R���(���R���(����(����R���t���getencodingN���s����c���������C���s���|��i�S(���N(���R���R ���(���R���(����(����R���t���gettypeS���s����c���������C���s���|��i�S(���N(���R���R!���(���R���(����(����R���t���getmaintypeV���s����c���������C���s���|��i�S(���N(���R���R"���(���R���(����(����R���t ���getsubtypeY���s����( ���t���__name__t ���__module__t���__doc__R���R���R���R(���R-���R0���R2���R3���R4���R5���(����(����(����R���R�������s���� i����c����������C���s(���t��i�ƒ��t�d�7a�t�}��t��i�ƒ��|��S(���Ni���(���t ���_counter_lockt���acquiret���_counterR.���t���release(���R.���(����(����R���t���_get_next_counterj���s����� c����������C���sÌ���d�k��}�t�d�j�oœ�d�k�}�|�i�|�i�ƒ��ƒ�}��y�t�t�i �ƒ��ƒ�}�Wn�t�j �o �d�}�n�Xy�t�t�i�ƒ��ƒ�}�Wn�t�j �o �d�}�n�X|��d�|�d�|�a�n�d�t�|�i��ƒ��t�ƒ��f�S(���sx��Return a string usable as a multipart boundary. The string chosen is unique within a single program run, and incorporates the user id (if available), process id (if available), and current time. So it's very unlikely the returned string appears in message text, but there's no guarantee. The boundary contains dots so you have to quote it in the header.Nt���1t���.s ���%s.%.3f.%d(���t���timet���_prefixR���t���sockett ���gethostbynamet���gethostnamet���hostidt���reprt���ost���getuidt���uidt���AttributeErrort���getpidt���pidR=���(���RE���RI���RL���R@���RB���(����(����R���R���t���s ������ c���������C���sØ���|�d�j�o�d�k�}�|�i�|��|�ƒ�Sn�|�d�j�o�d�k�}�|�i�|��|�ƒ�Sn�|�d�j�o�d�k�}�|�i�|��|�ƒ�Sn�|�d�j�o�|�i�|��i�ƒ��ƒ�Sn�|�t �j�o�t �|��t �|�|�ƒ�n�t�d �|�‚�d�S( ���sD���Decode common content-transfer-encodings (base64, quopri, uuencode).t���base64Ns���quoted-printablet���uuencodes ���x-uuencodet���uues���x-uueR1���t���8bits%���unknown Content-Transfer-Encoding: %s(���RN���s ���x-uuencodeRO���s���x-uue(���s���7bitRP���(���t���encodingRM���R���t���inputt���outputt���quoprit���uut���writet���readt ���decodetabt���pipethrought ���ValueError(���RR���RS���RQ���RU���RM���RT���(����(����R���R���‘���s����� c���������C���sÛ���|�d�j�o�d�k�}�|�i�|��|�ƒ�Sn�|�d�j�o �d�k�}�|�i�|��|�d�ƒ�Sn�|�d�j�o�d�k�}�|�i�|��|�ƒ�Sn�|�d �j�o�|�i�|��i�ƒ��ƒ�Sn�|�t �j�o�t �|��t �|�|�ƒ�n�t�d�|�‚�d�S(���sD���Encode common content-transfer-encodings (base64, quopri, uuencode).RM���Ns���quoted-printablei����RN���s ���x-uuencodeRO���s���x-uueR1���RP���s%���unknown Content-Transfer-Encoding: %s(���s���uuencodes ���x-uuencodes���uues���x-uue(���s���7bits���8bit(���RQ���RM���R���RR���RS���RT���RU���RV���RW���t ���encodetabRY���RZ���(���RR���RS���RQ���RU���RM���RT���(����(����R���R���¤���s����� sa���( TEMP=/tmp/@uu.$$ sed "s%^begin [0-7][0-7]* .*%begin 600 $TEMP%" | uudecode cat $TEMP rm $TEMP )RN���s ���x-uuencodeRO���s���x-uues���quoted-printables���mmencode -u -qRM���s���mmencode -u -bs���uuencode tempfiles���mmencode -qs���mmencode -bc���������C���s-���t��i�|�d�ƒ�}�t�|��|�ƒ�|�i�ƒ��d��S(���Nt���w(���RG���t���popent���commandt���pipeR���RR���t���close(���RR���R^���R_���(����(����R���t���pipetoÔ���s���� c���������C���s}���t��i�ƒ��\�}�}�t�i�|�d�ƒ�}�t�|��|�ƒ�|�i �ƒ��t�i �|�d�|�d�ƒ�}�t �|�|�ƒ�|�i �ƒ��t�i�|�ƒ�d��S(���NR\���s��� <t���r(���t���tempfilet���mkstempt���fdt���tempnameRG���t���fdopent���tempR���RR���R`���R]���R^���R_���R���RS���t���unlink(���RR���R^���RS���Rh���R_���Re���Rf���(����(����R���RY���Ù���s���� c���������C���s1���x*�|��i�ƒ��}�|�p�Pn�|�i�|�ƒ�q�Wd��S(���Ni���(���RR���t���readlinet���lineRS���RV���(���RR���RS���Rk���(����(����R���R���ã���s�������c���������C���s:���d�}�x-�|��i�|�ƒ�}�|�p�Pn�|�i�|�ƒ�q �Wd��S(���Ni� ��i���(���t���BUFSIZERR���RW���Rk���RS���RV���(���RR���RS���Rk���Rl���(����(����R���R���é���s�������(���R8���RG���R���Rc���t���__all__R����t���threadt���ImportErrort���dummy_threadt ���allocate_lockR9���R;���R=���R���RA���R���R���R���t ���uudecode_pipeRX���R[���Ra���RY���R���R���(���RX���RY���R9���R[���R���Ra���Rr���Rm���Rc���R���R���R=���R���R���Rn���R���R����RG���(����(����R���t���?���s0��� W < <