TCLIService.py 147 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647
  1. #
  2. # Autogenerated by Thrift Compiler (0.13.0)
  3. #
  4. # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
  5. #
  6. # options string: py:new_style
  7. #
  8. from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
  9. from thrift.protocol.TProtocol import TProtocolException
  10. from thrift.TRecursive import fix_spec
  11. import sys
  12. import logging
  13. from .ttypes import *
  14. from thrift.Thrift import TProcessor
  15. from thrift.transport import TTransport
  16. from django.utils.functional import wraps
  17. from django.utils.encoding import smart_str
  18. all_structs = []
  19. LOG = logging.getLogger()
  20. class Iface(object):
  21. def OpenSession(self, req):
  22. """
  23. Parameters:
  24. - req
  25. """
  26. pass
  27. def CloseSession(self, req):
  28. """
  29. Parameters:
  30. - req
  31. """
  32. pass
  33. def GetInfo(self, req):
  34. """
  35. Parameters:
  36. - req
  37. """
  38. pass
  39. def ExecuteStatement(self, req):
  40. """
  41. Parameters:
  42. - req
  43. """
  44. pass
  45. def GetTypeInfo(self, req):
  46. """
  47. Parameters:
  48. - req
  49. """
  50. pass
  51. def GetCatalogs(self, req):
  52. """
  53. Parameters:
  54. - req
  55. """
  56. pass
  57. def GetSchemas(self, req):
  58. """
  59. Parameters:
  60. - req
  61. """
  62. pass
  63. def GetTables(self, req):
  64. """
  65. Parameters:
  66. - req
  67. """
  68. pass
  69. def GetTableTypes(self, req):
  70. """
  71. Parameters:
  72. - req
  73. """
  74. pass
  75. def GetColumns(self, req):
  76. """
  77. Parameters:
  78. - req
  79. """
  80. pass
  81. def GetFunctions(self, req):
  82. """
  83. Parameters:
  84. - req
  85. """
  86. pass
  87. def GetPrimaryKeys(self, req):
  88. """
  89. Parameters:
  90. - req
  91. """
  92. pass
  93. def GetCrossReference(self, req):
  94. """
  95. Parameters:
  96. - req
  97. """
  98. pass
  99. def GetOperationStatus(self, req):
  100. """
  101. Parameters:
  102. - req
  103. """
  104. pass
  105. def CancelOperation(self, req):
  106. """
  107. Parameters:
  108. - req
  109. """
  110. pass
  111. def CloseOperation(self, req):
  112. """
  113. Parameters:
  114. - req
  115. """
  116. pass
  117. def GetResultSetMetadata(self, req):
  118. """
  119. Parameters:
  120. - req
  121. """
  122. pass
  123. def FetchResults(self, req):
  124. """
  125. Parameters:
  126. - req
  127. """
  128. pass
  129. def GetDelegationToken(self, req):
  130. """
  131. Parameters:
  132. - req
  133. """
  134. pass
  135. def CancelDelegationToken(self, req):
  136. """
  137. Parameters:
  138. - req
  139. """
  140. pass
  141. def RenewDelegationToken(self, req):
  142. """
  143. Parameters:
  144. - req
  145. """
  146. pass
  147. def GetQueryId(self, req):
  148. """
  149. Parameters:
  150. - req
  151. """
  152. pass
  153. def SetClientInfo(self, req):
  154. """
  155. Parameters:
  156. - req
  157. """
  158. pass
  159. def GetLog(self, req):
  160. """
  161. Parameters:
  162. - req
  163. """
  164. pass
  165. def add_xff_header(func):
  166. def decorate(*args, **kwargs):
  167. self = args[0]
  168. xff = None
  169. configuration = None
  170. if args[1].__dict__ is not None and 'configuration' in args[1].__dict__:
  171. configuration = args[1].__dict__['configuration']
  172. if configuration is not None and 'X-Forwarded-For' in configuration:
  173. xff = configuration.get('X-Forwarded-For')
  174. if xff:
  175. try:
  176. if hasattr(self._oprot.trans, 'TFramedTransport'):
  177. trans_client = self._oprot.trans._TFramedTransport__trans
  178. else:
  179. trans_client = self._oprot.trans._TBufferedTransport__trans
  180. trans_client.setCustomHeaders({'X-Forwarded-For': xff})
  181. except AttributeError as e:
  182. LOG.error('Could not set HTTP-X-FORWARDED-FOR header: %s' % smart_str(e))
  183. return func(*args, **kwargs)
  184. return wraps(func)(decorate)
  185. def add_csrf_header(func):
  186. def decorate(*args, **kwargs):
  187. self = args[0]
  188. csrf = None
  189. configuration = None
  190. if args[1].__dict__ is not None and 'configuration' in args[1].__dict__:
  191. configuration = args[1].__dict__['configuration']
  192. if configuration is not None and 'X-CSRF-TOKEN' in configuration:
  193. csrf = configuration.get('X-CSRF-TOKEN')
  194. if csrf:
  195. try:
  196. if hasattr(self._oprot.trans, 'TFramedTransport'):
  197. trans_client = self._oprot.trans._TFramedTransport__trans
  198. else:
  199. trans_client = self._oprot.trans._TBufferedTransport__trans
  200. trans_client.setCustomHeaders({'X-CSRF-TOKEN': csrf})
  201. except AttributeError as e:
  202. LOG.error('Could not set CSRF header: %s' % smart_str(e))
  203. return func(*args, **kwargs)
  204. return wraps(func)(decorate)
  205. class Client(Iface):
  206. def __init__(self, iprot, oprot=None):
  207. self._iprot = self._oprot = iprot
  208. if oprot is not None:
  209. self._oprot = oprot
  210. self._seqid = 0
  211. @add_csrf_header
  212. @add_xff_header
  213. def OpenSession(self, req):
  214. """
  215. Parameters:
  216. - req
  217. """
  218. self.send_OpenSession(req)
  219. return self.recv_OpenSession()
  220. def send_OpenSession(self, req):
  221. self._oprot.writeMessageBegin('OpenSession', TMessageType.CALL, self._seqid)
  222. args = OpenSession_args()
  223. args.req = req
  224. args.write(self._oprot)
  225. self._oprot.writeMessageEnd()
  226. self._oprot.trans.flush()
  227. def recv_OpenSession(self):
  228. iprot = self._iprot
  229. (fname, mtype, rseqid) = iprot.readMessageBegin()
  230. if mtype == TMessageType.EXCEPTION:
  231. x = TApplicationException()
  232. x.read(iprot)
  233. iprot.readMessageEnd()
  234. raise x
  235. result = OpenSession_result()
  236. result.read(iprot)
  237. iprot.readMessageEnd()
  238. if result.success is not None:
  239. return result.success
  240. raise TApplicationException(TApplicationException.MISSING_RESULT, "OpenSession failed: unknown result")
  241. def CloseSession(self, req):
  242. """
  243. Parameters:
  244. - req
  245. """
  246. self.send_CloseSession(req)
  247. return self.recv_CloseSession()
  248. def send_CloseSession(self, req):
  249. self._oprot.writeMessageBegin('CloseSession', TMessageType.CALL, self._seqid)
  250. args = CloseSession_args()
  251. args.req = req
  252. args.write(self._oprot)
  253. self._oprot.writeMessageEnd()
  254. self._oprot.trans.flush()
  255. def recv_CloseSession(self):
  256. iprot = self._iprot
  257. (fname, mtype, rseqid) = iprot.readMessageBegin()
  258. if mtype == TMessageType.EXCEPTION:
  259. x = TApplicationException()
  260. x.read(iprot)
  261. iprot.readMessageEnd()
  262. raise x
  263. result = CloseSession_result()
  264. result.read(iprot)
  265. iprot.readMessageEnd()
  266. if result.success is not None:
  267. return result.success
  268. raise TApplicationException(TApplicationException.MISSING_RESULT, "CloseSession failed: unknown result")
  269. def GetInfo(self, req):
  270. """
  271. Parameters:
  272. - req
  273. """
  274. self.send_GetInfo(req)
  275. return self.recv_GetInfo()
  276. def send_GetInfo(self, req):
  277. self._oprot.writeMessageBegin('GetInfo', TMessageType.CALL, self._seqid)
  278. args = GetInfo_args()
  279. args.req = req
  280. args.write(self._oprot)
  281. self._oprot.writeMessageEnd()
  282. self._oprot.trans.flush()
  283. def recv_GetInfo(self):
  284. iprot = self._iprot
  285. (fname, mtype, rseqid) = iprot.readMessageBegin()
  286. if mtype == TMessageType.EXCEPTION:
  287. x = TApplicationException()
  288. x.read(iprot)
  289. iprot.readMessageEnd()
  290. raise x
  291. result = GetInfo_result()
  292. result.read(iprot)
  293. iprot.readMessageEnd()
  294. if result.success is not None:
  295. return result.success
  296. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetInfo failed: unknown result")
  297. def ExecuteStatement(self, req):
  298. """
  299. Parameters:
  300. - req
  301. """
  302. self.send_ExecuteStatement(req)
  303. return self.recv_ExecuteStatement()
  304. def send_ExecuteStatement(self, req):
  305. self._oprot.writeMessageBegin('ExecuteStatement', TMessageType.CALL, self._seqid)
  306. args = ExecuteStatement_args()
  307. args.req = req
  308. args.write(self._oprot)
  309. self._oprot.writeMessageEnd()
  310. self._oprot.trans.flush()
  311. def recv_ExecuteStatement(self):
  312. iprot = self._iprot
  313. (fname, mtype, rseqid) = iprot.readMessageBegin()
  314. if mtype == TMessageType.EXCEPTION:
  315. x = TApplicationException()
  316. x.read(iprot)
  317. iprot.readMessageEnd()
  318. raise x
  319. result = ExecuteStatement_result()
  320. result.read(iprot)
  321. iprot.readMessageEnd()
  322. if result.success is not None:
  323. return result.success
  324. raise TApplicationException(TApplicationException.MISSING_RESULT, "ExecuteStatement failed: unknown result")
  325. def GetTypeInfo(self, req):
  326. """
  327. Parameters:
  328. - req
  329. """
  330. self.send_GetTypeInfo(req)
  331. return self.recv_GetTypeInfo()
  332. def send_GetTypeInfo(self, req):
  333. self._oprot.writeMessageBegin('GetTypeInfo', TMessageType.CALL, self._seqid)
  334. args = GetTypeInfo_args()
  335. args.req = req
  336. args.write(self._oprot)
  337. self._oprot.writeMessageEnd()
  338. self._oprot.trans.flush()
  339. def recv_GetTypeInfo(self):
  340. iprot = self._iprot
  341. (fname, mtype, rseqid) = iprot.readMessageBegin()
  342. if mtype == TMessageType.EXCEPTION:
  343. x = TApplicationException()
  344. x.read(iprot)
  345. iprot.readMessageEnd()
  346. raise x
  347. result = GetTypeInfo_result()
  348. result.read(iprot)
  349. iprot.readMessageEnd()
  350. if result.success is not None:
  351. return result.success
  352. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetTypeInfo failed: unknown result")
  353. def GetCatalogs(self, req):
  354. """
  355. Parameters:
  356. - req
  357. """
  358. self.send_GetCatalogs(req)
  359. return self.recv_GetCatalogs()
  360. def send_GetCatalogs(self, req):
  361. self._oprot.writeMessageBegin('GetCatalogs', TMessageType.CALL, self._seqid)
  362. args = GetCatalogs_args()
  363. args.req = req
  364. args.write(self._oprot)
  365. self._oprot.writeMessageEnd()
  366. self._oprot.trans.flush()
  367. def recv_GetCatalogs(self):
  368. iprot = self._iprot
  369. (fname, mtype, rseqid) = iprot.readMessageBegin()
  370. if mtype == TMessageType.EXCEPTION:
  371. x = TApplicationException()
  372. x.read(iprot)
  373. iprot.readMessageEnd()
  374. raise x
  375. result = GetCatalogs_result()
  376. result.read(iprot)
  377. iprot.readMessageEnd()
  378. if result.success is not None:
  379. return result.success
  380. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetCatalogs failed: unknown result")
  381. def GetSchemas(self, req):
  382. """
  383. Parameters:
  384. - req
  385. """
  386. self.send_GetSchemas(req)
  387. return self.recv_GetSchemas()
  388. def send_GetSchemas(self, req):
  389. self._oprot.writeMessageBegin('GetSchemas', TMessageType.CALL, self._seqid)
  390. args = GetSchemas_args()
  391. args.req = req
  392. args.write(self._oprot)
  393. self._oprot.writeMessageEnd()
  394. self._oprot.trans.flush()
  395. def recv_GetSchemas(self):
  396. iprot = self._iprot
  397. (fname, mtype, rseqid) = iprot.readMessageBegin()
  398. if mtype == TMessageType.EXCEPTION:
  399. x = TApplicationException()
  400. x.read(iprot)
  401. iprot.readMessageEnd()
  402. raise x
  403. result = GetSchemas_result()
  404. result.read(iprot)
  405. iprot.readMessageEnd()
  406. if result.success is not None:
  407. return result.success
  408. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetSchemas failed: unknown result")
  409. def GetTables(self, req):
  410. """
  411. Parameters:
  412. - req
  413. """
  414. self.send_GetTables(req)
  415. return self.recv_GetTables()
  416. def send_GetTables(self, req):
  417. self._oprot.writeMessageBegin('GetTables', TMessageType.CALL, self._seqid)
  418. args = GetTables_args()
  419. args.req = req
  420. args.write(self._oprot)
  421. self._oprot.writeMessageEnd()
  422. self._oprot.trans.flush()
  423. def recv_GetTables(self):
  424. iprot = self._iprot
  425. (fname, mtype, rseqid) = iprot.readMessageBegin()
  426. if mtype == TMessageType.EXCEPTION:
  427. x = TApplicationException()
  428. x.read(iprot)
  429. iprot.readMessageEnd()
  430. raise x
  431. result = GetTables_result()
  432. result.read(iprot)
  433. iprot.readMessageEnd()
  434. if result.success is not None:
  435. return result.success
  436. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetTables failed: unknown result")
  437. def GetTableTypes(self, req):
  438. """
  439. Parameters:
  440. - req
  441. """
  442. self.send_GetTableTypes(req)
  443. return self.recv_GetTableTypes()
  444. def send_GetTableTypes(self, req):
  445. self._oprot.writeMessageBegin('GetTableTypes', TMessageType.CALL, self._seqid)
  446. args = GetTableTypes_args()
  447. args.req = req
  448. args.write(self._oprot)
  449. self._oprot.writeMessageEnd()
  450. self._oprot.trans.flush()
  451. def recv_GetTableTypes(self):
  452. iprot = self._iprot
  453. (fname, mtype, rseqid) = iprot.readMessageBegin()
  454. if mtype == TMessageType.EXCEPTION:
  455. x = TApplicationException()
  456. x.read(iprot)
  457. iprot.readMessageEnd()
  458. raise x
  459. result = GetTableTypes_result()
  460. result.read(iprot)
  461. iprot.readMessageEnd()
  462. if result.success is not None:
  463. return result.success
  464. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetTableTypes failed: unknown result")
  465. def GetColumns(self, req):
  466. """
  467. Parameters:
  468. - req
  469. """
  470. self.send_GetColumns(req)
  471. return self.recv_GetColumns()
  472. def send_GetColumns(self, req):
  473. self._oprot.writeMessageBegin('GetColumns', TMessageType.CALL, self._seqid)
  474. args = GetColumns_args()
  475. args.req = req
  476. args.write(self._oprot)
  477. self._oprot.writeMessageEnd()
  478. self._oprot.trans.flush()
  479. def recv_GetColumns(self):
  480. iprot = self._iprot
  481. (fname, mtype, rseqid) = iprot.readMessageBegin()
  482. if mtype == TMessageType.EXCEPTION:
  483. x = TApplicationException()
  484. x.read(iprot)
  485. iprot.readMessageEnd()
  486. raise x
  487. result = GetColumns_result()
  488. result.read(iprot)
  489. iprot.readMessageEnd()
  490. if result.success is not None:
  491. return result.success
  492. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetColumns failed: unknown result")
  493. def GetFunctions(self, req):
  494. """
  495. Parameters:
  496. - req
  497. """
  498. self.send_GetFunctions(req)
  499. return self.recv_GetFunctions()
  500. def send_GetFunctions(self, req):
  501. self._oprot.writeMessageBegin('GetFunctions', TMessageType.CALL, self._seqid)
  502. args = GetFunctions_args()
  503. args.req = req
  504. args.write(self._oprot)
  505. self._oprot.writeMessageEnd()
  506. self._oprot.trans.flush()
  507. def recv_GetFunctions(self):
  508. iprot = self._iprot
  509. (fname, mtype, rseqid) = iprot.readMessageBegin()
  510. if mtype == TMessageType.EXCEPTION:
  511. x = TApplicationException()
  512. x.read(iprot)
  513. iprot.readMessageEnd()
  514. raise x
  515. result = GetFunctions_result()
  516. result.read(iprot)
  517. iprot.readMessageEnd()
  518. if result.success is not None:
  519. return result.success
  520. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetFunctions failed: unknown result")
  521. def GetPrimaryKeys(self, req):
  522. """
  523. Parameters:
  524. - req
  525. """
  526. self.send_GetPrimaryKeys(req)
  527. return self.recv_GetPrimaryKeys()
  528. def send_GetPrimaryKeys(self, req):
  529. self._oprot.writeMessageBegin('GetPrimaryKeys', TMessageType.CALL, self._seqid)
  530. args = GetPrimaryKeys_args()
  531. args.req = req
  532. args.write(self._oprot)
  533. self._oprot.writeMessageEnd()
  534. self._oprot.trans.flush()
  535. def recv_GetPrimaryKeys(self):
  536. iprot = self._iprot
  537. (fname, mtype, rseqid) = iprot.readMessageBegin()
  538. if mtype == TMessageType.EXCEPTION:
  539. x = TApplicationException()
  540. x.read(iprot)
  541. iprot.readMessageEnd()
  542. raise x
  543. result = GetPrimaryKeys_result()
  544. result.read(iprot)
  545. iprot.readMessageEnd()
  546. if result.success is not None:
  547. return result.success
  548. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetPrimaryKeys failed: unknown result")
  549. def GetCrossReference(self, req):
  550. """
  551. Parameters:
  552. - req
  553. """
  554. self.send_GetCrossReference(req)
  555. return self.recv_GetCrossReference()
  556. def send_GetCrossReference(self, req):
  557. self._oprot.writeMessageBegin('GetCrossReference', TMessageType.CALL, self._seqid)
  558. args = GetCrossReference_args()
  559. args.req = req
  560. args.write(self._oprot)
  561. self._oprot.writeMessageEnd()
  562. self._oprot.trans.flush()
  563. def recv_GetCrossReference(self):
  564. iprot = self._iprot
  565. (fname, mtype, rseqid) = iprot.readMessageBegin()
  566. if mtype == TMessageType.EXCEPTION:
  567. x = TApplicationException()
  568. x.read(iprot)
  569. iprot.readMessageEnd()
  570. raise x
  571. result = GetCrossReference_result()
  572. result.read(iprot)
  573. iprot.readMessageEnd()
  574. if result.success is not None:
  575. return result.success
  576. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetCrossReference failed: unknown result")
  577. def GetOperationStatus(self, req):
  578. """
  579. Parameters:
  580. - req
  581. """
  582. self.send_GetOperationStatus(req)
  583. return self.recv_GetOperationStatus()
  584. def send_GetOperationStatus(self, req):
  585. self._oprot.writeMessageBegin('GetOperationStatus', TMessageType.CALL, self._seqid)
  586. args = GetOperationStatus_args()
  587. args.req = req
  588. args.write(self._oprot)
  589. self._oprot.writeMessageEnd()
  590. self._oprot.trans.flush()
  591. def recv_GetOperationStatus(self):
  592. iprot = self._iprot
  593. (fname, mtype, rseqid) = iprot.readMessageBegin()
  594. if mtype == TMessageType.EXCEPTION:
  595. x = TApplicationException()
  596. x.read(iprot)
  597. iprot.readMessageEnd()
  598. raise x
  599. result = GetOperationStatus_result()
  600. result.read(iprot)
  601. iprot.readMessageEnd()
  602. if result.success is not None:
  603. return result.success
  604. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetOperationStatus failed: unknown result")
  605. def CancelOperation(self, req):
  606. """
  607. Parameters:
  608. - req
  609. """
  610. self.send_CancelOperation(req)
  611. return self.recv_CancelOperation()
  612. def send_CancelOperation(self, req):
  613. self._oprot.writeMessageBegin('CancelOperation', TMessageType.CALL, self._seqid)
  614. args = CancelOperation_args()
  615. args.req = req
  616. args.write(self._oprot)
  617. self._oprot.writeMessageEnd()
  618. self._oprot.trans.flush()
  619. def recv_CancelOperation(self):
  620. iprot = self._iprot
  621. (fname, mtype, rseqid) = iprot.readMessageBegin()
  622. if mtype == TMessageType.EXCEPTION:
  623. x = TApplicationException()
  624. x.read(iprot)
  625. iprot.readMessageEnd()
  626. raise x
  627. result = CancelOperation_result()
  628. result.read(iprot)
  629. iprot.readMessageEnd()
  630. if result.success is not None:
  631. return result.success
  632. raise TApplicationException(TApplicationException.MISSING_RESULT, "CancelOperation failed: unknown result")
  633. def CloseOperation(self, req):
  634. """
  635. Parameters:
  636. - req
  637. """
  638. self.send_CloseOperation(req)
  639. return self.recv_CloseOperation()
  640. def send_CloseOperation(self, req):
  641. self._oprot.writeMessageBegin('CloseOperation', TMessageType.CALL, self._seqid)
  642. args = CloseOperation_args()
  643. args.req = req
  644. args.write(self._oprot)
  645. self._oprot.writeMessageEnd()
  646. self._oprot.trans.flush()
  647. def recv_CloseOperation(self):
  648. iprot = self._iprot
  649. (fname, mtype, rseqid) = iprot.readMessageBegin()
  650. if mtype == TMessageType.EXCEPTION:
  651. x = TApplicationException()
  652. x.read(iprot)
  653. iprot.readMessageEnd()
  654. raise x
  655. result = CloseOperation_result()
  656. result.read(iprot)
  657. iprot.readMessageEnd()
  658. if result.success is not None:
  659. return result.success
  660. raise TApplicationException(TApplicationException.MISSING_RESULT, "CloseOperation failed: unknown result")
  661. def GetResultSetMetadata(self, req):
  662. """
  663. Parameters:
  664. - req
  665. """
  666. self.send_GetResultSetMetadata(req)
  667. return self.recv_GetResultSetMetadata()
  668. def send_GetResultSetMetadata(self, req):
  669. self._oprot.writeMessageBegin('GetResultSetMetadata', TMessageType.CALL, self._seqid)
  670. args = GetResultSetMetadata_args()
  671. args.req = req
  672. args.write(self._oprot)
  673. self._oprot.writeMessageEnd()
  674. self._oprot.trans.flush()
  675. def recv_GetResultSetMetadata(self):
  676. iprot = self._iprot
  677. (fname, mtype, rseqid) = iprot.readMessageBegin()
  678. if mtype == TMessageType.EXCEPTION:
  679. x = TApplicationException()
  680. x.read(iprot)
  681. iprot.readMessageEnd()
  682. raise x
  683. result = GetResultSetMetadata_result()
  684. result.read(iprot)
  685. iprot.readMessageEnd()
  686. if result.success is not None:
  687. return result.success
  688. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetResultSetMetadata failed: unknown result")
  689. def FetchResults(self, req):
  690. """
  691. Parameters:
  692. - req
  693. """
  694. self.send_FetchResults(req)
  695. return self.recv_FetchResults()
  696. def send_FetchResults(self, req):
  697. self._oprot.writeMessageBegin('FetchResults', TMessageType.CALL, self._seqid)
  698. args = FetchResults_args()
  699. args.req = req
  700. args.write(self._oprot)
  701. self._oprot.writeMessageEnd()
  702. self._oprot.trans.flush()
  703. def recv_FetchResults(self):
  704. iprot = self._iprot
  705. (fname, mtype, rseqid) = iprot.readMessageBegin()
  706. if mtype == TMessageType.EXCEPTION:
  707. x = TApplicationException()
  708. x.read(iprot)
  709. iprot.readMessageEnd()
  710. raise x
  711. result = FetchResults_result()
  712. result.read(iprot)
  713. iprot.readMessageEnd()
  714. if result.success is not None:
  715. return result.success
  716. raise TApplicationException(TApplicationException.MISSING_RESULT, "FetchResults failed: unknown result")
  717. def GetDelegationToken(self, req):
  718. """
  719. Parameters:
  720. - req
  721. """
  722. self.send_GetDelegationToken(req)
  723. return self.recv_GetDelegationToken()
  724. def send_GetDelegationToken(self, req):
  725. self._oprot.writeMessageBegin('GetDelegationToken', TMessageType.CALL, self._seqid)
  726. args = GetDelegationToken_args()
  727. args.req = req
  728. args.write(self._oprot)
  729. self._oprot.writeMessageEnd()
  730. self._oprot.trans.flush()
  731. def recv_GetDelegationToken(self):
  732. iprot = self._iprot
  733. (fname, mtype, rseqid) = iprot.readMessageBegin()
  734. if mtype == TMessageType.EXCEPTION:
  735. x = TApplicationException()
  736. x.read(iprot)
  737. iprot.readMessageEnd()
  738. raise x
  739. result = GetDelegationToken_result()
  740. result.read(iprot)
  741. iprot.readMessageEnd()
  742. if result.success is not None:
  743. return result.success
  744. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetDelegationToken failed: unknown result")
  745. def CancelDelegationToken(self, req):
  746. """
  747. Parameters:
  748. - req
  749. """
  750. self.send_CancelDelegationToken(req)
  751. return self.recv_CancelDelegationToken()
  752. def send_CancelDelegationToken(self, req):
  753. self._oprot.writeMessageBegin('CancelDelegationToken', TMessageType.CALL, self._seqid)
  754. args = CancelDelegationToken_args()
  755. args.req = req
  756. args.write(self._oprot)
  757. self._oprot.writeMessageEnd()
  758. self._oprot.trans.flush()
  759. def recv_CancelDelegationToken(self):
  760. iprot = self._iprot
  761. (fname, mtype, rseqid) = iprot.readMessageBegin()
  762. if mtype == TMessageType.EXCEPTION:
  763. x = TApplicationException()
  764. x.read(iprot)
  765. iprot.readMessageEnd()
  766. raise x
  767. result = CancelDelegationToken_result()
  768. result.read(iprot)
  769. iprot.readMessageEnd()
  770. if result.success is not None:
  771. return result.success
  772. raise TApplicationException(TApplicationException.MISSING_RESULT, "CancelDelegationToken failed: unknown result")
  773. def RenewDelegationToken(self, req):
  774. """
  775. Parameters:
  776. - req
  777. """
  778. self.send_RenewDelegationToken(req)
  779. return self.recv_RenewDelegationToken()
  780. def send_RenewDelegationToken(self, req):
  781. self._oprot.writeMessageBegin('RenewDelegationToken', TMessageType.CALL, self._seqid)
  782. args = RenewDelegationToken_args()
  783. args.req = req
  784. args.write(self._oprot)
  785. self._oprot.writeMessageEnd()
  786. self._oprot.trans.flush()
  787. def recv_RenewDelegationToken(self):
  788. iprot = self._iprot
  789. (fname, mtype, rseqid) = iprot.readMessageBegin()
  790. if mtype == TMessageType.EXCEPTION:
  791. x = TApplicationException()
  792. x.read(iprot)
  793. iprot.readMessageEnd()
  794. raise x
  795. result = RenewDelegationToken_result()
  796. result.read(iprot)
  797. iprot.readMessageEnd()
  798. if result.success is not None:
  799. return result.success
  800. raise TApplicationException(TApplicationException.MISSING_RESULT, "RenewDelegationToken failed: unknown result")
  801. def GetQueryId(self, req):
  802. """
  803. Parameters:
  804. - req
  805. """
  806. self.send_GetQueryId(req)
  807. return self.recv_GetQueryId()
  808. def send_GetQueryId(self, req):
  809. self._oprot.writeMessageBegin('GetQueryId', TMessageType.CALL, self._seqid)
  810. args = GetQueryId_args()
  811. args.req = req
  812. args.write(self._oprot)
  813. self._oprot.writeMessageEnd()
  814. self._oprot.trans.flush()
  815. def recv_GetQueryId(self):
  816. iprot = self._iprot
  817. (fname, mtype, rseqid) = iprot.readMessageBegin()
  818. if mtype == TMessageType.EXCEPTION:
  819. x = TApplicationException()
  820. x.read(iprot)
  821. iprot.readMessageEnd()
  822. raise x
  823. result = GetQueryId_result()
  824. result.read(iprot)
  825. iprot.readMessageEnd()
  826. if result.success is not None:
  827. return result.success
  828. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetQueryId failed: unknown result")
  829. def SetClientInfo(self, req):
  830. """
  831. Parameters:
  832. - req
  833. """
  834. self.send_SetClientInfo(req)
  835. return self.recv_SetClientInfo()
  836. def send_SetClientInfo(self, req):
  837. self._oprot.writeMessageBegin('SetClientInfo', TMessageType.CALL, self._seqid)
  838. args = SetClientInfo_args()
  839. args.req = req
  840. args.write(self._oprot)
  841. self._oprot.writeMessageEnd()
  842. self._oprot.trans.flush()
  843. def recv_SetClientInfo(self):
  844. iprot = self._iprot
  845. (fname, mtype, rseqid) = iprot.readMessageBegin()
  846. if mtype == TMessageType.EXCEPTION:
  847. x = TApplicationException()
  848. x.read(iprot)
  849. iprot.readMessageEnd()
  850. raise x
  851. result = SetClientInfo_result()
  852. result.read(iprot)
  853. iprot.readMessageEnd()
  854. if result.success is not None:
  855. return result.success
  856. raise TApplicationException(TApplicationException.MISSING_RESULT, "SetClientInfo failed: unknown result")
  857. def GetLog(self, req):
  858. """
  859. Parameters:
  860. - req
  861. """
  862. self.send_GetLog(req)
  863. return self.recv_GetLog()
  864. def send_GetLog(self, req):
  865. self._oprot.writeMessageBegin('GetLog', TMessageType.CALL, self._seqid)
  866. args = GetLog_args()
  867. args.req = req
  868. args.write(self._oprot)
  869. self._oprot.writeMessageEnd()
  870. self._oprot.trans.flush()
  871. def recv_GetLog(self):
  872. iprot = self._iprot
  873. (fname, mtype, rseqid) = iprot.readMessageBegin()
  874. if mtype == TMessageType.EXCEPTION:
  875. x = TApplicationException()
  876. x.read(iprot)
  877. iprot.readMessageEnd()
  878. raise x
  879. result = GetLog_result()
  880. result.read(iprot)
  881. iprot.readMessageEnd()
  882. if result.success is not None:
  883. return result.success
  884. raise TApplicationException(TApplicationException.MISSING_RESULT, "GetLog failed: unknown result")
  885. class Processor(Iface, TProcessor):
  886. def __init__(self, handler):
  887. self._handler = handler
  888. self._processMap = {}
  889. self._processMap["OpenSession"] = Processor.process_OpenSession
  890. self._processMap["CloseSession"] = Processor.process_CloseSession
  891. self._processMap["GetInfo"] = Processor.process_GetInfo
  892. self._processMap["ExecuteStatement"] = Processor.process_ExecuteStatement
  893. self._processMap["GetTypeInfo"] = Processor.process_GetTypeInfo
  894. self._processMap["GetCatalogs"] = Processor.process_GetCatalogs
  895. self._processMap["GetSchemas"] = Processor.process_GetSchemas
  896. self._processMap["GetTables"] = Processor.process_GetTables
  897. self._processMap["GetTableTypes"] = Processor.process_GetTableTypes
  898. self._processMap["GetColumns"] = Processor.process_GetColumns
  899. self._processMap["GetFunctions"] = Processor.process_GetFunctions
  900. self._processMap["GetPrimaryKeys"] = Processor.process_GetPrimaryKeys
  901. self._processMap["GetCrossReference"] = Processor.process_GetCrossReference
  902. self._processMap["GetOperationStatus"] = Processor.process_GetOperationStatus
  903. self._processMap["CancelOperation"] = Processor.process_CancelOperation
  904. self._processMap["CloseOperation"] = Processor.process_CloseOperation
  905. self._processMap["GetResultSetMetadata"] = Processor.process_GetResultSetMetadata
  906. self._processMap["FetchResults"] = Processor.process_FetchResults
  907. self._processMap["GetDelegationToken"] = Processor.process_GetDelegationToken
  908. self._processMap["CancelDelegationToken"] = Processor.process_CancelDelegationToken
  909. self._processMap["RenewDelegationToken"] = Processor.process_RenewDelegationToken
  910. self._processMap["GetQueryId"] = Processor.process_GetQueryId
  911. self._processMap["SetClientInfo"] = Processor.process_SetClientInfo
  912. self._processMap["GetLog"] = Processor.process_GetLog
  913. self._on_message_begin = None
  914. def on_message_begin(self, func):
  915. self._on_message_begin = func
  916. def process(self, iprot, oprot):
  917. (name, type, seqid) = iprot.readMessageBegin()
  918. if self._on_message_begin:
  919. self._on_message_begin(name, type, seqid)
  920. if name not in self._processMap:
  921. iprot.skip(TType.STRUCT)
  922. iprot.readMessageEnd()
  923. x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
  924. oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
  925. x.write(oprot)
  926. oprot.writeMessageEnd()
  927. oprot.trans.flush()
  928. return
  929. else:
  930. self._processMap[name](self, seqid, iprot, oprot)
  931. return True
  932. def process_OpenSession(self, seqid, iprot, oprot):
  933. args = OpenSession_args()
  934. args.read(iprot)
  935. iprot.readMessageEnd()
  936. result = OpenSession_result()
  937. try:
  938. result.success = self._handler.OpenSession(args.req)
  939. msg_type = TMessageType.REPLY
  940. except TTransport.TTransportException:
  941. raise
  942. except TApplicationException as ex:
  943. logging.exception('TApplication exception in handler')
  944. msg_type = TMessageType.EXCEPTION
  945. result = ex
  946. except Exception:
  947. logging.exception('Unexpected exception in handler')
  948. msg_type = TMessageType.EXCEPTION
  949. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  950. oprot.writeMessageBegin("OpenSession", msg_type, seqid)
  951. result.write(oprot)
  952. oprot.writeMessageEnd()
  953. oprot.trans.flush()
  954. def process_CloseSession(self, seqid, iprot, oprot):
  955. args = CloseSession_args()
  956. args.read(iprot)
  957. iprot.readMessageEnd()
  958. result = CloseSession_result()
  959. try:
  960. result.success = self._handler.CloseSession(args.req)
  961. msg_type = TMessageType.REPLY
  962. except TTransport.TTransportException:
  963. raise
  964. except TApplicationException as ex:
  965. logging.exception('TApplication exception in handler')
  966. msg_type = TMessageType.EXCEPTION
  967. result = ex
  968. except Exception:
  969. logging.exception('Unexpected exception in handler')
  970. msg_type = TMessageType.EXCEPTION
  971. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  972. oprot.writeMessageBegin("CloseSession", msg_type, seqid)
  973. result.write(oprot)
  974. oprot.writeMessageEnd()
  975. oprot.trans.flush()
  976. def process_GetInfo(self, seqid, iprot, oprot):
  977. args = GetInfo_args()
  978. args.read(iprot)
  979. iprot.readMessageEnd()
  980. result = GetInfo_result()
  981. try:
  982. result.success = self._handler.GetInfo(args.req)
  983. msg_type = TMessageType.REPLY
  984. except TTransport.TTransportException:
  985. raise
  986. except TApplicationException as ex:
  987. logging.exception('TApplication exception in handler')
  988. msg_type = TMessageType.EXCEPTION
  989. result = ex
  990. except Exception:
  991. logging.exception('Unexpected exception in handler')
  992. msg_type = TMessageType.EXCEPTION
  993. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  994. oprot.writeMessageBegin("GetInfo", msg_type, seqid)
  995. result.write(oprot)
  996. oprot.writeMessageEnd()
  997. oprot.trans.flush()
  998. def process_ExecuteStatement(self, seqid, iprot, oprot):
  999. args = ExecuteStatement_args()
  1000. args.read(iprot)
  1001. iprot.readMessageEnd()
  1002. result = ExecuteStatement_result()
  1003. try:
  1004. result.success = self._handler.ExecuteStatement(args.req)
  1005. msg_type = TMessageType.REPLY
  1006. except TTransport.TTransportException:
  1007. raise
  1008. except TApplicationException as ex:
  1009. logging.exception('TApplication exception in handler')
  1010. msg_type = TMessageType.EXCEPTION
  1011. result = ex
  1012. except Exception:
  1013. logging.exception('Unexpected exception in handler')
  1014. msg_type = TMessageType.EXCEPTION
  1015. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1016. oprot.writeMessageBegin("ExecuteStatement", msg_type, seqid)
  1017. result.write(oprot)
  1018. oprot.writeMessageEnd()
  1019. oprot.trans.flush()
  1020. def process_GetTypeInfo(self, seqid, iprot, oprot):
  1021. args = GetTypeInfo_args()
  1022. args.read(iprot)
  1023. iprot.readMessageEnd()
  1024. result = GetTypeInfo_result()
  1025. try:
  1026. result.success = self._handler.GetTypeInfo(args.req)
  1027. msg_type = TMessageType.REPLY
  1028. except TTransport.TTransportException:
  1029. raise
  1030. except TApplicationException as ex:
  1031. logging.exception('TApplication exception in handler')
  1032. msg_type = TMessageType.EXCEPTION
  1033. result = ex
  1034. except Exception:
  1035. logging.exception('Unexpected exception in handler')
  1036. msg_type = TMessageType.EXCEPTION
  1037. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1038. oprot.writeMessageBegin("GetTypeInfo", msg_type, seqid)
  1039. result.write(oprot)
  1040. oprot.writeMessageEnd()
  1041. oprot.trans.flush()
  1042. def process_GetCatalogs(self, seqid, iprot, oprot):
  1043. args = GetCatalogs_args()
  1044. args.read(iprot)
  1045. iprot.readMessageEnd()
  1046. result = GetCatalogs_result()
  1047. try:
  1048. result.success = self._handler.GetCatalogs(args.req)
  1049. msg_type = TMessageType.REPLY
  1050. except TTransport.TTransportException:
  1051. raise
  1052. except TApplicationException as ex:
  1053. logging.exception('TApplication exception in handler')
  1054. msg_type = TMessageType.EXCEPTION
  1055. result = ex
  1056. except Exception:
  1057. logging.exception('Unexpected exception in handler')
  1058. msg_type = TMessageType.EXCEPTION
  1059. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1060. oprot.writeMessageBegin("GetCatalogs", msg_type, seqid)
  1061. result.write(oprot)
  1062. oprot.writeMessageEnd()
  1063. oprot.trans.flush()
  1064. def process_GetSchemas(self, seqid, iprot, oprot):
  1065. args = GetSchemas_args()
  1066. args.read(iprot)
  1067. iprot.readMessageEnd()
  1068. result = GetSchemas_result()
  1069. try:
  1070. result.success = self._handler.GetSchemas(args.req)
  1071. msg_type = TMessageType.REPLY
  1072. except TTransport.TTransportException:
  1073. raise
  1074. except TApplicationException as ex:
  1075. logging.exception('TApplication exception in handler')
  1076. msg_type = TMessageType.EXCEPTION
  1077. result = ex
  1078. except Exception:
  1079. logging.exception('Unexpected exception in handler')
  1080. msg_type = TMessageType.EXCEPTION
  1081. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1082. oprot.writeMessageBegin("GetSchemas", msg_type, seqid)
  1083. result.write(oprot)
  1084. oprot.writeMessageEnd()
  1085. oprot.trans.flush()
  1086. def process_GetTables(self, seqid, iprot, oprot):
  1087. args = GetTables_args()
  1088. args.read(iprot)
  1089. iprot.readMessageEnd()
  1090. result = GetTables_result()
  1091. try:
  1092. result.success = self._handler.GetTables(args.req)
  1093. msg_type = TMessageType.REPLY
  1094. except TTransport.TTransportException:
  1095. raise
  1096. except TApplicationException as ex:
  1097. logging.exception('TApplication exception in handler')
  1098. msg_type = TMessageType.EXCEPTION
  1099. result = ex
  1100. except Exception:
  1101. logging.exception('Unexpected exception in handler')
  1102. msg_type = TMessageType.EXCEPTION
  1103. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1104. oprot.writeMessageBegin("GetTables", msg_type, seqid)
  1105. result.write(oprot)
  1106. oprot.writeMessageEnd()
  1107. oprot.trans.flush()
  1108. def process_GetTableTypes(self, seqid, iprot, oprot):
  1109. args = GetTableTypes_args()
  1110. args.read(iprot)
  1111. iprot.readMessageEnd()
  1112. result = GetTableTypes_result()
  1113. try:
  1114. result.success = self._handler.GetTableTypes(args.req)
  1115. msg_type = TMessageType.REPLY
  1116. except TTransport.TTransportException:
  1117. raise
  1118. except TApplicationException as ex:
  1119. logging.exception('TApplication exception in handler')
  1120. msg_type = TMessageType.EXCEPTION
  1121. result = ex
  1122. except Exception:
  1123. logging.exception('Unexpected exception in handler')
  1124. msg_type = TMessageType.EXCEPTION
  1125. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1126. oprot.writeMessageBegin("GetTableTypes", msg_type, seqid)
  1127. result.write(oprot)
  1128. oprot.writeMessageEnd()
  1129. oprot.trans.flush()
  1130. def process_GetColumns(self, seqid, iprot, oprot):
  1131. args = GetColumns_args()
  1132. args.read(iprot)
  1133. iprot.readMessageEnd()
  1134. result = GetColumns_result()
  1135. try:
  1136. result.success = self._handler.GetColumns(args.req)
  1137. msg_type = TMessageType.REPLY
  1138. except TTransport.TTransportException:
  1139. raise
  1140. except TApplicationException as ex:
  1141. logging.exception('TApplication exception in handler')
  1142. msg_type = TMessageType.EXCEPTION
  1143. result = ex
  1144. except Exception:
  1145. logging.exception('Unexpected exception in handler')
  1146. msg_type = TMessageType.EXCEPTION
  1147. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1148. oprot.writeMessageBegin("GetColumns", msg_type, seqid)
  1149. result.write(oprot)
  1150. oprot.writeMessageEnd()
  1151. oprot.trans.flush()
  1152. def process_GetFunctions(self, seqid, iprot, oprot):
  1153. args = GetFunctions_args()
  1154. args.read(iprot)
  1155. iprot.readMessageEnd()
  1156. result = GetFunctions_result()
  1157. try:
  1158. result.success = self._handler.GetFunctions(args.req)
  1159. msg_type = TMessageType.REPLY
  1160. except TTransport.TTransportException:
  1161. raise
  1162. except TApplicationException as ex:
  1163. logging.exception('TApplication exception in handler')
  1164. msg_type = TMessageType.EXCEPTION
  1165. result = ex
  1166. except Exception:
  1167. logging.exception('Unexpected exception in handler')
  1168. msg_type = TMessageType.EXCEPTION
  1169. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1170. oprot.writeMessageBegin("GetFunctions", msg_type, seqid)
  1171. result.write(oprot)
  1172. oprot.writeMessageEnd()
  1173. oprot.trans.flush()
  1174. def process_GetPrimaryKeys(self, seqid, iprot, oprot):
  1175. args = GetPrimaryKeys_args()
  1176. args.read(iprot)
  1177. iprot.readMessageEnd()
  1178. result = GetPrimaryKeys_result()
  1179. try:
  1180. result.success = self._handler.GetPrimaryKeys(args.req)
  1181. msg_type = TMessageType.REPLY
  1182. except TTransport.TTransportException:
  1183. raise
  1184. except TApplicationException as ex:
  1185. logging.exception('TApplication exception in handler')
  1186. msg_type = TMessageType.EXCEPTION
  1187. result = ex
  1188. except Exception:
  1189. logging.exception('Unexpected exception in handler')
  1190. msg_type = TMessageType.EXCEPTION
  1191. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1192. oprot.writeMessageBegin("GetPrimaryKeys", msg_type, seqid)
  1193. result.write(oprot)
  1194. oprot.writeMessageEnd()
  1195. oprot.trans.flush()
  1196. def process_GetCrossReference(self, seqid, iprot, oprot):
  1197. args = GetCrossReference_args()
  1198. args.read(iprot)
  1199. iprot.readMessageEnd()
  1200. result = GetCrossReference_result()
  1201. try:
  1202. result.success = self._handler.GetCrossReference(args.req)
  1203. msg_type = TMessageType.REPLY
  1204. except TTransport.TTransportException:
  1205. raise
  1206. except TApplicationException as ex:
  1207. logging.exception('TApplication exception in handler')
  1208. msg_type = TMessageType.EXCEPTION
  1209. result = ex
  1210. except Exception:
  1211. logging.exception('Unexpected exception in handler')
  1212. msg_type = TMessageType.EXCEPTION
  1213. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1214. oprot.writeMessageBegin("GetCrossReference", msg_type, seqid)
  1215. result.write(oprot)
  1216. oprot.writeMessageEnd()
  1217. oprot.trans.flush()
  1218. def process_GetOperationStatus(self, seqid, iprot, oprot):
  1219. args = GetOperationStatus_args()
  1220. args.read(iprot)
  1221. iprot.readMessageEnd()
  1222. result = GetOperationStatus_result()
  1223. try:
  1224. result.success = self._handler.GetOperationStatus(args.req)
  1225. msg_type = TMessageType.REPLY
  1226. except TTransport.TTransportException:
  1227. raise
  1228. except TApplicationException as ex:
  1229. logging.exception('TApplication exception in handler')
  1230. msg_type = TMessageType.EXCEPTION
  1231. result = ex
  1232. except Exception:
  1233. logging.exception('Unexpected exception in handler')
  1234. msg_type = TMessageType.EXCEPTION
  1235. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1236. oprot.writeMessageBegin("GetOperationStatus", msg_type, seqid)
  1237. result.write(oprot)
  1238. oprot.writeMessageEnd()
  1239. oprot.trans.flush()
  1240. def process_CancelOperation(self, seqid, iprot, oprot):
  1241. args = CancelOperation_args()
  1242. args.read(iprot)
  1243. iprot.readMessageEnd()
  1244. result = CancelOperation_result()
  1245. try:
  1246. result.success = self._handler.CancelOperation(args.req)
  1247. msg_type = TMessageType.REPLY
  1248. except TTransport.TTransportException:
  1249. raise
  1250. except TApplicationException as ex:
  1251. logging.exception('TApplication exception in handler')
  1252. msg_type = TMessageType.EXCEPTION
  1253. result = ex
  1254. except Exception:
  1255. logging.exception('Unexpected exception in handler')
  1256. msg_type = TMessageType.EXCEPTION
  1257. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1258. oprot.writeMessageBegin("CancelOperation", msg_type, seqid)
  1259. result.write(oprot)
  1260. oprot.writeMessageEnd()
  1261. oprot.trans.flush()
  1262. def process_CloseOperation(self, seqid, iprot, oprot):
  1263. args = CloseOperation_args()
  1264. args.read(iprot)
  1265. iprot.readMessageEnd()
  1266. result = CloseOperation_result()
  1267. try:
  1268. result.success = self._handler.CloseOperation(args.req)
  1269. msg_type = TMessageType.REPLY
  1270. except TTransport.TTransportException:
  1271. raise
  1272. except TApplicationException as ex:
  1273. logging.exception('TApplication exception in handler')
  1274. msg_type = TMessageType.EXCEPTION
  1275. result = ex
  1276. except Exception:
  1277. logging.exception('Unexpected exception in handler')
  1278. msg_type = TMessageType.EXCEPTION
  1279. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1280. oprot.writeMessageBegin("CloseOperation", msg_type, seqid)
  1281. result.write(oprot)
  1282. oprot.writeMessageEnd()
  1283. oprot.trans.flush()
  1284. def process_GetResultSetMetadata(self, seqid, iprot, oprot):
  1285. args = GetResultSetMetadata_args()
  1286. args.read(iprot)
  1287. iprot.readMessageEnd()
  1288. result = GetResultSetMetadata_result()
  1289. try:
  1290. result.success = self._handler.GetResultSetMetadata(args.req)
  1291. msg_type = TMessageType.REPLY
  1292. except TTransport.TTransportException:
  1293. raise
  1294. except TApplicationException as ex:
  1295. logging.exception('TApplication exception in handler')
  1296. msg_type = TMessageType.EXCEPTION
  1297. result = ex
  1298. except Exception:
  1299. logging.exception('Unexpected exception in handler')
  1300. msg_type = TMessageType.EXCEPTION
  1301. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1302. oprot.writeMessageBegin("GetResultSetMetadata", msg_type, seqid)
  1303. result.write(oprot)
  1304. oprot.writeMessageEnd()
  1305. oprot.trans.flush()
  1306. def process_FetchResults(self, seqid, iprot, oprot):
  1307. args = FetchResults_args()
  1308. args.read(iprot)
  1309. iprot.readMessageEnd()
  1310. result = FetchResults_result()
  1311. try:
  1312. result.success = self._handler.FetchResults(args.req)
  1313. msg_type = TMessageType.REPLY
  1314. except TTransport.TTransportException:
  1315. raise
  1316. except TApplicationException as ex:
  1317. logging.exception('TApplication exception in handler')
  1318. msg_type = TMessageType.EXCEPTION
  1319. result = ex
  1320. except Exception:
  1321. logging.exception('Unexpected exception in handler')
  1322. msg_type = TMessageType.EXCEPTION
  1323. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1324. oprot.writeMessageBegin("FetchResults", msg_type, seqid)
  1325. result.write(oprot)
  1326. oprot.writeMessageEnd()
  1327. oprot.trans.flush()
  1328. def process_GetDelegationToken(self, seqid, iprot, oprot):
  1329. args = GetDelegationToken_args()
  1330. args.read(iprot)
  1331. iprot.readMessageEnd()
  1332. result = GetDelegationToken_result()
  1333. try:
  1334. result.success = self._handler.GetDelegationToken(args.req)
  1335. msg_type = TMessageType.REPLY
  1336. except TTransport.TTransportException:
  1337. raise
  1338. except TApplicationException as ex:
  1339. logging.exception('TApplication exception in handler')
  1340. msg_type = TMessageType.EXCEPTION
  1341. result = ex
  1342. except Exception:
  1343. logging.exception('Unexpected exception in handler')
  1344. msg_type = TMessageType.EXCEPTION
  1345. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1346. oprot.writeMessageBegin("GetDelegationToken", msg_type, seqid)
  1347. result.write(oprot)
  1348. oprot.writeMessageEnd()
  1349. oprot.trans.flush()
  1350. def process_CancelDelegationToken(self, seqid, iprot, oprot):
  1351. args = CancelDelegationToken_args()
  1352. args.read(iprot)
  1353. iprot.readMessageEnd()
  1354. result = CancelDelegationToken_result()
  1355. try:
  1356. result.success = self._handler.CancelDelegationToken(args.req)
  1357. msg_type = TMessageType.REPLY
  1358. except TTransport.TTransportException:
  1359. raise
  1360. except TApplicationException as ex:
  1361. logging.exception('TApplication exception in handler')
  1362. msg_type = TMessageType.EXCEPTION
  1363. result = ex
  1364. except Exception:
  1365. logging.exception('Unexpected exception in handler')
  1366. msg_type = TMessageType.EXCEPTION
  1367. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1368. oprot.writeMessageBegin("CancelDelegationToken", msg_type, seqid)
  1369. result.write(oprot)
  1370. oprot.writeMessageEnd()
  1371. oprot.trans.flush()
  1372. def process_RenewDelegationToken(self, seqid, iprot, oprot):
  1373. args = RenewDelegationToken_args()
  1374. args.read(iprot)
  1375. iprot.readMessageEnd()
  1376. result = RenewDelegationToken_result()
  1377. try:
  1378. result.success = self._handler.RenewDelegationToken(args.req)
  1379. msg_type = TMessageType.REPLY
  1380. except TTransport.TTransportException:
  1381. raise
  1382. except TApplicationException as ex:
  1383. logging.exception('TApplication exception in handler')
  1384. msg_type = TMessageType.EXCEPTION
  1385. result = ex
  1386. except Exception:
  1387. logging.exception('Unexpected exception in handler')
  1388. msg_type = TMessageType.EXCEPTION
  1389. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1390. oprot.writeMessageBegin("RenewDelegationToken", msg_type, seqid)
  1391. result.write(oprot)
  1392. oprot.writeMessageEnd()
  1393. oprot.trans.flush()
  1394. def process_GetQueryId(self, seqid, iprot, oprot):
  1395. args = GetQueryId_args()
  1396. args.read(iprot)
  1397. iprot.readMessageEnd()
  1398. result = GetQueryId_result()
  1399. try:
  1400. result.success = self._handler.GetQueryId(args.req)
  1401. msg_type = TMessageType.REPLY
  1402. except TTransport.TTransportException:
  1403. raise
  1404. except TApplicationException as ex:
  1405. logging.exception('TApplication exception in handler')
  1406. msg_type = TMessageType.EXCEPTION
  1407. result = ex
  1408. except Exception:
  1409. logging.exception('Unexpected exception in handler')
  1410. msg_type = TMessageType.EXCEPTION
  1411. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1412. oprot.writeMessageBegin("GetQueryId", msg_type, seqid)
  1413. result.write(oprot)
  1414. oprot.writeMessageEnd()
  1415. oprot.trans.flush()
  1416. def process_SetClientInfo(self, seqid, iprot, oprot):
  1417. args = SetClientInfo_args()
  1418. args.read(iprot)
  1419. iprot.readMessageEnd()
  1420. result = SetClientInfo_result()
  1421. try:
  1422. result.success = self._handler.SetClientInfo(args.req)
  1423. msg_type = TMessageType.REPLY
  1424. except TTransport.TTransportException:
  1425. raise
  1426. except TApplicationException as ex:
  1427. logging.exception('TApplication exception in handler')
  1428. msg_type = TMessageType.EXCEPTION
  1429. result = ex
  1430. except Exception:
  1431. logging.exception('Unexpected exception in handler')
  1432. msg_type = TMessageType.EXCEPTION
  1433. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1434. oprot.writeMessageBegin("SetClientInfo", msg_type, seqid)
  1435. result.write(oprot)
  1436. oprot.writeMessageEnd()
  1437. oprot.trans.flush()
  1438. def process_GetLog(self, seqid, iprot, oprot):
  1439. args = GetLog_args()
  1440. args.read(iprot)
  1441. iprot.readMessageEnd()
  1442. result = GetLog_result()
  1443. try:
  1444. result.success = self._handler.GetLog(args.req)
  1445. msg_type = TMessageType.REPLY
  1446. except TTransport.TTransportException:
  1447. raise
  1448. except TApplicationException as ex:
  1449. logging.exception('TApplication exception in handler')
  1450. msg_type = TMessageType.EXCEPTION
  1451. result = ex
  1452. except Exception:
  1453. logging.exception('Unexpected exception in handler')
  1454. msg_type = TMessageType.EXCEPTION
  1455. result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
  1456. oprot.writeMessageBegin("GetLog", msg_type, seqid)
  1457. result.write(oprot)
  1458. oprot.writeMessageEnd()
  1459. oprot.trans.flush()
  1460. # HELPER FUNCTIONS AND STRUCTURES
  1461. class OpenSession_args(object):
  1462. """
  1463. Attributes:
  1464. - req
  1465. """
  1466. def __init__(self, req=None,):
  1467. self.req = req
  1468. def read(self, iprot):
  1469. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1470. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1471. return
  1472. iprot.readStructBegin()
  1473. while True:
  1474. (fname, ftype, fid) = iprot.readFieldBegin()
  1475. if ftype == TType.STOP:
  1476. break
  1477. if fid == 1:
  1478. if ftype == TType.STRUCT:
  1479. self.req = TOpenSessionReq()
  1480. self.req.read(iprot)
  1481. else:
  1482. iprot.skip(ftype)
  1483. else:
  1484. iprot.skip(ftype)
  1485. iprot.readFieldEnd()
  1486. iprot.readStructEnd()
  1487. def write(self, oprot):
  1488. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1489. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1490. return
  1491. oprot.writeStructBegin('OpenSession_args')
  1492. if self.req is not None:
  1493. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  1494. self.req.write(oprot)
  1495. oprot.writeFieldEnd()
  1496. oprot.writeFieldStop()
  1497. oprot.writeStructEnd()
  1498. def validate(self):
  1499. return
  1500. def __repr__(self):
  1501. L = ['%s=%r' % (key, value)
  1502. for key, value in self.__dict__.items()]
  1503. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1504. def __eq__(self, other):
  1505. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1506. def __ne__(self, other):
  1507. return not (self == other)
  1508. all_structs.append(OpenSession_args)
  1509. OpenSession_args.thrift_spec = (
  1510. None, # 0
  1511. (1, TType.STRUCT, 'req', [TOpenSessionReq, None], None, ), # 1
  1512. )
  1513. class OpenSession_result(object):
  1514. """
  1515. Attributes:
  1516. - success
  1517. """
  1518. def __init__(self, success=None,):
  1519. self.success = success
  1520. def read(self, iprot):
  1521. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1522. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1523. return
  1524. iprot.readStructBegin()
  1525. while True:
  1526. (fname, ftype, fid) = iprot.readFieldBegin()
  1527. if ftype == TType.STOP:
  1528. break
  1529. if fid == 0:
  1530. if ftype == TType.STRUCT:
  1531. self.success = TOpenSessionResp()
  1532. self.success.read(iprot)
  1533. else:
  1534. iprot.skip(ftype)
  1535. else:
  1536. iprot.skip(ftype)
  1537. iprot.readFieldEnd()
  1538. iprot.readStructEnd()
  1539. def write(self, oprot):
  1540. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1541. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1542. return
  1543. oprot.writeStructBegin('OpenSession_result')
  1544. if self.success is not None:
  1545. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  1546. self.success.write(oprot)
  1547. oprot.writeFieldEnd()
  1548. oprot.writeFieldStop()
  1549. oprot.writeStructEnd()
  1550. def validate(self):
  1551. return
  1552. def __repr__(self):
  1553. L = ['%s=%r' % (key, value)
  1554. for key, value in self.__dict__.items()]
  1555. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1556. def __eq__(self, other):
  1557. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1558. def __ne__(self, other):
  1559. return not (self == other)
  1560. all_structs.append(OpenSession_result)
  1561. OpenSession_result.thrift_spec = (
  1562. (0, TType.STRUCT, 'success', [TOpenSessionResp, None], None, ), # 0
  1563. )
  1564. class CloseSession_args(object):
  1565. """
  1566. Attributes:
  1567. - req
  1568. """
  1569. def __init__(self, req=None,):
  1570. self.req = req
  1571. def read(self, iprot):
  1572. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1573. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1574. return
  1575. iprot.readStructBegin()
  1576. while True:
  1577. (fname, ftype, fid) = iprot.readFieldBegin()
  1578. if ftype == TType.STOP:
  1579. break
  1580. if fid == 1:
  1581. if ftype == TType.STRUCT:
  1582. self.req = TCloseSessionReq()
  1583. self.req.read(iprot)
  1584. else:
  1585. iprot.skip(ftype)
  1586. else:
  1587. iprot.skip(ftype)
  1588. iprot.readFieldEnd()
  1589. iprot.readStructEnd()
  1590. def write(self, oprot):
  1591. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1592. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1593. return
  1594. oprot.writeStructBegin('CloseSession_args')
  1595. if self.req is not None:
  1596. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  1597. self.req.write(oprot)
  1598. oprot.writeFieldEnd()
  1599. oprot.writeFieldStop()
  1600. oprot.writeStructEnd()
  1601. def validate(self):
  1602. return
  1603. def __repr__(self):
  1604. L = ['%s=%r' % (key, value)
  1605. for key, value in self.__dict__.items()]
  1606. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1607. def __eq__(self, other):
  1608. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1609. def __ne__(self, other):
  1610. return not (self == other)
  1611. all_structs.append(CloseSession_args)
  1612. CloseSession_args.thrift_spec = (
  1613. None, # 0
  1614. (1, TType.STRUCT, 'req', [TCloseSessionReq, None], None, ), # 1
  1615. )
  1616. class CloseSession_result(object):
  1617. """
  1618. Attributes:
  1619. - success
  1620. """
  1621. def __init__(self, success=None,):
  1622. self.success = success
  1623. def read(self, iprot):
  1624. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1625. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1626. return
  1627. iprot.readStructBegin()
  1628. while True:
  1629. (fname, ftype, fid) = iprot.readFieldBegin()
  1630. if ftype == TType.STOP:
  1631. break
  1632. if fid == 0:
  1633. if ftype == TType.STRUCT:
  1634. self.success = TCloseSessionResp()
  1635. self.success.read(iprot)
  1636. else:
  1637. iprot.skip(ftype)
  1638. else:
  1639. iprot.skip(ftype)
  1640. iprot.readFieldEnd()
  1641. iprot.readStructEnd()
  1642. def write(self, oprot):
  1643. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1644. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1645. return
  1646. oprot.writeStructBegin('CloseSession_result')
  1647. if self.success is not None:
  1648. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  1649. self.success.write(oprot)
  1650. oprot.writeFieldEnd()
  1651. oprot.writeFieldStop()
  1652. oprot.writeStructEnd()
  1653. def validate(self):
  1654. return
  1655. def __repr__(self):
  1656. L = ['%s=%r' % (key, value)
  1657. for key, value in self.__dict__.items()]
  1658. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1659. def __eq__(self, other):
  1660. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1661. def __ne__(self, other):
  1662. return not (self == other)
  1663. all_structs.append(CloseSession_result)
  1664. CloseSession_result.thrift_spec = (
  1665. (0, TType.STRUCT, 'success', [TCloseSessionResp, None], None, ), # 0
  1666. )
  1667. class GetInfo_args(object):
  1668. """
  1669. Attributes:
  1670. - req
  1671. """
  1672. def __init__(self, req=None,):
  1673. self.req = req
  1674. def read(self, iprot):
  1675. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1676. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1677. return
  1678. iprot.readStructBegin()
  1679. while True:
  1680. (fname, ftype, fid) = iprot.readFieldBegin()
  1681. if ftype == TType.STOP:
  1682. break
  1683. if fid == 1:
  1684. if ftype == TType.STRUCT:
  1685. self.req = TGetInfoReq()
  1686. self.req.read(iprot)
  1687. else:
  1688. iprot.skip(ftype)
  1689. else:
  1690. iprot.skip(ftype)
  1691. iprot.readFieldEnd()
  1692. iprot.readStructEnd()
  1693. def write(self, oprot):
  1694. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1695. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1696. return
  1697. oprot.writeStructBegin('GetInfo_args')
  1698. if self.req is not None:
  1699. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  1700. self.req.write(oprot)
  1701. oprot.writeFieldEnd()
  1702. oprot.writeFieldStop()
  1703. oprot.writeStructEnd()
  1704. def validate(self):
  1705. return
  1706. def __repr__(self):
  1707. L = ['%s=%r' % (key, value)
  1708. for key, value in self.__dict__.items()]
  1709. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1710. def __eq__(self, other):
  1711. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1712. def __ne__(self, other):
  1713. return not (self == other)
  1714. all_structs.append(GetInfo_args)
  1715. GetInfo_args.thrift_spec = (
  1716. None, # 0
  1717. (1, TType.STRUCT, 'req', [TGetInfoReq, None], None, ), # 1
  1718. )
  1719. class GetInfo_result(object):
  1720. """
  1721. Attributes:
  1722. - success
  1723. """
  1724. def __init__(self, success=None,):
  1725. self.success = success
  1726. def read(self, iprot):
  1727. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1728. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1729. return
  1730. iprot.readStructBegin()
  1731. while True:
  1732. (fname, ftype, fid) = iprot.readFieldBegin()
  1733. if ftype == TType.STOP:
  1734. break
  1735. if fid == 0:
  1736. if ftype == TType.STRUCT:
  1737. self.success = TGetInfoResp()
  1738. self.success.read(iprot)
  1739. else:
  1740. iprot.skip(ftype)
  1741. else:
  1742. iprot.skip(ftype)
  1743. iprot.readFieldEnd()
  1744. iprot.readStructEnd()
  1745. def write(self, oprot):
  1746. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1747. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1748. return
  1749. oprot.writeStructBegin('GetInfo_result')
  1750. if self.success is not None:
  1751. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  1752. self.success.write(oprot)
  1753. oprot.writeFieldEnd()
  1754. oprot.writeFieldStop()
  1755. oprot.writeStructEnd()
  1756. def validate(self):
  1757. return
  1758. def __repr__(self):
  1759. L = ['%s=%r' % (key, value)
  1760. for key, value in self.__dict__.items()]
  1761. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1762. def __eq__(self, other):
  1763. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1764. def __ne__(self, other):
  1765. return not (self == other)
  1766. all_structs.append(GetInfo_result)
  1767. GetInfo_result.thrift_spec = (
  1768. (0, TType.STRUCT, 'success', [TGetInfoResp, None], None, ), # 0
  1769. )
  1770. class ExecuteStatement_args(object):
  1771. """
  1772. Attributes:
  1773. - req
  1774. """
  1775. def __init__(self, req=None,):
  1776. self.req = req
  1777. def read(self, iprot):
  1778. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1779. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1780. return
  1781. iprot.readStructBegin()
  1782. while True:
  1783. (fname, ftype, fid) = iprot.readFieldBegin()
  1784. if ftype == TType.STOP:
  1785. break
  1786. if fid == 1:
  1787. if ftype == TType.STRUCT:
  1788. self.req = TExecuteStatementReq()
  1789. self.req.read(iprot)
  1790. else:
  1791. iprot.skip(ftype)
  1792. else:
  1793. iprot.skip(ftype)
  1794. iprot.readFieldEnd()
  1795. iprot.readStructEnd()
  1796. def write(self, oprot):
  1797. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1798. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1799. return
  1800. oprot.writeStructBegin('ExecuteStatement_args')
  1801. if self.req is not None:
  1802. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  1803. self.req.write(oprot)
  1804. oprot.writeFieldEnd()
  1805. oprot.writeFieldStop()
  1806. oprot.writeStructEnd()
  1807. def validate(self):
  1808. return
  1809. def __repr__(self):
  1810. L = ['%s=%r' % (key, value)
  1811. for key, value in self.__dict__.items()]
  1812. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1813. def __eq__(self, other):
  1814. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1815. def __ne__(self, other):
  1816. return not (self == other)
  1817. all_structs.append(ExecuteStatement_args)
  1818. ExecuteStatement_args.thrift_spec = (
  1819. None, # 0
  1820. (1, TType.STRUCT, 'req', [TExecuteStatementReq, None], None, ), # 1
  1821. )
  1822. class ExecuteStatement_result(object):
  1823. """
  1824. Attributes:
  1825. - success
  1826. """
  1827. def __init__(self, success=None,):
  1828. self.success = success
  1829. def read(self, iprot):
  1830. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1831. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1832. return
  1833. iprot.readStructBegin()
  1834. while True:
  1835. (fname, ftype, fid) = iprot.readFieldBegin()
  1836. if ftype == TType.STOP:
  1837. break
  1838. if fid == 0:
  1839. if ftype == TType.STRUCT:
  1840. self.success = TExecuteStatementResp()
  1841. self.success.read(iprot)
  1842. else:
  1843. iprot.skip(ftype)
  1844. else:
  1845. iprot.skip(ftype)
  1846. iprot.readFieldEnd()
  1847. iprot.readStructEnd()
  1848. def write(self, oprot):
  1849. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1850. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1851. return
  1852. oprot.writeStructBegin('ExecuteStatement_result')
  1853. if self.success is not None:
  1854. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  1855. self.success.write(oprot)
  1856. oprot.writeFieldEnd()
  1857. oprot.writeFieldStop()
  1858. oprot.writeStructEnd()
  1859. def validate(self):
  1860. return
  1861. def __repr__(self):
  1862. L = ['%s=%r' % (key, value)
  1863. for key, value in self.__dict__.items()]
  1864. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1865. def __eq__(self, other):
  1866. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1867. def __ne__(self, other):
  1868. return not (self == other)
  1869. all_structs.append(ExecuteStatement_result)
  1870. ExecuteStatement_result.thrift_spec = (
  1871. (0, TType.STRUCT, 'success', [TExecuteStatementResp, None], None, ), # 0
  1872. )
  1873. class GetTypeInfo_args(object):
  1874. """
  1875. Attributes:
  1876. - req
  1877. """
  1878. def __init__(self, req=None,):
  1879. self.req = req
  1880. def read(self, iprot):
  1881. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1882. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1883. return
  1884. iprot.readStructBegin()
  1885. while True:
  1886. (fname, ftype, fid) = iprot.readFieldBegin()
  1887. if ftype == TType.STOP:
  1888. break
  1889. if fid == 1:
  1890. if ftype == TType.STRUCT:
  1891. self.req = TGetTypeInfoReq()
  1892. self.req.read(iprot)
  1893. else:
  1894. iprot.skip(ftype)
  1895. else:
  1896. iprot.skip(ftype)
  1897. iprot.readFieldEnd()
  1898. iprot.readStructEnd()
  1899. def write(self, oprot):
  1900. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1901. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1902. return
  1903. oprot.writeStructBegin('GetTypeInfo_args')
  1904. if self.req is not None:
  1905. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  1906. self.req.write(oprot)
  1907. oprot.writeFieldEnd()
  1908. oprot.writeFieldStop()
  1909. oprot.writeStructEnd()
  1910. def validate(self):
  1911. return
  1912. def __repr__(self):
  1913. L = ['%s=%r' % (key, value)
  1914. for key, value in self.__dict__.items()]
  1915. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1916. def __eq__(self, other):
  1917. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1918. def __ne__(self, other):
  1919. return not (self == other)
  1920. all_structs.append(GetTypeInfo_args)
  1921. GetTypeInfo_args.thrift_spec = (
  1922. None, # 0
  1923. (1, TType.STRUCT, 'req', [TGetTypeInfoReq, None], None, ), # 1
  1924. )
  1925. class GetTypeInfo_result(object):
  1926. """
  1927. Attributes:
  1928. - success
  1929. """
  1930. def __init__(self, success=None,):
  1931. self.success = success
  1932. def read(self, iprot):
  1933. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1934. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1935. return
  1936. iprot.readStructBegin()
  1937. while True:
  1938. (fname, ftype, fid) = iprot.readFieldBegin()
  1939. if ftype == TType.STOP:
  1940. break
  1941. if fid == 0:
  1942. if ftype == TType.STRUCT:
  1943. self.success = TGetTypeInfoResp()
  1944. self.success.read(iprot)
  1945. else:
  1946. iprot.skip(ftype)
  1947. else:
  1948. iprot.skip(ftype)
  1949. iprot.readFieldEnd()
  1950. iprot.readStructEnd()
  1951. def write(self, oprot):
  1952. if oprot._fast_encode is not None and self.thrift_spec is not None:
  1953. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  1954. return
  1955. oprot.writeStructBegin('GetTypeInfo_result')
  1956. if self.success is not None:
  1957. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  1958. self.success.write(oprot)
  1959. oprot.writeFieldEnd()
  1960. oprot.writeFieldStop()
  1961. oprot.writeStructEnd()
  1962. def validate(self):
  1963. return
  1964. def __repr__(self):
  1965. L = ['%s=%r' % (key, value)
  1966. for key, value in self.__dict__.items()]
  1967. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1968. def __eq__(self, other):
  1969. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1970. def __ne__(self, other):
  1971. return not (self == other)
  1972. all_structs.append(GetTypeInfo_result)
  1973. GetTypeInfo_result.thrift_spec = (
  1974. (0, TType.STRUCT, 'success', [TGetTypeInfoResp, None], None, ), # 0
  1975. )
  1976. class GetCatalogs_args(object):
  1977. """
  1978. Attributes:
  1979. - req
  1980. """
  1981. def __init__(self, req=None,):
  1982. self.req = req
  1983. def read(self, iprot):
  1984. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  1985. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  1986. return
  1987. iprot.readStructBegin()
  1988. while True:
  1989. (fname, ftype, fid) = iprot.readFieldBegin()
  1990. if ftype == TType.STOP:
  1991. break
  1992. if fid == 1:
  1993. if ftype == TType.STRUCT:
  1994. self.req = TGetCatalogsReq()
  1995. self.req.read(iprot)
  1996. else:
  1997. iprot.skip(ftype)
  1998. else:
  1999. iprot.skip(ftype)
  2000. iprot.readFieldEnd()
  2001. iprot.readStructEnd()
  2002. def write(self, oprot):
  2003. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2004. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2005. return
  2006. oprot.writeStructBegin('GetCatalogs_args')
  2007. if self.req is not None:
  2008. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2009. self.req.write(oprot)
  2010. oprot.writeFieldEnd()
  2011. oprot.writeFieldStop()
  2012. oprot.writeStructEnd()
  2013. def validate(self):
  2014. return
  2015. def __repr__(self):
  2016. L = ['%s=%r' % (key, value)
  2017. for key, value in self.__dict__.items()]
  2018. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2019. def __eq__(self, other):
  2020. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2021. def __ne__(self, other):
  2022. return not (self == other)
  2023. all_structs.append(GetCatalogs_args)
  2024. GetCatalogs_args.thrift_spec = (
  2025. None, # 0
  2026. (1, TType.STRUCT, 'req', [TGetCatalogsReq, None], None, ), # 1
  2027. )
  2028. class GetCatalogs_result(object):
  2029. """
  2030. Attributes:
  2031. - success
  2032. """
  2033. def __init__(self, success=None,):
  2034. self.success = success
  2035. def read(self, iprot):
  2036. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2037. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2038. return
  2039. iprot.readStructBegin()
  2040. while True:
  2041. (fname, ftype, fid) = iprot.readFieldBegin()
  2042. if ftype == TType.STOP:
  2043. break
  2044. if fid == 0:
  2045. if ftype == TType.STRUCT:
  2046. self.success = TGetCatalogsResp()
  2047. self.success.read(iprot)
  2048. else:
  2049. iprot.skip(ftype)
  2050. else:
  2051. iprot.skip(ftype)
  2052. iprot.readFieldEnd()
  2053. iprot.readStructEnd()
  2054. def write(self, oprot):
  2055. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2056. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2057. return
  2058. oprot.writeStructBegin('GetCatalogs_result')
  2059. if self.success is not None:
  2060. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2061. self.success.write(oprot)
  2062. oprot.writeFieldEnd()
  2063. oprot.writeFieldStop()
  2064. oprot.writeStructEnd()
  2065. def validate(self):
  2066. return
  2067. def __repr__(self):
  2068. L = ['%s=%r' % (key, value)
  2069. for key, value in self.__dict__.items()]
  2070. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2071. def __eq__(self, other):
  2072. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2073. def __ne__(self, other):
  2074. return not (self == other)
  2075. all_structs.append(GetCatalogs_result)
  2076. GetCatalogs_result.thrift_spec = (
  2077. (0, TType.STRUCT, 'success', [TGetCatalogsResp, None], None, ), # 0
  2078. )
  2079. class GetSchemas_args(object):
  2080. """
  2081. Attributes:
  2082. - req
  2083. """
  2084. def __init__(self, req=None,):
  2085. self.req = req
  2086. def read(self, iprot):
  2087. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2088. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2089. return
  2090. iprot.readStructBegin()
  2091. while True:
  2092. (fname, ftype, fid) = iprot.readFieldBegin()
  2093. if ftype == TType.STOP:
  2094. break
  2095. if fid == 1:
  2096. if ftype == TType.STRUCT:
  2097. self.req = TGetSchemasReq()
  2098. self.req.read(iprot)
  2099. else:
  2100. iprot.skip(ftype)
  2101. else:
  2102. iprot.skip(ftype)
  2103. iprot.readFieldEnd()
  2104. iprot.readStructEnd()
  2105. def write(self, oprot):
  2106. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2107. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2108. return
  2109. oprot.writeStructBegin('GetSchemas_args')
  2110. if self.req is not None:
  2111. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2112. self.req.write(oprot)
  2113. oprot.writeFieldEnd()
  2114. oprot.writeFieldStop()
  2115. oprot.writeStructEnd()
  2116. def validate(self):
  2117. return
  2118. def __repr__(self):
  2119. L = ['%s=%r' % (key, value)
  2120. for key, value in self.__dict__.items()]
  2121. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2122. def __eq__(self, other):
  2123. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2124. def __ne__(self, other):
  2125. return not (self == other)
  2126. all_structs.append(GetSchemas_args)
  2127. GetSchemas_args.thrift_spec = (
  2128. None, # 0
  2129. (1, TType.STRUCT, 'req', [TGetSchemasReq, None], None, ), # 1
  2130. )
  2131. class GetSchemas_result(object):
  2132. """
  2133. Attributes:
  2134. - success
  2135. """
  2136. def __init__(self, success=None,):
  2137. self.success = success
  2138. def read(self, iprot):
  2139. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2140. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2141. return
  2142. iprot.readStructBegin()
  2143. while True:
  2144. (fname, ftype, fid) = iprot.readFieldBegin()
  2145. if ftype == TType.STOP:
  2146. break
  2147. if fid == 0:
  2148. if ftype == TType.STRUCT:
  2149. self.success = TGetSchemasResp()
  2150. self.success.read(iprot)
  2151. else:
  2152. iprot.skip(ftype)
  2153. else:
  2154. iprot.skip(ftype)
  2155. iprot.readFieldEnd()
  2156. iprot.readStructEnd()
  2157. def write(self, oprot):
  2158. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2159. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2160. return
  2161. oprot.writeStructBegin('GetSchemas_result')
  2162. if self.success is not None:
  2163. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2164. self.success.write(oprot)
  2165. oprot.writeFieldEnd()
  2166. oprot.writeFieldStop()
  2167. oprot.writeStructEnd()
  2168. def validate(self):
  2169. return
  2170. def __repr__(self):
  2171. L = ['%s=%r' % (key, value)
  2172. for key, value in self.__dict__.items()]
  2173. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2174. def __eq__(self, other):
  2175. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2176. def __ne__(self, other):
  2177. return not (self == other)
  2178. all_structs.append(GetSchemas_result)
  2179. GetSchemas_result.thrift_spec = (
  2180. (0, TType.STRUCT, 'success', [TGetSchemasResp, None], None, ), # 0
  2181. )
  2182. class GetTables_args(object):
  2183. """
  2184. Attributes:
  2185. - req
  2186. """
  2187. def __init__(self, req=None,):
  2188. self.req = req
  2189. def read(self, iprot):
  2190. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2191. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2192. return
  2193. iprot.readStructBegin()
  2194. while True:
  2195. (fname, ftype, fid) = iprot.readFieldBegin()
  2196. if ftype == TType.STOP:
  2197. break
  2198. if fid == 1:
  2199. if ftype == TType.STRUCT:
  2200. self.req = TGetTablesReq()
  2201. self.req.read(iprot)
  2202. else:
  2203. iprot.skip(ftype)
  2204. else:
  2205. iprot.skip(ftype)
  2206. iprot.readFieldEnd()
  2207. iprot.readStructEnd()
  2208. def write(self, oprot):
  2209. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2210. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2211. return
  2212. oprot.writeStructBegin('GetTables_args')
  2213. if self.req is not None:
  2214. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2215. self.req.write(oprot)
  2216. oprot.writeFieldEnd()
  2217. oprot.writeFieldStop()
  2218. oprot.writeStructEnd()
  2219. def validate(self):
  2220. return
  2221. def __repr__(self):
  2222. L = ['%s=%r' % (key, value)
  2223. for key, value in self.__dict__.items()]
  2224. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2225. def __eq__(self, other):
  2226. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2227. def __ne__(self, other):
  2228. return not (self == other)
  2229. all_structs.append(GetTables_args)
  2230. GetTables_args.thrift_spec = (
  2231. None, # 0
  2232. (1, TType.STRUCT, 'req', [TGetTablesReq, None], None, ), # 1
  2233. )
  2234. class GetTables_result(object):
  2235. """
  2236. Attributes:
  2237. - success
  2238. """
  2239. def __init__(self, success=None,):
  2240. self.success = success
  2241. def read(self, iprot):
  2242. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2243. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2244. return
  2245. iprot.readStructBegin()
  2246. while True:
  2247. (fname, ftype, fid) = iprot.readFieldBegin()
  2248. if ftype == TType.STOP:
  2249. break
  2250. if fid == 0:
  2251. if ftype == TType.STRUCT:
  2252. self.success = TGetTablesResp()
  2253. self.success.read(iprot)
  2254. else:
  2255. iprot.skip(ftype)
  2256. else:
  2257. iprot.skip(ftype)
  2258. iprot.readFieldEnd()
  2259. iprot.readStructEnd()
  2260. def write(self, oprot):
  2261. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2262. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2263. return
  2264. oprot.writeStructBegin('GetTables_result')
  2265. if self.success is not None:
  2266. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2267. self.success.write(oprot)
  2268. oprot.writeFieldEnd()
  2269. oprot.writeFieldStop()
  2270. oprot.writeStructEnd()
  2271. def validate(self):
  2272. return
  2273. def __repr__(self):
  2274. L = ['%s=%r' % (key, value)
  2275. for key, value in self.__dict__.items()]
  2276. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2277. def __eq__(self, other):
  2278. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2279. def __ne__(self, other):
  2280. return not (self == other)
  2281. all_structs.append(GetTables_result)
  2282. GetTables_result.thrift_spec = (
  2283. (0, TType.STRUCT, 'success', [TGetTablesResp, None], None, ), # 0
  2284. )
  2285. class GetTableTypes_args(object):
  2286. """
  2287. Attributes:
  2288. - req
  2289. """
  2290. def __init__(self, req=None,):
  2291. self.req = req
  2292. def read(self, iprot):
  2293. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2294. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2295. return
  2296. iprot.readStructBegin()
  2297. while True:
  2298. (fname, ftype, fid) = iprot.readFieldBegin()
  2299. if ftype == TType.STOP:
  2300. break
  2301. if fid == 1:
  2302. if ftype == TType.STRUCT:
  2303. self.req = TGetTableTypesReq()
  2304. self.req.read(iprot)
  2305. else:
  2306. iprot.skip(ftype)
  2307. else:
  2308. iprot.skip(ftype)
  2309. iprot.readFieldEnd()
  2310. iprot.readStructEnd()
  2311. def write(self, oprot):
  2312. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2313. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2314. return
  2315. oprot.writeStructBegin('GetTableTypes_args')
  2316. if self.req is not None:
  2317. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2318. self.req.write(oprot)
  2319. oprot.writeFieldEnd()
  2320. oprot.writeFieldStop()
  2321. oprot.writeStructEnd()
  2322. def validate(self):
  2323. return
  2324. def __repr__(self):
  2325. L = ['%s=%r' % (key, value)
  2326. for key, value in self.__dict__.items()]
  2327. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2328. def __eq__(self, other):
  2329. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2330. def __ne__(self, other):
  2331. return not (self == other)
  2332. all_structs.append(GetTableTypes_args)
  2333. GetTableTypes_args.thrift_spec = (
  2334. None, # 0
  2335. (1, TType.STRUCT, 'req', [TGetTableTypesReq, None], None, ), # 1
  2336. )
  2337. class GetTableTypes_result(object):
  2338. """
  2339. Attributes:
  2340. - success
  2341. """
  2342. def __init__(self, success=None,):
  2343. self.success = success
  2344. def read(self, iprot):
  2345. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2346. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2347. return
  2348. iprot.readStructBegin()
  2349. while True:
  2350. (fname, ftype, fid) = iprot.readFieldBegin()
  2351. if ftype == TType.STOP:
  2352. break
  2353. if fid == 0:
  2354. if ftype == TType.STRUCT:
  2355. self.success = TGetTableTypesResp()
  2356. self.success.read(iprot)
  2357. else:
  2358. iprot.skip(ftype)
  2359. else:
  2360. iprot.skip(ftype)
  2361. iprot.readFieldEnd()
  2362. iprot.readStructEnd()
  2363. def write(self, oprot):
  2364. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2365. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2366. return
  2367. oprot.writeStructBegin('GetTableTypes_result')
  2368. if self.success is not None:
  2369. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2370. self.success.write(oprot)
  2371. oprot.writeFieldEnd()
  2372. oprot.writeFieldStop()
  2373. oprot.writeStructEnd()
  2374. def validate(self):
  2375. return
  2376. def __repr__(self):
  2377. L = ['%s=%r' % (key, value)
  2378. for key, value in self.__dict__.items()]
  2379. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2380. def __eq__(self, other):
  2381. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2382. def __ne__(self, other):
  2383. return not (self == other)
  2384. all_structs.append(GetTableTypes_result)
  2385. GetTableTypes_result.thrift_spec = (
  2386. (0, TType.STRUCT, 'success', [TGetTableTypesResp, None], None, ), # 0
  2387. )
  2388. class GetColumns_args(object):
  2389. """
  2390. Attributes:
  2391. - req
  2392. """
  2393. def __init__(self, req=None,):
  2394. self.req = req
  2395. def read(self, iprot):
  2396. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2397. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2398. return
  2399. iprot.readStructBegin()
  2400. while True:
  2401. (fname, ftype, fid) = iprot.readFieldBegin()
  2402. if ftype == TType.STOP:
  2403. break
  2404. if fid == 1:
  2405. if ftype == TType.STRUCT:
  2406. self.req = TGetColumnsReq()
  2407. self.req.read(iprot)
  2408. else:
  2409. iprot.skip(ftype)
  2410. else:
  2411. iprot.skip(ftype)
  2412. iprot.readFieldEnd()
  2413. iprot.readStructEnd()
  2414. def write(self, oprot):
  2415. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2416. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2417. return
  2418. oprot.writeStructBegin('GetColumns_args')
  2419. if self.req is not None:
  2420. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2421. self.req.write(oprot)
  2422. oprot.writeFieldEnd()
  2423. oprot.writeFieldStop()
  2424. oprot.writeStructEnd()
  2425. def validate(self):
  2426. return
  2427. def __repr__(self):
  2428. L = ['%s=%r' % (key, value)
  2429. for key, value in self.__dict__.items()]
  2430. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2431. def __eq__(self, other):
  2432. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2433. def __ne__(self, other):
  2434. return not (self == other)
  2435. all_structs.append(GetColumns_args)
  2436. GetColumns_args.thrift_spec = (
  2437. None, # 0
  2438. (1, TType.STRUCT, 'req', [TGetColumnsReq, None], None, ), # 1
  2439. )
  2440. class GetColumns_result(object):
  2441. """
  2442. Attributes:
  2443. - success
  2444. """
  2445. def __init__(self, success=None,):
  2446. self.success = success
  2447. def read(self, iprot):
  2448. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2449. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2450. return
  2451. iprot.readStructBegin()
  2452. while True:
  2453. (fname, ftype, fid) = iprot.readFieldBegin()
  2454. if ftype == TType.STOP:
  2455. break
  2456. if fid == 0:
  2457. if ftype == TType.STRUCT:
  2458. self.success = TGetColumnsResp()
  2459. self.success.read(iprot)
  2460. else:
  2461. iprot.skip(ftype)
  2462. else:
  2463. iprot.skip(ftype)
  2464. iprot.readFieldEnd()
  2465. iprot.readStructEnd()
  2466. def write(self, oprot):
  2467. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2468. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2469. return
  2470. oprot.writeStructBegin('GetColumns_result')
  2471. if self.success is not None:
  2472. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2473. self.success.write(oprot)
  2474. oprot.writeFieldEnd()
  2475. oprot.writeFieldStop()
  2476. oprot.writeStructEnd()
  2477. def validate(self):
  2478. return
  2479. def __repr__(self):
  2480. L = ['%s=%r' % (key, value)
  2481. for key, value in self.__dict__.items()]
  2482. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2483. def __eq__(self, other):
  2484. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2485. def __ne__(self, other):
  2486. return not (self == other)
  2487. all_structs.append(GetColumns_result)
  2488. GetColumns_result.thrift_spec = (
  2489. (0, TType.STRUCT, 'success', [TGetColumnsResp, None], None, ), # 0
  2490. )
  2491. class GetFunctions_args(object):
  2492. """
  2493. Attributes:
  2494. - req
  2495. """
  2496. def __init__(self, req=None,):
  2497. self.req = req
  2498. def read(self, iprot):
  2499. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2500. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2501. return
  2502. iprot.readStructBegin()
  2503. while True:
  2504. (fname, ftype, fid) = iprot.readFieldBegin()
  2505. if ftype == TType.STOP:
  2506. break
  2507. if fid == 1:
  2508. if ftype == TType.STRUCT:
  2509. self.req = TGetFunctionsReq()
  2510. self.req.read(iprot)
  2511. else:
  2512. iprot.skip(ftype)
  2513. else:
  2514. iprot.skip(ftype)
  2515. iprot.readFieldEnd()
  2516. iprot.readStructEnd()
  2517. def write(self, oprot):
  2518. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2519. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2520. return
  2521. oprot.writeStructBegin('GetFunctions_args')
  2522. if self.req is not None:
  2523. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2524. self.req.write(oprot)
  2525. oprot.writeFieldEnd()
  2526. oprot.writeFieldStop()
  2527. oprot.writeStructEnd()
  2528. def validate(self):
  2529. return
  2530. def __repr__(self):
  2531. L = ['%s=%r' % (key, value)
  2532. for key, value in self.__dict__.items()]
  2533. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2534. def __eq__(self, other):
  2535. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2536. def __ne__(self, other):
  2537. return not (self == other)
  2538. all_structs.append(GetFunctions_args)
  2539. GetFunctions_args.thrift_spec = (
  2540. None, # 0
  2541. (1, TType.STRUCT, 'req', [TGetFunctionsReq, None], None, ), # 1
  2542. )
  2543. class GetFunctions_result(object):
  2544. """
  2545. Attributes:
  2546. - success
  2547. """
  2548. def __init__(self, success=None,):
  2549. self.success = success
  2550. def read(self, iprot):
  2551. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2552. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2553. return
  2554. iprot.readStructBegin()
  2555. while True:
  2556. (fname, ftype, fid) = iprot.readFieldBegin()
  2557. if ftype == TType.STOP:
  2558. break
  2559. if fid == 0:
  2560. if ftype == TType.STRUCT:
  2561. self.success = TGetFunctionsResp()
  2562. self.success.read(iprot)
  2563. else:
  2564. iprot.skip(ftype)
  2565. else:
  2566. iprot.skip(ftype)
  2567. iprot.readFieldEnd()
  2568. iprot.readStructEnd()
  2569. def write(self, oprot):
  2570. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2571. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2572. return
  2573. oprot.writeStructBegin('GetFunctions_result')
  2574. if self.success is not None:
  2575. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2576. self.success.write(oprot)
  2577. oprot.writeFieldEnd()
  2578. oprot.writeFieldStop()
  2579. oprot.writeStructEnd()
  2580. def validate(self):
  2581. return
  2582. def __repr__(self):
  2583. L = ['%s=%r' % (key, value)
  2584. for key, value in self.__dict__.items()]
  2585. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2586. def __eq__(self, other):
  2587. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2588. def __ne__(self, other):
  2589. return not (self == other)
  2590. all_structs.append(GetFunctions_result)
  2591. GetFunctions_result.thrift_spec = (
  2592. (0, TType.STRUCT, 'success', [TGetFunctionsResp, None], None, ), # 0
  2593. )
  2594. class GetPrimaryKeys_args(object):
  2595. """
  2596. Attributes:
  2597. - req
  2598. """
  2599. def __init__(self, req=None,):
  2600. self.req = req
  2601. def read(self, iprot):
  2602. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2603. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2604. return
  2605. iprot.readStructBegin()
  2606. while True:
  2607. (fname, ftype, fid) = iprot.readFieldBegin()
  2608. if ftype == TType.STOP:
  2609. break
  2610. if fid == 1:
  2611. if ftype == TType.STRUCT:
  2612. self.req = TGetPrimaryKeysReq()
  2613. self.req.read(iprot)
  2614. else:
  2615. iprot.skip(ftype)
  2616. else:
  2617. iprot.skip(ftype)
  2618. iprot.readFieldEnd()
  2619. iprot.readStructEnd()
  2620. def write(self, oprot):
  2621. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2622. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2623. return
  2624. oprot.writeStructBegin('GetPrimaryKeys_args')
  2625. if self.req is not None:
  2626. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2627. self.req.write(oprot)
  2628. oprot.writeFieldEnd()
  2629. oprot.writeFieldStop()
  2630. oprot.writeStructEnd()
  2631. def validate(self):
  2632. return
  2633. def __repr__(self):
  2634. L = ['%s=%r' % (key, value)
  2635. for key, value in self.__dict__.items()]
  2636. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2637. def __eq__(self, other):
  2638. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2639. def __ne__(self, other):
  2640. return not (self == other)
  2641. all_structs.append(GetPrimaryKeys_args)
  2642. GetPrimaryKeys_args.thrift_spec = (
  2643. None, # 0
  2644. (1, TType.STRUCT, 'req', [TGetPrimaryKeysReq, None], None, ), # 1
  2645. )
  2646. class GetPrimaryKeys_result(object):
  2647. """
  2648. Attributes:
  2649. - success
  2650. """
  2651. def __init__(self, success=None,):
  2652. self.success = success
  2653. def read(self, iprot):
  2654. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2655. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2656. return
  2657. iprot.readStructBegin()
  2658. while True:
  2659. (fname, ftype, fid) = iprot.readFieldBegin()
  2660. if ftype == TType.STOP:
  2661. break
  2662. if fid == 0:
  2663. if ftype == TType.STRUCT:
  2664. self.success = TGetPrimaryKeysResp()
  2665. self.success.read(iprot)
  2666. else:
  2667. iprot.skip(ftype)
  2668. else:
  2669. iprot.skip(ftype)
  2670. iprot.readFieldEnd()
  2671. iprot.readStructEnd()
  2672. def write(self, oprot):
  2673. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2674. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2675. return
  2676. oprot.writeStructBegin('GetPrimaryKeys_result')
  2677. if self.success is not None:
  2678. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2679. self.success.write(oprot)
  2680. oprot.writeFieldEnd()
  2681. oprot.writeFieldStop()
  2682. oprot.writeStructEnd()
  2683. def validate(self):
  2684. return
  2685. def __repr__(self):
  2686. L = ['%s=%r' % (key, value)
  2687. for key, value in self.__dict__.items()]
  2688. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2689. def __eq__(self, other):
  2690. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2691. def __ne__(self, other):
  2692. return not (self == other)
  2693. all_structs.append(GetPrimaryKeys_result)
  2694. GetPrimaryKeys_result.thrift_spec = (
  2695. (0, TType.STRUCT, 'success', [TGetPrimaryKeysResp, None], None, ), # 0
  2696. )
  2697. class GetCrossReference_args(object):
  2698. """
  2699. Attributes:
  2700. - req
  2701. """
  2702. def __init__(self, req=None,):
  2703. self.req = req
  2704. def read(self, iprot):
  2705. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2706. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2707. return
  2708. iprot.readStructBegin()
  2709. while True:
  2710. (fname, ftype, fid) = iprot.readFieldBegin()
  2711. if ftype == TType.STOP:
  2712. break
  2713. if fid == 1:
  2714. if ftype == TType.STRUCT:
  2715. self.req = TGetCrossReferenceReq()
  2716. self.req.read(iprot)
  2717. else:
  2718. iprot.skip(ftype)
  2719. else:
  2720. iprot.skip(ftype)
  2721. iprot.readFieldEnd()
  2722. iprot.readStructEnd()
  2723. def write(self, oprot):
  2724. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2725. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2726. return
  2727. oprot.writeStructBegin('GetCrossReference_args')
  2728. if self.req is not None:
  2729. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2730. self.req.write(oprot)
  2731. oprot.writeFieldEnd()
  2732. oprot.writeFieldStop()
  2733. oprot.writeStructEnd()
  2734. def validate(self):
  2735. return
  2736. def __repr__(self):
  2737. L = ['%s=%r' % (key, value)
  2738. for key, value in self.__dict__.items()]
  2739. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2740. def __eq__(self, other):
  2741. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2742. def __ne__(self, other):
  2743. return not (self == other)
  2744. all_structs.append(GetCrossReference_args)
  2745. GetCrossReference_args.thrift_spec = (
  2746. None, # 0
  2747. (1, TType.STRUCT, 'req', [TGetCrossReferenceReq, None], None, ), # 1
  2748. )
  2749. class GetCrossReference_result(object):
  2750. """
  2751. Attributes:
  2752. - success
  2753. """
  2754. def __init__(self, success=None,):
  2755. self.success = success
  2756. def read(self, iprot):
  2757. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2758. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2759. return
  2760. iprot.readStructBegin()
  2761. while True:
  2762. (fname, ftype, fid) = iprot.readFieldBegin()
  2763. if ftype == TType.STOP:
  2764. break
  2765. if fid == 0:
  2766. if ftype == TType.STRUCT:
  2767. self.success = TGetCrossReferenceResp()
  2768. self.success.read(iprot)
  2769. else:
  2770. iprot.skip(ftype)
  2771. else:
  2772. iprot.skip(ftype)
  2773. iprot.readFieldEnd()
  2774. iprot.readStructEnd()
  2775. def write(self, oprot):
  2776. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2777. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2778. return
  2779. oprot.writeStructBegin('GetCrossReference_result')
  2780. if self.success is not None:
  2781. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2782. self.success.write(oprot)
  2783. oprot.writeFieldEnd()
  2784. oprot.writeFieldStop()
  2785. oprot.writeStructEnd()
  2786. def validate(self):
  2787. return
  2788. def __repr__(self):
  2789. L = ['%s=%r' % (key, value)
  2790. for key, value in self.__dict__.items()]
  2791. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2792. def __eq__(self, other):
  2793. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2794. def __ne__(self, other):
  2795. return not (self == other)
  2796. all_structs.append(GetCrossReference_result)
  2797. GetCrossReference_result.thrift_spec = (
  2798. (0, TType.STRUCT, 'success', [TGetCrossReferenceResp, None], None, ), # 0
  2799. )
  2800. class GetOperationStatus_args(object):
  2801. """
  2802. Attributes:
  2803. - req
  2804. """
  2805. def __init__(self, req=None,):
  2806. self.req = req
  2807. def read(self, iprot):
  2808. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2809. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2810. return
  2811. iprot.readStructBegin()
  2812. while True:
  2813. (fname, ftype, fid) = iprot.readFieldBegin()
  2814. if ftype == TType.STOP:
  2815. break
  2816. if fid == 1:
  2817. if ftype == TType.STRUCT:
  2818. self.req = TGetOperationStatusReq()
  2819. self.req.read(iprot)
  2820. else:
  2821. iprot.skip(ftype)
  2822. else:
  2823. iprot.skip(ftype)
  2824. iprot.readFieldEnd()
  2825. iprot.readStructEnd()
  2826. def write(self, oprot):
  2827. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2828. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2829. return
  2830. oprot.writeStructBegin('GetOperationStatus_args')
  2831. if self.req is not None:
  2832. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2833. self.req.write(oprot)
  2834. oprot.writeFieldEnd()
  2835. oprot.writeFieldStop()
  2836. oprot.writeStructEnd()
  2837. def validate(self):
  2838. return
  2839. def __repr__(self):
  2840. L = ['%s=%r' % (key, value)
  2841. for key, value in self.__dict__.items()]
  2842. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2843. def __eq__(self, other):
  2844. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2845. def __ne__(self, other):
  2846. return not (self == other)
  2847. all_structs.append(GetOperationStatus_args)
  2848. GetOperationStatus_args.thrift_spec = (
  2849. None, # 0
  2850. (1, TType.STRUCT, 'req', [TGetOperationStatusReq, None], None, ), # 1
  2851. )
  2852. class GetOperationStatus_result(object):
  2853. """
  2854. Attributes:
  2855. - success
  2856. """
  2857. def __init__(self, success=None,):
  2858. self.success = success
  2859. def read(self, iprot):
  2860. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2861. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2862. return
  2863. iprot.readStructBegin()
  2864. while True:
  2865. (fname, ftype, fid) = iprot.readFieldBegin()
  2866. if ftype == TType.STOP:
  2867. break
  2868. if fid == 0:
  2869. if ftype == TType.STRUCT:
  2870. self.success = TGetOperationStatusResp()
  2871. self.success.read(iprot)
  2872. else:
  2873. iprot.skip(ftype)
  2874. else:
  2875. iprot.skip(ftype)
  2876. iprot.readFieldEnd()
  2877. iprot.readStructEnd()
  2878. def write(self, oprot):
  2879. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2880. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2881. return
  2882. oprot.writeStructBegin('GetOperationStatus_result')
  2883. if self.success is not None:
  2884. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2885. self.success.write(oprot)
  2886. oprot.writeFieldEnd()
  2887. oprot.writeFieldStop()
  2888. oprot.writeStructEnd()
  2889. def validate(self):
  2890. return
  2891. def __repr__(self):
  2892. L = ['%s=%r' % (key, value)
  2893. for key, value in self.__dict__.items()]
  2894. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2895. def __eq__(self, other):
  2896. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2897. def __ne__(self, other):
  2898. return not (self == other)
  2899. all_structs.append(GetOperationStatus_result)
  2900. GetOperationStatus_result.thrift_spec = (
  2901. (0, TType.STRUCT, 'success', [TGetOperationStatusResp, None], None, ), # 0
  2902. )
  2903. class CancelOperation_args(object):
  2904. """
  2905. Attributes:
  2906. - req
  2907. """
  2908. def __init__(self, req=None,):
  2909. self.req = req
  2910. def read(self, iprot):
  2911. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2912. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2913. return
  2914. iprot.readStructBegin()
  2915. while True:
  2916. (fname, ftype, fid) = iprot.readFieldBegin()
  2917. if ftype == TType.STOP:
  2918. break
  2919. if fid == 1:
  2920. if ftype == TType.STRUCT:
  2921. self.req = TCancelOperationReq()
  2922. self.req.read(iprot)
  2923. else:
  2924. iprot.skip(ftype)
  2925. else:
  2926. iprot.skip(ftype)
  2927. iprot.readFieldEnd()
  2928. iprot.readStructEnd()
  2929. def write(self, oprot):
  2930. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2931. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2932. return
  2933. oprot.writeStructBegin('CancelOperation_args')
  2934. if self.req is not None:
  2935. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  2936. self.req.write(oprot)
  2937. oprot.writeFieldEnd()
  2938. oprot.writeFieldStop()
  2939. oprot.writeStructEnd()
  2940. def validate(self):
  2941. return
  2942. def __repr__(self):
  2943. L = ['%s=%r' % (key, value)
  2944. for key, value in self.__dict__.items()]
  2945. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2946. def __eq__(self, other):
  2947. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  2948. def __ne__(self, other):
  2949. return not (self == other)
  2950. all_structs.append(CancelOperation_args)
  2951. CancelOperation_args.thrift_spec = (
  2952. None, # 0
  2953. (1, TType.STRUCT, 'req', [TCancelOperationReq, None], None, ), # 1
  2954. )
  2955. class CancelOperation_result(object):
  2956. """
  2957. Attributes:
  2958. - success
  2959. """
  2960. def __init__(self, success=None,):
  2961. self.success = success
  2962. def read(self, iprot):
  2963. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  2964. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  2965. return
  2966. iprot.readStructBegin()
  2967. while True:
  2968. (fname, ftype, fid) = iprot.readFieldBegin()
  2969. if ftype == TType.STOP:
  2970. break
  2971. if fid == 0:
  2972. if ftype == TType.STRUCT:
  2973. self.success = TCancelOperationResp()
  2974. self.success.read(iprot)
  2975. else:
  2976. iprot.skip(ftype)
  2977. else:
  2978. iprot.skip(ftype)
  2979. iprot.readFieldEnd()
  2980. iprot.readStructEnd()
  2981. def write(self, oprot):
  2982. if oprot._fast_encode is not None and self.thrift_spec is not None:
  2983. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  2984. return
  2985. oprot.writeStructBegin('CancelOperation_result')
  2986. if self.success is not None:
  2987. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  2988. self.success.write(oprot)
  2989. oprot.writeFieldEnd()
  2990. oprot.writeFieldStop()
  2991. oprot.writeStructEnd()
  2992. def validate(self):
  2993. return
  2994. def __repr__(self):
  2995. L = ['%s=%r' % (key, value)
  2996. for key, value in self.__dict__.items()]
  2997. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  2998. def __eq__(self, other):
  2999. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3000. def __ne__(self, other):
  3001. return not (self == other)
  3002. all_structs.append(CancelOperation_result)
  3003. CancelOperation_result.thrift_spec = (
  3004. (0, TType.STRUCT, 'success', [TCancelOperationResp, None], None, ), # 0
  3005. )
  3006. class CloseOperation_args(object):
  3007. """
  3008. Attributes:
  3009. - req
  3010. """
  3011. def __init__(self, req=None,):
  3012. self.req = req
  3013. def read(self, iprot):
  3014. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3015. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3016. return
  3017. iprot.readStructBegin()
  3018. while True:
  3019. (fname, ftype, fid) = iprot.readFieldBegin()
  3020. if ftype == TType.STOP:
  3021. break
  3022. if fid == 1:
  3023. if ftype == TType.STRUCT:
  3024. self.req = TCloseOperationReq()
  3025. self.req.read(iprot)
  3026. else:
  3027. iprot.skip(ftype)
  3028. else:
  3029. iprot.skip(ftype)
  3030. iprot.readFieldEnd()
  3031. iprot.readStructEnd()
  3032. def write(self, oprot):
  3033. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3034. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3035. return
  3036. oprot.writeStructBegin('CloseOperation_args')
  3037. if self.req is not None:
  3038. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3039. self.req.write(oprot)
  3040. oprot.writeFieldEnd()
  3041. oprot.writeFieldStop()
  3042. oprot.writeStructEnd()
  3043. def validate(self):
  3044. return
  3045. def __repr__(self):
  3046. L = ['%s=%r' % (key, value)
  3047. for key, value in self.__dict__.items()]
  3048. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3049. def __eq__(self, other):
  3050. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3051. def __ne__(self, other):
  3052. return not (self == other)
  3053. all_structs.append(CloseOperation_args)
  3054. CloseOperation_args.thrift_spec = (
  3055. None, # 0
  3056. (1, TType.STRUCT, 'req', [TCloseOperationReq, None], None, ), # 1
  3057. )
  3058. class CloseOperation_result(object):
  3059. """
  3060. Attributes:
  3061. - success
  3062. """
  3063. def __init__(self, success=None,):
  3064. self.success = success
  3065. def read(self, iprot):
  3066. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3067. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3068. return
  3069. iprot.readStructBegin()
  3070. while True:
  3071. (fname, ftype, fid) = iprot.readFieldBegin()
  3072. if ftype == TType.STOP:
  3073. break
  3074. if fid == 0:
  3075. if ftype == TType.STRUCT:
  3076. self.success = TCloseOperationResp()
  3077. self.success.read(iprot)
  3078. else:
  3079. iprot.skip(ftype)
  3080. else:
  3081. iprot.skip(ftype)
  3082. iprot.readFieldEnd()
  3083. iprot.readStructEnd()
  3084. def write(self, oprot):
  3085. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3086. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3087. return
  3088. oprot.writeStructBegin('CloseOperation_result')
  3089. if self.success is not None:
  3090. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3091. self.success.write(oprot)
  3092. oprot.writeFieldEnd()
  3093. oprot.writeFieldStop()
  3094. oprot.writeStructEnd()
  3095. def validate(self):
  3096. return
  3097. def __repr__(self):
  3098. L = ['%s=%r' % (key, value)
  3099. for key, value in self.__dict__.items()]
  3100. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3101. def __eq__(self, other):
  3102. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3103. def __ne__(self, other):
  3104. return not (self == other)
  3105. all_structs.append(CloseOperation_result)
  3106. CloseOperation_result.thrift_spec = (
  3107. (0, TType.STRUCT, 'success', [TCloseOperationResp, None], None, ), # 0
  3108. )
  3109. class GetResultSetMetadata_args(object):
  3110. """
  3111. Attributes:
  3112. - req
  3113. """
  3114. def __init__(self, req=None,):
  3115. self.req = req
  3116. def read(self, iprot):
  3117. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3118. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3119. return
  3120. iprot.readStructBegin()
  3121. while True:
  3122. (fname, ftype, fid) = iprot.readFieldBegin()
  3123. if ftype == TType.STOP:
  3124. break
  3125. if fid == 1:
  3126. if ftype == TType.STRUCT:
  3127. self.req = TGetResultSetMetadataReq()
  3128. self.req.read(iprot)
  3129. else:
  3130. iprot.skip(ftype)
  3131. else:
  3132. iprot.skip(ftype)
  3133. iprot.readFieldEnd()
  3134. iprot.readStructEnd()
  3135. def write(self, oprot):
  3136. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3137. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3138. return
  3139. oprot.writeStructBegin('GetResultSetMetadata_args')
  3140. if self.req is not None:
  3141. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3142. self.req.write(oprot)
  3143. oprot.writeFieldEnd()
  3144. oprot.writeFieldStop()
  3145. oprot.writeStructEnd()
  3146. def validate(self):
  3147. return
  3148. def __repr__(self):
  3149. L = ['%s=%r' % (key, value)
  3150. for key, value in self.__dict__.items()]
  3151. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3152. def __eq__(self, other):
  3153. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3154. def __ne__(self, other):
  3155. return not (self == other)
  3156. all_structs.append(GetResultSetMetadata_args)
  3157. GetResultSetMetadata_args.thrift_spec = (
  3158. None, # 0
  3159. (1, TType.STRUCT, 'req', [TGetResultSetMetadataReq, None], None, ), # 1
  3160. )
  3161. class GetResultSetMetadata_result(object):
  3162. """
  3163. Attributes:
  3164. - success
  3165. """
  3166. def __init__(self, success=None,):
  3167. self.success = success
  3168. def read(self, iprot):
  3169. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3170. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3171. return
  3172. iprot.readStructBegin()
  3173. while True:
  3174. (fname, ftype, fid) = iprot.readFieldBegin()
  3175. if ftype == TType.STOP:
  3176. break
  3177. if fid == 0:
  3178. if ftype == TType.STRUCT:
  3179. self.success = TGetResultSetMetadataResp()
  3180. self.success.read(iprot)
  3181. else:
  3182. iprot.skip(ftype)
  3183. else:
  3184. iprot.skip(ftype)
  3185. iprot.readFieldEnd()
  3186. iprot.readStructEnd()
  3187. def write(self, oprot):
  3188. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3189. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3190. return
  3191. oprot.writeStructBegin('GetResultSetMetadata_result')
  3192. if self.success is not None:
  3193. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3194. self.success.write(oprot)
  3195. oprot.writeFieldEnd()
  3196. oprot.writeFieldStop()
  3197. oprot.writeStructEnd()
  3198. def validate(self):
  3199. return
  3200. def __repr__(self):
  3201. L = ['%s=%r' % (key, value)
  3202. for key, value in self.__dict__.items()]
  3203. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3204. def __eq__(self, other):
  3205. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3206. def __ne__(self, other):
  3207. return not (self == other)
  3208. all_structs.append(GetResultSetMetadata_result)
  3209. GetResultSetMetadata_result.thrift_spec = (
  3210. (0, TType.STRUCT, 'success', [TGetResultSetMetadataResp, None], None, ), # 0
  3211. )
  3212. class FetchResults_args(object):
  3213. """
  3214. Attributes:
  3215. - req
  3216. """
  3217. def __init__(self, req=None,):
  3218. self.req = req
  3219. def read(self, iprot):
  3220. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3221. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3222. return
  3223. iprot.readStructBegin()
  3224. while True:
  3225. (fname, ftype, fid) = iprot.readFieldBegin()
  3226. if ftype == TType.STOP:
  3227. break
  3228. if fid == 1:
  3229. if ftype == TType.STRUCT:
  3230. self.req = TFetchResultsReq()
  3231. self.req.read(iprot)
  3232. else:
  3233. iprot.skip(ftype)
  3234. else:
  3235. iprot.skip(ftype)
  3236. iprot.readFieldEnd()
  3237. iprot.readStructEnd()
  3238. def write(self, oprot):
  3239. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3240. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3241. return
  3242. oprot.writeStructBegin('FetchResults_args')
  3243. if self.req is not None:
  3244. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3245. self.req.write(oprot)
  3246. oprot.writeFieldEnd()
  3247. oprot.writeFieldStop()
  3248. oprot.writeStructEnd()
  3249. def validate(self):
  3250. return
  3251. def __repr__(self):
  3252. L = ['%s=%r' % (key, value)
  3253. for key, value in self.__dict__.items()]
  3254. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3255. def __eq__(self, other):
  3256. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3257. def __ne__(self, other):
  3258. return not (self == other)
  3259. all_structs.append(FetchResults_args)
  3260. FetchResults_args.thrift_spec = (
  3261. None, # 0
  3262. (1, TType.STRUCT, 'req', [TFetchResultsReq, None], None, ), # 1
  3263. )
  3264. class FetchResults_result(object):
  3265. """
  3266. Attributes:
  3267. - success
  3268. """
  3269. def __init__(self, success=None,):
  3270. self.success = success
  3271. def read(self, iprot):
  3272. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3273. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3274. return
  3275. iprot.readStructBegin()
  3276. while True:
  3277. (fname, ftype, fid) = iprot.readFieldBegin()
  3278. if ftype == TType.STOP:
  3279. break
  3280. if fid == 0:
  3281. if ftype == TType.STRUCT:
  3282. self.success = TFetchResultsResp()
  3283. self.success.read(iprot)
  3284. else:
  3285. iprot.skip(ftype)
  3286. else:
  3287. iprot.skip(ftype)
  3288. iprot.readFieldEnd()
  3289. iprot.readStructEnd()
  3290. def write(self, oprot):
  3291. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3292. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3293. return
  3294. oprot.writeStructBegin('FetchResults_result')
  3295. if self.success is not None:
  3296. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3297. self.success.write(oprot)
  3298. oprot.writeFieldEnd()
  3299. oprot.writeFieldStop()
  3300. oprot.writeStructEnd()
  3301. def validate(self):
  3302. return
  3303. def __repr__(self):
  3304. L = ['%s=%r' % (key, value)
  3305. for key, value in self.__dict__.items()]
  3306. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3307. def __eq__(self, other):
  3308. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3309. def __ne__(self, other):
  3310. return not (self == other)
  3311. all_structs.append(FetchResults_result)
  3312. FetchResults_result.thrift_spec = (
  3313. (0, TType.STRUCT, 'success', [TFetchResultsResp, None], None, ), # 0
  3314. )
  3315. class GetDelegationToken_args(object):
  3316. """
  3317. Attributes:
  3318. - req
  3319. """
  3320. def __init__(self, req=None,):
  3321. self.req = req
  3322. def read(self, iprot):
  3323. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3324. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3325. return
  3326. iprot.readStructBegin()
  3327. while True:
  3328. (fname, ftype, fid) = iprot.readFieldBegin()
  3329. if ftype == TType.STOP:
  3330. break
  3331. if fid == 1:
  3332. if ftype == TType.STRUCT:
  3333. self.req = TGetDelegationTokenReq()
  3334. self.req.read(iprot)
  3335. else:
  3336. iprot.skip(ftype)
  3337. else:
  3338. iprot.skip(ftype)
  3339. iprot.readFieldEnd()
  3340. iprot.readStructEnd()
  3341. def write(self, oprot):
  3342. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3343. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3344. return
  3345. oprot.writeStructBegin('GetDelegationToken_args')
  3346. if self.req is not None:
  3347. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3348. self.req.write(oprot)
  3349. oprot.writeFieldEnd()
  3350. oprot.writeFieldStop()
  3351. oprot.writeStructEnd()
  3352. def validate(self):
  3353. return
  3354. def __repr__(self):
  3355. L = ['%s=%r' % (key, value)
  3356. for key, value in self.__dict__.items()]
  3357. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3358. def __eq__(self, other):
  3359. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3360. def __ne__(self, other):
  3361. return not (self == other)
  3362. all_structs.append(GetDelegationToken_args)
  3363. GetDelegationToken_args.thrift_spec = (
  3364. None, # 0
  3365. (1, TType.STRUCT, 'req', [TGetDelegationTokenReq, None], None, ), # 1
  3366. )
  3367. class GetDelegationToken_result(object):
  3368. """
  3369. Attributes:
  3370. - success
  3371. """
  3372. def __init__(self, success=None,):
  3373. self.success = success
  3374. def read(self, iprot):
  3375. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3376. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3377. return
  3378. iprot.readStructBegin()
  3379. while True:
  3380. (fname, ftype, fid) = iprot.readFieldBegin()
  3381. if ftype == TType.STOP:
  3382. break
  3383. if fid == 0:
  3384. if ftype == TType.STRUCT:
  3385. self.success = TGetDelegationTokenResp()
  3386. self.success.read(iprot)
  3387. else:
  3388. iprot.skip(ftype)
  3389. else:
  3390. iprot.skip(ftype)
  3391. iprot.readFieldEnd()
  3392. iprot.readStructEnd()
  3393. def write(self, oprot):
  3394. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3395. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3396. return
  3397. oprot.writeStructBegin('GetDelegationToken_result')
  3398. if self.success is not None:
  3399. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3400. self.success.write(oprot)
  3401. oprot.writeFieldEnd()
  3402. oprot.writeFieldStop()
  3403. oprot.writeStructEnd()
  3404. def validate(self):
  3405. return
  3406. def __repr__(self):
  3407. L = ['%s=%r' % (key, value)
  3408. for key, value in self.__dict__.items()]
  3409. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3410. def __eq__(self, other):
  3411. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3412. def __ne__(self, other):
  3413. return not (self == other)
  3414. all_structs.append(GetDelegationToken_result)
  3415. GetDelegationToken_result.thrift_spec = (
  3416. (0, TType.STRUCT, 'success', [TGetDelegationTokenResp, None], None, ), # 0
  3417. )
  3418. class CancelDelegationToken_args(object):
  3419. """
  3420. Attributes:
  3421. - req
  3422. """
  3423. def __init__(self, req=None,):
  3424. self.req = req
  3425. def read(self, iprot):
  3426. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3427. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3428. return
  3429. iprot.readStructBegin()
  3430. while True:
  3431. (fname, ftype, fid) = iprot.readFieldBegin()
  3432. if ftype == TType.STOP:
  3433. break
  3434. if fid == 1:
  3435. if ftype == TType.STRUCT:
  3436. self.req = TCancelDelegationTokenReq()
  3437. self.req.read(iprot)
  3438. else:
  3439. iprot.skip(ftype)
  3440. else:
  3441. iprot.skip(ftype)
  3442. iprot.readFieldEnd()
  3443. iprot.readStructEnd()
  3444. def write(self, oprot):
  3445. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3446. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3447. return
  3448. oprot.writeStructBegin('CancelDelegationToken_args')
  3449. if self.req is not None:
  3450. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3451. self.req.write(oprot)
  3452. oprot.writeFieldEnd()
  3453. oprot.writeFieldStop()
  3454. oprot.writeStructEnd()
  3455. def validate(self):
  3456. return
  3457. def __repr__(self):
  3458. L = ['%s=%r' % (key, value)
  3459. for key, value in self.__dict__.items()]
  3460. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3461. def __eq__(self, other):
  3462. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3463. def __ne__(self, other):
  3464. return not (self == other)
  3465. all_structs.append(CancelDelegationToken_args)
  3466. CancelDelegationToken_args.thrift_spec = (
  3467. None, # 0
  3468. (1, TType.STRUCT, 'req', [TCancelDelegationTokenReq, None], None, ), # 1
  3469. )
  3470. class CancelDelegationToken_result(object):
  3471. """
  3472. Attributes:
  3473. - success
  3474. """
  3475. def __init__(self, success=None,):
  3476. self.success = success
  3477. def read(self, iprot):
  3478. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3479. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3480. return
  3481. iprot.readStructBegin()
  3482. while True:
  3483. (fname, ftype, fid) = iprot.readFieldBegin()
  3484. if ftype == TType.STOP:
  3485. break
  3486. if fid == 0:
  3487. if ftype == TType.STRUCT:
  3488. self.success = TCancelDelegationTokenResp()
  3489. self.success.read(iprot)
  3490. else:
  3491. iprot.skip(ftype)
  3492. else:
  3493. iprot.skip(ftype)
  3494. iprot.readFieldEnd()
  3495. iprot.readStructEnd()
  3496. def write(self, oprot):
  3497. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3498. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3499. return
  3500. oprot.writeStructBegin('CancelDelegationToken_result')
  3501. if self.success is not None:
  3502. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3503. self.success.write(oprot)
  3504. oprot.writeFieldEnd()
  3505. oprot.writeFieldStop()
  3506. oprot.writeStructEnd()
  3507. def validate(self):
  3508. return
  3509. def __repr__(self):
  3510. L = ['%s=%r' % (key, value)
  3511. for key, value in self.__dict__.items()]
  3512. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3513. def __eq__(self, other):
  3514. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3515. def __ne__(self, other):
  3516. return not (self == other)
  3517. all_structs.append(CancelDelegationToken_result)
  3518. CancelDelegationToken_result.thrift_spec = (
  3519. (0, TType.STRUCT, 'success', [TCancelDelegationTokenResp, None], None, ), # 0
  3520. )
  3521. class RenewDelegationToken_args(object):
  3522. """
  3523. Attributes:
  3524. - req
  3525. """
  3526. def __init__(self, req=None,):
  3527. self.req = req
  3528. def read(self, iprot):
  3529. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3530. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3531. return
  3532. iprot.readStructBegin()
  3533. while True:
  3534. (fname, ftype, fid) = iprot.readFieldBegin()
  3535. if ftype == TType.STOP:
  3536. break
  3537. if fid == 1:
  3538. if ftype == TType.STRUCT:
  3539. self.req = TRenewDelegationTokenReq()
  3540. self.req.read(iprot)
  3541. else:
  3542. iprot.skip(ftype)
  3543. else:
  3544. iprot.skip(ftype)
  3545. iprot.readFieldEnd()
  3546. iprot.readStructEnd()
  3547. def write(self, oprot):
  3548. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3549. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3550. return
  3551. oprot.writeStructBegin('RenewDelegationToken_args')
  3552. if self.req is not None:
  3553. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3554. self.req.write(oprot)
  3555. oprot.writeFieldEnd()
  3556. oprot.writeFieldStop()
  3557. oprot.writeStructEnd()
  3558. def validate(self):
  3559. return
  3560. def __repr__(self):
  3561. L = ['%s=%r' % (key, value)
  3562. for key, value in self.__dict__.items()]
  3563. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3564. def __eq__(self, other):
  3565. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3566. def __ne__(self, other):
  3567. return not (self == other)
  3568. all_structs.append(RenewDelegationToken_args)
  3569. RenewDelegationToken_args.thrift_spec = (
  3570. None, # 0
  3571. (1, TType.STRUCT, 'req', [TRenewDelegationTokenReq, None], None, ), # 1
  3572. )
  3573. class RenewDelegationToken_result(object):
  3574. """
  3575. Attributes:
  3576. - success
  3577. """
  3578. def __init__(self, success=None,):
  3579. self.success = success
  3580. def read(self, iprot):
  3581. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3582. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3583. return
  3584. iprot.readStructBegin()
  3585. while True:
  3586. (fname, ftype, fid) = iprot.readFieldBegin()
  3587. if ftype == TType.STOP:
  3588. break
  3589. if fid == 0:
  3590. if ftype == TType.STRUCT:
  3591. self.success = TRenewDelegationTokenResp()
  3592. self.success.read(iprot)
  3593. else:
  3594. iprot.skip(ftype)
  3595. else:
  3596. iprot.skip(ftype)
  3597. iprot.readFieldEnd()
  3598. iprot.readStructEnd()
  3599. def write(self, oprot):
  3600. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3601. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3602. return
  3603. oprot.writeStructBegin('RenewDelegationToken_result')
  3604. if self.success is not None:
  3605. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3606. self.success.write(oprot)
  3607. oprot.writeFieldEnd()
  3608. oprot.writeFieldStop()
  3609. oprot.writeStructEnd()
  3610. def validate(self):
  3611. return
  3612. def __repr__(self):
  3613. L = ['%s=%r' % (key, value)
  3614. for key, value in self.__dict__.items()]
  3615. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3616. def __eq__(self, other):
  3617. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3618. def __ne__(self, other):
  3619. return not (self == other)
  3620. all_structs.append(RenewDelegationToken_result)
  3621. RenewDelegationToken_result.thrift_spec = (
  3622. (0, TType.STRUCT, 'success', [TRenewDelegationTokenResp, None], None, ), # 0
  3623. )
  3624. class GetQueryId_args(object):
  3625. """
  3626. Attributes:
  3627. - req
  3628. """
  3629. def __init__(self, req=None,):
  3630. self.req = req
  3631. def read(self, iprot):
  3632. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3633. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3634. return
  3635. iprot.readStructBegin()
  3636. while True:
  3637. (fname, ftype, fid) = iprot.readFieldBegin()
  3638. if ftype == TType.STOP:
  3639. break
  3640. if fid == 1:
  3641. if ftype == TType.STRUCT:
  3642. self.req = TGetQueryIdReq()
  3643. self.req.read(iprot)
  3644. else:
  3645. iprot.skip(ftype)
  3646. else:
  3647. iprot.skip(ftype)
  3648. iprot.readFieldEnd()
  3649. iprot.readStructEnd()
  3650. def write(self, oprot):
  3651. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3652. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3653. return
  3654. oprot.writeStructBegin('GetQueryId_args')
  3655. if self.req is not None:
  3656. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3657. self.req.write(oprot)
  3658. oprot.writeFieldEnd()
  3659. oprot.writeFieldStop()
  3660. oprot.writeStructEnd()
  3661. def validate(self):
  3662. return
  3663. def __repr__(self):
  3664. L = ['%s=%r' % (key, value)
  3665. for key, value in self.__dict__.items()]
  3666. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3667. def __eq__(self, other):
  3668. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3669. def __ne__(self, other):
  3670. return not (self == other)
  3671. all_structs.append(GetQueryId_args)
  3672. GetQueryId_args.thrift_spec = (
  3673. None, # 0
  3674. (1, TType.STRUCT, 'req', [TGetQueryIdReq, None], None, ), # 1
  3675. )
  3676. class GetQueryId_result(object):
  3677. """
  3678. Attributes:
  3679. - success
  3680. """
  3681. def __init__(self, success=None,):
  3682. self.success = success
  3683. def read(self, iprot):
  3684. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3685. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3686. return
  3687. iprot.readStructBegin()
  3688. while True:
  3689. (fname, ftype, fid) = iprot.readFieldBegin()
  3690. if ftype == TType.STOP:
  3691. break
  3692. if fid == 0:
  3693. if ftype == TType.STRUCT:
  3694. self.success = TGetQueryIdResp()
  3695. self.success.read(iprot)
  3696. else:
  3697. iprot.skip(ftype)
  3698. else:
  3699. iprot.skip(ftype)
  3700. iprot.readFieldEnd()
  3701. iprot.readStructEnd()
  3702. def write(self, oprot):
  3703. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3704. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3705. return
  3706. oprot.writeStructBegin('GetQueryId_result')
  3707. if self.success is not None:
  3708. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3709. self.success.write(oprot)
  3710. oprot.writeFieldEnd()
  3711. oprot.writeFieldStop()
  3712. oprot.writeStructEnd()
  3713. def validate(self):
  3714. return
  3715. def __repr__(self):
  3716. L = ['%s=%r' % (key, value)
  3717. for key, value in self.__dict__.items()]
  3718. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3719. def __eq__(self, other):
  3720. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3721. def __ne__(self, other):
  3722. return not (self == other)
  3723. all_structs.append(GetQueryId_result)
  3724. GetQueryId_result.thrift_spec = (
  3725. (0, TType.STRUCT, 'success', [TGetQueryIdResp, None], None, ), # 0
  3726. )
  3727. class SetClientInfo_args(object):
  3728. """
  3729. Attributes:
  3730. - req
  3731. """
  3732. def __init__(self, req=None,):
  3733. self.req = req
  3734. def read(self, iprot):
  3735. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3736. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3737. return
  3738. iprot.readStructBegin()
  3739. while True:
  3740. (fname, ftype, fid) = iprot.readFieldBegin()
  3741. if ftype == TType.STOP:
  3742. break
  3743. if fid == 1:
  3744. if ftype == TType.STRUCT:
  3745. self.req = TSetClientInfoReq()
  3746. self.req.read(iprot)
  3747. else:
  3748. iprot.skip(ftype)
  3749. else:
  3750. iprot.skip(ftype)
  3751. iprot.readFieldEnd()
  3752. iprot.readStructEnd()
  3753. def write(self, oprot):
  3754. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3755. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3756. return
  3757. oprot.writeStructBegin('SetClientInfo_args')
  3758. if self.req is not None:
  3759. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3760. self.req.write(oprot)
  3761. oprot.writeFieldEnd()
  3762. oprot.writeFieldStop()
  3763. oprot.writeStructEnd()
  3764. def validate(self):
  3765. return
  3766. def __repr__(self):
  3767. L = ['%s=%r' % (key, value)
  3768. for key, value in self.__dict__.items()]
  3769. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3770. def __eq__(self, other):
  3771. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3772. def __ne__(self, other):
  3773. return not (self == other)
  3774. all_structs.append(SetClientInfo_args)
  3775. SetClientInfo_args.thrift_spec = (
  3776. None, # 0
  3777. (1, TType.STRUCT, 'req', [TSetClientInfoReq, None], None, ), # 1
  3778. )
  3779. class SetClientInfo_result(object):
  3780. """
  3781. Attributes:
  3782. - success
  3783. """
  3784. def __init__(self, success=None,):
  3785. self.success = success
  3786. def read(self, iprot):
  3787. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3788. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3789. return
  3790. iprot.readStructBegin()
  3791. while True:
  3792. (fname, ftype, fid) = iprot.readFieldBegin()
  3793. if ftype == TType.STOP:
  3794. break
  3795. if fid == 0:
  3796. if ftype == TType.STRUCT:
  3797. self.success = TSetClientInfoResp()
  3798. self.success.read(iprot)
  3799. else:
  3800. iprot.skip(ftype)
  3801. else:
  3802. iprot.skip(ftype)
  3803. iprot.readFieldEnd()
  3804. iprot.readStructEnd()
  3805. def write(self, oprot):
  3806. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3807. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3808. return
  3809. oprot.writeStructBegin('SetClientInfo_result')
  3810. if self.success is not None:
  3811. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3812. self.success.write(oprot)
  3813. oprot.writeFieldEnd()
  3814. oprot.writeFieldStop()
  3815. oprot.writeStructEnd()
  3816. def validate(self):
  3817. return
  3818. def __repr__(self):
  3819. L = ['%s=%r' % (key, value)
  3820. for key, value in self.__dict__.items()]
  3821. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3822. def __eq__(self, other):
  3823. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3824. def __ne__(self, other):
  3825. return not (self == other)
  3826. all_structs.append(SetClientInfo_result)
  3827. SetClientInfo_result.thrift_spec = (
  3828. (0, TType.STRUCT, 'success', [TSetClientInfoResp, None], None, ), # 0
  3829. )
  3830. class GetLog_args(object):
  3831. """
  3832. Attributes:
  3833. - req
  3834. """
  3835. def __init__(self, req=None,):
  3836. self.req = req
  3837. def read(self, iprot):
  3838. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3839. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3840. return
  3841. iprot.readStructBegin()
  3842. while True:
  3843. (fname, ftype, fid) = iprot.readFieldBegin()
  3844. if ftype == TType.STOP:
  3845. break
  3846. if fid == 1:
  3847. if ftype == TType.STRUCT:
  3848. self.req = TGetLogReq()
  3849. self.req.read(iprot)
  3850. else:
  3851. iprot.skip(ftype)
  3852. else:
  3853. iprot.skip(ftype)
  3854. iprot.readFieldEnd()
  3855. iprot.readStructEnd()
  3856. def write(self, oprot):
  3857. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3858. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3859. return
  3860. oprot.writeStructBegin('GetLog_args')
  3861. if self.req is not None:
  3862. oprot.writeFieldBegin('req', TType.STRUCT, 1)
  3863. self.req.write(oprot)
  3864. oprot.writeFieldEnd()
  3865. oprot.writeFieldStop()
  3866. oprot.writeStructEnd()
  3867. def validate(self):
  3868. return
  3869. def __repr__(self):
  3870. L = ['%s=%r' % (key, value)
  3871. for key, value in self.__dict__.items()]
  3872. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3873. def __eq__(self, other):
  3874. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3875. def __ne__(self, other):
  3876. return not (self == other)
  3877. all_structs.append(GetLog_args)
  3878. GetLog_args.thrift_spec = (
  3879. None, # 0
  3880. (1, TType.STRUCT, 'req', [TGetLogReq, None], None, ), # 1
  3881. )
  3882. class GetLog_result(object):
  3883. """
  3884. Attributes:
  3885. - success
  3886. """
  3887. def __init__(self, success=None,):
  3888. self.success = success
  3889. def read(self, iprot):
  3890. if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
  3891. iprot._fast_decode(self, iprot, [self.__class__, self.thrift_spec])
  3892. return
  3893. iprot.readStructBegin()
  3894. while True:
  3895. (fname, ftype, fid) = iprot.readFieldBegin()
  3896. if ftype == TType.STOP:
  3897. break
  3898. if fid == 0:
  3899. if ftype == TType.STRUCT:
  3900. self.success = TGetLogResp()
  3901. self.success.read(iprot)
  3902. else:
  3903. iprot.skip(ftype)
  3904. else:
  3905. iprot.skip(ftype)
  3906. iprot.readFieldEnd()
  3907. iprot.readStructEnd()
  3908. def write(self, oprot):
  3909. if oprot._fast_encode is not None and self.thrift_spec is not None:
  3910. oprot.trans.write(oprot._fast_encode(self, [self.__class__, self.thrift_spec]))
  3911. return
  3912. oprot.writeStructBegin('GetLog_result')
  3913. if self.success is not None:
  3914. oprot.writeFieldBegin('success', TType.STRUCT, 0)
  3915. self.success.write(oprot)
  3916. oprot.writeFieldEnd()
  3917. oprot.writeFieldStop()
  3918. oprot.writeStructEnd()
  3919. def validate(self):
  3920. return
  3921. def __repr__(self):
  3922. L = ['%s=%r' % (key, value)
  3923. for key, value in self.__dict__.items()]
  3924. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  3925. def __eq__(self, other):
  3926. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  3927. def __ne__(self, other):
  3928. return not (self == other)
  3929. all_structs.append(GetLog_result)
  3930. GetLog_result.thrift_spec = (
  3931. (0, TType.STRUCT, 'success', [TGetLogResp, None], None, ), # 0
  3932. )
  3933. fix_spec(all_structs)
  3934. del all_structs