ok

Mini Shell

Direktori : /proc/thread-self/root/proc/self/root/lib64/python2.7/
Upload File :
Current File : //proc/thread-self/root/proc/self/root/lib64/python2.7/xmlrpclib.pyo

�
zfc@s�dZddlZddlZddlZddlZddlTddlZddlZddlZyddl	Z	Wne
k
r�dZ	nXyeWne
k
r�dZnXyddlZWne
k
r�dZnXyejjdkZWne
k
r	dZnXejd�jd�Zejd�ZerCd	�Zn	d
�ZdZdXZdZZdZdZdZdZdZ dZ!dZ"dZ#dZ$dZ%dZ&dZ'de(fd��YZ)de)fd��YZ*de)fd��YZ+de)fd ��YZ,dd!l-m.Z.e.ej/Z0erBe1Z2Z3e4e0d"<ee0d#<nEd$d[d%��YZ3e3d�e0d"<e3d�e0d#<ee4fd&�Z2[.[0d'�Z5d(d\d)��YZ6d*�Z7d+�Z8ddl9Z9yddl:Z;Wne
k
r�ddl;Z;nXd,d]d-��YZ<d.�Z=e6e<fZ>es5e>e3fZ>ny"ddl?Z?e?j@ZAe?jBZCWn!eDe
fk
rzdZAZCnXyddl?Z?e?jEZFWneDe
fk
r�dZFnXy,dd/lGmHZHeIeHd0�s�e
�nWne
k
r�dZJnXd1d^d2��YZJd3d_d4��YZKd5d`d6��YZEd7dad8��YZBd9dbd:��YZLd;dcd<��YZMd=ddd>��YZNdd?�ZOddddd@�ZPddA�ZQdB�ZRdCdD�ZSdEe	r�e	jTneUfdF��YZVdGdedH��YZWdIdfdJ��YZXdKeXfdL��YZYdMdgdN��YZZeZZ[edOkr�eZdP�Z\e\GHeNe\�Z]e]j^dQdR�e]j_dSd�e]j_dTdU�yxe]�D]Z`e`GHq�WWq�e)k
r�ZadVGeaGHq�XndS(hs~
An XML-RPC client interface for Python.

The marshalling and response parser code can also be used to
implement XML-RPC servers.

Exported exceptions:

  Error          Base class for client errors
  ProtocolError  Indicates an HTTP protocol error
  ResponseError  Indicates a broken response package
  Fault          Indicates an XML-RPC fault package

Exported classes:

  ServerProxy    Represents a logical connection to an XML-RPC server

  MultiCall      Executor of boxcared xmlrpc requests
  Boolean        boolean wrapper to generate a "boolean" XML-RPC value
  DateTime       dateTime wrapper for an ISO 8601 string or time tuple or
                 localtime integer value to generate a "dateTime.iso8601"
                 XML-RPC value
  Binary         binary data wrapper

  SlowParser     Slow but safe standard parser (based on xmllib)
  Marshaller     Generate an XML-RPC params chunk from a Python data structure
  Unmarshaller   Unmarshal an XML-RPC response from incoming XML event message
  Transport      Handles an HTTP transaction to an XML-RPC server
  SafeTransport  Handles an HTTPS transaction to an XML-RPC server

Exported constants:

  True
  False

Exported functions:

  boolean        Convert any Python value to an XML-RPC boolean
  getparser      Create instance of the fastest available parser & attach
                 to an unmarshalling object
  dumps          Convert an argument tuple or a Fault instance to an XML-RPC
                 request (or response, if the methodresponse option is used).
  loads          Convert an XML-RPC packet to unmarshalled data plus a method
                 name (None if not present).
i����N(t*tboolis[�-�]cCs.tr*|r*||�r*t||�}n|S(N(tunicode(tdatatencodingtis8bit((s!/usr/lib64/python2.7/xmlrpclib.pyt_decode�scCs4||dd�}||dd�}||dd�S(Nt&s&amp;t<s&lt;t>s&gt;((tstreplace((s!/usr/lib64/python2.7/xmlrpclib.pytescape�scCs*y|jd�SWntk
r%|SXdS(Ntascii(tencodetUnicodeError(tstring((s!/usr/lib64/python2.7/xmlrpclib.pyt
_stringify�s
cCs|S(N((R((s!/usr/lib64/python2.7/xmlrpclib.pyR�ss1.0.1liiiD���i����i���ip���iԁ��iC���iB���i����i����i����tErrorcBseZdZd�ZRS(sBase class for client errors.cCs
t|�S(N(trepr(tself((s!/usr/lib64/python2.7/xmlrpclib.pyt__str__�s(t__name__t
__module__t__doc__R(((s!/usr/lib64/python2.7/xmlrpclib.pyR�st
ProtocolErrorcBs eZdZd�Zd�ZRS(s!Indicates an HTTP protocol error.cCs5tj|�||_||_||_||_dS(N(Rt__init__turlterrcodeterrmsgtheaders(RRRRR((s!/usr/lib64/python2.7/xmlrpclib.pyR�s

			cCsd|j|j|jfS(Ns<ProtocolError for %s: %s %s>(RRR(R((s!/usr/lib64/python2.7/xmlrpclib.pyt__repr__�s(RRRRR(((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	t
ResponseErrorcBseZdZRS(s$Indicates a broken response package.(RRR(((s!/usr/lib64/python2.7/xmlrpclib.pyR stFaultcBs eZdZd�Zd�ZRS(s#Indicates an XML-RPC fault package.cKs#tj|�||_||_dS(N(RRt	faultCodetfaultString(RR"R#textra((s!/usr/lib64/python2.7/xmlrpclib.pyRs
	cCsd|jt|j�fS(Ns<Fault %s: %s>(R"RR#(R((s!/usr/lib64/python2.7/xmlrpclib.pyRs(RRRRR(((s!/usr/lib64/python2.7/xmlrpclib.pyR!s	(tmodulestTruetFalsetBooleancBsGeZdZdd�Zd�Zd�Zd�Zd�Zd�ZRS(saBoolean-value wrapper.

        Use True or False to generate a "boolean" XML-RPC value.
        icCstj|�|_dS(N(toperatorttruthtvalue(RR+((s!/usr/lib64/python2.7/xmlrpclib.pyR3scCs|jd|j�dS(Ns%<value><boolean>%d</boolean></value>
(twriteR+(Rtout((s!/usr/lib64/python2.7/xmlrpclib.pyR6scCs+t|t�r|j}nt|j|�S(N(t
isinstanceR(R+tcmp(Rtother((s!/usr/lib64/python2.7/xmlrpclib.pyt__cmp__9scCs)|jrdt|�Sdt|�SdS(Ns<Boolean True at %x>s<Boolean False at %x>(R+tid(R((s!/usr/lib64/python2.7/xmlrpclib.pyR>s	cCs|jS(N(R+(R((s!/usr/lib64/python2.7/xmlrpclib.pyt__int__DscCs|jS(N(R+(R((s!/usr/lib64/python2.7/xmlrpclib.pyt__nonzero__Gs(	RRRRRR1RR3R4(((s!/usr/lib64/python2.7/xmlrpclib.pyR(-s				cCs|tj|�S(s.Convert any Python value to XML-RPC 'boolean'.(R)R*(R+t
_truefalse((s!/usr/lib64/python2.7/xmlrpclib.pytbooleanXscCs�trGt|tj�rGd|j|j|j|j|j|jfSnt|tt	j
f�s�|dkrzt	j	�}nt	j|�}nd|d S(Ns%04d%02d%02dT%02d:%02d:%02dii(tdatetimeR.tyeartmonthtdaythourtminutetsecondt	TupleTypettimetstruct_timet	localtime(R+((s!/usr/lib64/python2.7/xmlrpclib.pyt	_strftimekstDateTimecBs�eZdZdd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d	�Z
d
�Zd�Zd�Z
d
�Zd�Zd�ZRS(s�DateTime wrapper for an ISO 8601 string or time tuple or
    localtime integer value to generate 'dateTime.iso8601' XML-RPC
    value.
    icCs.t|t�r||_nt|�|_dS(N(R.t
StringTypeR+RB(RR+((s!/usr/lib64/python2.7/xmlrpclib.pyRscCs�t|t�r$|j}|j}n�trWt|tj�rW|j}|jd�}n�t|t�rx|j}|}nmt|d�r�|j�}|j�}nCt|d�r�|jj	p�t
|�}td|jj	|f��||fS(Ns%Y%m%dT%H:%M:%St	timetuplet	__class__sCan't compare %s and %s(R.RCR+R7tstrftimet
basestringthasattrRERFRttypet	TypeError(RR0R
tototype((s!/usr/lib64/python2.7/xmlrpclib.pytmake_comparable�s$				cCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__lt__�scCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__le__�scCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__gt__�scCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__ge__�scCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__eq__�scCs|j|�\}}||kS(N(RN(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyt__ne__�scCstj|jd�S(Ns%Y%m%dT%H:%M:%S(R?tstrptimeR+(R((s!/usr/lib64/python2.7/xmlrpclib.pyRE�scCs"|j|�\}}t||�S(N(RNR/(RR0R
RL((s!/usr/lib64/python2.7/xmlrpclib.pyR1�scCs|jS(N(R+(R((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCsdt|j�t|�fS(Ns<DateTime %s at %x>(RR+R2(R((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCs"t|�}tj|�|_dS(N(tstrRtstripR+(RR((s!/usr/lib64/python2.7/xmlrpclib.pytdecode�scCs.|jd�|j|j�|jd�dS(Ns<value><dateTime.iso8601>s</dateTime.iso8601></value>
(R,R+(RR-((s!/usr/lib64/python2.7/xmlrpclib.pyR�s
(RRRRRNRORPRQRRRSRTRER1RRRXR(((s!/usr/lib64/python2.7/xmlrpclib.pyRCys													cCst�}|j|�|S(N(RCRX(RR+((s!/usr/lib64/python2.7/xmlrpclib.pyt	_datetime�s	
cCs)tj|d�}tjt|�d �S(Ns%Y%m%dT%H:%M:%Si(R?RUR7ttuple(Rtt((s!/usr/lib64/python2.7/xmlrpclib.pyt_datetime_type�stBinarycBs>eZdZdd�Zd�Zd�Zd�Zd�ZRS(sWrapper for binary data.cCs
||_dS(N(R(RR((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCs
|jpdS(Nt(R(R((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCs+t|t�r|j}nt|j|�S(N(R.R]RR/(RR0((s!/usr/lib64/python2.7/xmlrpclib.pyR1�scCstj|�|_dS(N(tbase64tdecodestringR(RR((s!/usr/lib64/python2.7/xmlrpclib.pyRX�scCs:|jd�tjtj|j�|�|jd�dS(Ns<value><base64>
s</base64></value>
(R,R_RtStringIOR(RR-((s!/usr/lib64/python2.7/xmlrpclib.pyR�s
N(	RRRtNoneRRR1RXR(((s!/usr/lib64/python2.7/xmlrpclib.pyR]�s			cCst�}|j|�|S(N(R]RX(RR+((s!/usr/lib64/python2.7/xmlrpclib.pyt_binary�s	
(texpattParserCreatetExpatParsercBs#eZd�Zd�Zd�ZRS(cCsrtjdd�|_}||_|j|_|j|_|j	|_
d}|js^d}n|j|d�dS(Nsutf-8(
RdReRbt_parsert_targettstarttStartElementHandlertendtEndElementHandlerRtCharacterDataHandlertreturns_unicodetxml(RttargettparserR((s!/usr/lib64/python2.7/xmlrpclib.pyR"s			cCs|jj|d�dS(Ni(RgtParse(RR((s!/usr/lib64/python2.7/xmlrpclib.pytfeed-scCsAy
|j}Wntk
r nX|`|`|jdd�dS(NR^i(RgtAttributeErrorRhRr(RRq((s!/usr/lib64/python2.7/xmlrpclib.pytclose0s

(RRRRsRu(((s!/usr/lib64/python2.7/xmlrpclib.pyRf s		t
SlowParsercBseZdZd�ZRS(s/Default XML parser (based on xmllib.XMLParser).cCs�ddl}|jtjkr0|jft_n|j|_|j|_|j|_	|j|_
|j|_y|jj
|dd�Wn!tk
r�|jj
|�nXdS(Ni����taccept_utf8i(txmllibt	XMLParserRvt	__bases__Rot
handle_xmlRitunknown_starttagRthandle_datathandle_cdataRktunknown_endtagRRK(RRpRx((s!/usr/lib64/python2.7/xmlrpclib.pyR<s
(RRRR(((s!/usr/lib64/python2.7/xmlrpclib.pyRv9st
MarshallercBs7eZdZddd�ZiZd�Zd�Zd�Zeee	<d�Z
e
ee<erud�Z
e
ee<nd�Zeee<d	�Zeee<ed
�Zeee<er�ed�Zeee<nd�Zeee<eee<ed
�Zeee<er"d�Zeeej<nd�Z e ee!<RS(svGenerate an XML-RPC params chunk from a Python data structure.

    Create a Marshaller instance for each set of parameters, and use
    the "dumps" method to convert your data (represented as a tuple)
    to an XML-RPC params chunk.  To write a fault response, pass a
    Fault instance instead.  You may prefer to use the "dumps" module
    function for this purpose.
    icCs(i|_d|_||_||_dS(N(tmemoRbRRt
allow_none(RRR�((s!/usr/lib64/python2.7/xmlrpclib.pyRas			cCs�g}|j}|j}t|t�r_|d�|i|jd6|jd6|�|d�nF|d�x/|D]'}|d�|||�|d�qpW|d�tj|d	�}|S(
Ns<fault>
R"R#s	</fault>
s	<params>
s<param>
s	</param>
s
</params>
R^(tappendt_Marshaller__dumpR.R!R"R#Rtjoin(RtvaluesR-R,tdumptvtresult((s!/usr/lib64/python2.7/xmlrpclib.pytdumpsis"		







cCs�y|jt|�}Wn�tk
r�y|jWntdt|��nXxBt|�jD]1}||jj�kr_tdt|��q_q_W|jt}nX||||�dS(Nscannot marshal %s objects(tdispatchRJtKeyErrort__dict__RKt__mro__tkeystInstanceType(RR+R,tfttype_((s!/usr/lib64/python2.7/xmlrpclib.pyt__dump�s
cCs#|jstd�n|d�dS(Ns0cannot marshal None unless allow_none is enableds<value><nil/></value>(R�RK(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pytdump_nil�s	cCsL|tks|tkr$td�n|d�|t|��|d�dS(Nsint exceeds XML-RPC limitss<value><int>s</int></value>
(tMAXINTtMININTt
OverflowErrorRV(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pytdump_int�s

cCs.|d�||rdpd�|d�dS(Ns<value><boolean>t1t0s</boolean></value>
((RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pyt	dump_bool�s
cCsR|tks|tkr$td�n|d�|tt|���|d�dS(Nslong int exceeds XML-RPC limitss<value><int>s</int></value>
(R�R�R�RVtint(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pyt	dump_long�s

cCs(|d�|t|��|d�dS(Ns<value><double>s</double></value>
(R(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pytdump_double�s
cCs(|d�|||��|d�dS(Ns<value><string>s</string></value>
((RR+R,R((s!/usr/lib64/python2.7/xmlrpclib.pytdump_string�s
cCs7|d�|||�j|jd��|d�dS(Ns<value><string>txmlcharrefreplaces</string></value>
(RR(RR+R,R((s!/usr/lib64/python2.7/xmlrpclib.pytdump_unicode�s
cCs}t|�}||jkr'td�nd|j|<|j}|d�x|D]}|||�qNW|d�|j|=dS(Ns"cannot marshal recursive sequencess<value><array><data>
s</data></array></value>
(R2R�RKRbR�(RR+R,tiR�R�((s!/usr/lib64/python2.7/xmlrpclib.pyt
dump_array�s
	


cCst|�}||jkr'td�nd|j|<|j}|d�x�|j�D]�\}}|d�t|�tkr�||�}n?tr�t|�t	kr�||�j
|jd�}n	td�|d|�|||�|d�qTW|d�|j|=dS(	Ns%cannot marshal recursive dictionariess<value><struct>
s	<member>
R�sdictionary key must be strings<name>%s</name>
s
</member>
s</struct></value>
(R2R�RKRbR�titemsRJRDRtUnicodeTypeRR(RR+R,RR�R�tkR�((s!/usr/lib64/python2.7/xmlrpclib.pytdump_struct�s$
	

	

cCs(|d�|t|��|d�dS(Ns<value><dateTime.iso8601>s</dateTime.iso8601></value>
(RB(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pyt
dump_datetime�s
cCsE|jtkr.||_|j|�|`n|j|j|�dS(N(RFtWRAPPERSR,RR�R�(RR+R,((s!/usr/lib64/python2.7/xmlrpclib.pyt
dump_instance�s
	
	N("RRRRbRR�R�R�R�tNoneTypeR�tIntTypet_bool_is_builtinR�RR�tLongTypeR�t	FloatTypeRR�RDRR�R�R�R>tListTypeR�tDictTypeR7R�R�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyR�Ts>			
	
	
	
	


	


			tUnmarshallercBszeZdZdd�Zd�Zd�Zd�Zd�Zd�Ze	j
d�Zd	�ZiZ
d
�Zee
d<d�Zee
d
<d�Zee
d<ee
d<ee
d<d�Zee
d<d�Zee
d<ee
d<d�Zee
d<d�Zee
d<d�Zee
d<d�Zee
d<d�Zee
d <d!�Zee
d"<d#�Zee
d$<d%�Zee
d&<RS('sUnmarshal an XML-RPC response, based on incoming XML event
    messages (start, data, end).  Call close() to get the resulting
    data structure.

    Note that this reader is fairly tolerant, and gladly accepts bogus
    XML-RPC data without complaining (but not bogus XML).
    icCstd|_g|_g|_g|_t|_d|_d|_|jj	|_	||_
|rptrptd�ndS(Nsutf-8s$the datetime module is not available(
Rbt_typet_stackt_markst_dataR't_valuet_methodnamet	_encodingR�t
_use_datetimeR7t
ValueError(Rtuse_datetime((s!/usr/lib64/python2.7/xmlrpclib.pyRs								
cCsV|jdks|jr$t��n|jdkrIt|jd��nt|j�S(Ntfaulti(R�RbR�R R!R�RZ(R((s!/usr/lib64/python2.7/xmlrpclib.pyRus
cCs|jS(N(R�(R((s!/usr/lib64/python2.7/xmlrpclib.pyt
getmethodname#scCs
||_dS(N(R�(RRt
standalone((s!/usr/lib64/python2.7/xmlrpclib.pyRo)scCs{|dks|dkr4|jjt|j��ng|_|jrh||jkrhtd|��n|dk|_dS(Ntarraytstructsunknown tag %rR+(R�R�tlenR�R�R�R�R (Rttagtattrs((s!/usr/lib64/python2.7/xmlrpclib.pyRi-s	cCs|jj|�dS(N(R�R�(Rttext((s!/usr/lib64/python2.7/xmlrpclib.pyR6scCsBy|j|}Wntk
r$nX||||jd��SdS(NR^(R�R�R�(RR�R�R�((s!/usr/lib64/python2.7/xmlrpclib.pyRk9s

cCs6y|j|}Wntk
r$nX|||�SdS(N(R�R�(RR�RR�((s!/usr/lib64/python2.7/xmlrpclib.pytend_dispatchEs

cCs|jd�d|_dS(Ni(R�RbR�(RR((s!/usr/lib64/python2.7/xmlrpclib.pytend_nilSs
tnilcCsN|dkr|jt�n%|dkr8|jt�n	td�d|_dS(NR�R�sbad boolean valuei(R�R'R&RKR�(RR((s!/usr/lib64/python2.7/xmlrpclib.pytend_booleanXs	R6cCs |jt|��d|_dS(Ni(R�R�R�(RR((s!/usr/lib64/python2.7/xmlrpclib.pytend_intbsti4ti8R�cCs |jt|��d|_dS(Ni(R�tfloatR�(RR((s!/usr/lib64/python2.7/xmlrpclib.pyt
end_doubleistdoublecCs>|jrt||j�}n|jt|��d|_dS(Ni(R�RR�RR�(RR((s!/usr/lib64/python2.7/xmlrpclib.pyt
end_stringns	RtnamecCs3|jj�}|j|g|j|)d|_dS(Ni(R�tpopR�R�(RRtmark((s!/usr/lib64/python2.7/xmlrpclib.pyt	end_arrayvsR�cCs~|jj�}i}|j|}x<tdt|�d�D]"}||d|t||�<q;W|g|j|)d|_dS(Niii(R�R�R�trangeR�RR�(RRR�tdictR�R�((s!/usr/lib64/python2.7/xmlrpclib.pyt
end_struct}s
 R�cCs0t�}|j|�|j|�d|_dS(Ni(R]RXR�R�(RRR+((s!/usr/lib64/python2.7/xmlrpclib.pyt
end_base64�s	

R_cCs?t�}|j|�|jr.t|�}n|j|�dS(N(RCRXR�R\R�(RRR+((s!/usr/lib64/python2.7/xmlrpclib.pytend_dateTime�s
	
	sdateTime.iso8601cCs|jr|j|�ndS(N(R�R�(RR((s!/usr/lib64/python2.7/xmlrpclib.pyt	end_value�s	R+cCs
d|_dS(Ntparams(R�(RR((s!/usr/lib64/python2.7/xmlrpclib.pyt
end_params�sR�cCs
d|_dS(NR�(R�(RR((s!/usr/lib64/python2.7/xmlrpclib.pyt	end_fault�sR�cCs4|jrt||j�}n||_d|_dS(Nt
methodName(R�RR�R�(RR((s!/usr/lib64/python2.7/xmlrpclib.pytend_methodName�s		R�(RRRRRuR�RoRiRRR�RkR�R�R�R�R�R�R�R�R�R�R�R�R�R�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyR�sN
								
	
	


	
	

	
		
	
	
	
	
	
	t_MultiCallMethodcBs#eZd�Zd�Zd�ZRS(cCs||_||_dS(N(t_MultiCallMethod__call_listt_MultiCallMethod__name(Rt	call_listR�((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	cCst|jd|j|f�S(Ns%s.%s(R�R�R�(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyt__getattr__�scGs|jj|j|f�dS(N(R�R�R�(Rtargs((s!/usr/lib64/python2.7/xmlrpclib.pyt__call__�s(RRRR�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyR��s		tMultiCallIteratorcBs eZdZd�Zd�ZRS(saIterates over the results of a multicall. Exceptions are
    raised in response to xmlrpc faults.cCs
||_dS(N(tresults(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCsl|j|}t|�ti�kr?t|d|d��n)t|�tg�kr_|dStd�dS(NR"R#is#unexpected type in multicall result(R�RJR!R�(RR�titem((s!/usr/lib64/python2.7/xmlrpclib.pyt__getitem__�s
(RRRRR�(((s!/usr/lib64/python2.7/xmlrpclib.pyR��s	t	MultiCallcBs8eZdZd�Zd�ZeZd�Zd�ZRS(s~server -> an object used to boxcar method calls

    server should be a ServerProxy object.

    Methods can be added to the MultiCall using normal
    method call syntax e.g.:

    multicall = MultiCall(server_proxy)
    multicall.add(2,3)
    multicall.get_address("Guido")

    To execute the multicall, call the MultiCall object e.g.:

    add_result, address = multicall()
    cCs||_g|_dS(N(t_MultiCall__servert_MultiCall__call_list(Rtserver((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	cCsdt|�S(Ns<MultiCall at %x>(R2(R((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCst|j|�S(N(R�R�(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR��scCsTg}x2|jD]'\}}|ji|d6|d6�qWt|jjj|��S(NR�R�(R�R�R�R�tsystemt	multicall(Rtmarshalled_listR�R�((s!/usr/lib64/python2.7/xmlrpclib.pyR��s(RRRRRRR�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyR��s			cCs�|rtrtd�ntratra|r4t}nt}tttt|t	�}t|�}nEt
d|�}tr�t|�}n!tr�t|�}nt|�}||fS(s�getparser() -> parser, unmarshaller

    Create an instance of the fastest available parser, and attach it
    to an unmarshalling object.  Return both objects.
    s$the datetime module is not availableR�(
R7R�t
FastParsertFastUnmarshallerR\RYR&R'RcR!R�RfRv(R�t
mkdatetimeRpRq((s!/usr/lib64/python2.7/xmlrpclib.pyt	getparser�s
	cCst|t�rd}n|r0t|t�r0n|s?d}ntrTt|�}nt||�}|j|�}|dkr�dt|�}nd}|r�t|t�s�|j|d�}n|d|d|df}n|r�|d	|d
f}n|St	j
|d�S(s�data [,options] -> marshalled data

    Convert an argument tuple or a Fault instance to an XML-RPC
    request (or response, if the methodresponse option is used).

    In addition to the data object, the following options can be given
    as keyword arguments:

        methodname: the method name for a methodCall packet

        methodresponse: true to create a methodResponse packet.
        If this option is used with a tuple, the tuple must be
        a singleton (i.e. it can contain only one element).

        encoding: the packet encoding (default is UTF-8)

    All 8-bit strings in the data structure are assumed to use the
    packet encoding.  Unicode strings are automatically converted,
    where necessary.
    isutf-8s$<?xml version='1.0' encoding='%s'?>
s<?xml version='1.0'?>
R�s<methodCall>
<methodName>s</methodName>
s</methodCall>
s<methodResponse>
s</methodResponse>
R^(R.R!R>tFastMarshallerR�R�RVRDRRR�(R�t
methodnametmethodresponseRR�tmRt	xmlheader((s!/usr/lib64/python2.7/xmlrpclib.pyR�s8		cCsBtd|�\}}|j|�|j�|j�|j�fS(s�data -> unmarshalled data, method name

    Convert an XML-RPC packet to unmarshalled data plus a method
    name (None if not present).

    If the XML-RPC packet represents a fault condition, this function
    raises a Fault exception.
    R�(R�RsRuR�(RR�tptu((s!/usr/lib64/python2.7/xmlrpclib.pytloadsns	

cCsjtst�ntj�}tjddd|dd�}|j|�|j�|j�}|j�|S(shdata -> gzip encoded data

    Encode data using the gzip content encoding as described in RFC 1952
    tmodetwbtfileobjt
compressleveli(tgziptNotImplementedErrorRatGzipFileR,Rutgetvalue(RR�tgzftencoded((s!/usr/lib64/python2.7/xmlrpclib.pytgzip_encode�s	


i@cCs�tst�ntj|�}tjddd|�}y2|dkrT|j�}n|j|d�}Wntk
r�td��nX|j�|j�|dkr�t|�|kr�td��n|S(srgzip encoded data -> unencoded data

    Decode data using the gzip content encoding as described in RFC 1952
    R�trbRiisinvalid datas#max gzipped payload length exceeded(	RRRaRtreadtIOErrorR�RuR�(Rt
max_decodeR�Rtdecoded((s!/usr/lib64/python2.7/xmlrpclib.pytgzip_decode�s	


tGzipDecodedResponsecBs eZdZd�Zd�ZRS(sha file-like object to decode a response encoded with the gzip
    method, as described in RFC 1952.
    cCsJtst�ntj|j��|_tjj|ddd|j�dS(NR�R	R(RRRaR
tstringioRR(Rtresponse((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	cCs)ztjj|�Wd|jj�XdS(N(RRRuR(R((s!/usr/lib64/python2.7/xmlrpclib.pyRu�s(RRRRRu(((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	t_MethodcBs#eZd�Zd�Zd�ZRS(cCs||_||_dS(N(t
_Method__sendt
_Method__name(RtsendR�((s!/usr/lib64/python2.7/xmlrpclib.pyR�s	cCst|jd|j|f�S(Ns%s.%s(RRR(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR��scGs|j|j|�S(N(RR(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR��s(RRRR�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyR�s		t	TransportcBs�eZdZdeZeZdZdd�Z	dd�Z
dd�Zd�Zd�Z
d�Zd	�Zd
�Zd�Zd�Zd
�Zd�ZRS(s1Handles an HTTP transaction to an XML-RPC server.s'xmlrpclib.py/%s (by www.pythonware.com)icCs||_d|_g|_dS(N(NN(R�Rbt_connectiont_extra_headers(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR�s		cCs�x�dD]�}y|j||||�SWqtjk
rl}|sc|jtjtjtjfkr��q�qtjk
r�|r��q�qXqWdS(Nii(ii(	tsingle_requesttsocketterrorterrnot
ECONNRESETtECONNABORTEDtEPIPEthttplibt
BadStatusLine(Rthostthandlertrequest_bodytverboseR�te((s!/usr/lib64/python2.7/xmlrpclib.pytrequest�s
'	cCs|j|�}|r%|jd�ny{|j|||�|j||�|j|�|j||�|jdt�}|jdkr�||_	|j
|�SWn1tk
r��ntk
r�|j
��nX|jdd�r�|j�nt|||j|j|j��dS(Nit	bufferingi�scontent-lengthi(tmake_connectiontset_debugleveltsend_requestt	send_hosttsend_user_agenttsend_contenttgetresponseR&tstatusR%tparse_responseR!t	ExceptionRut	getheaderR
Rtreasontmsg(RR"R#R$R%thR((s!/usr/lib64/python2.7/xmlrpclib.pyRs.
	



cCstd|j�S(NR�(R�R�(R((s!/usr/lib64/python2.7/xmlrpclib.pyR�;scCs�i}t|t�r$|\}}nddl}|j|�\}}|r�ddl}|j|j|��}tjtj	|�d�}dd|fg}nd}|||fS(Ni����R^t
AuthorizationsBasic (R.R>turllibt	splituserR_tencodestringtunquoteRR�tsplitRb(RR"tx509R8tauthR_t
extra_headers((s!/usr/lib64/python2.7/xmlrpclib.pyt
get_host_infoIscCse|jr'||jdkr'|jdS|j|�\}|_}|tj|�f|_|jdS(Nii(RR@RR tHTTPConnection(RR"tchostR=((s!/usr/lib64/python2.7/xmlrpclib.pyR)ds
cCs/|j\}}|r+d|_|j�ndS(N(NN(RRbRu(RR"t
connection((s!/usr/lib64/python2.7/xmlrpclib.pyRuts	cCsL|jr8tr8|jd|dt�|jdd�n|jd|�dS(NtPOSTtskip_accept_encodingsAccept-EncodingR(taccept_gzip_encodingRt
putrequestR&t	putheader(RRCR#R$((s!/usr/lib64/python2.7/xmlrpclib.pyR+�scCs[|j}|rWt|t�r-|j�}nx'|D]\}}|j||�q4WndS(N(RR.R�R�RH(RRCR"R?tkeyR+((s!/usr/lib64/python2.7/xmlrpclib.pyR,�s	cCs|jd|j�dS(Ns
User-Agent(RHt
user_agent(RRC((s!/usr/lib64/python2.7/xmlrpclib.pyR-�scCs�|jdd�|jdk	rY|jt|�krYtrY|jdd�t|�}n|jdtt|���|j|�dS(NsContent-Typestext/xmlsContent-EncodingRsContent-Length(RHtencode_thresholdRbR�RRRVt
endheaders(RRCR$((s!/usr/lib64/python2.7/xmlrpclib.pyR.�scCs�t|d�r?|jdd�dkr6t|�}qE|}n|}|j�\}}xE|jd�}|ssPn|jr�dGt|�GHn|j|�qZW||k	r�|j�n|j�|j�S(NR3sContent-EncodingR^Risbody:(	RIR3RR�R
R%RRsRu(RRtstreamR�R�R((s!/usr/lib64/python2.7/xmlrpclib.pyR1�s"		

N(RRRt__version__RJR&RFRbRKRR'RR�R@R)RuR+R,R-R.R1(((s!/usr/lib64/python2.7/xmlrpclib.pyR�s 
'				
		
			t
SafeTransportcBs&eZdZddd�Zd�ZRS(s2Handles an HTTPS transaction to an XML-RPC server.icCs tj|d|�||_dS(NR�(RRtcontext(RR�RP((s!/usr/lib64/python2.7/xmlrpclib.pyR�scCs�|jr'||jdkr'|jdSy
tj}Wntk
rStd��nQX|j|�\}|_}|||dd|j|p�i�f|_|jdSdS(Niis-your version of httplib doesn't support HTTPSRP(	RR tHTTPSConnectionRtRR@RRbRP(RR"tHTTPSRBR=((s!/usr/lib64/python2.7/xmlrpclib.pyR)�s


*N(RRRRbRR)(((s!/usr/lib64/python2.7/xmlrpclib.pyRO�stServerProxycBs\eZdZddddddd�Zd�Zd�Zd�ZeZd�Z	d�Z
RS(	s�uri [,options] -> a logical connection to an XML-RPC server

    uri is the connection point on the server, given as
    scheme://host/target.

    The standard implementation always supports the "http" scheme.  If
    SSL socket support is available (Python 2.0), it also supports
    "https".

    If the target part and the slash preceding it are both omitted,
    "/RPC2" is assumed.

    The following options can be given as keyword arguments:

        transport: a transport factory
        encoding: the request encoding (default is UTF-8)

    All 8-bit strings passed to the server proxy are assumed to use
    the given encoding.
    ic
Cs�tr't|t�r'|jd�}nddl}|j|�\}	}|	d	kr`td�n|j|�\|_|_|js�d|_n|dkr�|	dkr�t
d|d|�}q�td|�}n||_||_
||_||_dS(
Ns
ISO-8859-1i����thttpthttpssunsupported XML-RPC protocols/RPC2R�RP(RTRU(RR.RR8t	splittypeRt	splithostt_ServerProxy__hostt_ServerProxy__handlerRbRORt_ServerProxy__transportt_ServerProxy__encodingt_ServerProxy__verboset_ServerProxy__allow_none(
Rturit	transportRR%R�R�RPR8RJ((s!/usr/lib64/python2.7/xmlrpclib.pyRs"				cCs|jj�dS(N(RZRu(R((s!/usr/lib64/python2.7/xmlrpclib.pyt__close5scCskt||d|jd|j�}|jj|j|j|d|j�}t|�dkrg|d}n|S(NRR�R%ii(	R�R[R]RZR'RXRYR\R�(RR�R�R'R((s!/usr/lib64/python2.7/xmlrpclib.pyt	__request8s	
cCsd|j|jfS(Ns<ServerProxy for %s%s>(RXRY(R((s!/usr/lib64/python2.7/xmlrpclib.pyRJscCst|j|�S(N(Rt_ServerProxy__request(RR�((s!/usr/lib64/python2.7/xmlrpclib.pyR�RscCs=|dkr|jS|dkr&|jStd|f��dS(s|A workaround to get special attributes on the ServerProxy
           without interfering with the magic __getattr__
        RuR_sAttribute %r not foundN(t_ServerProxy__closeRZRt(Rtattr((s!/usr/lib64/python2.7/xmlrpclib.pyR�Ys
N(RRRRbRRcRbRRR�R�(((s!/usr/lib64/python2.7/xmlrpclib.pyRSs					t__main__shttp://localhost:8000ii	iiitERRORll��ll����((((((((((((((bRtreRR?R)ttypesRRR RtImportErrorRbRt	NameErrorR7R'RFRR�tcompiletsearchRRRRRNR�R�tPARSE_ERRORtSERVER_ERRORtAPPLICATION_ERRORtSYSTEM_ERRORtTRANSPORT_ERRORtNOT_WELLFORMED_ERRORtUNSUPPORTED_ENCODINGtINVALID_ENCODING_CHARtINVALID_XMLRPCtMETHOD_NOT_FOUNDtINVALID_METHOD_PARAMStINTERNAL_ERRORR2RRR R!tsysR%R�tmod_dictRR6R(R&RBRCRYR\R_t	cStringIORaR]RcR�t
_xmlrpclibtParserR�R�R�RtR�R�txml.parsersRdRIRfRvR�R�R�R�R�R�RRRtobjectRRRRORStServerR�tmultitpowtaddRR�(((s!/usr/lib64/python2.7/xmlrpclib.pyt<module>�s�0








	





	T		

		





��-&	N	%�*a


Zerion Mini Shell 1.0