/opt/cloudlinux/venv/lib/python3.11/site-packages/lxml/__pycache__
NameSizeModeActions
builder.cpython-311.pyc81710644editdlrm
cssselect.cpython-311.pyc50660644editdlrm
doctestcompare.cpython-311.pyc272030644editdlrm
ElementInclude.cpython-311.pyc68120644editdlrm
pyclasslookup.cpython-311.pyc2860644editdlrm
sax.cpython-311.pyc141310644editdlrm
usedoctest.cpython-311.pyc5260644editdlrm
_elementpath.cpython-311.pyc120740644editdlrm
__init__.cpython-311.pyc10820644editdlrm
Edit: /opt/cloudlinux/venv/lib/python3.11/site-packages/lxml/__pycache__/builder.cpython-311.pyc (8171B)
§ Ù•®+`ª¢ãó°—dZddlmZddlmZejZddlm Z  e n #e $re Z YnwxYw e n #e $re Z YnwxYwGd„de¦«Ze¦«ZdS)z9 The ``E`` Element factory for generating XML documents. é)Úabsolute_importN©Úpartialcó*—eZdZdZ dd„Zd„Zd„ZdS)Ú ElementMakerac Element generator factory. Unlike the ordinary Element factory, the E factory allows you to pass in more than just a tag and some optional attributes; you can also pass in text and other elements. The text is added as either text or tail attributes, and elements are inserted at the right spot. Some small examples:: >>> from lxml import etree as ET >>> from lxml.builder import E >>> ET.tostring(E("tag")) '' >>> ET.tostring(E("tag", "text")) 'text' >>> ET.tostring(E("tag", "text", key="value")) 'text' >>> ET.tostring(E("tag", E("subtag", "text"), "tail")) 'texttail' For simple tags, the factory also allows you to write ``E.tag(...)`` instead of ``E('tag', ...)``:: >>> ET.tostring(E.tag()) '' >>> ET.tostring(E.tag("text")) 'text' >>> ET.tostring(E.tag(E.subtag("text"), "tail")) 'texttail' Here's a somewhat larger example; this shows how to generate HTML documents, using a mix of prepared factory functions for inline elements, nested ``E.tag`` calls, and embedded XHTML fragments:: # some common inline elements A = E.a I = E.i B = E.b def CLASS(v): # helper function, 'class' is a reserved word return {'class': v} page = ( E.html( E.head( E.title("This is a sample document") ), E.body( E.h1("Hello!", CLASS("title")), E.p("This is a paragraph with ", B("bold"), " text in it!"), E.p("This is another paragraph, with a ", A("link", href="http://www.python.org"), "."), E.p("Here are some reserved characters: ."), ET.XML("

And finally, here is an embedded XHTML fragment.

"), ) ) ) print ET.tostring(page) Here's a prettyprinted version of the output from the above script:: This is a sample document

Hello!

This is a paragraph with bold text in it!

This is another paragraph, with link.

Here are some reserved characters: <spam&egg>.

And finally, here is an embedded XHTML fragment.

For namespace support, you can pass a namespace map (``nsmap``) and/or a specific target ``namespace`` to the ElementMaker class:: >>> E = ElementMaker(namespace="http://my.ns/") >>> print(ET.tostring( E.test )) >>> E = ElementMaker(namespace="http://my.ns/", nsmap={'p':'http://my.ns/'}) >>> print(ET.tostring( E.test )) Ncó ‡—|�d|zdznd|_|rt|¦«nd|_|�t|¦«sJ‚|�|n tj|_‰rt‰¦«niŠd„}d„}t‰vr |‰t<t‰vr |‰t<tj ‰vr|‰tj <ˆfd„}t‰vr |‰t<‰|_ dS)NÚ{Ú}có~— |d}|jpd|z|_dS#t$r|jpd|z|_YdSwxYw)NéÿÿÿÿÚ)ÚtailÚ IndexErrorÚtext)ÚelemÚitemÚ last_childs ú`/builddir/build/BUILD/cloudlinux-venv-1.0.12/venv/lib64/python3.11/site-packages/lxml/builder.pyÚadd_textz'ElementMaker.__init__..add_text s_€ð AØ! "œX� ð$.¤?Ð#8°b¸DÑ"@� ”��øõð 5ð 5ð 5Ø!œY˜_¨"°Ñ4�” � � � ð 5øøøs ‚�<»<cóP—|jrtd|jz¦«‚||_dS)Nz.add_cdata¨s0€ØŒyð mÝ Ð!_ÐbfÔbkÑ!kÑlÔlÐl؈DŒIˆIˆIócóÄ•—|j}| ¦«D]B\}}t|t¦«r|||<Œ ‰t |¦«d|¦«||<ŒCdS©N)ÚattribÚitemsÚ isinstanceÚ basestringÚtype)rrrÚkÚvÚtypemaps €rÚadd_dictz'ElementMaker.__init__..add_dict´snø€Ø”[ˆFØŸ š ™ œ ð :ð :‘��1ݘa¥Ñ,Ô,ð:Ø !�F˜1‘I�Ià 0 ­¨Q©¬Ô 0°°qÑ 9Ô 9�F˜1‘I�Ið  :ð :r) Ú _namespaceÚdictÚ_nsmapÚcallableÚETÚElementÚ _makeelementÚstrÚunicodeÚCDATAÚ_typemap)Úselfr$Ú namespaceÚnsmapÚ makeelementrrr%s ` rÚ__init__zElementMaker.__init__•sø€à3<Ð3H˜#  ™/¨CÑ/Ð/ÈdˆŒØ%*Ð4•d˜5‘k”k�k°ˆŒ àÐ"¥h¨{Ñ&;Ô&;Ð"Ð"Ð;Ø+6Ð+B˜K˜KÍÌ ˆÔð$+Ð2•$�w‘-”-�-°ˆð Að Að Að ð ð õ �gÐ Ð Ø#ˆG•C‰LÝ ˜'Ð !Ð !Ø'ˆG•GÑ Ý Œ8˜7Ð "Ð "Ø )ˆG•B”HÑ ð :ð :ð :ð :ð :õ �wÐ Ð Ø$ˆG•D‰MàˆŒ ˆ ˆ rcó—|j}t|t¦«st|t¦«r|j}n|j�|ddkr |j|z}| ||j¬¦«}|r|t||¦«|D]û}t|¦«r |¦«}|  t|¦«¦«}|€‚tj |¦«r| |¦«Œit|¦«jD]}|  |¦«}|�n)Œt!dt|¦«j›d|›d�¦«‚|||¦«} | r,|  t| ¦«¦«|| ¦«Œü|S)Nrr )r3zbad argument type: ú(ú))r0rr-Ú_QNamerr&r,r(r'r)Úgetr!r*Ú iselementÚappendÚ__mro__Ú TypeErrorÚ__name__) r1ÚtagÚchildrenrr$rrÚtÚbasetyper#s rÚ__call__zElementMaker.__call__Ás¬€Ø”-ˆõ˜#�sÑ#Ô#ð (­ °3½Ñ(?Ô(?ð (à”(ˆCˆCØ Œ_Ð (¨S°¬V°sª]¨]Ø”/ CÑ'ˆCØ× Ò  ¨D¬KÐ Ñ8Ô8ˆØ ð (Ø ˆG•DŒM˜$ Ñ 'Ô 'Ð 'àð .ð .ˆDݘ‰~Œ~ð Ø�t‘v”v�Ø— ’ �D ™JœJÑ'Ô'ˆA؈yÝ”< Ñ%Ô%ðØ—K’K Ñ%Ô%Ð%ØÝ $ T¡ ¤ Ô 2ðAðA�HàŸ š  HÑ-Ô-�AØ�}ؘð%õ$˜)Ý%)¨$¡Z¤ZÔ%8Ð%8Ð%8¸$¸$¸$ð%@ñAôAðAà��$˜‘ ” ˆAØð .Ø$�— ’ �D ™GœGÑ$Ô$ T¨1Ñ-Ô-Ð-øàˆ rcó"—t||¦«Srr)r1r@s rÚ __getattr__zElementMaker.__getattr__äs€Ý�t˜SÑ!Ô!Ð!r)NNNN)r?Ú __module__Ú __qualname__Ú__doc__r5rDrF©rrrr<s]€€€€€ðVðVðp $Ø9=ð* ð* ð* ð* ðX!ð!ð!ðF"ð"ð"ð"ð"rr)rIÚ __future__rÚ lxml.etreeÚetreer*ÚQNamer9Ú functoolsrr Ú NameErrorr-r.ÚobjectrÚErJrrúrSsóððLðð'Ð&Ð&Ð&Ð&Ð&àÐÐÐÐÐØ Œ€àÐÐÐÐÐðØ€J€JøØðððØ€J€J€JðøøøðØ €G€GøØðððØ€G€G€Gðøøøði"ði"ði"ði"ði"�6ñi"ôi"ði"ðZ€L�N„N€€€s�  *©*®1±;º;