b374k
m1n1 1.01
Apache/2.2.15 (CentOS)
Linux obd60-6c49958d75-2q7cw 5.4.0-174-generic #193-Ubuntu SMP Thu Mar 7 14:29:28 UTC 2024 x86_64
uid=48(apache) gid=48(apache) groups=48(apache)
server ip : 104.21.65.202 | your ip : 10.244.126.0
safemode OFF
 >  / usr / lib64 / python2.6 /
Filename/usr/lib64/python2.6/DocXMLRPCServer.pyc
Size9.72 kb
Permissionrw-r--r--
Ownerapache
Create time23-Dec-2025 17:41
Last modified20-Jun-2019 19:45
Last accessed20-Jun-2019 19:45
Actionsedit | rename | delete | download (gzip)
Viewtext | code | image
Ñò
§ÚêLc@sÐdZddkZddkZddkZddkZddklZlZlZlZdei fd��YZ
ddd��YZ defd ��YZ d
ee fd ��YZ
d ee fd
��YZdS(sKSelf documenting XML-RPC Server.

This module can be used to create XML-RPC servers that
serve pydoc-style documentation in response to HTTP
GET requests. This documentation is dynamically generated
based on the functions and methods registered with the
server.

This module is built upon the pydoc and SimpleXMLRPCServer
modules.
iÿÿÿÿN(tSimpleXMLRPCServertSimpleXMLRPCRequestHandlertCGIXMLRPCRequestHandlertresolve_dotted_attributet
ServerHTMLDoccBsDeZdZdhhhd�Zdhhhdd�Zd�ZRS(s7Class used to generate pydoc HTML document for a servercCsÝ|p|i}g}d}tid�}x�|i||�} | pPn| i�\}
} |i||||
!��| i�\} }
}}}}|
o3|| �idd�}|id||f�ná|o1dt|�}|id||| �f�n©|o1dt|�}|id||| �f�nq|| | d!d jo#|i|i ||||��n6|o|id
|�n|i|i ||��| }q.|i|||��d i
|�S( s�Mark up some plain text, given a context of symbols to look for.
Each context dictionary maps object names to anchor names.isM\b((http|ftp)://\S+[\w/]|RFC[- ]?(\d+)|PEP[- ]?(\d+)|(self\.)?((?:\w|\.)+))\bt"s&quot;s<a href="%s">%s</a>s'http://www.rfc-editor.org/rfc/rfc%d.txts(http://www.python.org/dev/peps/pep-%04d/it(sself.<strong>%s</strong>t( tescapetretcompiletsearchtspantappendtgroupstreplacetinttnamelinktjoin(tselfttextRtfuncstclassestmethodstresultstheretpatterntmatchtstarttendtalltschemetrfctpeptselfdottnameturl((s'/usr/lib64/python2.6/DocXMLRPCServer.pytmarkups8!!# cCs�|o
|ipdd|}d} d|i|�|i|�f}
ti|�oGti|i�\} } }
}ti| d| |
|d|i�}nWti|�o@ti|�\} } }
}ti| | |
|d|i�}nd}t |t
�o&|dp|}|dpd}nt i |�}|
|| o|i
d| �}|i||i|||�}|od |}d
||fS( s;Produce HTML documentation for a function or method object.Rt-s$<a name="%s"><strong>%s</strong></a>it formatvalues(...)is'<font face="helvetica, arial">%s</font>s<dd><tt>%s</tt></dd>s<dl><dt>%s</dt>%s</dl>
(t__name__Rtinspecttismethodt
getargspectim_funct
formatargspecR't
isfunctiont
isinstancettupletpydoctgetdoctgreyR%t preformat(RtobjectR#tmodRRRtcltanchortnotettitletargstvarargstvarkwtdefaultstargspect docstringtdecltdoc((s'/usr/lib64/python2.6/DocXMLRPCServer.pyt
docroutineCs6c Csh}x6|i�D](\}}d|||<||||<qW|i|�}d|}|i|dd�}|i||i|�} | od| } |d| }g}
t|i��} x3| D]+\}}|
i|i||d|��qÃW||iddd t i
|
��}|S(
s1Produce HTML documentation for an XML-RPC server.s#-s)<big><big><strong>%s</strong></big></big>s#ffffffs#7799ees <tt>%s</tt>s
<p>%s</p>
RtMethodss#eeaa77( titemsRtheadingR%R4tsortedR
RCt
bigsectionR1R( Rt server_nametpackage_documentationRtfdicttkeytvaluetheadtresultRBtcontentst method_items((s'/usr/lib64/python2.6/DocXMLRPCServer.pyt docserverms&

 # N(R(t
__module__t__doc__tNoneR%RCRR(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyRs
))tXMLRPCDocGeneratorcBs;eZdZd�Zd�Zd�Zd�Zd�ZRS(s�Generates documentation for an XML-RPC server.

This class is designed as mix-in and should not
be constructed directly.
cCsd|_d|_d|_dS(NsXML-RPC Server DocumentationsGThis server exports the following methods through the XML-RPC protocol.(RItserver_documentationt server_title(R((s'/usr/lib64/python2.6/DocXMLRPCServer.pyt__init__�s  cCs
||_dS(s8Set the HTML title of the generated server documentationN(RX(RRX((s'/usr/lib64/python2.6/DocXMLRPCServer.pytset_server_title�scCs
||_dS(s7Set the name of the generated HTML server documentationN(RI(RRI((s'/usr/lib64/python2.6/DocXMLRPCServer.pytset_server_name�scCs
||_dS(s3Set the documentation string for the entire server.N(RW(RRW((s'/usr/lib64/python2.6/DocXMLRPCServer.pytset_server_documentation�scCs|h}x<|i�D].}||ijo|i|}nþ|idj oÜddg}t|id�o|ii|�|d<nt|id�o|ii|�|d<nt|�}|djo
|}q7t|id�p6yt|i|�}Wq"t j
o
|}q"Xq7|}ndp
t
d�|||<qWt �}|i |i
|i|�}|i|i|�S( sgenerate_html_documentation() => html documentation for the server

Generates HTML documentation for the server using introspection for
installed functions and instances that do not implement the
_dispatch method. Alternatively, instances can choose to implement
the _get_method_argstring(method_name) method to provide the
argument string used in the documentation and the
_methodHelp(method_name) method to provide the help text used
in the documentation.t_get_method_argstringit _methodHelpit _dispatchsACould not find method in self.functions and no instance installedN(NN(tsystem_listMethodsRtinstanceRUthasattrR]R^R0RtAttributeErrortAssertionErrorRRRRIRWtpageRX(RRt method_nametmethodt method_infot
documentert
documentation((s'/usr/lib64/python2.6/DocXMLRPCServer.pytgenerate_html_documentation¤s< 
  



  (R(RSRTRYRZR[R\Rk(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyRV�s     tDocXMLRPCRequestHandlercBseZdZd�ZRS(sèXML-RPC and documentation request handler class.

Handles all HTTP POST requests and attempts to decode them as
XML-RPC requests.

Handles all HTTP GET requests and interprets them as requests
for documentation.
cCs�|i�p|i�dS|ii�}|id�|idd�|idtt|���|i�|i i
|�|i i �|i i
d�dS(s}Handles the HTTP GET request.

Interpret all HTTP GET requests as requests for server
documentation.
NiÈs Content-types text/htmlsContent-lengthi(tis_rpc_path_validt
report_404tserverRkt
send_responset send_headertstrtlent end_headerstwfiletwritetflusht
connectiontshutdown(Rtresponse((s'/usr/lib64/python2.6/DocXMLRPCServer.pytdo_GETás




(R(RSRTR{(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyRl×stDocXMLRPCServercBs&eZdZededed�ZRS(s�XML-RPC and HTML documentation server.

Adds the ability to serve server documentation to the capabilities
of SimpleXMLRPCServer.
icCs0ti|||||||�ti|�dS(N(RRYRV(RtaddrtrequestHandlert logRequestst
allow_nonetencodingtbind_and_activate((s'/usr/lib64/python2.6/DocXMLRPCServer.pyRYÿs
N(R(RSRTRltFalseRUtTrueRY(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyR|÷s tDocCGIXMLRPCRequestHandlercBs eZdZd�Zd�ZRS(sJHandler for XML-RPC data and documentation requests passed through
CGIcCs5|i�}dGHdt|�GHHtii|�dS(s}Handles the HTTP GET request.

Interpret all HTTP GET requests as requests for server
documentation.
sContent-Type: text/htmlsContent-Length: %dN(RkRstsyststdoutRv(RRz((s'/usr/lib64/python2.6/DocXMLRPCServer.pyt
handle_get s
 cCsti|�ti|�dS(N(RRYRV(R((s'/usr/lib64/python2.6/DocXMLRPCServer.pyRYs
(R(RSRTR�RY(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyR�s ((RTR1R)R R�RRRRtHTMLDocRRVRlR|R�(((s'/usr/lib64/python2.6/DocXMLRPCServer.pyt<module> s    "oQ