FacebookService.py 57 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928
  1. #
  2. # Autogenerated by Thrift Compiler (0.7.0)
  3. #
  4. # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
  5. #
  6. from thrift.Thrift import *
  7. from ttypes import *
  8. from thrift.Thrift import TProcessor
  9. from thrift.transport import TTransport
  10. from thrift.protocol import TBinaryProtocol, TProtocol
  11. try:
  12. from thrift.protocol import fastbinary
  13. except:
  14. fastbinary = None
  15. class Iface(object):
  16. """
  17. Standard base service
  18. """
  19. def getName(self, ):
  20. """
  21. Returns a descriptive name of the service
  22. """
  23. pass
  24. def getVersion(self, ):
  25. """
  26. Returns the version of the service
  27. """
  28. pass
  29. def getStatus(self, ):
  30. """
  31. Gets the status of this service
  32. """
  33. pass
  34. def getStatusDetails(self, ):
  35. """
  36. User friendly description of status, such as why the service is in
  37. the dead or warning state, or what is being started or stopped.
  38. """
  39. pass
  40. def getCounters(self, ):
  41. """
  42. Gets the counters for this service
  43. """
  44. pass
  45. def getCounter(self, key):
  46. """
  47. Gets the value of a single counter
  48. Parameters:
  49. - key
  50. """
  51. pass
  52. def setOption(self, key, value):
  53. """
  54. Sets an option
  55. Parameters:
  56. - key
  57. - value
  58. """
  59. pass
  60. def getOption(self, key):
  61. """
  62. Gets an option
  63. Parameters:
  64. - key
  65. """
  66. pass
  67. def getOptions(self, ):
  68. """
  69. Gets all options
  70. """
  71. pass
  72. def getCpuProfile(self, profileDurationInSec):
  73. """
  74. Returns a CPU profile over the given time interval (client and server
  75. must agree on the profile format).
  76. Parameters:
  77. - profileDurationInSec
  78. """
  79. pass
  80. def aliveSince(self, ):
  81. """
  82. Returns the unix time that the server has been running since
  83. """
  84. pass
  85. def reinitialize(self, ):
  86. """
  87. Tell the server to reload its configuration, reopen log files, etc
  88. """
  89. pass
  90. def shutdown(self, ):
  91. """
  92. Suggest a shutdown to the server
  93. """
  94. pass
  95. class Client(Iface):
  96. """
  97. Standard base service
  98. """
  99. def __init__(self, iprot, oprot=None):
  100. self._iprot = self._oprot = iprot
  101. if oprot is not None:
  102. self._oprot = oprot
  103. self._seqid = 0
  104. def getName(self, ):
  105. """
  106. Returns a descriptive name of the service
  107. """
  108. self.send_getName()
  109. return self.recv_getName()
  110. def send_getName(self, ):
  111. self._oprot.writeMessageBegin('getName', TMessageType.CALL, self._seqid)
  112. args = getName_args()
  113. args.write(self._oprot)
  114. self._oprot.writeMessageEnd()
  115. self._oprot.trans.flush()
  116. def recv_getName(self, ):
  117. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  118. if mtype == TMessageType.EXCEPTION:
  119. x = TApplicationException()
  120. x.read(self._iprot)
  121. self._iprot.readMessageEnd()
  122. raise x
  123. result = getName_result()
  124. result.read(self._iprot)
  125. self._iprot.readMessageEnd()
  126. if result.success is not None:
  127. return result.success
  128. raise TApplicationException(TApplicationException.MISSING_RESULT, "getName failed: unknown result");
  129. def getVersion(self, ):
  130. """
  131. Returns the version of the service
  132. """
  133. self.send_getVersion()
  134. return self.recv_getVersion()
  135. def send_getVersion(self, ):
  136. self._oprot.writeMessageBegin('getVersion', TMessageType.CALL, self._seqid)
  137. args = getVersion_args()
  138. args.write(self._oprot)
  139. self._oprot.writeMessageEnd()
  140. self._oprot.trans.flush()
  141. def recv_getVersion(self, ):
  142. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  143. if mtype == TMessageType.EXCEPTION:
  144. x = TApplicationException()
  145. x.read(self._iprot)
  146. self._iprot.readMessageEnd()
  147. raise x
  148. result = getVersion_result()
  149. result.read(self._iprot)
  150. self._iprot.readMessageEnd()
  151. if result.success is not None:
  152. return result.success
  153. raise TApplicationException(TApplicationException.MISSING_RESULT, "getVersion failed: unknown result");
  154. def getStatus(self, ):
  155. """
  156. Gets the status of this service
  157. """
  158. self.send_getStatus()
  159. return self.recv_getStatus()
  160. def send_getStatus(self, ):
  161. self._oprot.writeMessageBegin('getStatus', TMessageType.CALL, self._seqid)
  162. args = getStatus_args()
  163. args.write(self._oprot)
  164. self._oprot.writeMessageEnd()
  165. self._oprot.trans.flush()
  166. def recv_getStatus(self, ):
  167. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  168. if mtype == TMessageType.EXCEPTION:
  169. x = TApplicationException()
  170. x.read(self._iprot)
  171. self._iprot.readMessageEnd()
  172. raise x
  173. result = getStatus_result()
  174. result.read(self._iprot)
  175. self._iprot.readMessageEnd()
  176. if result.success is not None:
  177. return result.success
  178. raise TApplicationException(TApplicationException.MISSING_RESULT, "getStatus failed: unknown result");
  179. def getStatusDetails(self, ):
  180. """
  181. User friendly description of status, such as why the service is in
  182. the dead or warning state, or what is being started or stopped.
  183. """
  184. self.send_getStatusDetails()
  185. return self.recv_getStatusDetails()
  186. def send_getStatusDetails(self, ):
  187. self._oprot.writeMessageBegin('getStatusDetails', TMessageType.CALL, self._seqid)
  188. args = getStatusDetails_args()
  189. args.write(self._oprot)
  190. self._oprot.writeMessageEnd()
  191. self._oprot.trans.flush()
  192. def recv_getStatusDetails(self, ):
  193. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  194. if mtype == TMessageType.EXCEPTION:
  195. x = TApplicationException()
  196. x.read(self._iprot)
  197. self._iprot.readMessageEnd()
  198. raise x
  199. result = getStatusDetails_result()
  200. result.read(self._iprot)
  201. self._iprot.readMessageEnd()
  202. if result.success is not None:
  203. return result.success
  204. raise TApplicationException(TApplicationException.MISSING_RESULT, "getStatusDetails failed: unknown result");
  205. def getCounters(self, ):
  206. """
  207. Gets the counters for this service
  208. """
  209. self.send_getCounters()
  210. return self.recv_getCounters()
  211. def send_getCounters(self, ):
  212. self._oprot.writeMessageBegin('getCounters', TMessageType.CALL, self._seqid)
  213. args = getCounters_args()
  214. args.write(self._oprot)
  215. self._oprot.writeMessageEnd()
  216. self._oprot.trans.flush()
  217. def recv_getCounters(self, ):
  218. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  219. if mtype == TMessageType.EXCEPTION:
  220. x = TApplicationException()
  221. x.read(self._iprot)
  222. self._iprot.readMessageEnd()
  223. raise x
  224. result = getCounters_result()
  225. result.read(self._iprot)
  226. self._iprot.readMessageEnd()
  227. if result.success is not None:
  228. return result.success
  229. raise TApplicationException(TApplicationException.MISSING_RESULT, "getCounters failed: unknown result");
  230. def getCounter(self, key):
  231. """
  232. Gets the value of a single counter
  233. Parameters:
  234. - key
  235. """
  236. self.send_getCounter(key)
  237. return self.recv_getCounter()
  238. def send_getCounter(self, key):
  239. self._oprot.writeMessageBegin('getCounter', TMessageType.CALL, self._seqid)
  240. args = getCounter_args()
  241. args.key = key
  242. args.write(self._oprot)
  243. self._oprot.writeMessageEnd()
  244. self._oprot.trans.flush()
  245. def recv_getCounter(self, ):
  246. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  247. if mtype == TMessageType.EXCEPTION:
  248. x = TApplicationException()
  249. x.read(self._iprot)
  250. self._iprot.readMessageEnd()
  251. raise x
  252. result = getCounter_result()
  253. result.read(self._iprot)
  254. self._iprot.readMessageEnd()
  255. if result.success is not None:
  256. return result.success
  257. raise TApplicationException(TApplicationException.MISSING_RESULT, "getCounter failed: unknown result");
  258. def setOption(self, key, value):
  259. """
  260. Sets an option
  261. Parameters:
  262. - key
  263. - value
  264. """
  265. self.send_setOption(key, value)
  266. self.recv_setOption()
  267. def send_setOption(self, key, value):
  268. self._oprot.writeMessageBegin('setOption', TMessageType.CALL, self._seqid)
  269. args = setOption_args()
  270. args.key = key
  271. args.value = value
  272. args.write(self._oprot)
  273. self._oprot.writeMessageEnd()
  274. self._oprot.trans.flush()
  275. def recv_setOption(self, ):
  276. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  277. if mtype == TMessageType.EXCEPTION:
  278. x = TApplicationException()
  279. x.read(self._iprot)
  280. self._iprot.readMessageEnd()
  281. raise x
  282. result = setOption_result()
  283. result.read(self._iprot)
  284. self._iprot.readMessageEnd()
  285. return
  286. def getOption(self, key):
  287. """
  288. Gets an option
  289. Parameters:
  290. - key
  291. """
  292. self.send_getOption(key)
  293. return self.recv_getOption()
  294. def send_getOption(self, key):
  295. self._oprot.writeMessageBegin('getOption', TMessageType.CALL, self._seqid)
  296. args = getOption_args()
  297. args.key = key
  298. args.write(self._oprot)
  299. self._oprot.writeMessageEnd()
  300. self._oprot.trans.flush()
  301. def recv_getOption(self, ):
  302. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  303. if mtype == TMessageType.EXCEPTION:
  304. x = TApplicationException()
  305. x.read(self._iprot)
  306. self._iprot.readMessageEnd()
  307. raise x
  308. result = getOption_result()
  309. result.read(self._iprot)
  310. self._iprot.readMessageEnd()
  311. if result.success is not None:
  312. return result.success
  313. raise TApplicationException(TApplicationException.MISSING_RESULT, "getOption failed: unknown result");
  314. def getOptions(self, ):
  315. """
  316. Gets all options
  317. """
  318. self.send_getOptions()
  319. return self.recv_getOptions()
  320. def send_getOptions(self, ):
  321. self._oprot.writeMessageBegin('getOptions', TMessageType.CALL, self._seqid)
  322. args = getOptions_args()
  323. args.write(self._oprot)
  324. self._oprot.writeMessageEnd()
  325. self._oprot.trans.flush()
  326. def recv_getOptions(self, ):
  327. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  328. if mtype == TMessageType.EXCEPTION:
  329. x = TApplicationException()
  330. x.read(self._iprot)
  331. self._iprot.readMessageEnd()
  332. raise x
  333. result = getOptions_result()
  334. result.read(self._iprot)
  335. self._iprot.readMessageEnd()
  336. if result.success is not None:
  337. return result.success
  338. raise TApplicationException(TApplicationException.MISSING_RESULT, "getOptions failed: unknown result");
  339. def getCpuProfile(self, profileDurationInSec):
  340. """
  341. Returns a CPU profile over the given time interval (client and server
  342. must agree on the profile format).
  343. Parameters:
  344. - profileDurationInSec
  345. """
  346. self.send_getCpuProfile(profileDurationInSec)
  347. return self.recv_getCpuProfile()
  348. def send_getCpuProfile(self, profileDurationInSec):
  349. self._oprot.writeMessageBegin('getCpuProfile', TMessageType.CALL, self._seqid)
  350. args = getCpuProfile_args()
  351. args.profileDurationInSec = profileDurationInSec
  352. args.write(self._oprot)
  353. self._oprot.writeMessageEnd()
  354. self._oprot.trans.flush()
  355. def recv_getCpuProfile(self, ):
  356. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  357. if mtype == TMessageType.EXCEPTION:
  358. x = TApplicationException()
  359. x.read(self._iprot)
  360. self._iprot.readMessageEnd()
  361. raise x
  362. result = getCpuProfile_result()
  363. result.read(self._iprot)
  364. self._iprot.readMessageEnd()
  365. if result.success is not None:
  366. return result.success
  367. raise TApplicationException(TApplicationException.MISSING_RESULT, "getCpuProfile failed: unknown result");
  368. def aliveSince(self, ):
  369. """
  370. Returns the unix time that the server has been running since
  371. """
  372. self.send_aliveSince()
  373. return self.recv_aliveSince()
  374. def send_aliveSince(self, ):
  375. self._oprot.writeMessageBegin('aliveSince', TMessageType.CALL, self._seqid)
  376. args = aliveSince_args()
  377. args.write(self._oprot)
  378. self._oprot.writeMessageEnd()
  379. self._oprot.trans.flush()
  380. def recv_aliveSince(self, ):
  381. (fname, mtype, rseqid) = self._iprot.readMessageBegin()
  382. if mtype == TMessageType.EXCEPTION:
  383. x = TApplicationException()
  384. x.read(self._iprot)
  385. self._iprot.readMessageEnd()
  386. raise x
  387. result = aliveSince_result()
  388. result.read(self._iprot)
  389. self._iprot.readMessageEnd()
  390. if result.success is not None:
  391. return result.success
  392. raise TApplicationException(TApplicationException.MISSING_RESULT, "aliveSince failed: unknown result");
  393. def reinitialize(self, ):
  394. """
  395. Tell the server to reload its configuration, reopen log files, etc
  396. """
  397. self.send_reinitialize()
  398. def send_reinitialize(self, ):
  399. self._oprot.writeMessageBegin('reinitialize', TMessageType.CALL, self._seqid)
  400. args = reinitialize_args()
  401. args.write(self._oprot)
  402. self._oprot.writeMessageEnd()
  403. self._oprot.trans.flush()
  404. def shutdown(self, ):
  405. """
  406. Suggest a shutdown to the server
  407. """
  408. self.send_shutdown()
  409. def send_shutdown(self, ):
  410. self._oprot.writeMessageBegin('shutdown', TMessageType.CALL, self._seqid)
  411. args = shutdown_args()
  412. args.write(self._oprot)
  413. self._oprot.writeMessageEnd()
  414. self._oprot.trans.flush()
  415. class Processor(Iface, TProcessor):
  416. def __init__(self, handler):
  417. self._handler = handler
  418. self._processMap = {}
  419. self._processMap["getName"] = Processor.process_getName
  420. self._processMap["getVersion"] = Processor.process_getVersion
  421. self._processMap["getStatus"] = Processor.process_getStatus
  422. self._processMap["getStatusDetails"] = Processor.process_getStatusDetails
  423. self._processMap["getCounters"] = Processor.process_getCounters
  424. self._processMap["getCounter"] = Processor.process_getCounter
  425. self._processMap["setOption"] = Processor.process_setOption
  426. self._processMap["getOption"] = Processor.process_getOption
  427. self._processMap["getOptions"] = Processor.process_getOptions
  428. self._processMap["getCpuProfile"] = Processor.process_getCpuProfile
  429. self._processMap["aliveSince"] = Processor.process_aliveSince
  430. self._processMap["reinitialize"] = Processor.process_reinitialize
  431. self._processMap["shutdown"] = Processor.process_shutdown
  432. def process(self, iprot, oprot):
  433. (name, type, seqid) = iprot.readMessageBegin()
  434. if name not in self._processMap:
  435. iprot.skip(TType.STRUCT)
  436. iprot.readMessageEnd()
  437. x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
  438. oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
  439. x.write(oprot)
  440. oprot.writeMessageEnd()
  441. oprot.trans.flush()
  442. return
  443. else:
  444. self._processMap[name](self, seqid, iprot, oprot)
  445. return True
  446. def process_getName(self, seqid, iprot, oprot):
  447. args = getName_args()
  448. args.read(iprot)
  449. iprot.readMessageEnd()
  450. result = getName_result()
  451. result.success = self._handler.getName()
  452. oprot.writeMessageBegin("getName", TMessageType.REPLY, seqid)
  453. result.write(oprot)
  454. oprot.writeMessageEnd()
  455. oprot.trans.flush()
  456. def process_getVersion(self, seqid, iprot, oprot):
  457. args = getVersion_args()
  458. args.read(iprot)
  459. iprot.readMessageEnd()
  460. result = getVersion_result()
  461. result.success = self._handler.getVersion()
  462. oprot.writeMessageBegin("getVersion", TMessageType.REPLY, seqid)
  463. result.write(oprot)
  464. oprot.writeMessageEnd()
  465. oprot.trans.flush()
  466. def process_getStatus(self, seqid, iprot, oprot):
  467. args = getStatus_args()
  468. args.read(iprot)
  469. iprot.readMessageEnd()
  470. result = getStatus_result()
  471. result.success = self._handler.getStatus()
  472. oprot.writeMessageBegin("getStatus", TMessageType.REPLY, seqid)
  473. result.write(oprot)
  474. oprot.writeMessageEnd()
  475. oprot.trans.flush()
  476. def process_getStatusDetails(self, seqid, iprot, oprot):
  477. args = getStatusDetails_args()
  478. args.read(iprot)
  479. iprot.readMessageEnd()
  480. result = getStatusDetails_result()
  481. result.success = self._handler.getStatusDetails()
  482. oprot.writeMessageBegin("getStatusDetails", TMessageType.REPLY, seqid)
  483. result.write(oprot)
  484. oprot.writeMessageEnd()
  485. oprot.trans.flush()
  486. def process_getCounters(self, seqid, iprot, oprot):
  487. args = getCounters_args()
  488. args.read(iprot)
  489. iprot.readMessageEnd()
  490. result = getCounters_result()
  491. result.success = self._handler.getCounters()
  492. oprot.writeMessageBegin("getCounters", TMessageType.REPLY, seqid)
  493. result.write(oprot)
  494. oprot.writeMessageEnd()
  495. oprot.trans.flush()
  496. def process_getCounter(self, seqid, iprot, oprot):
  497. args = getCounter_args()
  498. args.read(iprot)
  499. iprot.readMessageEnd()
  500. result = getCounter_result()
  501. result.success = self._handler.getCounter(args.key)
  502. oprot.writeMessageBegin("getCounter", TMessageType.REPLY, seqid)
  503. result.write(oprot)
  504. oprot.writeMessageEnd()
  505. oprot.trans.flush()
  506. def process_setOption(self, seqid, iprot, oprot):
  507. args = setOption_args()
  508. args.read(iprot)
  509. iprot.readMessageEnd()
  510. result = setOption_result()
  511. self._handler.setOption(args.key, args.value)
  512. oprot.writeMessageBegin("setOption", TMessageType.REPLY, seqid)
  513. result.write(oprot)
  514. oprot.writeMessageEnd()
  515. oprot.trans.flush()
  516. def process_getOption(self, seqid, iprot, oprot):
  517. args = getOption_args()
  518. args.read(iprot)
  519. iprot.readMessageEnd()
  520. result = getOption_result()
  521. result.success = self._handler.getOption(args.key)
  522. oprot.writeMessageBegin("getOption", TMessageType.REPLY, seqid)
  523. result.write(oprot)
  524. oprot.writeMessageEnd()
  525. oprot.trans.flush()
  526. def process_getOptions(self, seqid, iprot, oprot):
  527. args = getOptions_args()
  528. args.read(iprot)
  529. iprot.readMessageEnd()
  530. result = getOptions_result()
  531. result.success = self._handler.getOptions()
  532. oprot.writeMessageBegin("getOptions", TMessageType.REPLY, seqid)
  533. result.write(oprot)
  534. oprot.writeMessageEnd()
  535. oprot.trans.flush()
  536. def process_getCpuProfile(self, seqid, iprot, oprot):
  537. args = getCpuProfile_args()
  538. args.read(iprot)
  539. iprot.readMessageEnd()
  540. result = getCpuProfile_result()
  541. result.success = self._handler.getCpuProfile(args.profileDurationInSec)
  542. oprot.writeMessageBegin("getCpuProfile", TMessageType.REPLY, seqid)
  543. result.write(oprot)
  544. oprot.writeMessageEnd()
  545. oprot.trans.flush()
  546. def process_aliveSince(self, seqid, iprot, oprot):
  547. args = aliveSince_args()
  548. args.read(iprot)
  549. iprot.readMessageEnd()
  550. result = aliveSince_result()
  551. result.success = self._handler.aliveSince()
  552. oprot.writeMessageBegin("aliveSince", TMessageType.REPLY, seqid)
  553. result.write(oprot)
  554. oprot.writeMessageEnd()
  555. oprot.trans.flush()
  556. def process_reinitialize(self, seqid, iprot, oprot):
  557. args = reinitialize_args()
  558. args.read(iprot)
  559. iprot.readMessageEnd()
  560. self._handler.reinitialize()
  561. return
  562. def process_shutdown(self, seqid, iprot, oprot):
  563. args = shutdown_args()
  564. args.read(iprot)
  565. iprot.readMessageEnd()
  566. self._handler.shutdown()
  567. return
  568. # HELPER FUNCTIONS AND STRUCTURES
  569. class getName_args(object):
  570. thrift_spec = (
  571. )
  572. def read(self, iprot):
  573. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  574. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  575. return
  576. iprot.readStructBegin()
  577. while True:
  578. (fname, ftype, fid) = iprot.readFieldBegin()
  579. if ftype == TType.STOP:
  580. break
  581. else:
  582. iprot.skip(ftype)
  583. iprot.readFieldEnd()
  584. iprot.readStructEnd()
  585. def write(self, oprot):
  586. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  587. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  588. return
  589. oprot.writeStructBegin('getName_args')
  590. oprot.writeFieldStop()
  591. oprot.writeStructEnd()
  592. def validate(self):
  593. return
  594. def __repr__(self):
  595. L = ['%s=%r' % (key, value)
  596. for key, value in self.__dict__.iteritems()]
  597. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  598. def __eq__(self, other):
  599. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  600. def __ne__(self, other):
  601. return not (self == other)
  602. class getName_result(object):
  603. """
  604. Attributes:
  605. - success
  606. """
  607. thrift_spec = (
  608. (0, TType.STRING, 'success', None, None, ), # 0
  609. )
  610. def __init__(self, success=None,):
  611. self.success = success
  612. def read(self, iprot):
  613. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  614. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  615. return
  616. iprot.readStructBegin()
  617. while True:
  618. (fname, ftype, fid) = iprot.readFieldBegin()
  619. if ftype == TType.STOP:
  620. break
  621. if fid == 0:
  622. if ftype == TType.STRING:
  623. self.success = iprot.readString();
  624. else:
  625. iprot.skip(ftype)
  626. else:
  627. iprot.skip(ftype)
  628. iprot.readFieldEnd()
  629. iprot.readStructEnd()
  630. def write(self, oprot):
  631. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  632. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  633. return
  634. oprot.writeStructBegin('getName_result')
  635. if self.success is not None:
  636. oprot.writeFieldBegin('success', TType.STRING, 0)
  637. oprot.writeString(self.success)
  638. oprot.writeFieldEnd()
  639. oprot.writeFieldStop()
  640. oprot.writeStructEnd()
  641. def validate(self):
  642. return
  643. def __repr__(self):
  644. L = ['%s=%r' % (key, value)
  645. for key, value in self.__dict__.iteritems()]
  646. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  647. def __eq__(self, other):
  648. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  649. def __ne__(self, other):
  650. return not (self == other)
  651. class getVersion_args(object):
  652. thrift_spec = (
  653. )
  654. def read(self, iprot):
  655. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  656. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  657. return
  658. iprot.readStructBegin()
  659. while True:
  660. (fname, ftype, fid) = iprot.readFieldBegin()
  661. if ftype == TType.STOP:
  662. break
  663. else:
  664. iprot.skip(ftype)
  665. iprot.readFieldEnd()
  666. iprot.readStructEnd()
  667. def write(self, oprot):
  668. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  669. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  670. return
  671. oprot.writeStructBegin('getVersion_args')
  672. oprot.writeFieldStop()
  673. oprot.writeStructEnd()
  674. def validate(self):
  675. return
  676. def __repr__(self):
  677. L = ['%s=%r' % (key, value)
  678. for key, value in self.__dict__.iteritems()]
  679. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  680. def __eq__(self, other):
  681. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  682. def __ne__(self, other):
  683. return not (self == other)
  684. class getVersion_result(object):
  685. """
  686. Attributes:
  687. - success
  688. """
  689. thrift_spec = (
  690. (0, TType.STRING, 'success', None, None, ), # 0
  691. )
  692. def __init__(self, success=None,):
  693. self.success = success
  694. def read(self, iprot):
  695. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  696. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  697. return
  698. iprot.readStructBegin()
  699. while True:
  700. (fname, ftype, fid) = iprot.readFieldBegin()
  701. if ftype == TType.STOP:
  702. break
  703. if fid == 0:
  704. if ftype == TType.STRING:
  705. self.success = iprot.readString();
  706. else:
  707. iprot.skip(ftype)
  708. else:
  709. iprot.skip(ftype)
  710. iprot.readFieldEnd()
  711. iprot.readStructEnd()
  712. def write(self, oprot):
  713. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  714. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  715. return
  716. oprot.writeStructBegin('getVersion_result')
  717. if self.success is not None:
  718. oprot.writeFieldBegin('success', TType.STRING, 0)
  719. oprot.writeString(self.success)
  720. oprot.writeFieldEnd()
  721. oprot.writeFieldStop()
  722. oprot.writeStructEnd()
  723. def validate(self):
  724. return
  725. def __repr__(self):
  726. L = ['%s=%r' % (key, value)
  727. for key, value in self.__dict__.iteritems()]
  728. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  729. def __eq__(self, other):
  730. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  731. def __ne__(self, other):
  732. return not (self == other)
  733. class getStatus_args(object):
  734. thrift_spec = (
  735. )
  736. def read(self, iprot):
  737. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  738. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  739. return
  740. iprot.readStructBegin()
  741. while True:
  742. (fname, ftype, fid) = iprot.readFieldBegin()
  743. if ftype == TType.STOP:
  744. break
  745. else:
  746. iprot.skip(ftype)
  747. iprot.readFieldEnd()
  748. iprot.readStructEnd()
  749. def write(self, oprot):
  750. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  751. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  752. return
  753. oprot.writeStructBegin('getStatus_args')
  754. oprot.writeFieldStop()
  755. oprot.writeStructEnd()
  756. def validate(self):
  757. return
  758. def __repr__(self):
  759. L = ['%s=%r' % (key, value)
  760. for key, value in self.__dict__.iteritems()]
  761. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  762. def __eq__(self, other):
  763. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  764. def __ne__(self, other):
  765. return not (self == other)
  766. class getStatus_result(object):
  767. """
  768. Attributes:
  769. - success
  770. """
  771. thrift_spec = (
  772. (0, TType.I32, 'success', None, None, ), # 0
  773. )
  774. def __init__(self, success=None,):
  775. self.success = success
  776. def read(self, iprot):
  777. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  778. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  779. return
  780. iprot.readStructBegin()
  781. while True:
  782. (fname, ftype, fid) = iprot.readFieldBegin()
  783. if ftype == TType.STOP:
  784. break
  785. if fid == 0:
  786. if ftype == TType.I32:
  787. self.success = iprot.readI32();
  788. else:
  789. iprot.skip(ftype)
  790. else:
  791. iprot.skip(ftype)
  792. iprot.readFieldEnd()
  793. iprot.readStructEnd()
  794. def write(self, oprot):
  795. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  796. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  797. return
  798. oprot.writeStructBegin('getStatus_result')
  799. if self.success is not None:
  800. oprot.writeFieldBegin('success', TType.I32, 0)
  801. oprot.writeI32(self.success)
  802. oprot.writeFieldEnd()
  803. oprot.writeFieldStop()
  804. oprot.writeStructEnd()
  805. def validate(self):
  806. return
  807. def __repr__(self):
  808. L = ['%s=%r' % (key, value)
  809. for key, value in self.__dict__.iteritems()]
  810. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  811. def __eq__(self, other):
  812. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  813. def __ne__(self, other):
  814. return not (self == other)
  815. class getStatusDetails_args(object):
  816. thrift_spec = (
  817. )
  818. def read(self, iprot):
  819. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  820. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  821. return
  822. iprot.readStructBegin()
  823. while True:
  824. (fname, ftype, fid) = iprot.readFieldBegin()
  825. if ftype == TType.STOP:
  826. break
  827. else:
  828. iprot.skip(ftype)
  829. iprot.readFieldEnd()
  830. iprot.readStructEnd()
  831. def write(self, oprot):
  832. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  833. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  834. return
  835. oprot.writeStructBegin('getStatusDetails_args')
  836. oprot.writeFieldStop()
  837. oprot.writeStructEnd()
  838. def validate(self):
  839. return
  840. def __repr__(self):
  841. L = ['%s=%r' % (key, value)
  842. for key, value in self.__dict__.iteritems()]
  843. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  844. def __eq__(self, other):
  845. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  846. def __ne__(self, other):
  847. return not (self == other)
  848. class getStatusDetails_result(object):
  849. """
  850. Attributes:
  851. - success
  852. """
  853. thrift_spec = (
  854. (0, TType.STRING, 'success', None, None, ), # 0
  855. )
  856. def __init__(self, success=None,):
  857. self.success = success
  858. def read(self, iprot):
  859. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  860. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  861. return
  862. iprot.readStructBegin()
  863. while True:
  864. (fname, ftype, fid) = iprot.readFieldBegin()
  865. if ftype == TType.STOP:
  866. break
  867. if fid == 0:
  868. if ftype == TType.STRING:
  869. self.success = iprot.readString();
  870. else:
  871. iprot.skip(ftype)
  872. else:
  873. iprot.skip(ftype)
  874. iprot.readFieldEnd()
  875. iprot.readStructEnd()
  876. def write(self, oprot):
  877. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  878. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  879. return
  880. oprot.writeStructBegin('getStatusDetails_result')
  881. if self.success is not None:
  882. oprot.writeFieldBegin('success', TType.STRING, 0)
  883. oprot.writeString(self.success)
  884. oprot.writeFieldEnd()
  885. oprot.writeFieldStop()
  886. oprot.writeStructEnd()
  887. def validate(self):
  888. return
  889. def __repr__(self):
  890. L = ['%s=%r' % (key, value)
  891. for key, value in self.__dict__.iteritems()]
  892. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  893. def __eq__(self, other):
  894. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  895. def __ne__(self, other):
  896. return not (self == other)
  897. class getCounters_args(object):
  898. thrift_spec = (
  899. )
  900. def read(self, iprot):
  901. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  902. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  903. return
  904. iprot.readStructBegin()
  905. while True:
  906. (fname, ftype, fid) = iprot.readFieldBegin()
  907. if ftype == TType.STOP:
  908. break
  909. else:
  910. iprot.skip(ftype)
  911. iprot.readFieldEnd()
  912. iprot.readStructEnd()
  913. def write(self, oprot):
  914. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  915. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  916. return
  917. oprot.writeStructBegin('getCounters_args')
  918. oprot.writeFieldStop()
  919. oprot.writeStructEnd()
  920. def validate(self):
  921. return
  922. def __repr__(self):
  923. L = ['%s=%r' % (key, value)
  924. for key, value in self.__dict__.iteritems()]
  925. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  926. def __eq__(self, other):
  927. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  928. def __ne__(self, other):
  929. return not (self == other)
  930. class getCounters_result(object):
  931. """
  932. Attributes:
  933. - success
  934. """
  935. thrift_spec = (
  936. (0, TType.MAP, 'success', (TType.STRING,None,TType.I64,None), None, ), # 0
  937. )
  938. def __init__(self, success=None,):
  939. self.success = success
  940. def read(self, iprot):
  941. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  942. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  943. return
  944. iprot.readStructBegin()
  945. while True:
  946. (fname, ftype, fid) = iprot.readFieldBegin()
  947. if ftype == TType.STOP:
  948. break
  949. if fid == 0:
  950. if ftype == TType.MAP:
  951. self.success = {}
  952. (_ktype1, _vtype2, _size0 ) = iprot.readMapBegin()
  953. for _i4 in xrange(_size0):
  954. _key5 = iprot.readString();
  955. _val6 = iprot.readI64();
  956. self.success[_key5] = _val6
  957. iprot.readMapEnd()
  958. else:
  959. iprot.skip(ftype)
  960. else:
  961. iprot.skip(ftype)
  962. iprot.readFieldEnd()
  963. iprot.readStructEnd()
  964. def write(self, oprot):
  965. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  966. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  967. return
  968. oprot.writeStructBegin('getCounters_result')
  969. if self.success is not None:
  970. oprot.writeFieldBegin('success', TType.MAP, 0)
  971. oprot.writeMapBegin(TType.STRING, TType.I64, len(self.success))
  972. for kiter7,viter8 in self.success.items():
  973. oprot.writeString(kiter7)
  974. oprot.writeI64(viter8)
  975. oprot.writeMapEnd()
  976. oprot.writeFieldEnd()
  977. oprot.writeFieldStop()
  978. oprot.writeStructEnd()
  979. def validate(self):
  980. return
  981. def __repr__(self):
  982. L = ['%s=%r' % (key, value)
  983. for key, value in self.__dict__.iteritems()]
  984. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  985. def __eq__(self, other):
  986. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  987. def __ne__(self, other):
  988. return not (self == other)
  989. class getCounter_args(object):
  990. """
  991. Attributes:
  992. - key
  993. """
  994. thrift_spec = (
  995. None, # 0
  996. (1, TType.STRING, 'key', None, None, ), # 1
  997. )
  998. def __init__(self, key=None,):
  999. self.key = key
  1000. def read(self, iprot):
  1001. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1002. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1003. return
  1004. iprot.readStructBegin()
  1005. while True:
  1006. (fname, ftype, fid) = iprot.readFieldBegin()
  1007. if ftype == TType.STOP:
  1008. break
  1009. if fid == 1:
  1010. if ftype == TType.STRING:
  1011. self.key = iprot.readString();
  1012. else:
  1013. iprot.skip(ftype)
  1014. else:
  1015. iprot.skip(ftype)
  1016. iprot.readFieldEnd()
  1017. iprot.readStructEnd()
  1018. def write(self, oprot):
  1019. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1020. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1021. return
  1022. oprot.writeStructBegin('getCounter_args')
  1023. if self.key is not None:
  1024. oprot.writeFieldBegin('key', TType.STRING, 1)
  1025. oprot.writeString(self.key)
  1026. oprot.writeFieldEnd()
  1027. oprot.writeFieldStop()
  1028. oprot.writeStructEnd()
  1029. def validate(self):
  1030. return
  1031. def __repr__(self):
  1032. L = ['%s=%r' % (key, value)
  1033. for key, value in self.__dict__.iteritems()]
  1034. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1035. def __eq__(self, other):
  1036. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1037. def __ne__(self, other):
  1038. return not (self == other)
  1039. class getCounter_result(object):
  1040. """
  1041. Attributes:
  1042. - success
  1043. """
  1044. thrift_spec = (
  1045. (0, TType.I64, 'success', None, None, ), # 0
  1046. )
  1047. def __init__(self, success=None,):
  1048. self.success = success
  1049. def read(self, iprot):
  1050. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1051. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1052. return
  1053. iprot.readStructBegin()
  1054. while True:
  1055. (fname, ftype, fid) = iprot.readFieldBegin()
  1056. if ftype == TType.STOP:
  1057. break
  1058. if fid == 0:
  1059. if ftype == TType.I64:
  1060. self.success = iprot.readI64();
  1061. else:
  1062. iprot.skip(ftype)
  1063. else:
  1064. iprot.skip(ftype)
  1065. iprot.readFieldEnd()
  1066. iprot.readStructEnd()
  1067. def write(self, oprot):
  1068. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1069. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1070. return
  1071. oprot.writeStructBegin('getCounter_result')
  1072. if self.success is not None:
  1073. oprot.writeFieldBegin('success', TType.I64, 0)
  1074. oprot.writeI64(self.success)
  1075. oprot.writeFieldEnd()
  1076. oprot.writeFieldStop()
  1077. oprot.writeStructEnd()
  1078. def validate(self):
  1079. return
  1080. def __repr__(self):
  1081. L = ['%s=%r' % (key, value)
  1082. for key, value in self.__dict__.iteritems()]
  1083. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1084. def __eq__(self, other):
  1085. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1086. def __ne__(self, other):
  1087. return not (self == other)
  1088. class setOption_args(object):
  1089. """
  1090. Attributes:
  1091. - key
  1092. - value
  1093. """
  1094. thrift_spec = (
  1095. None, # 0
  1096. (1, TType.STRING, 'key', None, None, ), # 1
  1097. (2, TType.STRING, 'value', None, None, ), # 2
  1098. )
  1099. def __init__(self, key=None, value=None,):
  1100. self.key = key
  1101. self.value = value
  1102. def read(self, iprot):
  1103. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1104. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1105. return
  1106. iprot.readStructBegin()
  1107. while True:
  1108. (fname, ftype, fid) = iprot.readFieldBegin()
  1109. if ftype == TType.STOP:
  1110. break
  1111. if fid == 1:
  1112. if ftype == TType.STRING:
  1113. self.key = iprot.readString();
  1114. else:
  1115. iprot.skip(ftype)
  1116. elif fid == 2:
  1117. if ftype == TType.STRING:
  1118. self.value = iprot.readString();
  1119. else:
  1120. iprot.skip(ftype)
  1121. else:
  1122. iprot.skip(ftype)
  1123. iprot.readFieldEnd()
  1124. iprot.readStructEnd()
  1125. def write(self, oprot):
  1126. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1127. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1128. return
  1129. oprot.writeStructBegin('setOption_args')
  1130. if self.key is not None:
  1131. oprot.writeFieldBegin('key', TType.STRING, 1)
  1132. oprot.writeString(self.key)
  1133. oprot.writeFieldEnd()
  1134. if self.value is not None:
  1135. oprot.writeFieldBegin('value', TType.STRING, 2)
  1136. oprot.writeString(self.value)
  1137. oprot.writeFieldEnd()
  1138. oprot.writeFieldStop()
  1139. oprot.writeStructEnd()
  1140. def validate(self):
  1141. return
  1142. def __repr__(self):
  1143. L = ['%s=%r' % (key, value)
  1144. for key, value in self.__dict__.iteritems()]
  1145. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1146. def __eq__(self, other):
  1147. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1148. def __ne__(self, other):
  1149. return not (self == other)
  1150. class setOption_result(object):
  1151. thrift_spec = (
  1152. )
  1153. def read(self, iprot):
  1154. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1155. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1156. return
  1157. iprot.readStructBegin()
  1158. while True:
  1159. (fname, ftype, fid) = iprot.readFieldBegin()
  1160. if ftype == TType.STOP:
  1161. break
  1162. else:
  1163. iprot.skip(ftype)
  1164. iprot.readFieldEnd()
  1165. iprot.readStructEnd()
  1166. def write(self, oprot):
  1167. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1168. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1169. return
  1170. oprot.writeStructBegin('setOption_result')
  1171. oprot.writeFieldStop()
  1172. oprot.writeStructEnd()
  1173. def validate(self):
  1174. return
  1175. def __repr__(self):
  1176. L = ['%s=%r' % (key, value)
  1177. for key, value in self.__dict__.iteritems()]
  1178. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1179. def __eq__(self, other):
  1180. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1181. def __ne__(self, other):
  1182. return not (self == other)
  1183. class getOption_args(object):
  1184. """
  1185. Attributes:
  1186. - key
  1187. """
  1188. thrift_spec = (
  1189. None, # 0
  1190. (1, TType.STRING, 'key', None, None, ), # 1
  1191. )
  1192. def __init__(self, key=None,):
  1193. self.key = key
  1194. def read(self, iprot):
  1195. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1196. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1197. return
  1198. iprot.readStructBegin()
  1199. while True:
  1200. (fname, ftype, fid) = iprot.readFieldBegin()
  1201. if ftype == TType.STOP:
  1202. break
  1203. if fid == 1:
  1204. if ftype == TType.STRING:
  1205. self.key = iprot.readString();
  1206. else:
  1207. iprot.skip(ftype)
  1208. else:
  1209. iprot.skip(ftype)
  1210. iprot.readFieldEnd()
  1211. iprot.readStructEnd()
  1212. def write(self, oprot):
  1213. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1214. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1215. return
  1216. oprot.writeStructBegin('getOption_args')
  1217. if self.key is not None:
  1218. oprot.writeFieldBegin('key', TType.STRING, 1)
  1219. oprot.writeString(self.key)
  1220. oprot.writeFieldEnd()
  1221. oprot.writeFieldStop()
  1222. oprot.writeStructEnd()
  1223. def validate(self):
  1224. return
  1225. def __repr__(self):
  1226. L = ['%s=%r' % (key, value)
  1227. for key, value in self.__dict__.iteritems()]
  1228. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1229. def __eq__(self, other):
  1230. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1231. def __ne__(self, other):
  1232. return not (self == other)
  1233. class getOption_result(object):
  1234. """
  1235. Attributes:
  1236. - success
  1237. """
  1238. thrift_spec = (
  1239. (0, TType.STRING, 'success', None, None, ), # 0
  1240. )
  1241. def __init__(self, success=None,):
  1242. self.success = success
  1243. def read(self, iprot):
  1244. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1245. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1246. return
  1247. iprot.readStructBegin()
  1248. while True:
  1249. (fname, ftype, fid) = iprot.readFieldBegin()
  1250. if ftype == TType.STOP:
  1251. break
  1252. if fid == 0:
  1253. if ftype == TType.STRING:
  1254. self.success = iprot.readString();
  1255. else:
  1256. iprot.skip(ftype)
  1257. else:
  1258. iprot.skip(ftype)
  1259. iprot.readFieldEnd()
  1260. iprot.readStructEnd()
  1261. def write(self, oprot):
  1262. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1263. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1264. return
  1265. oprot.writeStructBegin('getOption_result')
  1266. if self.success is not None:
  1267. oprot.writeFieldBegin('success', TType.STRING, 0)
  1268. oprot.writeString(self.success)
  1269. oprot.writeFieldEnd()
  1270. oprot.writeFieldStop()
  1271. oprot.writeStructEnd()
  1272. def validate(self):
  1273. return
  1274. def __repr__(self):
  1275. L = ['%s=%r' % (key, value)
  1276. for key, value in self.__dict__.iteritems()]
  1277. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1278. def __eq__(self, other):
  1279. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1280. def __ne__(self, other):
  1281. return not (self == other)
  1282. class getOptions_args(object):
  1283. thrift_spec = (
  1284. )
  1285. def read(self, iprot):
  1286. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1287. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1288. return
  1289. iprot.readStructBegin()
  1290. while True:
  1291. (fname, ftype, fid) = iprot.readFieldBegin()
  1292. if ftype == TType.STOP:
  1293. break
  1294. else:
  1295. iprot.skip(ftype)
  1296. iprot.readFieldEnd()
  1297. iprot.readStructEnd()
  1298. def write(self, oprot):
  1299. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1300. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1301. return
  1302. oprot.writeStructBegin('getOptions_args')
  1303. oprot.writeFieldStop()
  1304. oprot.writeStructEnd()
  1305. def validate(self):
  1306. return
  1307. def __repr__(self):
  1308. L = ['%s=%r' % (key, value)
  1309. for key, value in self.__dict__.iteritems()]
  1310. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1311. def __eq__(self, other):
  1312. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1313. def __ne__(self, other):
  1314. return not (self == other)
  1315. class getOptions_result(object):
  1316. """
  1317. Attributes:
  1318. - success
  1319. """
  1320. thrift_spec = (
  1321. (0, TType.MAP, 'success', (TType.STRING,None,TType.STRING,None), None, ), # 0
  1322. )
  1323. def __init__(self, success=None,):
  1324. self.success = success
  1325. def read(self, iprot):
  1326. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1327. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1328. return
  1329. iprot.readStructBegin()
  1330. while True:
  1331. (fname, ftype, fid) = iprot.readFieldBegin()
  1332. if ftype == TType.STOP:
  1333. break
  1334. if fid == 0:
  1335. if ftype == TType.MAP:
  1336. self.success = {}
  1337. (_ktype10, _vtype11, _size9 ) = iprot.readMapBegin()
  1338. for _i13 in xrange(_size9):
  1339. _key14 = iprot.readString();
  1340. _val15 = iprot.readString();
  1341. self.success[_key14] = _val15
  1342. iprot.readMapEnd()
  1343. else:
  1344. iprot.skip(ftype)
  1345. else:
  1346. iprot.skip(ftype)
  1347. iprot.readFieldEnd()
  1348. iprot.readStructEnd()
  1349. def write(self, oprot):
  1350. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1351. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1352. return
  1353. oprot.writeStructBegin('getOptions_result')
  1354. if self.success is not None:
  1355. oprot.writeFieldBegin('success', TType.MAP, 0)
  1356. oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.success))
  1357. for kiter16,viter17 in self.success.items():
  1358. oprot.writeString(kiter16)
  1359. oprot.writeString(viter17)
  1360. oprot.writeMapEnd()
  1361. oprot.writeFieldEnd()
  1362. oprot.writeFieldStop()
  1363. oprot.writeStructEnd()
  1364. def validate(self):
  1365. return
  1366. def __repr__(self):
  1367. L = ['%s=%r' % (key, value)
  1368. for key, value in self.__dict__.iteritems()]
  1369. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1370. def __eq__(self, other):
  1371. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1372. def __ne__(self, other):
  1373. return not (self == other)
  1374. class getCpuProfile_args(object):
  1375. """
  1376. Attributes:
  1377. - profileDurationInSec
  1378. """
  1379. thrift_spec = (
  1380. None, # 0
  1381. (1, TType.I32, 'profileDurationInSec', None, None, ), # 1
  1382. )
  1383. def __init__(self, profileDurationInSec=None,):
  1384. self.profileDurationInSec = profileDurationInSec
  1385. def read(self, iprot):
  1386. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1387. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1388. return
  1389. iprot.readStructBegin()
  1390. while True:
  1391. (fname, ftype, fid) = iprot.readFieldBegin()
  1392. if ftype == TType.STOP:
  1393. break
  1394. if fid == 1:
  1395. if ftype == TType.I32:
  1396. self.profileDurationInSec = iprot.readI32();
  1397. else:
  1398. iprot.skip(ftype)
  1399. else:
  1400. iprot.skip(ftype)
  1401. iprot.readFieldEnd()
  1402. iprot.readStructEnd()
  1403. def write(self, oprot):
  1404. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1405. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1406. return
  1407. oprot.writeStructBegin('getCpuProfile_args')
  1408. if self.profileDurationInSec is not None:
  1409. oprot.writeFieldBegin('profileDurationInSec', TType.I32, 1)
  1410. oprot.writeI32(self.profileDurationInSec)
  1411. oprot.writeFieldEnd()
  1412. oprot.writeFieldStop()
  1413. oprot.writeStructEnd()
  1414. def validate(self):
  1415. return
  1416. def __repr__(self):
  1417. L = ['%s=%r' % (key, value)
  1418. for key, value in self.__dict__.iteritems()]
  1419. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1420. def __eq__(self, other):
  1421. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1422. def __ne__(self, other):
  1423. return not (self == other)
  1424. class getCpuProfile_result(object):
  1425. """
  1426. Attributes:
  1427. - success
  1428. """
  1429. thrift_spec = (
  1430. (0, TType.STRING, 'success', None, None, ), # 0
  1431. )
  1432. def __init__(self, success=None,):
  1433. self.success = success
  1434. def read(self, iprot):
  1435. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1436. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1437. return
  1438. iprot.readStructBegin()
  1439. while True:
  1440. (fname, ftype, fid) = iprot.readFieldBegin()
  1441. if ftype == TType.STOP:
  1442. break
  1443. if fid == 0:
  1444. if ftype == TType.STRING:
  1445. self.success = iprot.readString();
  1446. else:
  1447. iprot.skip(ftype)
  1448. else:
  1449. iprot.skip(ftype)
  1450. iprot.readFieldEnd()
  1451. iprot.readStructEnd()
  1452. def write(self, oprot):
  1453. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1454. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1455. return
  1456. oprot.writeStructBegin('getCpuProfile_result')
  1457. if self.success is not None:
  1458. oprot.writeFieldBegin('success', TType.STRING, 0)
  1459. oprot.writeString(self.success)
  1460. oprot.writeFieldEnd()
  1461. oprot.writeFieldStop()
  1462. oprot.writeStructEnd()
  1463. def validate(self):
  1464. return
  1465. def __repr__(self):
  1466. L = ['%s=%r' % (key, value)
  1467. for key, value in self.__dict__.iteritems()]
  1468. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1469. def __eq__(self, other):
  1470. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1471. def __ne__(self, other):
  1472. return not (self == other)
  1473. class aliveSince_args(object):
  1474. thrift_spec = (
  1475. )
  1476. def read(self, iprot):
  1477. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1478. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1479. return
  1480. iprot.readStructBegin()
  1481. while True:
  1482. (fname, ftype, fid) = iprot.readFieldBegin()
  1483. if ftype == TType.STOP:
  1484. break
  1485. else:
  1486. iprot.skip(ftype)
  1487. iprot.readFieldEnd()
  1488. iprot.readStructEnd()
  1489. def write(self, oprot):
  1490. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1491. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1492. return
  1493. oprot.writeStructBegin('aliveSince_args')
  1494. oprot.writeFieldStop()
  1495. oprot.writeStructEnd()
  1496. def validate(self):
  1497. return
  1498. def __repr__(self):
  1499. L = ['%s=%r' % (key, value)
  1500. for key, value in self.__dict__.iteritems()]
  1501. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1502. def __eq__(self, other):
  1503. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1504. def __ne__(self, other):
  1505. return not (self == other)
  1506. class aliveSince_result(object):
  1507. """
  1508. Attributes:
  1509. - success
  1510. """
  1511. thrift_spec = (
  1512. (0, TType.I64, 'success', None, None, ), # 0
  1513. )
  1514. def __init__(self, success=None,):
  1515. self.success = success
  1516. def read(self, iprot):
  1517. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1518. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1519. return
  1520. iprot.readStructBegin()
  1521. while True:
  1522. (fname, ftype, fid) = iprot.readFieldBegin()
  1523. if ftype == TType.STOP:
  1524. break
  1525. if fid == 0:
  1526. if ftype == TType.I64:
  1527. self.success = iprot.readI64();
  1528. else:
  1529. iprot.skip(ftype)
  1530. else:
  1531. iprot.skip(ftype)
  1532. iprot.readFieldEnd()
  1533. iprot.readStructEnd()
  1534. def write(self, oprot):
  1535. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1536. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1537. return
  1538. oprot.writeStructBegin('aliveSince_result')
  1539. if self.success is not None:
  1540. oprot.writeFieldBegin('success', TType.I64, 0)
  1541. oprot.writeI64(self.success)
  1542. oprot.writeFieldEnd()
  1543. oprot.writeFieldStop()
  1544. oprot.writeStructEnd()
  1545. def validate(self):
  1546. return
  1547. def __repr__(self):
  1548. L = ['%s=%r' % (key, value)
  1549. for key, value in self.__dict__.iteritems()]
  1550. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1551. def __eq__(self, other):
  1552. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1553. def __ne__(self, other):
  1554. return not (self == other)
  1555. class reinitialize_args(object):
  1556. thrift_spec = (
  1557. )
  1558. def read(self, iprot):
  1559. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1560. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1561. return
  1562. iprot.readStructBegin()
  1563. while True:
  1564. (fname, ftype, fid) = iprot.readFieldBegin()
  1565. if ftype == TType.STOP:
  1566. break
  1567. else:
  1568. iprot.skip(ftype)
  1569. iprot.readFieldEnd()
  1570. iprot.readStructEnd()
  1571. def write(self, oprot):
  1572. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1573. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1574. return
  1575. oprot.writeStructBegin('reinitialize_args')
  1576. oprot.writeFieldStop()
  1577. oprot.writeStructEnd()
  1578. def validate(self):
  1579. return
  1580. def __repr__(self):
  1581. L = ['%s=%r' % (key, value)
  1582. for key, value in self.__dict__.iteritems()]
  1583. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1584. def __eq__(self, other):
  1585. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1586. def __ne__(self, other):
  1587. return not (self == other)
  1588. class shutdown_args(object):
  1589. thrift_spec = (
  1590. )
  1591. def read(self, iprot):
  1592. if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
  1593. fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
  1594. return
  1595. iprot.readStructBegin()
  1596. while True:
  1597. (fname, ftype, fid) = iprot.readFieldBegin()
  1598. if ftype == TType.STOP:
  1599. break
  1600. else:
  1601. iprot.skip(ftype)
  1602. iprot.readFieldEnd()
  1603. iprot.readStructEnd()
  1604. def write(self, oprot):
  1605. if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
  1606. oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
  1607. return
  1608. oprot.writeStructBegin('shutdown_args')
  1609. oprot.writeFieldStop()
  1610. oprot.writeStructEnd()
  1611. def validate(self):
  1612. return
  1613. def __repr__(self):
  1614. L = ['%s=%r' % (key, value)
  1615. for key, value in self.__dict__.iteritems()]
  1616. return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
  1617. def __eq__(self, other):
  1618. return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
  1619. def __ne__(self, other):
  1620. return not (self == other)