KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 DAV/2 PHP/5.2.17
System : Linux localhost 2.6.18-419.el5 #1 SMP Fri Feb 24 22:47:42 UTC 2017 x86_64
User : nobody ( 99)
PHP Version : 5.2.17
Disable Function : NONE
Directory :  /proc/21585/root/usr/lib64/python2.4/email/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/21585/root/usr/lib64/python2.4/email/Generator.pyo
mò
‚=5Dc@sÙdZdkZdkZdkZdkZdkZdklZdkl	Z	dZ
dZeidei
ƒZd„Zdfd	„ƒYZd
Zdefd„ƒYZeeeid
ƒƒZdeZdd„ZdS(s:Classes to generate plain text from a message object tree.N(sStringIO(sHeadert_s
s^From cCsCt|tƒo/yt|dƒWq?tj
otSq?XntS(Nsus-ascii(t
isinstancetststrtunicodetUnicodeErrortTruetFalse(R((t'/usr/lib64/python2.4/email/Generator.pyt
_is8bitstrings
t	GeneratorcBsŒtZdZedd„Zd„Zed„Zed„Zd„Z	d„Z
d„Zd	„Zd
„Z
e
Zd„Zd„Zd
„ZRS(sŠGenerates output from a Message object tree.

    This basic generator writes the message to the given file object as plain
    text.
    iNcCs||_||_||_dS(sáCreate the generator for message flattening.

        outfp is the output file-like object for writing the message to.  It
        must have a write() method.

        Optional mangle_from_ is a flag that, when True (the default), escapes
        From_ lines in the body of the message by putting a `>' in front of
        them.

        Optional maxheaderlen specifies the longest length for a non-continued
        header.  When a header line is longer (in characters, with tabs
        expanded to 8 spaces) than maxheaderlen, the header will split as
        defined in the Header class.  Set maxheaderlen to zero to disable
        header wrapping.  The default is 78, as recommended (but not required)
        by RFC 2822.
        N(toutfptselft_fptmangle_from_t
_mangle_from_tmaxheaderlent
_maxheaderlen(RRRR((Rt__init__)s		cCs|ii|ƒdS(N(RR
twriteR(RR((RR>scCsY|oA|iƒ}|pdtitiƒƒ}n|i|IJn|i|ƒdS(sìPrint the message object tree rooted at msg to the output file
        specified when the Generator instance was created.

        unixfrom is a flag that forces the printing of a Unix From_ delimiter
        before the first object in the message tree.  If the original message
        has no From_ delimiter, a `standard' one is crafted.  By default, this
        is False to inhibit the printing of any From_ delimiter.

        Note that for subobjects, no From_ line is printed.
        sFrom nobody N(	tunixfromtmsgtget_unixfromtufromttimetctimeRR
t_write(RRRR((RtflattenBs
cCs'tidtdƒ|i||ƒdS(Ns$__call__() deprecated; use flatten()i(twarningstwarntDeprecationWarningRRRR(RRR((Rt__call__Us	
cCs|i||i|iƒS(s1Clone this generator with the exact same options.N(Rt	__class__tfpRR(RR!((RtcloneZscCs‹|i}z!tƒ|_}|i|ƒWd||_Xt|ddƒ}|djo|i
|ƒn||ƒ|ii|iƒƒdS(Nt_write_headers(
RR
toldfptStringIOtsfpt	_dispatchRtgetattrtNonetmethR#Rtgetvalue(RRR$R&R*((RRbs	


cCs°|iƒ}|iƒ}ti||fƒiddƒ}t	|d|dƒ}|djoF|iddƒ}t	|d|dƒ}|djo
|i}q¢n||ƒdS(Nt-Rt_handle_(Rtget_content_maintypetmaintget_content_subtypetsubt
UNDERSCOREtjointreplacetspecificR(RR)R*tgenerict
_writeBody(RRR1R6R5R*R/((RR'}s!

cCsÍx¿|iƒD]±\}}|id|I|idjo|i|IJq
t|tƒo|i|i	ƒIJq
t
|ƒo|i|IJq
|it|d|id|ddƒi	ƒIJq
W|iJdS(Ns%s:it
maxlinelentheader_nametcontinuation_wss	(RtitemsthtvRR
RRtHeadertencodeR	(RRR<R=((RR#‘s

cCs|iƒ}|djodSnt|tƒptdt|ƒƒ‚n|i	ot
id|ƒ}n|ii
|ƒdS(Nsstring payload expected: %ss>From (Rtget_payloadtpayloadR)Rt
basestringt	TypeErrorttypeRRtfcreR1R
R(RRRA((Rt_handle_text®s

c
CsÝg}|iƒ}|djo
g}nFt|tƒo|ii	|ƒdSnt|t
ƒp
|g}nxL|D]D}tƒ}|i|ƒ}|i|dtƒ|i|iƒƒquWti|ƒ}|idt|ƒƒ}	|iƒ|	jo|i|	ƒn|idj	o|i|iIJn|id|	IJ|o|ii	|idƒƒnx/|D]'}|id|	IJ|ii	|ƒqhW|ii	d|	dƒ|idj	o|iJ|ii	|iƒndS(NRtfailobjs--is
--(tmsgtextsRR@tsubpartsR)RRBRR
RtlisttpartR%RR"tgRRtappendR+tNLR3talltexttget_boundaryt_make_boundarytboundarytset_boundarytpreambletpopt	body_parttepilogue(
RRRORLRHRIRRKRVRR((Rt_handle_multipart»s@


	cCsÃg}x|iƒD]}tƒ}|i|ƒ}|i	|dt
ƒ|iƒ}|i
dƒ}|o/|ddjo|iti|d ƒƒq|i|ƒqW|iiti|ƒƒdS(NRs
iÿÿÿÿt(tblocksRR@RKR%RRR"RLRRR+ttexttsplittlinesRMRNR3R
R(RRRZRLR[R]RRK((Rt_handle_message_delivery_statusòs
	cCsNtƒ}|i|ƒ}|i|idƒdtƒ|i	i
|iƒƒdS(NiR(R%RRR"RLRRR@RR
RR+(RRRLR((Rt_handle_messages	(t__name__t
__module__t__doc__RRRRRRR"RR'R#RFR7RXR^R_(((RR
s							7	sD[Non-text (%(type)s) part of message omitted, filename %(filename)s]tDecodedGeneratorcBs)tZdZeded„Zd„ZRS(s±Generator a text representation of a message.

    Like the Generator base class, except that non-text parts are substituted
    with a format string representing the part.
    iNcCs=ti||||ƒ|djo
t|_	n
||_	dS(sŒLike Generator.__init__() except that an additional optional
        argument is allowed.

        Walks through all subparts of a message.  If the subpart is of main
        type `text', then it prints the decoded payload of the subpart.

        Otherwise, fmt is a format string that is used instead of the message
        payload.  fmt is expanded with the following keywords (in
        %(keyword)s format):

        type       : Full MIME type of the non-text part
        maintype   : Main MIME type of the non-text part
        subtype    : Sub-MIME type of the non-text part
        filename   : Filename of the non-text part
        description: Description associated with the non-text part
        encoding   : Content transfer encoding of the non-text part

        The default value for fmt is None, meaning

        [Non-text (%(type)s) part of message omitted, filename %(filename)s]
        N(
R
RRRRRtfmtR)t_FMTt_fmt(RRRRRd((RRs


cCsÙxÒ|iƒD]Ä}|iƒ}|djo||idtƒIJq
|djoq
||ihd|i	ƒ<d|iƒ<d|i
ƒ<d|idƒ<d	|id
dƒ<d|id
dƒ<IJq
WdS(NR[tdecodet	multipartRDtmaintypetsubtypetfilenames
[no filename]tdescriptionsContent-Descriptions[no description]tencodingsContent-Transfer-Encodings
[no encoding](
RtwalkRKR.RiRR@RRftget_content_typeR0tget_filenametget(RRRKRi((RR'7s


Y(R`RaRbRR)RR'(((RRcsis%%0%ddcCsµtitiƒ}ddt|d}|djo|Sn|}d}xeto]ti
dti|ƒdtiƒ}|i|ƒpPn|dt|ƒ}|d7}qLW|S(	Nt=is==is^--s(--)?$t.i(trandomt	randrangetsystmaxintttokenRfRRR[R)tbtcounterRtretcompiletescapet	MULTILINEtcretsearchR(R[RyRxRRRRz((RRQQs
&(RbR{RvRRtRt	cStringIOR%temail.HeaderR>R2RNR|R~RER	R
ReRctlentreprRwt_widthRfR)RQ(RER…RNR2R
R%RtR	R>RvR{RfRRReRQRc((Rt?s"					

	
ô9


Anon7 - 2021