All Downloads are FREE. Search and download functionalities are using the official Maven repository.

gen.python.Search.TrecSearch.pyc Maven / Gradle / Ivy

The newest version!
?
s?Qc@s?ddlmZmZmZddlTddlmZddlmZddlm	Z	m
Z
yddlmZWn
dZnXddd??YZ
d	e
fd
??YZde
efd??YZd
dd??YZddd??YZdS(i????(tTTypetTMessageTypet
TException(t*(t
TProcessor(t
TTransport(tTBinaryProtocolt	TProtocol(t
fastbinarytIfacecBseZd?ZRS(cCsdS(s"
    Parameters:
     - query
    N((tselftquery((s%../../gen/python/Search/TrecSearch.pytsearchs(t__name__t
__module__R(((s%../../gen/python/Search/TrecSearch.pyR	stClientcBs/eZdd?Zd?Zd?Zd?ZRS(cCs5||_|_|dk	r(||_nd|_dS(Ni(t_iprott_oprottNonet_seqid(R
tiprottoprot((s%../../gen/python/Search/TrecSearch.pyt__init__scCs|j|?|j?S(s"
    Parameters:
     - query
    (tsend_searchtrecv_search(R
R((s%../../gen/python/Search/TrecSearch.pyR$s
cCs_|jjdtj|j?t?}||_|j|j?|jj?|jj	j
?dS(NR(RtwriteMessageBeginRtCALLRtsearch_argsRtwritetwriteMessageEndttranstflush(R
Rtargs((s%../../gen/python/Search/TrecSearch.pyR,s		
cCs?|jj?\}}}|tjkrVt?}|j|j?|jj?|?nt?}|j|j?|jj?|jdk	r?|jS|j
dk	r?|j
?nttjd??dS(Nssearch failed: unknown result(RtreadMessageBeginRt	EXCEPTIONtTApplicationExceptiontreadtreadMessageEndt
search_resulttsuccessRterrortMISSING_RESULT(R
tfnametmtypetrseqidtxtresult((s%../../gen/python/Search/TrecSearch.pyR4s	
		
N(R
RRRRRR(((s%../../gen/python/Search/TrecSearch.pyRs		t	ProcessorcBs#eZd?Zd?Zd?ZRS(cCs&||_i|_tj|jdRR?RBRRRRt
encode_binarytwriteStructBeginRtwriteFieldBeginRR5t
writeFieldEndtwriteFieldStoptwriteStructEnd(R
R((s%../../gen/python/Search/TrecSearch.pyR?s-(


cCsdS(N((R
((s%../../gen/python/Search/TrecSearch.pytvalidate?scCsOg|jj?D]\}}d||f^q}d|jjdj|?fS(Ns%s=%rs%s(%s)s, (t__dict__t	iteritemsR>R
tjoin(R
tkeytvaluetL((s%../../gen/python/Search/TrecSearch.pyt__repr__?s/cCs"t||j?o!|j|jkS(N(R@R>RS(R
tother((s%../../gen/python/Search/TrecSearch.pyt__eq__?scCs||kS(N((R
RZ((s%../../gen/python/Search/TrecSearch.pyt__ne__?sN(R
Rt__doc__RRR5RGRBRR$RRRRYR[R\(((s%../../gen/python/Search/TrecSearch.pyRks$					R&cBs?eZdZdejdejeejffdfdejde	e	jfdffZddd?Z
d?Zd?Zd?Z
d	?Zd
?Zd?ZRS(
s)
  Attributes:
   - success
   - error
  iR'iR(cCs||_||_dS(N(R'R((R
R'R(((s%../../gen/python/Search/TrecSearch.pyR?s	c	Cs?|jtjkrht|jtj?rh|jdk	rht	dk	rht	j
||j|j|jf?dS|j?x#tr?|j
?\}}}|tjkr?Pn|dkr3|tjkr#g|_|j?\}}x:t|?D],}t?}|j|?|jj|?q?W|j?q?|j|?nW|dkr}|tjkrmt?|_|jj|?q?|j|?n
|j|?|j?quW|j?dS(Nii(R>RR?R@RRRARBRRRCRDR7RERRFtLISTR't
readListBegintxrangetTResultR$tappendtreadListEndR4R5R<R(RHRI(	R
RR*RJRKt_etype3t_size0t_i4t_elem5((s%../../gen/python/Search/TrecSearch.pyR$?s4B"
			


cCs9|jtjkrY|jdk	rYtdk	rY|jjtj||j|jf??dS|j	d?|j
dk	r?|jdtj
d?|jtjt|j
??x|j
D]}|j|?q?W|j?|j?n|jdk	r!|jdtjd?|jj|?|j?n|j?|j?dS(NR&R'iR(i(R>RR?RBRRRRRLRMR'RNRR^twriteListBeginR5tlentwriteListEndROR(RPRQ(R
Rtiter6((s%../../gen/python/Search/TrecSearch.pyR?s"-(




cCsdS(N((R
((s%../../gen/python/Search/TrecSearch.pyRR?scCsOg|jj?D]\}}d||f^q}d|jjdj|?fS(Ns%s=%rs%s(%s)s, (RSRTR>R
RU(R
RVRWRX((s%../../gen/python/Search/TrecSearch.pyRY?s/cCs"t||j?o!|j|jkS(N(R@R>RS(R
RZ((s%../../gen/python/Search/TrecSearch.pyR[?scCs||kS(N((R
RZ((s%../../gen/python/Search/TrecSearch.pyR\?sN(R
RR]RR^R5RaRBRR<RR$RRRRYR[R\(((s%../../gen/python/Search/TrecSearch.pyR&?s'$					N((((t
thrift.ThriftRRRtttypesRtthrift.transportRtthrift.protocolRRRRR	RR/RR&(((s%../../gen/python/Search/TrecSearch.pyt	s

	(&=




© 2015 - 2024 Weber Informatics LLC | Privacy Policy