403Webshell
Server IP : 61.19.30.66  /  Your IP : 216.73.216.15
Web Server : Apache/2.2.22 (Ubuntu)
System : Linux klw 3.11.0-15-generic #25~precise1-Ubuntu SMP Thu Jan 30 17:39:31 UTC 2014 x86_64
User : www-data ( 33)
PHP Version : 5.3.10-1ubuntu3.48
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : ON  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /usr/lib/python2.7/dist-packages/twisted/enterprise/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyc
ó
[³XMc@slddlZddlZddlmZdd
d„ƒYZdZdZdZdZdd	d
ddgZ	dS(iÿÿÿÿN(tDBErrort	ReflectorcBs§eZdZdZd„Zd„Zd„Zd„Zd„Zd„Z	d„Z
d	„Zd
„Zd„Z
d„Zddgd
d„Zd„Zd„Zd„ZRS(s]
    DEPRECATED.

    Base class for enterprise reflectors. This implements row caching.
    icCsHtjddtddƒtjƒ|_||_i|_|jƒdS(sš
        Initialize me against a database.

        @param rowClasses: a list of row class objects that describe the
            database schema.
        s<twisted.enterprise.reflector is deprecated since Twisted 8.0tcategoryt
stackleveliN(	twarningstwarntDeprecationWarningtweakreftWeakValueDictionarytrowCachet
rowClassestschemat	_populate(tselfR
((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt__init__s
		cCs|jjƒ}|d=|S(NR	(t__dict__tcopy(R
td((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt__getstate__!scCs&||_tjƒ|_|jƒdS(N(RRRR	R(R
tstate((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt__setstate__&s	cCstdƒ‚dS(sGImplement me to populate schema information for the reflector.
        snot implementedN(R(R
((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyR+scCsZ||j|j<xC|jD]8\}}}}}|j|j|||j||ƒqWdS(sThis is called once for each registered rowClass to add it
        and its foreign key relationships for that rowClass to the
        schema.N(RtrowTableNametrowForeignKeyst
addForeignKeytrowClass(R
t	tableInfotforeignTableNametchildColumnst
parentColumnstcontainerMethodtautoLoad((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytpopulateSchemaFor0s
	cCsCy|j|jSWn*tk
r>td|j|fƒ‚nXdS(sGet a TableInfo record about a particular instance.

        This record contains various information about the instance's
        class as registered with this reflector.

        @param rowObject: a L{RowObject} instance of a class previously
            registered with me.
        @raises twisted.enterprise.row.DBError: raised if this class was not
            previously registered.
        s#class %s was not registered with %sN(RRtKeyErrorRt	__class__(R
t	rowObject((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytgetTableInfo=s

cCshg}x[tdt|jƒƒD]A}t||j|dƒ}|j|j|dt|gƒqW|S(s^util method used by reflectors. builds a where clause to link a row to another table.
        i(trangetlenRtgetattrRtappendtEQUAL(R
trelationshiptrowtwhereClausetitvalue((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytbuildWhereClauseNs
%cCsú|j|ƒ}|j|ƒ}|s@td|j|fƒ‚n|js›t|dƒrŽx<|D](}||jkr_|jj|ƒq_q_Wn	||_dSt||jƒsÉtd||jfƒ‚nt||jƒ}x|D]}||ƒqâWdS(sÁutil method used by reflectors. adds these rows to the parent row object.
        If a rowClass does not have a containerMethod, then a list attribute "childRows"
        will be used.
        sno relationship from %s to %st	childRowsNs2parent row (%s) doesnt have container method <%s>!(	R#tgetRelationshipForRRRthasattrR/R'R&(R
t	parentRowtrowst	tableNamet
parentInfoR)R*tmeth((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytaddToParentWs 	
	
cCs||j|jƒ<dS(sGNOTE: Should this be recursive?! requires better container knowledge...N(R	tgetKeyTuple(R
R"((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt
addToCachesscCs]g}|j|jƒx(|jD]\}}|j||ƒq Wt|ƒ}|jj|ƒS(N(R'Rt
rowKeyColumnsttupleR	tget(R
RtkwtkeystkeyNametkeyTypetkeyTuple((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytfindInCachewscCs/|jƒ}|jj|ƒr+|j|=ndS(s!NOTE: should this be recursive!??N(R8R	thas_key(R
R"tkey((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytremoveFromCachesicCstdƒ‚dS(sImplement me to load objects from the database.

        @param whereClause: a list of tuples of (columnName, conditional, value)
            so it can be parsed by all types of reflectors. eg.::
              whereClause = [("name", EQUALS, "fred"), ("age", GREATERTHAN, 18)]
        snot implementedN(R(R
R4tparenttdataR+tloadChildren((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pytloadObjectsFrom‡scCstdƒ‚dS(s/update this rowObject to the database.
        snot implementedN(R(R
R"((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt	updateRow‘scCstdƒ‚dS(s3insert a new row for this object instance.
        snot implementedN(R(R
R"((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt	insertRow–scCstdƒ‚dS(s:delete the row for this object from the database.
        snot implementedN(R(R
R"((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt	deleteRow›sN(t__name__t
__module__t__doc__t	populatedRRRRRR#R.R7R9RBREtNoneRIRJRKRL(((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyR
s$					
										iiiiR(tLESSTHANtGREATERTHANtLIKE((
RRttwisted.enterprise.utilRRR(RRRSRTt__all__(((s@/usr/lib/python2.7/dist-packages/twisted/enterprise/reflector.pyt<module>s—

Youez - 2016 - github.com/yon3zu
LinuXploit