Critics have remarked that those four worthies were truly peerless throughout the ages; yet the present falls short of the pastβ€”the ancients favored unadorned simplicity, whereas the moderns prefer refined elegance. Styles of substance and ornament rise and fall in succession, shifting with the changing mores of the times; such evolution is simply the natural order of things. The ideal lies in honoring antiquity without clashing with the present, and embracing modernity without succumbing to its flawsβ€”embodying that perfect balance of substance and refinement that defines the true gentleman. There is surely no need to abandon a carved palace in favor of a cave dwelling, or to trade a jade carriage for a primitive cart with solid wooden wheels.🌌 SpectraShell

🌌 SpectraShell

Current path: lib64/python2.7/



⬆️ Go up: /lib64

πŸ“„ Viewing: htmllib.pyo

οΏ½
zfc@sοΏ½dZddlmZedddοΏ½[ddlZddlmZdd	gZd	ejfd
οΏ½οΏ½YZdej	fdοΏ½οΏ½YZ
edοΏ½Ze
d
krοΏ½eοΏ½ndS(svHTML 2.0 parser.

See the HTML 2.0 specification:
http://www.w3.org/hypertext/WWW/MarkUp/html-spec/html-spec_toc.html
iοΏ½οΏ½οΏ½οΏ½(twarnpy3ks1the htmllib module has been removed in Python 3.0t
stackleveliN(tAS_ISt
HTMLParsertHTMLParseErrorcBseZdZRS(s3Error raised when an HTML document can't be parsed.(t__name__t
__module__t__doc__(((s/usr/lib64/python2.7/htmllib.pyRscBs3eZdZddlmZddοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½Z	d	οΏ½Z
d
οΏ½ZdοΏ½ZdοΏ½Z
d
οΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½ZdοΏ½Z d οΏ½Z!d!οΏ½Z"d"οΏ½Z#d#οΏ½Z$d$οΏ½Z%d%οΏ½Z&d&οΏ½Z'd'οΏ½Z(d(οΏ½Z)d)οΏ½Z*d*οΏ½Z+d+οΏ½Z,d,οΏ½Z-d-οΏ½Z.d.οΏ½Z/d/οΏ½Z0d0οΏ½Z1d1οΏ½Z2d2οΏ½Z3d3οΏ½Z4d4οΏ½Z5d5οΏ½Z6d6οΏ½Z7d7οΏ½Z8d8οΏ½Z9d9οΏ½Z:d:οΏ½Z;d;οΏ½Z<d<οΏ½Z=d=οΏ½Z>dd>οΏ½Z?d?οΏ½Z@d@οΏ½ZAdAοΏ½ZBdBοΏ½ZCdCοΏ½ZDdDοΏ½ZEdEοΏ½ZFdFοΏ½ZGdGοΏ½ZHdHοΏ½ZIdIοΏ½ZJdJοΏ½ZKdKοΏ½ZLdLοΏ½ZMdMοΏ½ZNdNοΏ½ZOdOοΏ½ZPdPοΏ½ZQdQοΏ½ZRdRοΏ½ZSdSοΏ½ZTdTοΏ½ZUdUοΏ½ZVdVοΏ½ZWdWοΏ½ZXdXοΏ½ZYdYοΏ½ZZdZοΏ½Z[RS([sοΏ½This is the basic HTML parser class.

    It supports all entity names required by the XHTML 1.0 Recommendation.
    It also defines handlers for all HTML 2.0 and many HTML 3.0 and 3.2
    elements.

    iοΏ½οΏ½οΏ½οΏ½(t
entitydefsicCs tjj||οΏ½||_dS(sοΏ½Creates an instance of the HTMLParser class.

        The formatter parameter is the formatter instance associated with
        the parser.

        N(tsgmllibt
SGMLParsert__init__t	formatter(tselfRtverbose((s/usr/lib64/python2.7/htmllib.pyR"scCst|οΏ½οΏ½dS(N(R(R
tmessage((s/usr/lib64/python2.7/htmllib.pyterror,scCs\tjj|οΏ½d|_d|_d|_d|_d|_g|_	d|_
g|_dS(Ni(R	R
tresettNonetsavedatatisindexttitletbasetanchort
anchorlisttnofillt
list_stack(R
((s/usr/lib64/python2.7/htmllib.pyR/s							cCsR|jdk	r"|j||_n,|jr>|jj|οΏ½n|jj|οΏ½dS(N(RRRRtadd_literal_datatadd_flowing_data(R
tdata((s/usr/lib64/python2.7/htmllib.pythandle_data?s
	cCs
d|_dS(sοΏ½Begins saving character data in a buffer instead of sending it
        to the formatter object.

        Retrieve the stored data via the save_end() method.  Use of the
        save_bgn() / save_end() pair may not be nested.

        tN(R(R
((s/usr/lib64/python2.7/htmllib.pytsave_bgnJscCs7|j}d|_|js3dj|jοΏ½οΏ½}n|S(sHEnds buffering character data and returns all data saved since
        the preceding call to the save_bgn() method.

        If the nofill flag is false, whitespace is collapsed to single
        spaces.  A call to this method without a preceding call to the
        save_bgn() method will raise a TypeError exception.

        t N(RRRtjointsplit(R
R((s/usr/lib64/python2.7/htmllib.pytsave_endTs
				cCs)||_|jr%|jj|οΏ½ndS(s}This method is called at the start of an anchor region.

        The arguments correspond to the attributes of the <A> tag with
        the same names.  The default implementation maintains a list of
        hyperlinks (defined by the HREF attribute for <A> tags) within
        the document.  The list of hyperlinks is available as the data
        attribute anchorlist.

        N(RRtappend(R
threftnamettype((s/usr/lib64/python2.7/htmllib.pyt
anchor_bgnes
		cCs3|jr/|jdt|jοΏ½οΏ½d|_ndS(sοΏ½This method is called at the end of an anchor region.

        The default implementation adds a textual footnote marker using an
        index into the list of hyperlinks created by the anchor_bgn()method.

        s[%d]N(RRtlenRR(R
((s/usr/lib64/python2.7/htmllib.pyt
anchor_endss	cGs|j|οΏ½dS(sοΏ½This method is called to handle images.

        The default implementation simply passes the alt value to the
        handle_data() method.

        N(R(R
tsrctalttargs((s/usr/lib64/python2.7/htmllib.pythandle_imageοΏ½scCsdS(N((R
tattrs((s/usr/lib64/python2.7/htmllib.pyt
start_htmlοΏ½RcCsdS(N((R
((s/usr/lib64/python2.7/htmllib.pytend_htmlοΏ½RcCsdS(N((R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_headοΏ½RcCsdS(N((R
((s/usr/lib64/python2.7/htmllib.pytend_headοΏ½RcCsdS(N((R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_bodyοΏ½RcCsdS(N((R
((s/usr/lib64/python2.7/htmllib.pytend_bodyοΏ½RcCs|jοΏ½dS(N(R (R
R0((s/usr/lib64/python2.7/htmllib.pytstart_titleοΏ½scCs|jοΏ½|_dS(N(R$R(R
((s/usr/lib64/python2.7/htmllib.pyt	end_titleοΏ½scCs3x,|D]$\}}|dkr||_qqWdS(NR&(R(R
R0tatv((s/usr/lib64/python2.7/htmllib.pytdo_baseοΏ½scCs
d|_dS(Ni(R(R
R0((s/usr/lib64/python2.7/htmllib.pyt
do_isindexοΏ½scCsdS(N((R
R0((s/usr/lib64/python2.7/htmllib.pytdo_linkοΏ½scCsdS(N((R
R0((s/usr/lib64/python2.7/htmllib.pytdo_metaοΏ½scCsdS(N((R
R0((s/usr/lib64/python2.7/htmllib.pyt	do_nextidοΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith1i(R@iii(Rt
end_paragrapht	push_font(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h1οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRAtpop_font(R
((s/usr/lib64/python2.7/htmllib.pytend_h1οΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith2i(RFiii(RRARB(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h2οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_h2οΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith3i(RIiii(RRARB(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h3οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_h3οΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith4i(RLiii(RRARB(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h4οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_h4οΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith5i(ROiii(RRARB(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h5οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_h5οΏ½scCs$|jjdοΏ½|jjdοΏ½dS(Nith6i(RRiii(RRARB(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_h6οΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_h6οΏ½scCs|jjdοΏ½dS(Ni(RRA(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_pοΏ½scCs@|jjdοΏ½|jjtttdfοΏ½|jd|_dS(Ni(RRARBRR(R
R0((s/usr/lib64/python2.7/htmllib.pyt	start_preοΏ½scCs:|jjdοΏ½|jjοΏ½td|jdοΏ½|_dS(Nii(RRARDtmaxR(R
((s/usr/lib64/python2.7/htmllib.pytend_preοΏ½s
cCs|j|οΏ½|jdοΏ½dS(Ntxmp(RVt
setliteral(R
R0((s/usr/lib64/python2.7/htmllib.pyt	start_xmpοΏ½s
cCs|jοΏ½dS(N(RX(R
((s/usr/lib64/python2.7/htmllib.pytend_xmpοΏ½scCs|j|οΏ½|jdοΏ½dS(Ntlisting(RVRZ(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_listingοΏ½s
cCs|jοΏ½dS(N(RX(R
((s/usr/lib64/python2.7/htmllib.pytend_listingοΏ½scCs0|jjdοΏ½|jjtdttfοΏ½dS(Nii(RRARBR(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_addressοΏ½scCs!|jjdοΏ½|jjοΏ½dS(Ni(RRARD(R
((s/usr/lib64/python2.7/htmllib.pytend_addressscCs$|jjdοΏ½|jjdοΏ½dS(Nit
blockquote(RRAtpush_margin(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_blockquotescCs!|jjdοΏ½|jjοΏ½dS(Ni(RRAt
pop_margin(R
((s/usr/lib64/python2.7/htmllib.pytend_blockquote
scCsA|jj|jοΏ½|jjdοΏ½|jjdddgοΏ½dS(Ntult*i(RRARRcR%(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_ulscCs;|jr|jd=n|jj|jοΏ½|jjοΏ½dS(NiοΏ½οΏ½οΏ½οΏ½(RRRARe(R
((s/usr/lib64/python2.7/htmllib.pytend_uls	
cCsk|jjdοΏ½|jrH|jd\}}}}|d|d<}nd\}}|jj||οΏ½dS(NiiοΏ½οΏ½οΏ½οΏ½iiRh(Rhi(RRARtadd_label_data(R
R0tdummytlabeltcounterttop((s/usr/lib64/python2.7/htmllib.pytdo_lis	cCsοΏ½|jj|jοΏ½|jjdοΏ½d}xH|D]@\}}|dkr1t|οΏ½dkrh|d}n|}q1q1W|jjd|dgοΏ½dS(Ntols1.R(it.i(RRARRcR*R%(R
R0RmR9R:((s/usr/lib64/python2.7/htmllib.pytstart_ol#s

cCs;|jr|jd=n|jj|jοΏ½|jjοΏ½dS(NiοΏ½οΏ½οΏ½οΏ½(RRRARe(R
((s/usr/lib64/python2.7/htmllib.pytend_ol-s	
cCs|j|οΏ½dS(N(Ri(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_menu2scCs|jοΏ½dS(N(Rj(R
((s/usr/lib64/python2.7/htmllib.pytend_menu5scCs|j|οΏ½dS(N(Ri(R
R0((s/usr/lib64/python2.7/htmllib.pyt	start_dir8scCs|jοΏ½dS(N(Rj(R
((s/usr/lib64/python2.7/htmllib.pytend_dir;scCs-|jjdοΏ½|jjdddgοΏ½dS(NitdlRi(RRARR%(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_dl>scCs'|jdοΏ½|jr#|jd=ndS(NiiοΏ½οΏ½οΏ½οΏ½(tddpopR(R
((s/usr/lib64/python2.7/htmllib.pytend_dlBs
	cCs|jοΏ½dS(N(R{(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_dtFscCs7|jοΏ½|jjdοΏ½|jjdddgοΏ½dS(NtddRi(R{RRcRR%(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_ddIs
cCsQ|jj|οΏ½|jrM|jdddkrM|jd=|jjοΏ½qMndS(NiοΏ½οΏ½οΏ½οΏ½iR~(RRARRe(R
tbl((s/usr/lib64/python2.7/htmllib.pyR{Ns
	
cCs|j|οΏ½dS(N(tstart_i(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_citeYRcCs|jοΏ½dS(N(tend_i(R
((s/usr/lib64/python2.7/htmllib.pytend_citeZRcCs|j|οΏ½dS(N(tstart_tt(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_code\RcCs|jοΏ½dS(N(tend_tt(R
((s/usr/lib64/python2.7/htmllib.pytend_code]RcCs|j|οΏ½dS(N(RοΏ½(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_em_RcCs|jοΏ½dS(N(RοΏ½(R
((s/usr/lib64/python2.7/htmllib.pytend_em`RcCs|j|οΏ½dS(N(RοΏ½(R
R0((s/usr/lib64/python2.7/htmllib.pyt	start_kbdbRcCs|jοΏ½dS(N(RοΏ½(R
((s/usr/lib64/python2.7/htmllib.pytend_kbdcRcCs|j|οΏ½dS(N(RοΏ½(R
R0((s/usr/lib64/python2.7/htmllib.pyt
start_sampeRcCs|jοΏ½dS(N(RοΏ½(R
((s/usr/lib64/python2.7/htmllib.pytend_sampfRcCs|j|οΏ½dS(N(tstart_b(R
R0((s/usr/lib64/python2.7/htmllib.pytstart_stronghRcCs|jοΏ½dS(N(tend_b(R
((s/usr/lib64/python2.7/htmllib.pyt
end_strongiRcCs|j|οΏ½dS(N(RοΏ½(R
R0((s/usr/lib64/python2.7/htmllib.pyt	start_varkRcCs|jοΏ½dS(N(RοΏ½(R
((s/usr/lib64/python2.7/htmllib.pytend_varlRcCs |jjtdttfοΏ½dS(Ni(RRBR(R
R0((s/usr/lib64/python2.7/htmllib.pyRοΏ½pscCs|jjοΏ½dS(N(RRD(R
((s/usr/lib64/python2.7/htmllib.pyRοΏ½rscCs |jjttdtfοΏ½dS(Ni(RRBR(R
R0((s/usr/lib64/python2.7/htmllib.pyRοΏ½uscCs|jjοΏ½dS(N(RRD(R
((s/usr/lib64/python2.7/htmllib.pyRοΏ½wscCs |jjtttdfοΏ½dS(Ni(RRBR(R
R0((s/usr/lib64/python2.7/htmllib.pyRοΏ½zscCs|jjοΏ½dS(N(RRD(R
((s/usr/lib64/python2.7/htmllib.pyRοΏ½|scCsοΏ½d}d}d}xe|D]]\}}|jοΏ½}|dkrF|}n|dkr[|}n|dkr|jοΏ½}qqW|j|||οΏ½dS(NRR&R'R((tstriptlowerR)(R
R0R&R'R(tattrnametvalue((s/usr/lib64/python2.7/htmllib.pytstart_as		cCs|jοΏ½dS(N(R+(R
((s/usr/lib64/python2.7/htmllib.pytend_aοΏ½scCs|jjοΏ½dS(N(Rtadd_line_break(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_brοΏ½scCs|jjοΏ½dS(N(Rtadd_hor_rule(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_hrοΏ½sc
Csd}d}d}d}d}d}xοΏ½|D]οΏ½\}}	|dkrL|	}n|dkra|	}n|dkrv|	}n|dkrοΏ½|	}n|dkrοΏ½yt|	οΏ½}WqοΏ½tk
rοΏ½qοΏ½Xn|d	kr+yt|	οΏ½}WqοΏ½tk
rοΏ½qοΏ½Xq+q+W|j||||||οΏ½dS(
NRs(image)italignR-tismapR,twidththeight(tintt
ValueErrorR/(
R
R0RοΏ½R-RοΏ½R,RοΏ½RοΏ½RοΏ½RοΏ½((s/usr/lib64/python2.7/htmllib.pytdo_imgοΏ½s4				

cCs|j|οΏ½|jοΏ½dS(N(RVt
setnomoretags(R
R0((s/usr/lib64/python2.7/htmllib.pytdo_plaintextοΏ½s
cCsdS(N((R
ttagR0((s/usr/lib64/python2.7/htmllib.pytunknown_starttagοΏ½scCsdS(N((R
RοΏ½((s/usr/lib64/python2.7/htmllib.pytunknown_endtagοΏ½s(\RRRthtmlentitydefsRRRRRR R$R)R+R/R1R2R3R4R5R6R7R8R;R<R=R>R?RCRERGRHRJRKRMRNRPRQRSRTRURVRXR[R\R^R_R`RaRdRfRiRjRpRsRtRuRvRwRxRzR|R}RR{RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½RοΏ½(((s/usr/lib64/python2.7/htmllib.pyRsοΏ½
				
			
																																										
																																				c	CsAddl}ddl}|s.|jd}n|oA|ddk}|rT|d=n|rg|d}nd}|dkrοΏ½|j}nCyt|dοΏ½}Wn-tk
rοΏ½}|GdG|GH|jdοΏ½nX|jοΏ½}||jk	rοΏ½|jοΏ½n|r|j	οΏ½}n|j
|jοΏ½οΏ½}t|οΏ½}|j
|οΏ½|jοΏ½dS(	NiοΏ½οΏ½οΏ½οΏ½iis-ss	test.htmlt-trt:(tsysRtargvtstdintopentIOErrortexittreadtcloset
NullFormattertAbstractFormattert
DumbWriterRtfeed(	R.RοΏ½RtsilenttfiletftmsgRtp((s/usr/lib64/python2.7/htmllib.pyttestοΏ½s2




t__main__(RtwarningsRR	RRt__all__tSGMLParseErrorRR
RRRοΏ½R(((s/usr/lib64/python2.7/htmllib.pyt<module>s	οΏ½οΏ½'


πŸ“