Cassandra.cpp 323 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061
  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. #include "Cassandra.h"
  7. namespace org { namespace apache { namespace cassandra {
  8. uint32_t Cassandra_login_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  9. uint32_t xfer = 0;
  10. std::string fname;
  11. ::apache::thrift::protocol::TType ftype;
  12. int16_t fid;
  13. xfer += iprot->readStructBegin(fname);
  14. using ::apache::thrift::protocol::TProtocolException;
  15. bool isset_auth_request = false;
  16. while (true)
  17. {
  18. xfer += iprot->readFieldBegin(fname, ftype, fid);
  19. if (ftype == ::apache::thrift::protocol::T_STOP) {
  20. break;
  21. }
  22. switch (fid)
  23. {
  24. case 1:
  25. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  26. xfer += this->auth_request.read(iprot);
  27. isset_auth_request = true;
  28. } else {
  29. xfer += iprot->skip(ftype);
  30. }
  31. break;
  32. default:
  33. xfer += iprot->skip(ftype);
  34. break;
  35. }
  36. xfer += iprot->readFieldEnd();
  37. }
  38. xfer += iprot->readStructEnd();
  39. if (!isset_auth_request)
  40. throw TProtocolException(TProtocolException::INVALID_DATA);
  41. return xfer;
  42. }
  43. uint32_t Cassandra_login_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  44. uint32_t xfer = 0;
  45. xfer += oprot->writeStructBegin("Cassandra_login_args");
  46. xfer += oprot->writeFieldBegin("auth_request", ::apache::thrift::protocol::T_STRUCT, 1);
  47. xfer += this->auth_request.write(oprot);
  48. xfer += oprot->writeFieldEnd();
  49. xfer += oprot->writeFieldStop();
  50. xfer += oprot->writeStructEnd();
  51. return xfer;
  52. }
  53. uint32_t Cassandra_login_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  54. uint32_t xfer = 0;
  55. xfer += oprot->writeStructBegin("Cassandra_login_pargs");
  56. xfer += oprot->writeFieldBegin("auth_request", ::apache::thrift::protocol::T_STRUCT, 1);
  57. xfer += (*(this->auth_request)).write(oprot);
  58. xfer += oprot->writeFieldEnd();
  59. xfer += oprot->writeFieldStop();
  60. xfer += oprot->writeStructEnd();
  61. return xfer;
  62. }
  63. uint32_t Cassandra_login_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  64. uint32_t xfer = 0;
  65. std::string fname;
  66. ::apache::thrift::protocol::TType ftype;
  67. int16_t fid;
  68. xfer += iprot->readStructBegin(fname);
  69. using ::apache::thrift::protocol::TProtocolException;
  70. while (true)
  71. {
  72. xfer += iprot->readFieldBegin(fname, ftype, fid);
  73. if (ftype == ::apache::thrift::protocol::T_STOP) {
  74. break;
  75. }
  76. switch (fid)
  77. {
  78. case 1:
  79. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  80. xfer += this->authnx.read(iprot);
  81. this->__isset.authnx = true;
  82. } else {
  83. xfer += iprot->skip(ftype);
  84. }
  85. break;
  86. case 2:
  87. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  88. xfer += this->authzx.read(iprot);
  89. this->__isset.authzx = true;
  90. } else {
  91. xfer += iprot->skip(ftype);
  92. }
  93. break;
  94. default:
  95. xfer += iprot->skip(ftype);
  96. break;
  97. }
  98. xfer += iprot->readFieldEnd();
  99. }
  100. xfer += iprot->readStructEnd();
  101. return xfer;
  102. }
  103. uint32_t Cassandra_login_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  104. uint32_t xfer = 0;
  105. xfer += oprot->writeStructBegin("Cassandra_login_result");
  106. if (this->__isset.authnx) {
  107. xfer += oprot->writeFieldBegin("authnx", ::apache::thrift::protocol::T_STRUCT, 1);
  108. xfer += this->authnx.write(oprot);
  109. xfer += oprot->writeFieldEnd();
  110. } else if (this->__isset.authzx) {
  111. xfer += oprot->writeFieldBegin("authzx", ::apache::thrift::protocol::T_STRUCT, 2);
  112. xfer += this->authzx.write(oprot);
  113. xfer += oprot->writeFieldEnd();
  114. }
  115. xfer += oprot->writeFieldStop();
  116. xfer += oprot->writeStructEnd();
  117. return xfer;
  118. }
  119. uint32_t Cassandra_login_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  120. uint32_t xfer = 0;
  121. std::string fname;
  122. ::apache::thrift::protocol::TType ftype;
  123. int16_t fid;
  124. xfer += iprot->readStructBegin(fname);
  125. using ::apache::thrift::protocol::TProtocolException;
  126. while (true)
  127. {
  128. xfer += iprot->readFieldBegin(fname, ftype, fid);
  129. if (ftype == ::apache::thrift::protocol::T_STOP) {
  130. break;
  131. }
  132. switch (fid)
  133. {
  134. case 1:
  135. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  136. xfer += this->authnx.read(iprot);
  137. this->__isset.authnx = true;
  138. } else {
  139. xfer += iprot->skip(ftype);
  140. }
  141. break;
  142. case 2:
  143. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  144. xfer += this->authzx.read(iprot);
  145. this->__isset.authzx = true;
  146. } else {
  147. xfer += iprot->skip(ftype);
  148. }
  149. break;
  150. default:
  151. xfer += iprot->skip(ftype);
  152. break;
  153. }
  154. xfer += iprot->readFieldEnd();
  155. }
  156. xfer += iprot->readStructEnd();
  157. return xfer;
  158. }
  159. uint32_t Cassandra_set_keyspace_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  160. uint32_t xfer = 0;
  161. std::string fname;
  162. ::apache::thrift::protocol::TType ftype;
  163. int16_t fid;
  164. xfer += iprot->readStructBegin(fname);
  165. using ::apache::thrift::protocol::TProtocolException;
  166. bool isset_keyspace = false;
  167. while (true)
  168. {
  169. xfer += iprot->readFieldBegin(fname, ftype, fid);
  170. if (ftype == ::apache::thrift::protocol::T_STOP) {
  171. break;
  172. }
  173. switch (fid)
  174. {
  175. case 1:
  176. if (ftype == ::apache::thrift::protocol::T_STRING) {
  177. xfer += iprot->readString(this->keyspace);
  178. isset_keyspace = true;
  179. } else {
  180. xfer += iprot->skip(ftype);
  181. }
  182. break;
  183. default:
  184. xfer += iprot->skip(ftype);
  185. break;
  186. }
  187. xfer += iprot->readFieldEnd();
  188. }
  189. xfer += iprot->readStructEnd();
  190. if (!isset_keyspace)
  191. throw TProtocolException(TProtocolException::INVALID_DATA);
  192. return xfer;
  193. }
  194. uint32_t Cassandra_set_keyspace_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  195. uint32_t xfer = 0;
  196. xfer += oprot->writeStructBegin("Cassandra_set_keyspace_args");
  197. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  198. xfer += oprot->writeString(this->keyspace);
  199. xfer += oprot->writeFieldEnd();
  200. xfer += oprot->writeFieldStop();
  201. xfer += oprot->writeStructEnd();
  202. return xfer;
  203. }
  204. uint32_t Cassandra_set_keyspace_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  205. uint32_t xfer = 0;
  206. xfer += oprot->writeStructBegin("Cassandra_set_keyspace_pargs");
  207. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  208. xfer += oprot->writeString((*(this->keyspace)));
  209. xfer += oprot->writeFieldEnd();
  210. xfer += oprot->writeFieldStop();
  211. xfer += oprot->writeStructEnd();
  212. return xfer;
  213. }
  214. uint32_t Cassandra_set_keyspace_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  215. uint32_t xfer = 0;
  216. std::string fname;
  217. ::apache::thrift::protocol::TType ftype;
  218. int16_t fid;
  219. xfer += iprot->readStructBegin(fname);
  220. using ::apache::thrift::protocol::TProtocolException;
  221. while (true)
  222. {
  223. xfer += iprot->readFieldBegin(fname, ftype, fid);
  224. if (ftype == ::apache::thrift::protocol::T_STOP) {
  225. break;
  226. }
  227. switch (fid)
  228. {
  229. case 1:
  230. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  231. xfer += this->ire.read(iprot);
  232. this->__isset.ire = true;
  233. } else {
  234. xfer += iprot->skip(ftype);
  235. }
  236. break;
  237. default:
  238. xfer += iprot->skip(ftype);
  239. break;
  240. }
  241. xfer += iprot->readFieldEnd();
  242. }
  243. xfer += iprot->readStructEnd();
  244. return xfer;
  245. }
  246. uint32_t Cassandra_set_keyspace_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  247. uint32_t xfer = 0;
  248. xfer += oprot->writeStructBegin("Cassandra_set_keyspace_result");
  249. if (this->__isset.ire) {
  250. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  251. xfer += this->ire.write(oprot);
  252. xfer += oprot->writeFieldEnd();
  253. }
  254. xfer += oprot->writeFieldStop();
  255. xfer += oprot->writeStructEnd();
  256. return xfer;
  257. }
  258. uint32_t Cassandra_set_keyspace_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  259. uint32_t xfer = 0;
  260. std::string fname;
  261. ::apache::thrift::protocol::TType ftype;
  262. int16_t fid;
  263. xfer += iprot->readStructBegin(fname);
  264. using ::apache::thrift::protocol::TProtocolException;
  265. while (true)
  266. {
  267. xfer += iprot->readFieldBegin(fname, ftype, fid);
  268. if (ftype == ::apache::thrift::protocol::T_STOP) {
  269. break;
  270. }
  271. switch (fid)
  272. {
  273. case 1:
  274. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  275. xfer += this->ire.read(iprot);
  276. this->__isset.ire = true;
  277. } else {
  278. xfer += iprot->skip(ftype);
  279. }
  280. break;
  281. default:
  282. xfer += iprot->skip(ftype);
  283. break;
  284. }
  285. xfer += iprot->readFieldEnd();
  286. }
  287. xfer += iprot->readStructEnd();
  288. return xfer;
  289. }
  290. uint32_t Cassandra_get_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  291. uint32_t xfer = 0;
  292. std::string fname;
  293. ::apache::thrift::protocol::TType ftype;
  294. int16_t fid;
  295. xfer += iprot->readStructBegin(fname);
  296. using ::apache::thrift::protocol::TProtocolException;
  297. bool isset_key = false;
  298. bool isset_column_path = false;
  299. bool isset_consistency_level = false;
  300. while (true)
  301. {
  302. xfer += iprot->readFieldBegin(fname, ftype, fid);
  303. if (ftype == ::apache::thrift::protocol::T_STOP) {
  304. break;
  305. }
  306. switch (fid)
  307. {
  308. case 1:
  309. if (ftype == ::apache::thrift::protocol::T_STRING) {
  310. xfer += iprot->readBinary(this->key);
  311. isset_key = true;
  312. } else {
  313. xfer += iprot->skip(ftype);
  314. }
  315. break;
  316. case 2:
  317. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  318. xfer += this->column_path.read(iprot);
  319. isset_column_path = true;
  320. } else {
  321. xfer += iprot->skip(ftype);
  322. }
  323. break;
  324. case 3:
  325. if (ftype == ::apache::thrift::protocol::T_I32) {
  326. int32_t ecast131;
  327. xfer += iprot->readI32(ecast131);
  328. this->consistency_level = (ConsistencyLevel::type)ecast131;
  329. isset_consistency_level = true;
  330. } else {
  331. xfer += iprot->skip(ftype);
  332. }
  333. break;
  334. default:
  335. xfer += iprot->skip(ftype);
  336. break;
  337. }
  338. xfer += iprot->readFieldEnd();
  339. }
  340. xfer += iprot->readStructEnd();
  341. if (!isset_key)
  342. throw TProtocolException(TProtocolException::INVALID_DATA);
  343. if (!isset_column_path)
  344. throw TProtocolException(TProtocolException::INVALID_DATA);
  345. if (!isset_consistency_level)
  346. throw TProtocolException(TProtocolException::INVALID_DATA);
  347. return xfer;
  348. }
  349. uint32_t Cassandra_get_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  350. uint32_t xfer = 0;
  351. xfer += oprot->writeStructBegin("Cassandra_get_args");
  352. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  353. xfer += oprot->writeBinary(this->key);
  354. xfer += oprot->writeFieldEnd();
  355. xfer += oprot->writeFieldBegin("column_path", ::apache::thrift::protocol::T_STRUCT, 2);
  356. xfer += this->column_path.write(oprot);
  357. xfer += oprot->writeFieldEnd();
  358. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 3);
  359. xfer += oprot->writeI32((int32_t)this->consistency_level);
  360. xfer += oprot->writeFieldEnd();
  361. xfer += oprot->writeFieldStop();
  362. xfer += oprot->writeStructEnd();
  363. return xfer;
  364. }
  365. uint32_t Cassandra_get_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  366. uint32_t xfer = 0;
  367. xfer += oprot->writeStructBegin("Cassandra_get_pargs");
  368. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  369. xfer += oprot->writeBinary((*(this->key)));
  370. xfer += oprot->writeFieldEnd();
  371. xfer += oprot->writeFieldBegin("column_path", ::apache::thrift::protocol::T_STRUCT, 2);
  372. xfer += (*(this->column_path)).write(oprot);
  373. xfer += oprot->writeFieldEnd();
  374. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 3);
  375. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  376. xfer += oprot->writeFieldEnd();
  377. xfer += oprot->writeFieldStop();
  378. xfer += oprot->writeStructEnd();
  379. return xfer;
  380. }
  381. uint32_t Cassandra_get_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  382. uint32_t xfer = 0;
  383. std::string fname;
  384. ::apache::thrift::protocol::TType ftype;
  385. int16_t fid;
  386. xfer += iprot->readStructBegin(fname);
  387. using ::apache::thrift::protocol::TProtocolException;
  388. while (true)
  389. {
  390. xfer += iprot->readFieldBegin(fname, ftype, fid);
  391. if (ftype == ::apache::thrift::protocol::T_STOP) {
  392. break;
  393. }
  394. switch (fid)
  395. {
  396. case 0:
  397. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  398. xfer += this->success.read(iprot);
  399. this->__isset.success = true;
  400. } else {
  401. xfer += iprot->skip(ftype);
  402. }
  403. break;
  404. case 1:
  405. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  406. xfer += this->ire.read(iprot);
  407. this->__isset.ire = true;
  408. } else {
  409. xfer += iprot->skip(ftype);
  410. }
  411. break;
  412. case 2:
  413. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  414. xfer += this->nfe.read(iprot);
  415. this->__isset.nfe = true;
  416. } else {
  417. xfer += iprot->skip(ftype);
  418. }
  419. break;
  420. case 3:
  421. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  422. xfer += this->ue.read(iprot);
  423. this->__isset.ue = true;
  424. } else {
  425. xfer += iprot->skip(ftype);
  426. }
  427. break;
  428. case 4:
  429. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  430. xfer += this->te.read(iprot);
  431. this->__isset.te = true;
  432. } else {
  433. xfer += iprot->skip(ftype);
  434. }
  435. break;
  436. default:
  437. xfer += iprot->skip(ftype);
  438. break;
  439. }
  440. xfer += iprot->readFieldEnd();
  441. }
  442. xfer += iprot->readStructEnd();
  443. return xfer;
  444. }
  445. uint32_t Cassandra_get_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  446. uint32_t xfer = 0;
  447. xfer += oprot->writeStructBegin("Cassandra_get_result");
  448. if (this->__isset.success) {
  449. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRUCT, 0);
  450. xfer += this->success.write(oprot);
  451. xfer += oprot->writeFieldEnd();
  452. } else if (this->__isset.ire) {
  453. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  454. xfer += this->ire.write(oprot);
  455. xfer += oprot->writeFieldEnd();
  456. } else if (this->__isset.nfe) {
  457. xfer += oprot->writeFieldBegin("nfe", ::apache::thrift::protocol::T_STRUCT, 2);
  458. xfer += this->nfe.write(oprot);
  459. xfer += oprot->writeFieldEnd();
  460. } else if (this->__isset.ue) {
  461. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 3);
  462. xfer += this->ue.write(oprot);
  463. xfer += oprot->writeFieldEnd();
  464. } else if (this->__isset.te) {
  465. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 4);
  466. xfer += this->te.write(oprot);
  467. xfer += oprot->writeFieldEnd();
  468. }
  469. xfer += oprot->writeFieldStop();
  470. xfer += oprot->writeStructEnd();
  471. return xfer;
  472. }
  473. uint32_t Cassandra_get_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  474. uint32_t xfer = 0;
  475. std::string fname;
  476. ::apache::thrift::protocol::TType ftype;
  477. int16_t fid;
  478. xfer += iprot->readStructBegin(fname);
  479. using ::apache::thrift::protocol::TProtocolException;
  480. while (true)
  481. {
  482. xfer += iprot->readFieldBegin(fname, ftype, fid);
  483. if (ftype == ::apache::thrift::protocol::T_STOP) {
  484. break;
  485. }
  486. switch (fid)
  487. {
  488. case 0:
  489. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  490. xfer += (*(this->success)).read(iprot);
  491. this->__isset.success = true;
  492. } else {
  493. xfer += iprot->skip(ftype);
  494. }
  495. break;
  496. case 1:
  497. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  498. xfer += this->ire.read(iprot);
  499. this->__isset.ire = true;
  500. } else {
  501. xfer += iprot->skip(ftype);
  502. }
  503. break;
  504. case 2:
  505. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  506. xfer += this->nfe.read(iprot);
  507. this->__isset.nfe = true;
  508. } else {
  509. xfer += iprot->skip(ftype);
  510. }
  511. break;
  512. case 3:
  513. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  514. xfer += this->ue.read(iprot);
  515. this->__isset.ue = true;
  516. } else {
  517. xfer += iprot->skip(ftype);
  518. }
  519. break;
  520. case 4:
  521. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  522. xfer += this->te.read(iprot);
  523. this->__isset.te = true;
  524. } else {
  525. xfer += iprot->skip(ftype);
  526. }
  527. break;
  528. default:
  529. xfer += iprot->skip(ftype);
  530. break;
  531. }
  532. xfer += iprot->readFieldEnd();
  533. }
  534. xfer += iprot->readStructEnd();
  535. return xfer;
  536. }
  537. uint32_t Cassandra_get_slice_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  538. uint32_t xfer = 0;
  539. std::string fname;
  540. ::apache::thrift::protocol::TType ftype;
  541. int16_t fid;
  542. xfer += iprot->readStructBegin(fname);
  543. using ::apache::thrift::protocol::TProtocolException;
  544. bool isset_key = false;
  545. bool isset_column_parent = false;
  546. bool isset_predicate = false;
  547. bool isset_consistency_level = false;
  548. while (true)
  549. {
  550. xfer += iprot->readFieldBegin(fname, ftype, fid);
  551. if (ftype == ::apache::thrift::protocol::T_STOP) {
  552. break;
  553. }
  554. switch (fid)
  555. {
  556. case 1:
  557. if (ftype == ::apache::thrift::protocol::T_STRING) {
  558. xfer += iprot->readBinary(this->key);
  559. isset_key = true;
  560. } else {
  561. xfer += iprot->skip(ftype);
  562. }
  563. break;
  564. case 2:
  565. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  566. xfer += this->column_parent.read(iprot);
  567. isset_column_parent = true;
  568. } else {
  569. xfer += iprot->skip(ftype);
  570. }
  571. break;
  572. case 3:
  573. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  574. xfer += this->predicate.read(iprot);
  575. isset_predicate = true;
  576. } else {
  577. xfer += iprot->skip(ftype);
  578. }
  579. break;
  580. case 4:
  581. if (ftype == ::apache::thrift::protocol::T_I32) {
  582. int32_t ecast132;
  583. xfer += iprot->readI32(ecast132);
  584. this->consistency_level = (ConsistencyLevel::type)ecast132;
  585. isset_consistency_level = true;
  586. } else {
  587. xfer += iprot->skip(ftype);
  588. }
  589. break;
  590. default:
  591. xfer += iprot->skip(ftype);
  592. break;
  593. }
  594. xfer += iprot->readFieldEnd();
  595. }
  596. xfer += iprot->readStructEnd();
  597. if (!isset_key)
  598. throw TProtocolException(TProtocolException::INVALID_DATA);
  599. if (!isset_column_parent)
  600. throw TProtocolException(TProtocolException::INVALID_DATA);
  601. if (!isset_predicate)
  602. throw TProtocolException(TProtocolException::INVALID_DATA);
  603. if (!isset_consistency_level)
  604. throw TProtocolException(TProtocolException::INVALID_DATA);
  605. return xfer;
  606. }
  607. uint32_t Cassandra_get_slice_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  608. uint32_t xfer = 0;
  609. xfer += oprot->writeStructBegin("Cassandra_get_slice_args");
  610. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  611. xfer += oprot->writeBinary(this->key);
  612. xfer += oprot->writeFieldEnd();
  613. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  614. xfer += this->column_parent.write(oprot);
  615. xfer += oprot->writeFieldEnd();
  616. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  617. xfer += this->predicate.write(oprot);
  618. xfer += oprot->writeFieldEnd();
  619. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  620. xfer += oprot->writeI32((int32_t)this->consistency_level);
  621. xfer += oprot->writeFieldEnd();
  622. xfer += oprot->writeFieldStop();
  623. xfer += oprot->writeStructEnd();
  624. return xfer;
  625. }
  626. uint32_t Cassandra_get_slice_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  627. uint32_t xfer = 0;
  628. xfer += oprot->writeStructBegin("Cassandra_get_slice_pargs");
  629. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  630. xfer += oprot->writeBinary((*(this->key)));
  631. xfer += oprot->writeFieldEnd();
  632. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  633. xfer += (*(this->column_parent)).write(oprot);
  634. xfer += oprot->writeFieldEnd();
  635. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  636. xfer += (*(this->predicate)).write(oprot);
  637. xfer += oprot->writeFieldEnd();
  638. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  639. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  640. xfer += oprot->writeFieldEnd();
  641. xfer += oprot->writeFieldStop();
  642. xfer += oprot->writeStructEnd();
  643. return xfer;
  644. }
  645. uint32_t Cassandra_get_slice_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  646. uint32_t xfer = 0;
  647. std::string fname;
  648. ::apache::thrift::protocol::TType ftype;
  649. int16_t fid;
  650. xfer += iprot->readStructBegin(fname);
  651. using ::apache::thrift::protocol::TProtocolException;
  652. while (true)
  653. {
  654. xfer += iprot->readFieldBegin(fname, ftype, fid);
  655. if (ftype == ::apache::thrift::protocol::T_STOP) {
  656. break;
  657. }
  658. switch (fid)
  659. {
  660. case 0:
  661. if (ftype == ::apache::thrift::protocol::T_LIST) {
  662. {
  663. this->success.clear();
  664. uint32_t _size133;
  665. ::apache::thrift::protocol::TType _etype136;
  666. iprot->readListBegin(_etype136, _size133);
  667. this->success.resize(_size133);
  668. uint32_t _i137;
  669. for (_i137 = 0; _i137 < _size133; ++_i137)
  670. {
  671. xfer += this->success[_i137].read(iprot);
  672. }
  673. iprot->readListEnd();
  674. }
  675. this->__isset.success = true;
  676. } else {
  677. xfer += iprot->skip(ftype);
  678. }
  679. break;
  680. case 1:
  681. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  682. xfer += this->ire.read(iprot);
  683. this->__isset.ire = true;
  684. } else {
  685. xfer += iprot->skip(ftype);
  686. }
  687. break;
  688. case 2:
  689. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  690. xfer += this->ue.read(iprot);
  691. this->__isset.ue = true;
  692. } else {
  693. xfer += iprot->skip(ftype);
  694. }
  695. break;
  696. case 3:
  697. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  698. xfer += this->te.read(iprot);
  699. this->__isset.te = true;
  700. } else {
  701. xfer += iprot->skip(ftype);
  702. }
  703. break;
  704. default:
  705. xfer += iprot->skip(ftype);
  706. break;
  707. }
  708. xfer += iprot->readFieldEnd();
  709. }
  710. xfer += iprot->readStructEnd();
  711. return xfer;
  712. }
  713. uint32_t Cassandra_get_slice_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  714. uint32_t xfer = 0;
  715. xfer += oprot->writeStructBegin("Cassandra_get_slice_result");
  716. if (this->__isset.success) {
  717. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  718. {
  719. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(this->success.size()));
  720. std::vector<ColumnOrSuperColumn> ::const_iterator _iter138;
  721. for (_iter138 = this->success.begin(); _iter138 != this->success.end(); ++_iter138)
  722. {
  723. xfer += (*_iter138).write(oprot);
  724. }
  725. xfer += oprot->writeListEnd();
  726. }
  727. xfer += oprot->writeFieldEnd();
  728. } else if (this->__isset.ire) {
  729. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  730. xfer += this->ire.write(oprot);
  731. xfer += oprot->writeFieldEnd();
  732. } else if (this->__isset.ue) {
  733. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  734. xfer += this->ue.write(oprot);
  735. xfer += oprot->writeFieldEnd();
  736. } else if (this->__isset.te) {
  737. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  738. xfer += this->te.write(oprot);
  739. xfer += oprot->writeFieldEnd();
  740. }
  741. xfer += oprot->writeFieldStop();
  742. xfer += oprot->writeStructEnd();
  743. return xfer;
  744. }
  745. uint32_t Cassandra_get_slice_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  746. uint32_t xfer = 0;
  747. std::string fname;
  748. ::apache::thrift::protocol::TType ftype;
  749. int16_t fid;
  750. xfer += iprot->readStructBegin(fname);
  751. using ::apache::thrift::protocol::TProtocolException;
  752. while (true)
  753. {
  754. xfer += iprot->readFieldBegin(fname, ftype, fid);
  755. if (ftype == ::apache::thrift::protocol::T_STOP) {
  756. break;
  757. }
  758. switch (fid)
  759. {
  760. case 0:
  761. if (ftype == ::apache::thrift::protocol::T_LIST) {
  762. {
  763. (*(this->success)).clear();
  764. uint32_t _size139;
  765. ::apache::thrift::protocol::TType _etype142;
  766. iprot->readListBegin(_etype142, _size139);
  767. (*(this->success)).resize(_size139);
  768. uint32_t _i143;
  769. for (_i143 = 0; _i143 < _size139; ++_i143)
  770. {
  771. xfer += (*(this->success))[_i143].read(iprot);
  772. }
  773. iprot->readListEnd();
  774. }
  775. this->__isset.success = true;
  776. } else {
  777. xfer += iprot->skip(ftype);
  778. }
  779. break;
  780. case 1:
  781. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  782. xfer += this->ire.read(iprot);
  783. this->__isset.ire = true;
  784. } else {
  785. xfer += iprot->skip(ftype);
  786. }
  787. break;
  788. case 2:
  789. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  790. xfer += this->ue.read(iprot);
  791. this->__isset.ue = true;
  792. } else {
  793. xfer += iprot->skip(ftype);
  794. }
  795. break;
  796. case 3:
  797. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  798. xfer += this->te.read(iprot);
  799. this->__isset.te = true;
  800. } else {
  801. xfer += iprot->skip(ftype);
  802. }
  803. break;
  804. default:
  805. xfer += iprot->skip(ftype);
  806. break;
  807. }
  808. xfer += iprot->readFieldEnd();
  809. }
  810. xfer += iprot->readStructEnd();
  811. return xfer;
  812. }
  813. uint32_t Cassandra_get_count_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  814. uint32_t xfer = 0;
  815. std::string fname;
  816. ::apache::thrift::protocol::TType ftype;
  817. int16_t fid;
  818. xfer += iprot->readStructBegin(fname);
  819. using ::apache::thrift::protocol::TProtocolException;
  820. bool isset_key = false;
  821. bool isset_column_parent = false;
  822. bool isset_predicate = false;
  823. bool isset_consistency_level = false;
  824. while (true)
  825. {
  826. xfer += iprot->readFieldBegin(fname, ftype, fid);
  827. if (ftype == ::apache::thrift::protocol::T_STOP) {
  828. break;
  829. }
  830. switch (fid)
  831. {
  832. case 1:
  833. if (ftype == ::apache::thrift::protocol::T_STRING) {
  834. xfer += iprot->readBinary(this->key);
  835. isset_key = true;
  836. } else {
  837. xfer += iprot->skip(ftype);
  838. }
  839. break;
  840. case 2:
  841. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  842. xfer += this->column_parent.read(iprot);
  843. isset_column_parent = true;
  844. } else {
  845. xfer += iprot->skip(ftype);
  846. }
  847. break;
  848. case 3:
  849. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  850. xfer += this->predicate.read(iprot);
  851. isset_predicate = true;
  852. } else {
  853. xfer += iprot->skip(ftype);
  854. }
  855. break;
  856. case 4:
  857. if (ftype == ::apache::thrift::protocol::T_I32) {
  858. int32_t ecast144;
  859. xfer += iprot->readI32(ecast144);
  860. this->consistency_level = (ConsistencyLevel::type)ecast144;
  861. isset_consistency_level = true;
  862. } else {
  863. xfer += iprot->skip(ftype);
  864. }
  865. break;
  866. default:
  867. xfer += iprot->skip(ftype);
  868. break;
  869. }
  870. xfer += iprot->readFieldEnd();
  871. }
  872. xfer += iprot->readStructEnd();
  873. if (!isset_key)
  874. throw TProtocolException(TProtocolException::INVALID_DATA);
  875. if (!isset_column_parent)
  876. throw TProtocolException(TProtocolException::INVALID_DATA);
  877. if (!isset_predicate)
  878. throw TProtocolException(TProtocolException::INVALID_DATA);
  879. if (!isset_consistency_level)
  880. throw TProtocolException(TProtocolException::INVALID_DATA);
  881. return xfer;
  882. }
  883. uint32_t Cassandra_get_count_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  884. uint32_t xfer = 0;
  885. xfer += oprot->writeStructBegin("Cassandra_get_count_args");
  886. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  887. xfer += oprot->writeBinary(this->key);
  888. xfer += oprot->writeFieldEnd();
  889. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  890. xfer += this->column_parent.write(oprot);
  891. xfer += oprot->writeFieldEnd();
  892. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  893. xfer += this->predicate.write(oprot);
  894. xfer += oprot->writeFieldEnd();
  895. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  896. xfer += oprot->writeI32((int32_t)this->consistency_level);
  897. xfer += oprot->writeFieldEnd();
  898. xfer += oprot->writeFieldStop();
  899. xfer += oprot->writeStructEnd();
  900. return xfer;
  901. }
  902. uint32_t Cassandra_get_count_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  903. uint32_t xfer = 0;
  904. xfer += oprot->writeStructBegin("Cassandra_get_count_pargs");
  905. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  906. xfer += oprot->writeBinary((*(this->key)));
  907. xfer += oprot->writeFieldEnd();
  908. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  909. xfer += (*(this->column_parent)).write(oprot);
  910. xfer += oprot->writeFieldEnd();
  911. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  912. xfer += (*(this->predicate)).write(oprot);
  913. xfer += oprot->writeFieldEnd();
  914. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  915. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  916. xfer += oprot->writeFieldEnd();
  917. xfer += oprot->writeFieldStop();
  918. xfer += oprot->writeStructEnd();
  919. return xfer;
  920. }
  921. uint32_t Cassandra_get_count_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  922. uint32_t xfer = 0;
  923. std::string fname;
  924. ::apache::thrift::protocol::TType ftype;
  925. int16_t fid;
  926. xfer += iprot->readStructBegin(fname);
  927. using ::apache::thrift::protocol::TProtocolException;
  928. while (true)
  929. {
  930. xfer += iprot->readFieldBegin(fname, ftype, fid);
  931. if (ftype == ::apache::thrift::protocol::T_STOP) {
  932. break;
  933. }
  934. switch (fid)
  935. {
  936. case 0:
  937. if (ftype == ::apache::thrift::protocol::T_I32) {
  938. xfer += iprot->readI32(this->success);
  939. this->__isset.success = true;
  940. } else {
  941. xfer += iprot->skip(ftype);
  942. }
  943. break;
  944. case 1:
  945. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  946. xfer += this->ire.read(iprot);
  947. this->__isset.ire = true;
  948. } else {
  949. xfer += iprot->skip(ftype);
  950. }
  951. break;
  952. case 2:
  953. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  954. xfer += this->ue.read(iprot);
  955. this->__isset.ue = true;
  956. } else {
  957. xfer += iprot->skip(ftype);
  958. }
  959. break;
  960. case 3:
  961. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  962. xfer += this->te.read(iprot);
  963. this->__isset.te = true;
  964. } else {
  965. xfer += iprot->skip(ftype);
  966. }
  967. break;
  968. default:
  969. xfer += iprot->skip(ftype);
  970. break;
  971. }
  972. xfer += iprot->readFieldEnd();
  973. }
  974. xfer += iprot->readStructEnd();
  975. return xfer;
  976. }
  977. uint32_t Cassandra_get_count_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  978. uint32_t xfer = 0;
  979. xfer += oprot->writeStructBegin("Cassandra_get_count_result");
  980. if (this->__isset.success) {
  981. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_I32, 0);
  982. xfer += oprot->writeI32(this->success);
  983. xfer += oprot->writeFieldEnd();
  984. } else if (this->__isset.ire) {
  985. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  986. xfer += this->ire.write(oprot);
  987. xfer += oprot->writeFieldEnd();
  988. } else if (this->__isset.ue) {
  989. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  990. xfer += this->ue.write(oprot);
  991. xfer += oprot->writeFieldEnd();
  992. } else if (this->__isset.te) {
  993. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  994. xfer += this->te.write(oprot);
  995. xfer += oprot->writeFieldEnd();
  996. }
  997. xfer += oprot->writeFieldStop();
  998. xfer += oprot->writeStructEnd();
  999. return xfer;
  1000. }
  1001. uint32_t Cassandra_get_count_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  1002. uint32_t xfer = 0;
  1003. std::string fname;
  1004. ::apache::thrift::protocol::TType ftype;
  1005. int16_t fid;
  1006. xfer += iprot->readStructBegin(fname);
  1007. using ::apache::thrift::protocol::TProtocolException;
  1008. while (true)
  1009. {
  1010. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1011. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1012. break;
  1013. }
  1014. switch (fid)
  1015. {
  1016. case 0:
  1017. if (ftype == ::apache::thrift::protocol::T_I32) {
  1018. xfer += iprot->readI32((*(this->success)));
  1019. this->__isset.success = true;
  1020. } else {
  1021. xfer += iprot->skip(ftype);
  1022. }
  1023. break;
  1024. case 1:
  1025. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1026. xfer += this->ire.read(iprot);
  1027. this->__isset.ire = true;
  1028. } else {
  1029. xfer += iprot->skip(ftype);
  1030. }
  1031. break;
  1032. case 2:
  1033. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1034. xfer += this->ue.read(iprot);
  1035. this->__isset.ue = true;
  1036. } else {
  1037. xfer += iprot->skip(ftype);
  1038. }
  1039. break;
  1040. case 3:
  1041. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1042. xfer += this->te.read(iprot);
  1043. this->__isset.te = true;
  1044. } else {
  1045. xfer += iprot->skip(ftype);
  1046. }
  1047. break;
  1048. default:
  1049. xfer += iprot->skip(ftype);
  1050. break;
  1051. }
  1052. xfer += iprot->readFieldEnd();
  1053. }
  1054. xfer += iprot->readStructEnd();
  1055. return xfer;
  1056. }
  1057. uint32_t Cassandra_multiget_slice_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  1058. uint32_t xfer = 0;
  1059. std::string fname;
  1060. ::apache::thrift::protocol::TType ftype;
  1061. int16_t fid;
  1062. xfer += iprot->readStructBegin(fname);
  1063. using ::apache::thrift::protocol::TProtocolException;
  1064. bool isset_keys = false;
  1065. bool isset_column_parent = false;
  1066. bool isset_predicate = false;
  1067. bool isset_consistency_level = false;
  1068. while (true)
  1069. {
  1070. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1071. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1072. break;
  1073. }
  1074. switch (fid)
  1075. {
  1076. case 1:
  1077. if (ftype == ::apache::thrift::protocol::T_LIST) {
  1078. {
  1079. this->keys.clear();
  1080. uint32_t _size145;
  1081. ::apache::thrift::protocol::TType _etype148;
  1082. iprot->readListBegin(_etype148, _size145);
  1083. this->keys.resize(_size145);
  1084. uint32_t _i149;
  1085. for (_i149 = 0; _i149 < _size145; ++_i149)
  1086. {
  1087. xfer += iprot->readBinary(this->keys[_i149]);
  1088. }
  1089. iprot->readListEnd();
  1090. }
  1091. isset_keys = true;
  1092. } else {
  1093. xfer += iprot->skip(ftype);
  1094. }
  1095. break;
  1096. case 2:
  1097. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1098. xfer += this->column_parent.read(iprot);
  1099. isset_column_parent = true;
  1100. } else {
  1101. xfer += iprot->skip(ftype);
  1102. }
  1103. break;
  1104. case 3:
  1105. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1106. xfer += this->predicate.read(iprot);
  1107. isset_predicate = true;
  1108. } else {
  1109. xfer += iprot->skip(ftype);
  1110. }
  1111. break;
  1112. case 4:
  1113. if (ftype == ::apache::thrift::protocol::T_I32) {
  1114. int32_t ecast150;
  1115. xfer += iprot->readI32(ecast150);
  1116. this->consistency_level = (ConsistencyLevel::type)ecast150;
  1117. isset_consistency_level = true;
  1118. } else {
  1119. xfer += iprot->skip(ftype);
  1120. }
  1121. break;
  1122. default:
  1123. xfer += iprot->skip(ftype);
  1124. break;
  1125. }
  1126. xfer += iprot->readFieldEnd();
  1127. }
  1128. xfer += iprot->readStructEnd();
  1129. if (!isset_keys)
  1130. throw TProtocolException(TProtocolException::INVALID_DATA);
  1131. if (!isset_column_parent)
  1132. throw TProtocolException(TProtocolException::INVALID_DATA);
  1133. if (!isset_predicate)
  1134. throw TProtocolException(TProtocolException::INVALID_DATA);
  1135. if (!isset_consistency_level)
  1136. throw TProtocolException(TProtocolException::INVALID_DATA);
  1137. return xfer;
  1138. }
  1139. uint32_t Cassandra_multiget_slice_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1140. uint32_t xfer = 0;
  1141. xfer += oprot->writeStructBegin("Cassandra_multiget_slice_args");
  1142. xfer += oprot->writeFieldBegin("keys", ::apache::thrift::protocol::T_LIST, 1);
  1143. {
  1144. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>(this->keys.size()));
  1145. std::vector<std::string> ::const_iterator _iter151;
  1146. for (_iter151 = this->keys.begin(); _iter151 != this->keys.end(); ++_iter151)
  1147. {
  1148. xfer += oprot->writeBinary((*_iter151));
  1149. }
  1150. xfer += oprot->writeListEnd();
  1151. }
  1152. xfer += oprot->writeFieldEnd();
  1153. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  1154. xfer += this->column_parent.write(oprot);
  1155. xfer += oprot->writeFieldEnd();
  1156. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  1157. xfer += this->predicate.write(oprot);
  1158. xfer += oprot->writeFieldEnd();
  1159. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1160. xfer += oprot->writeI32((int32_t)this->consistency_level);
  1161. xfer += oprot->writeFieldEnd();
  1162. xfer += oprot->writeFieldStop();
  1163. xfer += oprot->writeStructEnd();
  1164. return xfer;
  1165. }
  1166. uint32_t Cassandra_multiget_slice_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1167. uint32_t xfer = 0;
  1168. xfer += oprot->writeStructBegin("Cassandra_multiget_slice_pargs");
  1169. xfer += oprot->writeFieldBegin("keys", ::apache::thrift::protocol::T_LIST, 1);
  1170. {
  1171. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>((*(this->keys)).size()));
  1172. std::vector<std::string> ::const_iterator _iter152;
  1173. for (_iter152 = (*(this->keys)).begin(); _iter152 != (*(this->keys)).end(); ++_iter152)
  1174. {
  1175. xfer += oprot->writeBinary((*_iter152));
  1176. }
  1177. xfer += oprot->writeListEnd();
  1178. }
  1179. xfer += oprot->writeFieldEnd();
  1180. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  1181. xfer += (*(this->column_parent)).write(oprot);
  1182. xfer += oprot->writeFieldEnd();
  1183. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  1184. xfer += (*(this->predicate)).write(oprot);
  1185. xfer += oprot->writeFieldEnd();
  1186. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1187. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  1188. xfer += oprot->writeFieldEnd();
  1189. xfer += oprot->writeFieldStop();
  1190. xfer += oprot->writeStructEnd();
  1191. return xfer;
  1192. }
  1193. uint32_t Cassandra_multiget_slice_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  1194. uint32_t xfer = 0;
  1195. std::string fname;
  1196. ::apache::thrift::protocol::TType ftype;
  1197. int16_t fid;
  1198. xfer += iprot->readStructBegin(fname);
  1199. using ::apache::thrift::protocol::TProtocolException;
  1200. while (true)
  1201. {
  1202. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1203. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1204. break;
  1205. }
  1206. switch (fid)
  1207. {
  1208. case 0:
  1209. if (ftype == ::apache::thrift::protocol::T_MAP) {
  1210. {
  1211. this->success.clear();
  1212. uint32_t _size153;
  1213. ::apache::thrift::protocol::TType _ktype154;
  1214. ::apache::thrift::protocol::TType _vtype155;
  1215. iprot->readMapBegin(_ktype154, _vtype155, _size153);
  1216. uint32_t _i157;
  1217. for (_i157 = 0; _i157 < _size153; ++_i157)
  1218. {
  1219. std::string _key158;
  1220. xfer += iprot->readBinary(_key158);
  1221. std::vector<ColumnOrSuperColumn> & _val159 = this->success[_key158];
  1222. {
  1223. _val159.clear();
  1224. uint32_t _size160;
  1225. ::apache::thrift::protocol::TType _etype163;
  1226. iprot->readListBegin(_etype163, _size160);
  1227. _val159.resize(_size160);
  1228. uint32_t _i164;
  1229. for (_i164 = 0; _i164 < _size160; ++_i164)
  1230. {
  1231. xfer += _val159[_i164].read(iprot);
  1232. }
  1233. iprot->readListEnd();
  1234. }
  1235. }
  1236. iprot->readMapEnd();
  1237. }
  1238. this->__isset.success = true;
  1239. } else {
  1240. xfer += iprot->skip(ftype);
  1241. }
  1242. break;
  1243. case 1:
  1244. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1245. xfer += this->ire.read(iprot);
  1246. this->__isset.ire = true;
  1247. } else {
  1248. xfer += iprot->skip(ftype);
  1249. }
  1250. break;
  1251. case 2:
  1252. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1253. xfer += this->ue.read(iprot);
  1254. this->__isset.ue = true;
  1255. } else {
  1256. xfer += iprot->skip(ftype);
  1257. }
  1258. break;
  1259. case 3:
  1260. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1261. xfer += this->te.read(iprot);
  1262. this->__isset.te = true;
  1263. } else {
  1264. xfer += iprot->skip(ftype);
  1265. }
  1266. break;
  1267. default:
  1268. xfer += iprot->skip(ftype);
  1269. break;
  1270. }
  1271. xfer += iprot->readFieldEnd();
  1272. }
  1273. xfer += iprot->readStructEnd();
  1274. return xfer;
  1275. }
  1276. uint32_t Cassandra_multiget_slice_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1277. uint32_t xfer = 0;
  1278. xfer += oprot->writeStructBegin("Cassandra_multiget_slice_result");
  1279. if (this->__isset.success) {
  1280. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_MAP, 0);
  1281. {
  1282. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_LIST, static_cast<uint32_t>(this->success.size()));
  1283. std::map<std::string, std::vector<ColumnOrSuperColumn> > ::const_iterator _iter165;
  1284. for (_iter165 = this->success.begin(); _iter165 != this->success.end(); ++_iter165)
  1285. {
  1286. xfer += oprot->writeBinary(_iter165->first);
  1287. {
  1288. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(_iter165->second.size()));
  1289. std::vector<ColumnOrSuperColumn> ::const_iterator _iter166;
  1290. for (_iter166 = _iter165->second.begin(); _iter166 != _iter165->second.end(); ++_iter166)
  1291. {
  1292. xfer += (*_iter166).write(oprot);
  1293. }
  1294. xfer += oprot->writeListEnd();
  1295. }
  1296. }
  1297. xfer += oprot->writeMapEnd();
  1298. }
  1299. xfer += oprot->writeFieldEnd();
  1300. } else if (this->__isset.ire) {
  1301. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  1302. xfer += this->ire.write(oprot);
  1303. xfer += oprot->writeFieldEnd();
  1304. } else if (this->__isset.ue) {
  1305. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  1306. xfer += this->ue.write(oprot);
  1307. xfer += oprot->writeFieldEnd();
  1308. } else if (this->__isset.te) {
  1309. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  1310. xfer += this->te.write(oprot);
  1311. xfer += oprot->writeFieldEnd();
  1312. }
  1313. xfer += oprot->writeFieldStop();
  1314. xfer += oprot->writeStructEnd();
  1315. return xfer;
  1316. }
  1317. uint32_t Cassandra_multiget_slice_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  1318. uint32_t xfer = 0;
  1319. std::string fname;
  1320. ::apache::thrift::protocol::TType ftype;
  1321. int16_t fid;
  1322. xfer += iprot->readStructBegin(fname);
  1323. using ::apache::thrift::protocol::TProtocolException;
  1324. while (true)
  1325. {
  1326. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1327. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1328. break;
  1329. }
  1330. switch (fid)
  1331. {
  1332. case 0:
  1333. if (ftype == ::apache::thrift::protocol::T_MAP) {
  1334. {
  1335. (*(this->success)).clear();
  1336. uint32_t _size167;
  1337. ::apache::thrift::protocol::TType _ktype168;
  1338. ::apache::thrift::protocol::TType _vtype169;
  1339. iprot->readMapBegin(_ktype168, _vtype169, _size167);
  1340. uint32_t _i171;
  1341. for (_i171 = 0; _i171 < _size167; ++_i171)
  1342. {
  1343. std::string _key172;
  1344. xfer += iprot->readBinary(_key172);
  1345. std::vector<ColumnOrSuperColumn> & _val173 = (*(this->success))[_key172];
  1346. {
  1347. _val173.clear();
  1348. uint32_t _size174;
  1349. ::apache::thrift::protocol::TType _etype177;
  1350. iprot->readListBegin(_etype177, _size174);
  1351. _val173.resize(_size174);
  1352. uint32_t _i178;
  1353. for (_i178 = 0; _i178 < _size174; ++_i178)
  1354. {
  1355. xfer += _val173[_i178].read(iprot);
  1356. }
  1357. iprot->readListEnd();
  1358. }
  1359. }
  1360. iprot->readMapEnd();
  1361. }
  1362. this->__isset.success = true;
  1363. } else {
  1364. xfer += iprot->skip(ftype);
  1365. }
  1366. break;
  1367. case 1:
  1368. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1369. xfer += this->ire.read(iprot);
  1370. this->__isset.ire = true;
  1371. } else {
  1372. xfer += iprot->skip(ftype);
  1373. }
  1374. break;
  1375. case 2:
  1376. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1377. xfer += this->ue.read(iprot);
  1378. this->__isset.ue = true;
  1379. } else {
  1380. xfer += iprot->skip(ftype);
  1381. }
  1382. break;
  1383. case 3:
  1384. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1385. xfer += this->te.read(iprot);
  1386. this->__isset.te = true;
  1387. } else {
  1388. xfer += iprot->skip(ftype);
  1389. }
  1390. break;
  1391. default:
  1392. xfer += iprot->skip(ftype);
  1393. break;
  1394. }
  1395. xfer += iprot->readFieldEnd();
  1396. }
  1397. xfer += iprot->readStructEnd();
  1398. return xfer;
  1399. }
  1400. uint32_t Cassandra_multiget_count_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  1401. uint32_t xfer = 0;
  1402. std::string fname;
  1403. ::apache::thrift::protocol::TType ftype;
  1404. int16_t fid;
  1405. xfer += iprot->readStructBegin(fname);
  1406. using ::apache::thrift::protocol::TProtocolException;
  1407. bool isset_keys = false;
  1408. bool isset_column_parent = false;
  1409. bool isset_predicate = false;
  1410. bool isset_consistency_level = false;
  1411. while (true)
  1412. {
  1413. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1414. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1415. break;
  1416. }
  1417. switch (fid)
  1418. {
  1419. case 1:
  1420. if (ftype == ::apache::thrift::protocol::T_LIST) {
  1421. {
  1422. this->keys.clear();
  1423. uint32_t _size179;
  1424. ::apache::thrift::protocol::TType _etype182;
  1425. iprot->readListBegin(_etype182, _size179);
  1426. this->keys.resize(_size179);
  1427. uint32_t _i183;
  1428. for (_i183 = 0; _i183 < _size179; ++_i183)
  1429. {
  1430. xfer += iprot->readBinary(this->keys[_i183]);
  1431. }
  1432. iprot->readListEnd();
  1433. }
  1434. isset_keys = true;
  1435. } else {
  1436. xfer += iprot->skip(ftype);
  1437. }
  1438. break;
  1439. case 2:
  1440. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1441. xfer += this->column_parent.read(iprot);
  1442. isset_column_parent = true;
  1443. } else {
  1444. xfer += iprot->skip(ftype);
  1445. }
  1446. break;
  1447. case 3:
  1448. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1449. xfer += this->predicate.read(iprot);
  1450. isset_predicate = true;
  1451. } else {
  1452. xfer += iprot->skip(ftype);
  1453. }
  1454. break;
  1455. case 4:
  1456. if (ftype == ::apache::thrift::protocol::T_I32) {
  1457. int32_t ecast184;
  1458. xfer += iprot->readI32(ecast184);
  1459. this->consistency_level = (ConsistencyLevel::type)ecast184;
  1460. isset_consistency_level = true;
  1461. } else {
  1462. xfer += iprot->skip(ftype);
  1463. }
  1464. break;
  1465. default:
  1466. xfer += iprot->skip(ftype);
  1467. break;
  1468. }
  1469. xfer += iprot->readFieldEnd();
  1470. }
  1471. xfer += iprot->readStructEnd();
  1472. if (!isset_keys)
  1473. throw TProtocolException(TProtocolException::INVALID_DATA);
  1474. if (!isset_column_parent)
  1475. throw TProtocolException(TProtocolException::INVALID_DATA);
  1476. if (!isset_predicate)
  1477. throw TProtocolException(TProtocolException::INVALID_DATA);
  1478. if (!isset_consistency_level)
  1479. throw TProtocolException(TProtocolException::INVALID_DATA);
  1480. return xfer;
  1481. }
  1482. uint32_t Cassandra_multiget_count_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1483. uint32_t xfer = 0;
  1484. xfer += oprot->writeStructBegin("Cassandra_multiget_count_args");
  1485. xfer += oprot->writeFieldBegin("keys", ::apache::thrift::protocol::T_LIST, 1);
  1486. {
  1487. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>(this->keys.size()));
  1488. std::vector<std::string> ::const_iterator _iter185;
  1489. for (_iter185 = this->keys.begin(); _iter185 != this->keys.end(); ++_iter185)
  1490. {
  1491. xfer += oprot->writeBinary((*_iter185));
  1492. }
  1493. xfer += oprot->writeListEnd();
  1494. }
  1495. xfer += oprot->writeFieldEnd();
  1496. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  1497. xfer += this->column_parent.write(oprot);
  1498. xfer += oprot->writeFieldEnd();
  1499. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  1500. xfer += this->predicate.write(oprot);
  1501. xfer += oprot->writeFieldEnd();
  1502. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1503. xfer += oprot->writeI32((int32_t)this->consistency_level);
  1504. xfer += oprot->writeFieldEnd();
  1505. xfer += oprot->writeFieldStop();
  1506. xfer += oprot->writeStructEnd();
  1507. return xfer;
  1508. }
  1509. uint32_t Cassandra_multiget_count_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1510. uint32_t xfer = 0;
  1511. xfer += oprot->writeStructBegin("Cassandra_multiget_count_pargs");
  1512. xfer += oprot->writeFieldBegin("keys", ::apache::thrift::protocol::T_LIST, 1);
  1513. {
  1514. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>((*(this->keys)).size()));
  1515. std::vector<std::string> ::const_iterator _iter186;
  1516. for (_iter186 = (*(this->keys)).begin(); _iter186 != (*(this->keys)).end(); ++_iter186)
  1517. {
  1518. xfer += oprot->writeBinary((*_iter186));
  1519. }
  1520. xfer += oprot->writeListEnd();
  1521. }
  1522. xfer += oprot->writeFieldEnd();
  1523. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  1524. xfer += (*(this->column_parent)).write(oprot);
  1525. xfer += oprot->writeFieldEnd();
  1526. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  1527. xfer += (*(this->predicate)).write(oprot);
  1528. xfer += oprot->writeFieldEnd();
  1529. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1530. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  1531. xfer += oprot->writeFieldEnd();
  1532. xfer += oprot->writeFieldStop();
  1533. xfer += oprot->writeStructEnd();
  1534. return xfer;
  1535. }
  1536. uint32_t Cassandra_multiget_count_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  1537. uint32_t xfer = 0;
  1538. std::string fname;
  1539. ::apache::thrift::protocol::TType ftype;
  1540. int16_t fid;
  1541. xfer += iprot->readStructBegin(fname);
  1542. using ::apache::thrift::protocol::TProtocolException;
  1543. while (true)
  1544. {
  1545. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1546. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1547. break;
  1548. }
  1549. switch (fid)
  1550. {
  1551. case 0:
  1552. if (ftype == ::apache::thrift::protocol::T_MAP) {
  1553. {
  1554. this->success.clear();
  1555. uint32_t _size187;
  1556. ::apache::thrift::protocol::TType _ktype188;
  1557. ::apache::thrift::protocol::TType _vtype189;
  1558. iprot->readMapBegin(_ktype188, _vtype189, _size187);
  1559. uint32_t _i191;
  1560. for (_i191 = 0; _i191 < _size187; ++_i191)
  1561. {
  1562. std::string _key192;
  1563. xfer += iprot->readBinary(_key192);
  1564. int32_t& _val193 = this->success[_key192];
  1565. xfer += iprot->readI32(_val193);
  1566. }
  1567. iprot->readMapEnd();
  1568. }
  1569. this->__isset.success = true;
  1570. } else {
  1571. xfer += iprot->skip(ftype);
  1572. }
  1573. break;
  1574. case 1:
  1575. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1576. xfer += this->ire.read(iprot);
  1577. this->__isset.ire = true;
  1578. } else {
  1579. xfer += iprot->skip(ftype);
  1580. }
  1581. break;
  1582. case 2:
  1583. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1584. xfer += this->ue.read(iprot);
  1585. this->__isset.ue = true;
  1586. } else {
  1587. xfer += iprot->skip(ftype);
  1588. }
  1589. break;
  1590. case 3:
  1591. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1592. xfer += this->te.read(iprot);
  1593. this->__isset.te = true;
  1594. } else {
  1595. xfer += iprot->skip(ftype);
  1596. }
  1597. break;
  1598. default:
  1599. xfer += iprot->skip(ftype);
  1600. break;
  1601. }
  1602. xfer += iprot->readFieldEnd();
  1603. }
  1604. xfer += iprot->readStructEnd();
  1605. return xfer;
  1606. }
  1607. uint32_t Cassandra_multiget_count_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1608. uint32_t xfer = 0;
  1609. xfer += oprot->writeStructBegin("Cassandra_multiget_count_result");
  1610. if (this->__isset.success) {
  1611. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_MAP, 0);
  1612. {
  1613. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_I32, static_cast<uint32_t>(this->success.size()));
  1614. std::map<std::string, int32_t> ::const_iterator _iter194;
  1615. for (_iter194 = this->success.begin(); _iter194 != this->success.end(); ++_iter194)
  1616. {
  1617. xfer += oprot->writeBinary(_iter194->first);
  1618. xfer += oprot->writeI32(_iter194->second);
  1619. }
  1620. xfer += oprot->writeMapEnd();
  1621. }
  1622. xfer += oprot->writeFieldEnd();
  1623. } else if (this->__isset.ire) {
  1624. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  1625. xfer += this->ire.write(oprot);
  1626. xfer += oprot->writeFieldEnd();
  1627. } else if (this->__isset.ue) {
  1628. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  1629. xfer += this->ue.write(oprot);
  1630. xfer += oprot->writeFieldEnd();
  1631. } else if (this->__isset.te) {
  1632. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  1633. xfer += this->te.write(oprot);
  1634. xfer += oprot->writeFieldEnd();
  1635. }
  1636. xfer += oprot->writeFieldStop();
  1637. xfer += oprot->writeStructEnd();
  1638. return xfer;
  1639. }
  1640. uint32_t Cassandra_multiget_count_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  1641. uint32_t xfer = 0;
  1642. std::string fname;
  1643. ::apache::thrift::protocol::TType ftype;
  1644. int16_t fid;
  1645. xfer += iprot->readStructBegin(fname);
  1646. using ::apache::thrift::protocol::TProtocolException;
  1647. while (true)
  1648. {
  1649. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1650. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1651. break;
  1652. }
  1653. switch (fid)
  1654. {
  1655. case 0:
  1656. if (ftype == ::apache::thrift::protocol::T_MAP) {
  1657. {
  1658. (*(this->success)).clear();
  1659. uint32_t _size195;
  1660. ::apache::thrift::protocol::TType _ktype196;
  1661. ::apache::thrift::protocol::TType _vtype197;
  1662. iprot->readMapBegin(_ktype196, _vtype197, _size195);
  1663. uint32_t _i199;
  1664. for (_i199 = 0; _i199 < _size195; ++_i199)
  1665. {
  1666. std::string _key200;
  1667. xfer += iprot->readBinary(_key200);
  1668. int32_t& _val201 = (*(this->success))[_key200];
  1669. xfer += iprot->readI32(_val201);
  1670. }
  1671. iprot->readMapEnd();
  1672. }
  1673. this->__isset.success = true;
  1674. } else {
  1675. xfer += iprot->skip(ftype);
  1676. }
  1677. break;
  1678. case 1:
  1679. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1680. xfer += this->ire.read(iprot);
  1681. this->__isset.ire = true;
  1682. } else {
  1683. xfer += iprot->skip(ftype);
  1684. }
  1685. break;
  1686. case 2:
  1687. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1688. xfer += this->ue.read(iprot);
  1689. this->__isset.ue = true;
  1690. } else {
  1691. xfer += iprot->skip(ftype);
  1692. }
  1693. break;
  1694. case 3:
  1695. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1696. xfer += this->te.read(iprot);
  1697. this->__isset.te = true;
  1698. } else {
  1699. xfer += iprot->skip(ftype);
  1700. }
  1701. break;
  1702. default:
  1703. xfer += iprot->skip(ftype);
  1704. break;
  1705. }
  1706. xfer += iprot->readFieldEnd();
  1707. }
  1708. xfer += iprot->readStructEnd();
  1709. return xfer;
  1710. }
  1711. uint32_t Cassandra_get_range_slices_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  1712. uint32_t xfer = 0;
  1713. std::string fname;
  1714. ::apache::thrift::protocol::TType ftype;
  1715. int16_t fid;
  1716. xfer += iprot->readStructBegin(fname);
  1717. using ::apache::thrift::protocol::TProtocolException;
  1718. bool isset_column_parent = false;
  1719. bool isset_predicate = false;
  1720. bool isset_range = false;
  1721. bool isset_consistency_level = false;
  1722. while (true)
  1723. {
  1724. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1725. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1726. break;
  1727. }
  1728. switch (fid)
  1729. {
  1730. case 1:
  1731. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1732. xfer += this->column_parent.read(iprot);
  1733. isset_column_parent = true;
  1734. } else {
  1735. xfer += iprot->skip(ftype);
  1736. }
  1737. break;
  1738. case 2:
  1739. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1740. xfer += this->predicate.read(iprot);
  1741. isset_predicate = true;
  1742. } else {
  1743. xfer += iprot->skip(ftype);
  1744. }
  1745. break;
  1746. case 3:
  1747. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1748. xfer += this->range.read(iprot);
  1749. isset_range = true;
  1750. } else {
  1751. xfer += iprot->skip(ftype);
  1752. }
  1753. break;
  1754. case 4:
  1755. if (ftype == ::apache::thrift::protocol::T_I32) {
  1756. int32_t ecast202;
  1757. xfer += iprot->readI32(ecast202);
  1758. this->consistency_level = (ConsistencyLevel::type)ecast202;
  1759. isset_consistency_level = true;
  1760. } else {
  1761. xfer += iprot->skip(ftype);
  1762. }
  1763. break;
  1764. default:
  1765. xfer += iprot->skip(ftype);
  1766. break;
  1767. }
  1768. xfer += iprot->readFieldEnd();
  1769. }
  1770. xfer += iprot->readStructEnd();
  1771. if (!isset_column_parent)
  1772. throw TProtocolException(TProtocolException::INVALID_DATA);
  1773. if (!isset_predicate)
  1774. throw TProtocolException(TProtocolException::INVALID_DATA);
  1775. if (!isset_range)
  1776. throw TProtocolException(TProtocolException::INVALID_DATA);
  1777. if (!isset_consistency_level)
  1778. throw TProtocolException(TProtocolException::INVALID_DATA);
  1779. return xfer;
  1780. }
  1781. uint32_t Cassandra_get_range_slices_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1782. uint32_t xfer = 0;
  1783. xfer += oprot->writeStructBegin("Cassandra_get_range_slices_args");
  1784. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 1);
  1785. xfer += this->column_parent.write(oprot);
  1786. xfer += oprot->writeFieldEnd();
  1787. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 2);
  1788. xfer += this->predicate.write(oprot);
  1789. xfer += oprot->writeFieldEnd();
  1790. xfer += oprot->writeFieldBegin("range", ::apache::thrift::protocol::T_STRUCT, 3);
  1791. xfer += this->range.write(oprot);
  1792. xfer += oprot->writeFieldEnd();
  1793. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1794. xfer += oprot->writeI32((int32_t)this->consistency_level);
  1795. xfer += oprot->writeFieldEnd();
  1796. xfer += oprot->writeFieldStop();
  1797. xfer += oprot->writeStructEnd();
  1798. return xfer;
  1799. }
  1800. uint32_t Cassandra_get_range_slices_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1801. uint32_t xfer = 0;
  1802. xfer += oprot->writeStructBegin("Cassandra_get_range_slices_pargs");
  1803. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 1);
  1804. xfer += (*(this->column_parent)).write(oprot);
  1805. xfer += oprot->writeFieldEnd();
  1806. xfer += oprot->writeFieldBegin("predicate", ::apache::thrift::protocol::T_STRUCT, 2);
  1807. xfer += (*(this->predicate)).write(oprot);
  1808. xfer += oprot->writeFieldEnd();
  1809. xfer += oprot->writeFieldBegin("range", ::apache::thrift::protocol::T_STRUCT, 3);
  1810. xfer += (*(this->range)).write(oprot);
  1811. xfer += oprot->writeFieldEnd();
  1812. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  1813. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  1814. xfer += oprot->writeFieldEnd();
  1815. xfer += oprot->writeFieldStop();
  1816. xfer += oprot->writeStructEnd();
  1817. return xfer;
  1818. }
  1819. uint32_t Cassandra_get_range_slices_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  1820. uint32_t xfer = 0;
  1821. std::string fname;
  1822. ::apache::thrift::protocol::TType ftype;
  1823. int16_t fid;
  1824. xfer += iprot->readStructBegin(fname);
  1825. using ::apache::thrift::protocol::TProtocolException;
  1826. while (true)
  1827. {
  1828. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1829. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1830. break;
  1831. }
  1832. switch (fid)
  1833. {
  1834. case 0:
  1835. if (ftype == ::apache::thrift::protocol::T_LIST) {
  1836. {
  1837. this->success.clear();
  1838. uint32_t _size203;
  1839. ::apache::thrift::protocol::TType _etype206;
  1840. iprot->readListBegin(_etype206, _size203);
  1841. this->success.resize(_size203);
  1842. uint32_t _i207;
  1843. for (_i207 = 0; _i207 < _size203; ++_i207)
  1844. {
  1845. xfer += this->success[_i207].read(iprot);
  1846. }
  1847. iprot->readListEnd();
  1848. }
  1849. this->__isset.success = true;
  1850. } else {
  1851. xfer += iprot->skip(ftype);
  1852. }
  1853. break;
  1854. case 1:
  1855. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1856. xfer += this->ire.read(iprot);
  1857. this->__isset.ire = true;
  1858. } else {
  1859. xfer += iprot->skip(ftype);
  1860. }
  1861. break;
  1862. case 2:
  1863. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1864. xfer += this->ue.read(iprot);
  1865. this->__isset.ue = true;
  1866. } else {
  1867. xfer += iprot->skip(ftype);
  1868. }
  1869. break;
  1870. case 3:
  1871. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1872. xfer += this->te.read(iprot);
  1873. this->__isset.te = true;
  1874. } else {
  1875. xfer += iprot->skip(ftype);
  1876. }
  1877. break;
  1878. default:
  1879. xfer += iprot->skip(ftype);
  1880. break;
  1881. }
  1882. xfer += iprot->readFieldEnd();
  1883. }
  1884. xfer += iprot->readStructEnd();
  1885. return xfer;
  1886. }
  1887. uint32_t Cassandra_get_range_slices_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  1888. uint32_t xfer = 0;
  1889. xfer += oprot->writeStructBegin("Cassandra_get_range_slices_result");
  1890. if (this->__isset.success) {
  1891. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  1892. {
  1893. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(this->success.size()));
  1894. std::vector<KeySlice> ::const_iterator _iter208;
  1895. for (_iter208 = this->success.begin(); _iter208 != this->success.end(); ++_iter208)
  1896. {
  1897. xfer += (*_iter208).write(oprot);
  1898. }
  1899. xfer += oprot->writeListEnd();
  1900. }
  1901. xfer += oprot->writeFieldEnd();
  1902. } else if (this->__isset.ire) {
  1903. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  1904. xfer += this->ire.write(oprot);
  1905. xfer += oprot->writeFieldEnd();
  1906. } else if (this->__isset.ue) {
  1907. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  1908. xfer += this->ue.write(oprot);
  1909. xfer += oprot->writeFieldEnd();
  1910. } else if (this->__isset.te) {
  1911. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  1912. xfer += this->te.write(oprot);
  1913. xfer += oprot->writeFieldEnd();
  1914. }
  1915. xfer += oprot->writeFieldStop();
  1916. xfer += oprot->writeStructEnd();
  1917. return xfer;
  1918. }
  1919. uint32_t Cassandra_get_range_slices_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  1920. uint32_t xfer = 0;
  1921. std::string fname;
  1922. ::apache::thrift::protocol::TType ftype;
  1923. int16_t fid;
  1924. xfer += iprot->readStructBegin(fname);
  1925. using ::apache::thrift::protocol::TProtocolException;
  1926. while (true)
  1927. {
  1928. xfer += iprot->readFieldBegin(fname, ftype, fid);
  1929. if (ftype == ::apache::thrift::protocol::T_STOP) {
  1930. break;
  1931. }
  1932. switch (fid)
  1933. {
  1934. case 0:
  1935. if (ftype == ::apache::thrift::protocol::T_LIST) {
  1936. {
  1937. (*(this->success)).clear();
  1938. uint32_t _size209;
  1939. ::apache::thrift::protocol::TType _etype212;
  1940. iprot->readListBegin(_etype212, _size209);
  1941. (*(this->success)).resize(_size209);
  1942. uint32_t _i213;
  1943. for (_i213 = 0; _i213 < _size209; ++_i213)
  1944. {
  1945. xfer += (*(this->success))[_i213].read(iprot);
  1946. }
  1947. iprot->readListEnd();
  1948. }
  1949. this->__isset.success = true;
  1950. } else {
  1951. xfer += iprot->skip(ftype);
  1952. }
  1953. break;
  1954. case 1:
  1955. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1956. xfer += this->ire.read(iprot);
  1957. this->__isset.ire = true;
  1958. } else {
  1959. xfer += iprot->skip(ftype);
  1960. }
  1961. break;
  1962. case 2:
  1963. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1964. xfer += this->ue.read(iprot);
  1965. this->__isset.ue = true;
  1966. } else {
  1967. xfer += iprot->skip(ftype);
  1968. }
  1969. break;
  1970. case 3:
  1971. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  1972. xfer += this->te.read(iprot);
  1973. this->__isset.te = true;
  1974. } else {
  1975. xfer += iprot->skip(ftype);
  1976. }
  1977. break;
  1978. default:
  1979. xfer += iprot->skip(ftype);
  1980. break;
  1981. }
  1982. xfer += iprot->readFieldEnd();
  1983. }
  1984. xfer += iprot->readStructEnd();
  1985. return xfer;
  1986. }
  1987. uint32_t Cassandra_get_indexed_slices_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  1988. uint32_t xfer = 0;
  1989. std::string fname;
  1990. ::apache::thrift::protocol::TType ftype;
  1991. int16_t fid;
  1992. xfer += iprot->readStructBegin(fname);
  1993. using ::apache::thrift::protocol::TProtocolException;
  1994. bool isset_column_parent = false;
  1995. bool isset_index_clause = false;
  1996. bool isset_column_predicate = false;
  1997. bool isset_consistency_level = false;
  1998. while (true)
  1999. {
  2000. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2001. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2002. break;
  2003. }
  2004. switch (fid)
  2005. {
  2006. case 1:
  2007. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2008. xfer += this->column_parent.read(iprot);
  2009. isset_column_parent = true;
  2010. } else {
  2011. xfer += iprot->skip(ftype);
  2012. }
  2013. break;
  2014. case 2:
  2015. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2016. xfer += this->index_clause.read(iprot);
  2017. isset_index_clause = true;
  2018. } else {
  2019. xfer += iprot->skip(ftype);
  2020. }
  2021. break;
  2022. case 3:
  2023. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2024. xfer += this->column_predicate.read(iprot);
  2025. isset_column_predicate = true;
  2026. } else {
  2027. xfer += iprot->skip(ftype);
  2028. }
  2029. break;
  2030. case 4:
  2031. if (ftype == ::apache::thrift::protocol::T_I32) {
  2032. int32_t ecast214;
  2033. xfer += iprot->readI32(ecast214);
  2034. this->consistency_level = (ConsistencyLevel::type)ecast214;
  2035. isset_consistency_level = true;
  2036. } else {
  2037. xfer += iprot->skip(ftype);
  2038. }
  2039. break;
  2040. default:
  2041. xfer += iprot->skip(ftype);
  2042. break;
  2043. }
  2044. xfer += iprot->readFieldEnd();
  2045. }
  2046. xfer += iprot->readStructEnd();
  2047. if (!isset_column_parent)
  2048. throw TProtocolException(TProtocolException::INVALID_DATA);
  2049. if (!isset_index_clause)
  2050. throw TProtocolException(TProtocolException::INVALID_DATA);
  2051. if (!isset_column_predicate)
  2052. throw TProtocolException(TProtocolException::INVALID_DATA);
  2053. if (!isset_consistency_level)
  2054. throw TProtocolException(TProtocolException::INVALID_DATA);
  2055. return xfer;
  2056. }
  2057. uint32_t Cassandra_get_indexed_slices_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2058. uint32_t xfer = 0;
  2059. xfer += oprot->writeStructBegin("Cassandra_get_indexed_slices_args");
  2060. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 1);
  2061. xfer += this->column_parent.write(oprot);
  2062. xfer += oprot->writeFieldEnd();
  2063. xfer += oprot->writeFieldBegin("index_clause", ::apache::thrift::protocol::T_STRUCT, 2);
  2064. xfer += this->index_clause.write(oprot);
  2065. xfer += oprot->writeFieldEnd();
  2066. xfer += oprot->writeFieldBegin("column_predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  2067. xfer += this->column_predicate.write(oprot);
  2068. xfer += oprot->writeFieldEnd();
  2069. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2070. xfer += oprot->writeI32((int32_t)this->consistency_level);
  2071. xfer += oprot->writeFieldEnd();
  2072. xfer += oprot->writeFieldStop();
  2073. xfer += oprot->writeStructEnd();
  2074. return xfer;
  2075. }
  2076. uint32_t Cassandra_get_indexed_slices_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2077. uint32_t xfer = 0;
  2078. xfer += oprot->writeStructBegin("Cassandra_get_indexed_slices_pargs");
  2079. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 1);
  2080. xfer += (*(this->column_parent)).write(oprot);
  2081. xfer += oprot->writeFieldEnd();
  2082. xfer += oprot->writeFieldBegin("index_clause", ::apache::thrift::protocol::T_STRUCT, 2);
  2083. xfer += (*(this->index_clause)).write(oprot);
  2084. xfer += oprot->writeFieldEnd();
  2085. xfer += oprot->writeFieldBegin("column_predicate", ::apache::thrift::protocol::T_STRUCT, 3);
  2086. xfer += (*(this->column_predicate)).write(oprot);
  2087. xfer += oprot->writeFieldEnd();
  2088. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2089. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  2090. xfer += oprot->writeFieldEnd();
  2091. xfer += oprot->writeFieldStop();
  2092. xfer += oprot->writeStructEnd();
  2093. return xfer;
  2094. }
  2095. uint32_t Cassandra_get_indexed_slices_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  2096. uint32_t xfer = 0;
  2097. std::string fname;
  2098. ::apache::thrift::protocol::TType ftype;
  2099. int16_t fid;
  2100. xfer += iprot->readStructBegin(fname);
  2101. using ::apache::thrift::protocol::TProtocolException;
  2102. while (true)
  2103. {
  2104. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2105. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2106. break;
  2107. }
  2108. switch (fid)
  2109. {
  2110. case 0:
  2111. if (ftype == ::apache::thrift::protocol::T_LIST) {
  2112. {
  2113. this->success.clear();
  2114. uint32_t _size215;
  2115. ::apache::thrift::protocol::TType _etype218;
  2116. iprot->readListBegin(_etype218, _size215);
  2117. this->success.resize(_size215);
  2118. uint32_t _i219;
  2119. for (_i219 = 0; _i219 < _size215; ++_i219)
  2120. {
  2121. xfer += this->success[_i219].read(iprot);
  2122. }
  2123. iprot->readListEnd();
  2124. }
  2125. this->__isset.success = true;
  2126. } else {
  2127. xfer += iprot->skip(ftype);
  2128. }
  2129. break;
  2130. case 1:
  2131. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2132. xfer += this->ire.read(iprot);
  2133. this->__isset.ire = true;
  2134. } else {
  2135. xfer += iprot->skip(ftype);
  2136. }
  2137. break;
  2138. case 2:
  2139. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2140. xfer += this->ue.read(iprot);
  2141. this->__isset.ue = true;
  2142. } else {
  2143. xfer += iprot->skip(ftype);
  2144. }
  2145. break;
  2146. case 3:
  2147. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2148. xfer += this->te.read(iprot);
  2149. this->__isset.te = true;
  2150. } else {
  2151. xfer += iprot->skip(ftype);
  2152. }
  2153. break;
  2154. default:
  2155. xfer += iprot->skip(ftype);
  2156. break;
  2157. }
  2158. xfer += iprot->readFieldEnd();
  2159. }
  2160. xfer += iprot->readStructEnd();
  2161. return xfer;
  2162. }
  2163. uint32_t Cassandra_get_indexed_slices_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2164. uint32_t xfer = 0;
  2165. xfer += oprot->writeStructBegin("Cassandra_get_indexed_slices_result");
  2166. if (this->__isset.success) {
  2167. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  2168. {
  2169. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(this->success.size()));
  2170. std::vector<KeySlice> ::const_iterator _iter220;
  2171. for (_iter220 = this->success.begin(); _iter220 != this->success.end(); ++_iter220)
  2172. {
  2173. xfer += (*_iter220).write(oprot);
  2174. }
  2175. xfer += oprot->writeListEnd();
  2176. }
  2177. xfer += oprot->writeFieldEnd();
  2178. } else if (this->__isset.ire) {
  2179. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  2180. xfer += this->ire.write(oprot);
  2181. xfer += oprot->writeFieldEnd();
  2182. } else if (this->__isset.ue) {
  2183. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  2184. xfer += this->ue.write(oprot);
  2185. xfer += oprot->writeFieldEnd();
  2186. } else if (this->__isset.te) {
  2187. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  2188. xfer += this->te.write(oprot);
  2189. xfer += oprot->writeFieldEnd();
  2190. }
  2191. xfer += oprot->writeFieldStop();
  2192. xfer += oprot->writeStructEnd();
  2193. return xfer;
  2194. }
  2195. uint32_t Cassandra_get_indexed_slices_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  2196. uint32_t xfer = 0;
  2197. std::string fname;
  2198. ::apache::thrift::protocol::TType ftype;
  2199. int16_t fid;
  2200. xfer += iprot->readStructBegin(fname);
  2201. using ::apache::thrift::protocol::TProtocolException;
  2202. while (true)
  2203. {
  2204. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2205. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2206. break;
  2207. }
  2208. switch (fid)
  2209. {
  2210. case 0:
  2211. if (ftype == ::apache::thrift::protocol::T_LIST) {
  2212. {
  2213. (*(this->success)).clear();
  2214. uint32_t _size221;
  2215. ::apache::thrift::protocol::TType _etype224;
  2216. iprot->readListBegin(_etype224, _size221);
  2217. (*(this->success)).resize(_size221);
  2218. uint32_t _i225;
  2219. for (_i225 = 0; _i225 < _size221; ++_i225)
  2220. {
  2221. xfer += (*(this->success))[_i225].read(iprot);
  2222. }
  2223. iprot->readListEnd();
  2224. }
  2225. this->__isset.success = true;
  2226. } else {
  2227. xfer += iprot->skip(ftype);
  2228. }
  2229. break;
  2230. case 1:
  2231. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2232. xfer += this->ire.read(iprot);
  2233. this->__isset.ire = true;
  2234. } else {
  2235. xfer += iprot->skip(ftype);
  2236. }
  2237. break;
  2238. case 2:
  2239. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2240. xfer += this->ue.read(iprot);
  2241. this->__isset.ue = true;
  2242. } else {
  2243. xfer += iprot->skip(ftype);
  2244. }
  2245. break;
  2246. case 3:
  2247. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2248. xfer += this->te.read(iprot);
  2249. this->__isset.te = true;
  2250. } else {
  2251. xfer += iprot->skip(ftype);
  2252. }
  2253. break;
  2254. default:
  2255. xfer += iprot->skip(ftype);
  2256. break;
  2257. }
  2258. xfer += iprot->readFieldEnd();
  2259. }
  2260. xfer += iprot->readStructEnd();
  2261. return xfer;
  2262. }
  2263. uint32_t Cassandra_insert_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  2264. uint32_t xfer = 0;
  2265. std::string fname;
  2266. ::apache::thrift::protocol::TType ftype;
  2267. int16_t fid;
  2268. xfer += iprot->readStructBegin(fname);
  2269. using ::apache::thrift::protocol::TProtocolException;
  2270. bool isset_key = false;
  2271. bool isset_column_parent = false;
  2272. bool isset_column = false;
  2273. bool isset_consistency_level = false;
  2274. while (true)
  2275. {
  2276. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2277. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2278. break;
  2279. }
  2280. switch (fid)
  2281. {
  2282. case 1:
  2283. if (ftype == ::apache::thrift::protocol::T_STRING) {
  2284. xfer += iprot->readBinary(this->key);
  2285. isset_key = true;
  2286. } else {
  2287. xfer += iprot->skip(ftype);
  2288. }
  2289. break;
  2290. case 2:
  2291. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2292. xfer += this->column_parent.read(iprot);
  2293. isset_column_parent = true;
  2294. } else {
  2295. xfer += iprot->skip(ftype);
  2296. }
  2297. break;
  2298. case 3:
  2299. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2300. xfer += this->column.read(iprot);
  2301. isset_column = true;
  2302. } else {
  2303. xfer += iprot->skip(ftype);
  2304. }
  2305. break;
  2306. case 4:
  2307. if (ftype == ::apache::thrift::protocol::T_I32) {
  2308. int32_t ecast226;
  2309. xfer += iprot->readI32(ecast226);
  2310. this->consistency_level = (ConsistencyLevel::type)ecast226;
  2311. isset_consistency_level = true;
  2312. } else {
  2313. xfer += iprot->skip(ftype);
  2314. }
  2315. break;
  2316. default:
  2317. xfer += iprot->skip(ftype);
  2318. break;
  2319. }
  2320. xfer += iprot->readFieldEnd();
  2321. }
  2322. xfer += iprot->readStructEnd();
  2323. if (!isset_key)
  2324. throw TProtocolException(TProtocolException::INVALID_DATA);
  2325. if (!isset_column_parent)
  2326. throw TProtocolException(TProtocolException::INVALID_DATA);
  2327. if (!isset_column)
  2328. throw TProtocolException(TProtocolException::INVALID_DATA);
  2329. if (!isset_consistency_level)
  2330. throw TProtocolException(TProtocolException::INVALID_DATA);
  2331. return xfer;
  2332. }
  2333. uint32_t Cassandra_insert_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2334. uint32_t xfer = 0;
  2335. xfer += oprot->writeStructBegin("Cassandra_insert_args");
  2336. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2337. xfer += oprot->writeBinary(this->key);
  2338. xfer += oprot->writeFieldEnd();
  2339. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  2340. xfer += this->column_parent.write(oprot);
  2341. xfer += oprot->writeFieldEnd();
  2342. xfer += oprot->writeFieldBegin("column", ::apache::thrift::protocol::T_STRUCT, 3);
  2343. xfer += this->column.write(oprot);
  2344. xfer += oprot->writeFieldEnd();
  2345. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2346. xfer += oprot->writeI32((int32_t)this->consistency_level);
  2347. xfer += oprot->writeFieldEnd();
  2348. xfer += oprot->writeFieldStop();
  2349. xfer += oprot->writeStructEnd();
  2350. return xfer;
  2351. }
  2352. uint32_t Cassandra_insert_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2353. uint32_t xfer = 0;
  2354. xfer += oprot->writeStructBegin("Cassandra_insert_pargs");
  2355. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2356. xfer += oprot->writeBinary((*(this->key)));
  2357. xfer += oprot->writeFieldEnd();
  2358. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  2359. xfer += (*(this->column_parent)).write(oprot);
  2360. xfer += oprot->writeFieldEnd();
  2361. xfer += oprot->writeFieldBegin("column", ::apache::thrift::protocol::T_STRUCT, 3);
  2362. xfer += (*(this->column)).write(oprot);
  2363. xfer += oprot->writeFieldEnd();
  2364. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2365. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  2366. xfer += oprot->writeFieldEnd();
  2367. xfer += oprot->writeFieldStop();
  2368. xfer += oprot->writeStructEnd();
  2369. return xfer;
  2370. }
  2371. uint32_t Cassandra_insert_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  2372. uint32_t xfer = 0;
  2373. std::string fname;
  2374. ::apache::thrift::protocol::TType ftype;
  2375. int16_t fid;
  2376. xfer += iprot->readStructBegin(fname);
  2377. using ::apache::thrift::protocol::TProtocolException;
  2378. while (true)
  2379. {
  2380. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2381. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2382. break;
  2383. }
  2384. switch (fid)
  2385. {
  2386. case 1:
  2387. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2388. xfer += this->ire.read(iprot);
  2389. this->__isset.ire = true;
  2390. } else {
  2391. xfer += iprot->skip(ftype);
  2392. }
  2393. break;
  2394. case 2:
  2395. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2396. xfer += this->ue.read(iprot);
  2397. this->__isset.ue = true;
  2398. } else {
  2399. xfer += iprot->skip(ftype);
  2400. }
  2401. break;
  2402. case 3:
  2403. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2404. xfer += this->te.read(iprot);
  2405. this->__isset.te = true;
  2406. } else {
  2407. xfer += iprot->skip(ftype);
  2408. }
  2409. break;
  2410. default:
  2411. xfer += iprot->skip(ftype);
  2412. break;
  2413. }
  2414. xfer += iprot->readFieldEnd();
  2415. }
  2416. xfer += iprot->readStructEnd();
  2417. return xfer;
  2418. }
  2419. uint32_t Cassandra_insert_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2420. uint32_t xfer = 0;
  2421. xfer += oprot->writeStructBegin("Cassandra_insert_result");
  2422. if (this->__isset.ire) {
  2423. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  2424. xfer += this->ire.write(oprot);
  2425. xfer += oprot->writeFieldEnd();
  2426. } else if (this->__isset.ue) {
  2427. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  2428. xfer += this->ue.write(oprot);
  2429. xfer += oprot->writeFieldEnd();
  2430. } else if (this->__isset.te) {
  2431. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  2432. xfer += this->te.write(oprot);
  2433. xfer += oprot->writeFieldEnd();
  2434. }
  2435. xfer += oprot->writeFieldStop();
  2436. xfer += oprot->writeStructEnd();
  2437. return xfer;
  2438. }
  2439. uint32_t Cassandra_insert_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  2440. uint32_t xfer = 0;
  2441. std::string fname;
  2442. ::apache::thrift::protocol::TType ftype;
  2443. int16_t fid;
  2444. xfer += iprot->readStructBegin(fname);
  2445. using ::apache::thrift::protocol::TProtocolException;
  2446. while (true)
  2447. {
  2448. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2449. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2450. break;
  2451. }
  2452. switch (fid)
  2453. {
  2454. case 1:
  2455. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2456. xfer += this->ire.read(iprot);
  2457. this->__isset.ire = true;
  2458. } else {
  2459. xfer += iprot->skip(ftype);
  2460. }
  2461. break;
  2462. case 2:
  2463. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2464. xfer += this->ue.read(iprot);
  2465. this->__isset.ue = true;
  2466. } else {
  2467. xfer += iprot->skip(ftype);
  2468. }
  2469. break;
  2470. case 3:
  2471. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2472. xfer += this->te.read(iprot);
  2473. this->__isset.te = true;
  2474. } else {
  2475. xfer += iprot->skip(ftype);
  2476. }
  2477. break;
  2478. default:
  2479. xfer += iprot->skip(ftype);
  2480. break;
  2481. }
  2482. xfer += iprot->readFieldEnd();
  2483. }
  2484. xfer += iprot->readStructEnd();
  2485. return xfer;
  2486. }
  2487. uint32_t Cassandra_add_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  2488. uint32_t xfer = 0;
  2489. std::string fname;
  2490. ::apache::thrift::protocol::TType ftype;
  2491. int16_t fid;
  2492. xfer += iprot->readStructBegin(fname);
  2493. using ::apache::thrift::protocol::TProtocolException;
  2494. bool isset_key = false;
  2495. bool isset_column_parent = false;
  2496. bool isset_column = false;
  2497. bool isset_consistency_level = false;
  2498. while (true)
  2499. {
  2500. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2501. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2502. break;
  2503. }
  2504. switch (fid)
  2505. {
  2506. case 1:
  2507. if (ftype == ::apache::thrift::protocol::T_STRING) {
  2508. xfer += iprot->readBinary(this->key);
  2509. isset_key = true;
  2510. } else {
  2511. xfer += iprot->skip(ftype);
  2512. }
  2513. break;
  2514. case 2:
  2515. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2516. xfer += this->column_parent.read(iprot);
  2517. isset_column_parent = true;
  2518. } else {
  2519. xfer += iprot->skip(ftype);
  2520. }
  2521. break;
  2522. case 3:
  2523. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2524. xfer += this->column.read(iprot);
  2525. isset_column = true;
  2526. } else {
  2527. xfer += iprot->skip(ftype);
  2528. }
  2529. break;
  2530. case 4:
  2531. if (ftype == ::apache::thrift::protocol::T_I32) {
  2532. int32_t ecast227;
  2533. xfer += iprot->readI32(ecast227);
  2534. this->consistency_level = (ConsistencyLevel::type)ecast227;
  2535. isset_consistency_level = true;
  2536. } else {
  2537. xfer += iprot->skip(ftype);
  2538. }
  2539. break;
  2540. default:
  2541. xfer += iprot->skip(ftype);
  2542. break;
  2543. }
  2544. xfer += iprot->readFieldEnd();
  2545. }
  2546. xfer += iprot->readStructEnd();
  2547. if (!isset_key)
  2548. throw TProtocolException(TProtocolException::INVALID_DATA);
  2549. if (!isset_column_parent)
  2550. throw TProtocolException(TProtocolException::INVALID_DATA);
  2551. if (!isset_column)
  2552. throw TProtocolException(TProtocolException::INVALID_DATA);
  2553. if (!isset_consistency_level)
  2554. throw TProtocolException(TProtocolException::INVALID_DATA);
  2555. return xfer;
  2556. }
  2557. uint32_t Cassandra_add_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2558. uint32_t xfer = 0;
  2559. xfer += oprot->writeStructBegin("Cassandra_add_args");
  2560. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2561. xfer += oprot->writeBinary(this->key);
  2562. xfer += oprot->writeFieldEnd();
  2563. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  2564. xfer += this->column_parent.write(oprot);
  2565. xfer += oprot->writeFieldEnd();
  2566. xfer += oprot->writeFieldBegin("column", ::apache::thrift::protocol::T_STRUCT, 3);
  2567. xfer += this->column.write(oprot);
  2568. xfer += oprot->writeFieldEnd();
  2569. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2570. xfer += oprot->writeI32((int32_t)this->consistency_level);
  2571. xfer += oprot->writeFieldEnd();
  2572. xfer += oprot->writeFieldStop();
  2573. xfer += oprot->writeStructEnd();
  2574. return xfer;
  2575. }
  2576. uint32_t Cassandra_add_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2577. uint32_t xfer = 0;
  2578. xfer += oprot->writeStructBegin("Cassandra_add_pargs");
  2579. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2580. xfer += oprot->writeBinary((*(this->key)));
  2581. xfer += oprot->writeFieldEnd();
  2582. xfer += oprot->writeFieldBegin("column_parent", ::apache::thrift::protocol::T_STRUCT, 2);
  2583. xfer += (*(this->column_parent)).write(oprot);
  2584. xfer += oprot->writeFieldEnd();
  2585. xfer += oprot->writeFieldBegin("column", ::apache::thrift::protocol::T_STRUCT, 3);
  2586. xfer += (*(this->column)).write(oprot);
  2587. xfer += oprot->writeFieldEnd();
  2588. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2589. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  2590. xfer += oprot->writeFieldEnd();
  2591. xfer += oprot->writeFieldStop();
  2592. xfer += oprot->writeStructEnd();
  2593. return xfer;
  2594. }
  2595. uint32_t Cassandra_add_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  2596. uint32_t xfer = 0;
  2597. std::string fname;
  2598. ::apache::thrift::protocol::TType ftype;
  2599. int16_t fid;
  2600. xfer += iprot->readStructBegin(fname);
  2601. using ::apache::thrift::protocol::TProtocolException;
  2602. while (true)
  2603. {
  2604. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2605. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2606. break;
  2607. }
  2608. switch (fid)
  2609. {
  2610. case 1:
  2611. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2612. xfer += this->ire.read(iprot);
  2613. this->__isset.ire = true;
  2614. } else {
  2615. xfer += iprot->skip(ftype);
  2616. }
  2617. break;
  2618. case 2:
  2619. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2620. xfer += this->ue.read(iprot);
  2621. this->__isset.ue = true;
  2622. } else {
  2623. xfer += iprot->skip(ftype);
  2624. }
  2625. break;
  2626. case 3:
  2627. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2628. xfer += this->te.read(iprot);
  2629. this->__isset.te = true;
  2630. } else {
  2631. xfer += iprot->skip(ftype);
  2632. }
  2633. break;
  2634. default:
  2635. xfer += iprot->skip(ftype);
  2636. break;
  2637. }
  2638. xfer += iprot->readFieldEnd();
  2639. }
  2640. xfer += iprot->readStructEnd();
  2641. return xfer;
  2642. }
  2643. uint32_t Cassandra_add_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2644. uint32_t xfer = 0;
  2645. xfer += oprot->writeStructBegin("Cassandra_add_result");
  2646. if (this->__isset.ire) {
  2647. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  2648. xfer += this->ire.write(oprot);
  2649. xfer += oprot->writeFieldEnd();
  2650. } else if (this->__isset.ue) {
  2651. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  2652. xfer += this->ue.write(oprot);
  2653. xfer += oprot->writeFieldEnd();
  2654. } else if (this->__isset.te) {
  2655. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  2656. xfer += this->te.write(oprot);
  2657. xfer += oprot->writeFieldEnd();
  2658. }
  2659. xfer += oprot->writeFieldStop();
  2660. xfer += oprot->writeStructEnd();
  2661. return xfer;
  2662. }
  2663. uint32_t Cassandra_add_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  2664. uint32_t xfer = 0;
  2665. std::string fname;
  2666. ::apache::thrift::protocol::TType ftype;
  2667. int16_t fid;
  2668. xfer += iprot->readStructBegin(fname);
  2669. using ::apache::thrift::protocol::TProtocolException;
  2670. while (true)
  2671. {
  2672. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2673. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2674. break;
  2675. }
  2676. switch (fid)
  2677. {
  2678. case 1:
  2679. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2680. xfer += this->ire.read(iprot);
  2681. this->__isset.ire = true;
  2682. } else {
  2683. xfer += iprot->skip(ftype);
  2684. }
  2685. break;
  2686. case 2:
  2687. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2688. xfer += this->ue.read(iprot);
  2689. this->__isset.ue = true;
  2690. } else {
  2691. xfer += iprot->skip(ftype);
  2692. }
  2693. break;
  2694. case 3:
  2695. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2696. xfer += this->te.read(iprot);
  2697. this->__isset.te = true;
  2698. } else {
  2699. xfer += iprot->skip(ftype);
  2700. }
  2701. break;
  2702. default:
  2703. xfer += iprot->skip(ftype);
  2704. break;
  2705. }
  2706. xfer += iprot->readFieldEnd();
  2707. }
  2708. xfer += iprot->readStructEnd();
  2709. return xfer;
  2710. }
  2711. uint32_t Cassandra_remove_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  2712. uint32_t xfer = 0;
  2713. std::string fname;
  2714. ::apache::thrift::protocol::TType ftype;
  2715. int16_t fid;
  2716. xfer += iprot->readStructBegin(fname);
  2717. using ::apache::thrift::protocol::TProtocolException;
  2718. bool isset_key = false;
  2719. bool isset_column_path = false;
  2720. bool isset_timestamp = false;
  2721. while (true)
  2722. {
  2723. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2724. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2725. break;
  2726. }
  2727. switch (fid)
  2728. {
  2729. case 1:
  2730. if (ftype == ::apache::thrift::protocol::T_STRING) {
  2731. xfer += iprot->readBinary(this->key);
  2732. isset_key = true;
  2733. } else {
  2734. xfer += iprot->skip(ftype);
  2735. }
  2736. break;
  2737. case 2:
  2738. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2739. xfer += this->column_path.read(iprot);
  2740. isset_column_path = true;
  2741. } else {
  2742. xfer += iprot->skip(ftype);
  2743. }
  2744. break;
  2745. case 3:
  2746. if (ftype == ::apache::thrift::protocol::T_I64) {
  2747. xfer += iprot->readI64(this->timestamp);
  2748. isset_timestamp = true;
  2749. } else {
  2750. xfer += iprot->skip(ftype);
  2751. }
  2752. break;
  2753. case 4:
  2754. if (ftype == ::apache::thrift::protocol::T_I32) {
  2755. int32_t ecast228;
  2756. xfer += iprot->readI32(ecast228);
  2757. this->consistency_level = (ConsistencyLevel::type)ecast228;
  2758. this->__isset.consistency_level = true;
  2759. } else {
  2760. xfer += iprot->skip(ftype);
  2761. }
  2762. break;
  2763. default:
  2764. xfer += iprot->skip(ftype);
  2765. break;
  2766. }
  2767. xfer += iprot->readFieldEnd();
  2768. }
  2769. xfer += iprot->readStructEnd();
  2770. if (!isset_key)
  2771. throw TProtocolException(TProtocolException::INVALID_DATA);
  2772. if (!isset_column_path)
  2773. throw TProtocolException(TProtocolException::INVALID_DATA);
  2774. if (!isset_timestamp)
  2775. throw TProtocolException(TProtocolException::INVALID_DATA);
  2776. return xfer;
  2777. }
  2778. uint32_t Cassandra_remove_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2779. uint32_t xfer = 0;
  2780. xfer += oprot->writeStructBegin("Cassandra_remove_args");
  2781. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2782. xfer += oprot->writeBinary(this->key);
  2783. xfer += oprot->writeFieldEnd();
  2784. xfer += oprot->writeFieldBegin("column_path", ::apache::thrift::protocol::T_STRUCT, 2);
  2785. xfer += this->column_path.write(oprot);
  2786. xfer += oprot->writeFieldEnd();
  2787. xfer += oprot->writeFieldBegin("timestamp", ::apache::thrift::protocol::T_I64, 3);
  2788. xfer += oprot->writeI64(this->timestamp);
  2789. xfer += oprot->writeFieldEnd();
  2790. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2791. xfer += oprot->writeI32((int32_t)this->consistency_level);
  2792. xfer += oprot->writeFieldEnd();
  2793. xfer += oprot->writeFieldStop();
  2794. xfer += oprot->writeStructEnd();
  2795. return xfer;
  2796. }
  2797. uint32_t Cassandra_remove_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2798. uint32_t xfer = 0;
  2799. xfer += oprot->writeStructBegin("Cassandra_remove_pargs");
  2800. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2801. xfer += oprot->writeBinary((*(this->key)));
  2802. xfer += oprot->writeFieldEnd();
  2803. xfer += oprot->writeFieldBegin("column_path", ::apache::thrift::protocol::T_STRUCT, 2);
  2804. xfer += (*(this->column_path)).write(oprot);
  2805. xfer += oprot->writeFieldEnd();
  2806. xfer += oprot->writeFieldBegin("timestamp", ::apache::thrift::protocol::T_I64, 3);
  2807. xfer += oprot->writeI64((*(this->timestamp)));
  2808. xfer += oprot->writeFieldEnd();
  2809. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 4);
  2810. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  2811. xfer += oprot->writeFieldEnd();
  2812. xfer += oprot->writeFieldStop();
  2813. xfer += oprot->writeStructEnd();
  2814. return xfer;
  2815. }
  2816. uint32_t Cassandra_remove_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  2817. uint32_t xfer = 0;
  2818. std::string fname;
  2819. ::apache::thrift::protocol::TType ftype;
  2820. int16_t fid;
  2821. xfer += iprot->readStructBegin(fname);
  2822. using ::apache::thrift::protocol::TProtocolException;
  2823. while (true)
  2824. {
  2825. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2826. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2827. break;
  2828. }
  2829. switch (fid)
  2830. {
  2831. case 1:
  2832. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2833. xfer += this->ire.read(iprot);
  2834. this->__isset.ire = true;
  2835. } else {
  2836. xfer += iprot->skip(ftype);
  2837. }
  2838. break;
  2839. case 2:
  2840. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2841. xfer += this->ue.read(iprot);
  2842. this->__isset.ue = true;
  2843. } else {
  2844. xfer += iprot->skip(ftype);
  2845. }
  2846. break;
  2847. case 3:
  2848. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2849. xfer += this->te.read(iprot);
  2850. this->__isset.te = true;
  2851. } else {
  2852. xfer += iprot->skip(ftype);
  2853. }
  2854. break;
  2855. default:
  2856. xfer += iprot->skip(ftype);
  2857. break;
  2858. }
  2859. xfer += iprot->readFieldEnd();
  2860. }
  2861. xfer += iprot->readStructEnd();
  2862. return xfer;
  2863. }
  2864. uint32_t Cassandra_remove_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2865. uint32_t xfer = 0;
  2866. xfer += oprot->writeStructBegin("Cassandra_remove_result");
  2867. if (this->__isset.ire) {
  2868. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  2869. xfer += this->ire.write(oprot);
  2870. xfer += oprot->writeFieldEnd();
  2871. } else if (this->__isset.ue) {
  2872. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  2873. xfer += this->ue.write(oprot);
  2874. xfer += oprot->writeFieldEnd();
  2875. } else if (this->__isset.te) {
  2876. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  2877. xfer += this->te.write(oprot);
  2878. xfer += oprot->writeFieldEnd();
  2879. }
  2880. xfer += oprot->writeFieldStop();
  2881. xfer += oprot->writeStructEnd();
  2882. return xfer;
  2883. }
  2884. uint32_t Cassandra_remove_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  2885. uint32_t xfer = 0;
  2886. std::string fname;
  2887. ::apache::thrift::protocol::TType ftype;
  2888. int16_t fid;
  2889. xfer += iprot->readStructBegin(fname);
  2890. using ::apache::thrift::protocol::TProtocolException;
  2891. while (true)
  2892. {
  2893. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2894. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2895. break;
  2896. }
  2897. switch (fid)
  2898. {
  2899. case 1:
  2900. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2901. xfer += this->ire.read(iprot);
  2902. this->__isset.ire = true;
  2903. } else {
  2904. xfer += iprot->skip(ftype);
  2905. }
  2906. break;
  2907. case 2:
  2908. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2909. xfer += this->ue.read(iprot);
  2910. this->__isset.ue = true;
  2911. } else {
  2912. xfer += iprot->skip(ftype);
  2913. }
  2914. break;
  2915. case 3:
  2916. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2917. xfer += this->te.read(iprot);
  2918. this->__isset.te = true;
  2919. } else {
  2920. xfer += iprot->skip(ftype);
  2921. }
  2922. break;
  2923. default:
  2924. xfer += iprot->skip(ftype);
  2925. break;
  2926. }
  2927. xfer += iprot->readFieldEnd();
  2928. }
  2929. xfer += iprot->readStructEnd();
  2930. return xfer;
  2931. }
  2932. uint32_t Cassandra_remove_counter_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  2933. uint32_t xfer = 0;
  2934. std::string fname;
  2935. ::apache::thrift::protocol::TType ftype;
  2936. int16_t fid;
  2937. xfer += iprot->readStructBegin(fname);
  2938. using ::apache::thrift::protocol::TProtocolException;
  2939. bool isset_key = false;
  2940. bool isset_path = false;
  2941. bool isset_consistency_level = false;
  2942. while (true)
  2943. {
  2944. xfer += iprot->readFieldBegin(fname, ftype, fid);
  2945. if (ftype == ::apache::thrift::protocol::T_STOP) {
  2946. break;
  2947. }
  2948. switch (fid)
  2949. {
  2950. case 1:
  2951. if (ftype == ::apache::thrift::protocol::T_STRING) {
  2952. xfer += iprot->readBinary(this->key);
  2953. isset_key = true;
  2954. } else {
  2955. xfer += iprot->skip(ftype);
  2956. }
  2957. break;
  2958. case 2:
  2959. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  2960. xfer += this->path.read(iprot);
  2961. isset_path = true;
  2962. } else {
  2963. xfer += iprot->skip(ftype);
  2964. }
  2965. break;
  2966. case 3:
  2967. if (ftype == ::apache::thrift::protocol::T_I32) {
  2968. int32_t ecast229;
  2969. xfer += iprot->readI32(ecast229);
  2970. this->consistency_level = (ConsistencyLevel::type)ecast229;
  2971. isset_consistency_level = true;
  2972. } else {
  2973. xfer += iprot->skip(ftype);
  2974. }
  2975. break;
  2976. default:
  2977. xfer += iprot->skip(ftype);
  2978. break;
  2979. }
  2980. xfer += iprot->readFieldEnd();
  2981. }
  2982. xfer += iprot->readStructEnd();
  2983. if (!isset_key)
  2984. throw TProtocolException(TProtocolException::INVALID_DATA);
  2985. if (!isset_path)
  2986. throw TProtocolException(TProtocolException::INVALID_DATA);
  2987. if (!isset_consistency_level)
  2988. throw TProtocolException(TProtocolException::INVALID_DATA);
  2989. return xfer;
  2990. }
  2991. uint32_t Cassandra_remove_counter_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  2992. uint32_t xfer = 0;
  2993. xfer += oprot->writeStructBegin("Cassandra_remove_counter_args");
  2994. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  2995. xfer += oprot->writeBinary(this->key);
  2996. xfer += oprot->writeFieldEnd();
  2997. xfer += oprot->writeFieldBegin("path", ::apache::thrift::protocol::T_STRUCT, 2);
  2998. xfer += this->path.write(oprot);
  2999. xfer += oprot->writeFieldEnd();
  3000. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 3);
  3001. xfer += oprot->writeI32((int32_t)this->consistency_level);
  3002. xfer += oprot->writeFieldEnd();
  3003. xfer += oprot->writeFieldStop();
  3004. xfer += oprot->writeStructEnd();
  3005. return xfer;
  3006. }
  3007. uint32_t Cassandra_remove_counter_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3008. uint32_t xfer = 0;
  3009. xfer += oprot->writeStructBegin("Cassandra_remove_counter_pargs");
  3010. xfer += oprot->writeFieldBegin("key", ::apache::thrift::protocol::T_STRING, 1);
  3011. xfer += oprot->writeBinary((*(this->key)));
  3012. xfer += oprot->writeFieldEnd();
  3013. xfer += oprot->writeFieldBegin("path", ::apache::thrift::protocol::T_STRUCT, 2);
  3014. xfer += (*(this->path)).write(oprot);
  3015. xfer += oprot->writeFieldEnd();
  3016. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 3);
  3017. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  3018. xfer += oprot->writeFieldEnd();
  3019. xfer += oprot->writeFieldStop();
  3020. xfer += oprot->writeStructEnd();
  3021. return xfer;
  3022. }
  3023. uint32_t Cassandra_remove_counter_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3024. uint32_t xfer = 0;
  3025. std::string fname;
  3026. ::apache::thrift::protocol::TType ftype;
  3027. int16_t fid;
  3028. xfer += iprot->readStructBegin(fname);
  3029. using ::apache::thrift::protocol::TProtocolException;
  3030. while (true)
  3031. {
  3032. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3033. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3034. break;
  3035. }
  3036. switch (fid)
  3037. {
  3038. case 1:
  3039. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3040. xfer += this->ire.read(iprot);
  3041. this->__isset.ire = true;
  3042. } else {
  3043. xfer += iprot->skip(ftype);
  3044. }
  3045. break;
  3046. case 2:
  3047. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3048. xfer += this->ue.read(iprot);
  3049. this->__isset.ue = true;
  3050. } else {
  3051. xfer += iprot->skip(ftype);
  3052. }
  3053. break;
  3054. case 3:
  3055. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3056. xfer += this->te.read(iprot);
  3057. this->__isset.te = true;
  3058. } else {
  3059. xfer += iprot->skip(ftype);
  3060. }
  3061. break;
  3062. default:
  3063. xfer += iprot->skip(ftype);
  3064. break;
  3065. }
  3066. xfer += iprot->readFieldEnd();
  3067. }
  3068. xfer += iprot->readStructEnd();
  3069. return xfer;
  3070. }
  3071. uint32_t Cassandra_remove_counter_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3072. uint32_t xfer = 0;
  3073. xfer += oprot->writeStructBegin("Cassandra_remove_counter_result");
  3074. if (this->__isset.ire) {
  3075. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  3076. xfer += this->ire.write(oprot);
  3077. xfer += oprot->writeFieldEnd();
  3078. } else if (this->__isset.ue) {
  3079. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  3080. xfer += this->ue.write(oprot);
  3081. xfer += oprot->writeFieldEnd();
  3082. } else if (this->__isset.te) {
  3083. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  3084. xfer += this->te.write(oprot);
  3085. xfer += oprot->writeFieldEnd();
  3086. }
  3087. xfer += oprot->writeFieldStop();
  3088. xfer += oprot->writeStructEnd();
  3089. return xfer;
  3090. }
  3091. uint32_t Cassandra_remove_counter_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  3092. uint32_t xfer = 0;
  3093. std::string fname;
  3094. ::apache::thrift::protocol::TType ftype;
  3095. int16_t fid;
  3096. xfer += iprot->readStructBegin(fname);
  3097. using ::apache::thrift::protocol::TProtocolException;
  3098. while (true)
  3099. {
  3100. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3101. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3102. break;
  3103. }
  3104. switch (fid)
  3105. {
  3106. case 1:
  3107. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3108. xfer += this->ire.read(iprot);
  3109. this->__isset.ire = true;
  3110. } else {
  3111. xfer += iprot->skip(ftype);
  3112. }
  3113. break;
  3114. case 2:
  3115. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3116. xfer += this->ue.read(iprot);
  3117. this->__isset.ue = true;
  3118. } else {
  3119. xfer += iprot->skip(ftype);
  3120. }
  3121. break;
  3122. case 3:
  3123. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3124. xfer += this->te.read(iprot);
  3125. this->__isset.te = true;
  3126. } else {
  3127. xfer += iprot->skip(ftype);
  3128. }
  3129. break;
  3130. default:
  3131. xfer += iprot->skip(ftype);
  3132. break;
  3133. }
  3134. xfer += iprot->readFieldEnd();
  3135. }
  3136. xfer += iprot->readStructEnd();
  3137. return xfer;
  3138. }
  3139. uint32_t Cassandra_batch_mutate_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  3140. uint32_t xfer = 0;
  3141. std::string fname;
  3142. ::apache::thrift::protocol::TType ftype;
  3143. int16_t fid;
  3144. xfer += iprot->readStructBegin(fname);
  3145. using ::apache::thrift::protocol::TProtocolException;
  3146. bool isset_mutation_map = false;
  3147. bool isset_consistency_level = false;
  3148. while (true)
  3149. {
  3150. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3151. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3152. break;
  3153. }
  3154. switch (fid)
  3155. {
  3156. case 1:
  3157. if (ftype == ::apache::thrift::protocol::T_MAP) {
  3158. {
  3159. this->mutation_map.clear();
  3160. uint32_t _size230;
  3161. ::apache::thrift::protocol::TType _ktype231;
  3162. ::apache::thrift::protocol::TType _vtype232;
  3163. iprot->readMapBegin(_ktype231, _vtype232, _size230);
  3164. uint32_t _i234;
  3165. for (_i234 = 0; _i234 < _size230; ++_i234)
  3166. {
  3167. std::string _key235;
  3168. xfer += iprot->readBinary(_key235);
  3169. std::map<std::string, std::vector<Mutation> > & _val236 = this->mutation_map[_key235];
  3170. {
  3171. _val236.clear();
  3172. uint32_t _size237;
  3173. ::apache::thrift::protocol::TType _ktype238;
  3174. ::apache::thrift::protocol::TType _vtype239;
  3175. iprot->readMapBegin(_ktype238, _vtype239, _size237);
  3176. uint32_t _i241;
  3177. for (_i241 = 0; _i241 < _size237; ++_i241)
  3178. {
  3179. std::string _key242;
  3180. xfer += iprot->readString(_key242);
  3181. std::vector<Mutation> & _val243 = _val236[_key242];
  3182. {
  3183. _val243.clear();
  3184. uint32_t _size244;
  3185. ::apache::thrift::protocol::TType _etype247;
  3186. iprot->readListBegin(_etype247, _size244);
  3187. _val243.resize(_size244);
  3188. uint32_t _i248;
  3189. for (_i248 = 0; _i248 < _size244; ++_i248)
  3190. {
  3191. xfer += _val243[_i248].read(iprot);
  3192. }
  3193. iprot->readListEnd();
  3194. }
  3195. }
  3196. iprot->readMapEnd();
  3197. }
  3198. }
  3199. iprot->readMapEnd();
  3200. }
  3201. isset_mutation_map = true;
  3202. } else {
  3203. xfer += iprot->skip(ftype);
  3204. }
  3205. break;
  3206. case 2:
  3207. if (ftype == ::apache::thrift::protocol::T_I32) {
  3208. int32_t ecast249;
  3209. xfer += iprot->readI32(ecast249);
  3210. this->consistency_level = (ConsistencyLevel::type)ecast249;
  3211. isset_consistency_level = true;
  3212. } else {
  3213. xfer += iprot->skip(ftype);
  3214. }
  3215. break;
  3216. default:
  3217. xfer += iprot->skip(ftype);
  3218. break;
  3219. }
  3220. xfer += iprot->readFieldEnd();
  3221. }
  3222. xfer += iprot->readStructEnd();
  3223. if (!isset_mutation_map)
  3224. throw TProtocolException(TProtocolException::INVALID_DATA);
  3225. if (!isset_consistency_level)
  3226. throw TProtocolException(TProtocolException::INVALID_DATA);
  3227. return xfer;
  3228. }
  3229. uint32_t Cassandra_batch_mutate_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3230. uint32_t xfer = 0;
  3231. xfer += oprot->writeStructBegin("Cassandra_batch_mutate_args");
  3232. xfer += oprot->writeFieldBegin("mutation_map", ::apache::thrift::protocol::T_MAP, 1);
  3233. {
  3234. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_MAP, static_cast<uint32_t>(this->mutation_map.size()));
  3235. std::map<std::string, std::map<std::string, std::vector<Mutation> > > ::const_iterator _iter250;
  3236. for (_iter250 = this->mutation_map.begin(); _iter250 != this->mutation_map.end(); ++_iter250)
  3237. {
  3238. xfer += oprot->writeBinary(_iter250->first);
  3239. {
  3240. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_LIST, static_cast<uint32_t>(_iter250->second.size()));
  3241. std::map<std::string, std::vector<Mutation> > ::const_iterator _iter251;
  3242. for (_iter251 = _iter250->second.begin(); _iter251 != _iter250->second.end(); ++_iter251)
  3243. {
  3244. xfer += oprot->writeString(_iter251->first);
  3245. {
  3246. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(_iter251->second.size()));
  3247. std::vector<Mutation> ::const_iterator _iter252;
  3248. for (_iter252 = _iter251->second.begin(); _iter252 != _iter251->second.end(); ++_iter252)
  3249. {
  3250. xfer += (*_iter252).write(oprot);
  3251. }
  3252. xfer += oprot->writeListEnd();
  3253. }
  3254. }
  3255. xfer += oprot->writeMapEnd();
  3256. }
  3257. }
  3258. xfer += oprot->writeMapEnd();
  3259. }
  3260. xfer += oprot->writeFieldEnd();
  3261. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 2);
  3262. xfer += oprot->writeI32((int32_t)this->consistency_level);
  3263. xfer += oprot->writeFieldEnd();
  3264. xfer += oprot->writeFieldStop();
  3265. xfer += oprot->writeStructEnd();
  3266. return xfer;
  3267. }
  3268. uint32_t Cassandra_batch_mutate_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3269. uint32_t xfer = 0;
  3270. xfer += oprot->writeStructBegin("Cassandra_batch_mutate_pargs");
  3271. xfer += oprot->writeFieldBegin("mutation_map", ::apache::thrift::protocol::T_MAP, 1);
  3272. {
  3273. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_MAP, static_cast<uint32_t>((*(this->mutation_map)).size()));
  3274. std::map<std::string, std::map<std::string, std::vector<Mutation> > > ::const_iterator _iter253;
  3275. for (_iter253 = (*(this->mutation_map)).begin(); _iter253 != (*(this->mutation_map)).end(); ++_iter253)
  3276. {
  3277. xfer += oprot->writeBinary(_iter253->first);
  3278. {
  3279. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_LIST, static_cast<uint32_t>(_iter253->second.size()));
  3280. std::map<std::string, std::vector<Mutation> > ::const_iterator _iter254;
  3281. for (_iter254 = _iter253->second.begin(); _iter254 != _iter253->second.end(); ++_iter254)
  3282. {
  3283. xfer += oprot->writeString(_iter254->first);
  3284. {
  3285. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(_iter254->second.size()));
  3286. std::vector<Mutation> ::const_iterator _iter255;
  3287. for (_iter255 = _iter254->second.begin(); _iter255 != _iter254->second.end(); ++_iter255)
  3288. {
  3289. xfer += (*_iter255).write(oprot);
  3290. }
  3291. xfer += oprot->writeListEnd();
  3292. }
  3293. }
  3294. xfer += oprot->writeMapEnd();
  3295. }
  3296. }
  3297. xfer += oprot->writeMapEnd();
  3298. }
  3299. xfer += oprot->writeFieldEnd();
  3300. xfer += oprot->writeFieldBegin("consistency_level", ::apache::thrift::protocol::T_I32, 2);
  3301. xfer += oprot->writeI32((int32_t)(*(this->consistency_level)));
  3302. xfer += oprot->writeFieldEnd();
  3303. xfer += oprot->writeFieldStop();
  3304. xfer += oprot->writeStructEnd();
  3305. return xfer;
  3306. }
  3307. uint32_t Cassandra_batch_mutate_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3308. uint32_t xfer = 0;
  3309. std::string fname;
  3310. ::apache::thrift::protocol::TType ftype;
  3311. int16_t fid;
  3312. xfer += iprot->readStructBegin(fname);
  3313. using ::apache::thrift::protocol::TProtocolException;
  3314. while (true)
  3315. {
  3316. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3317. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3318. break;
  3319. }
  3320. switch (fid)
  3321. {
  3322. case 1:
  3323. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3324. xfer += this->ire.read(iprot);
  3325. this->__isset.ire = true;
  3326. } else {
  3327. xfer += iprot->skip(ftype);
  3328. }
  3329. break;
  3330. case 2:
  3331. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3332. xfer += this->ue.read(iprot);
  3333. this->__isset.ue = true;
  3334. } else {
  3335. xfer += iprot->skip(ftype);
  3336. }
  3337. break;
  3338. case 3:
  3339. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3340. xfer += this->te.read(iprot);
  3341. this->__isset.te = true;
  3342. } else {
  3343. xfer += iprot->skip(ftype);
  3344. }
  3345. break;
  3346. default:
  3347. xfer += iprot->skip(ftype);
  3348. break;
  3349. }
  3350. xfer += iprot->readFieldEnd();
  3351. }
  3352. xfer += iprot->readStructEnd();
  3353. return xfer;
  3354. }
  3355. uint32_t Cassandra_batch_mutate_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3356. uint32_t xfer = 0;
  3357. xfer += oprot->writeStructBegin("Cassandra_batch_mutate_result");
  3358. if (this->__isset.ire) {
  3359. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  3360. xfer += this->ire.write(oprot);
  3361. xfer += oprot->writeFieldEnd();
  3362. } else if (this->__isset.ue) {
  3363. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  3364. xfer += this->ue.write(oprot);
  3365. xfer += oprot->writeFieldEnd();
  3366. } else if (this->__isset.te) {
  3367. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  3368. xfer += this->te.write(oprot);
  3369. xfer += oprot->writeFieldEnd();
  3370. }
  3371. xfer += oprot->writeFieldStop();
  3372. xfer += oprot->writeStructEnd();
  3373. return xfer;
  3374. }
  3375. uint32_t Cassandra_batch_mutate_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  3376. uint32_t xfer = 0;
  3377. std::string fname;
  3378. ::apache::thrift::protocol::TType ftype;
  3379. int16_t fid;
  3380. xfer += iprot->readStructBegin(fname);
  3381. using ::apache::thrift::protocol::TProtocolException;
  3382. while (true)
  3383. {
  3384. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3385. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3386. break;
  3387. }
  3388. switch (fid)
  3389. {
  3390. case 1:
  3391. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3392. xfer += this->ire.read(iprot);
  3393. this->__isset.ire = true;
  3394. } else {
  3395. xfer += iprot->skip(ftype);
  3396. }
  3397. break;
  3398. case 2:
  3399. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3400. xfer += this->ue.read(iprot);
  3401. this->__isset.ue = true;
  3402. } else {
  3403. xfer += iprot->skip(ftype);
  3404. }
  3405. break;
  3406. case 3:
  3407. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3408. xfer += this->te.read(iprot);
  3409. this->__isset.te = true;
  3410. } else {
  3411. xfer += iprot->skip(ftype);
  3412. }
  3413. break;
  3414. default:
  3415. xfer += iprot->skip(ftype);
  3416. break;
  3417. }
  3418. xfer += iprot->readFieldEnd();
  3419. }
  3420. xfer += iprot->readStructEnd();
  3421. return xfer;
  3422. }
  3423. uint32_t Cassandra_truncate_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  3424. uint32_t xfer = 0;
  3425. std::string fname;
  3426. ::apache::thrift::protocol::TType ftype;
  3427. int16_t fid;
  3428. xfer += iprot->readStructBegin(fname);
  3429. using ::apache::thrift::protocol::TProtocolException;
  3430. bool isset_cfname = false;
  3431. while (true)
  3432. {
  3433. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3434. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3435. break;
  3436. }
  3437. switch (fid)
  3438. {
  3439. case 1:
  3440. if (ftype == ::apache::thrift::protocol::T_STRING) {
  3441. xfer += iprot->readString(this->cfname);
  3442. isset_cfname = true;
  3443. } else {
  3444. xfer += iprot->skip(ftype);
  3445. }
  3446. break;
  3447. default:
  3448. xfer += iprot->skip(ftype);
  3449. break;
  3450. }
  3451. xfer += iprot->readFieldEnd();
  3452. }
  3453. xfer += iprot->readStructEnd();
  3454. if (!isset_cfname)
  3455. throw TProtocolException(TProtocolException::INVALID_DATA);
  3456. return xfer;
  3457. }
  3458. uint32_t Cassandra_truncate_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3459. uint32_t xfer = 0;
  3460. xfer += oprot->writeStructBegin("Cassandra_truncate_args");
  3461. xfer += oprot->writeFieldBegin("cfname", ::apache::thrift::protocol::T_STRING, 1);
  3462. xfer += oprot->writeString(this->cfname);
  3463. xfer += oprot->writeFieldEnd();
  3464. xfer += oprot->writeFieldStop();
  3465. xfer += oprot->writeStructEnd();
  3466. return xfer;
  3467. }
  3468. uint32_t Cassandra_truncate_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3469. uint32_t xfer = 0;
  3470. xfer += oprot->writeStructBegin("Cassandra_truncate_pargs");
  3471. xfer += oprot->writeFieldBegin("cfname", ::apache::thrift::protocol::T_STRING, 1);
  3472. xfer += oprot->writeString((*(this->cfname)));
  3473. xfer += oprot->writeFieldEnd();
  3474. xfer += oprot->writeFieldStop();
  3475. xfer += oprot->writeStructEnd();
  3476. return xfer;
  3477. }
  3478. uint32_t Cassandra_truncate_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3479. uint32_t xfer = 0;
  3480. std::string fname;
  3481. ::apache::thrift::protocol::TType ftype;
  3482. int16_t fid;
  3483. xfer += iprot->readStructBegin(fname);
  3484. using ::apache::thrift::protocol::TProtocolException;
  3485. while (true)
  3486. {
  3487. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3488. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3489. break;
  3490. }
  3491. switch (fid)
  3492. {
  3493. case 1:
  3494. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3495. xfer += this->ire.read(iprot);
  3496. this->__isset.ire = true;
  3497. } else {
  3498. xfer += iprot->skip(ftype);
  3499. }
  3500. break;
  3501. case 2:
  3502. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3503. xfer += this->ue.read(iprot);
  3504. this->__isset.ue = true;
  3505. } else {
  3506. xfer += iprot->skip(ftype);
  3507. }
  3508. break;
  3509. default:
  3510. xfer += iprot->skip(ftype);
  3511. break;
  3512. }
  3513. xfer += iprot->readFieldEnd();
  3514. }
  3515. xfer += iprot->readStructEnd();
  3516. return xfer;
  3517. }
  3518. uint32_t Cassandra_truncate_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3519. uint32_t xfer = 0;
  3520. xfer += oprot->writeStructBegin("Cassandra_truncate_result");
  3521. if (this->__isset.ire) {
  3522. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  3523. xfer += this->ire.write(oprot);
  3524. xfer += oprot->writeFieldEnd();
  3525. } else if (this->__isset.ue) {
  3526. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  3527. xfer += this->ue.write(oprot);
  3528. xfer += oprot->writeFieldEnd();
  3529. }
  3530. xfer += oprot->writeFieldStop();
  3531. xfer += oprot->writeStructEnd();
  3532. return xfer;
  3533. }
  3534. uint32_t Cassandra_truncate_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  3535. uint32_t xfer = 0;
  3536. std::string fname;
  3537. ::apache::thrift::protocol::TType ftype;
  3538. int16_t fid;
  3539. xfer += iprot->readStructBegin(fname);
  3540. using ::apache::thrift::protocol::TProtocolException;
  3541. while (true)
  3542. {
  3543. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3544. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3545. break;
  3546. }
  3547. switch (fid)
  3548. {
  3549. case 1:
  3550. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3551. xfer += this->ire.read(iprot);
  3552. this->__isset.ire = true;
  3553. } else {
  3554. xfer += iprot->skip(ftype);
  3555. }
  3556. break;
  3557. case 2:
  3558. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3559. xfer += this->ue.read(iprot);
  3560. this->__isset.ue = true;
  3561. } else {
  3562. xfer += iprot->skip(ftype);
  3563. }
  3564. break;
  3565. default:
  3566. xfer += iprot->skip(ftype);
  3567. break;
  3568. }
  3569. xfer += iprot->readFieldEnd();
  3570. }
  3571. xfer += iprot->readStructEnd();
  3572. return xfer;
  3573. }
  3574. uint32_t Cassandra_describe_schema_versions_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  3575. uint32_t xfer = 0;
  3576. std::string fname;
  3577. ::apache::thrift::protocol::TType ftype;
  3578. int16_t fid;
  3579. xfer += iprot->readStructBegin(fname);
  3580. using ::apache::thrift::protocol::TProtocolException;
  3581. while (true)
  3582. {
  3583. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3584. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3585. break;
  3586. }
  3587. switch (fid)
  3588. {
  3589. default:
  3590. xfer += iprot->skip(ftype);
  3591. break;
  3592. }
  3593. xfer += iprot->readFieldEnd();
  3594. }
  3595. xfer += iprot->readStructEnd();
  3596. return xfer;
  3597. }
  3598. uint32_t Cassandra_describe_schema_versions_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3599. uint32_t xfer = 0;
  3600. xfer += oprot->writeStructBegin("Cassandra_describe_schema_versions_args");
  3601. xfer += oprot->writeFieldStop();
  3602. xfer += oprot->writeStructEnd();
  3603. return xfer;
  3604. }
  3605. uint32_t Cassandra_describe_schema_versions_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3606. uint32_t xfer = 0;
  3607. xfer += oprot->writeStructBegin("Cassandra_describe_schema_versions_pargs");
  3608. xfer += oprot->writeFieldStop();
  3609. xfer += oprot->writeStructEnd();
  3610. return xfer;
  3611. }
  3612. uint32_t Cassandra_describe_schema_versions_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3613. uint32_t xfer = 0;
  3614. std::string fname;
  3615. ::apache::thrift::protocol::TType ftype;
  3616. int16_t fid;
  3617. xfer += iprot->readStructBegin(fname);
  3618. using ::apache::thrift::protocol::TProtocolException;
  3619. while (true)
  3620. {
  3621. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3622. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3623. break;
  3624. }
  3625. switch (fid)
  3626. {
  3627. case 0:
  3628. if (ftype == ::apache::thrift::protocol::T_MAP) {
  3629. {
  3630. this->success.clear();
  3631. uint32_t _size256;
  3632. ::apache::thrift::protocol::TType _ktype257;
  3633. ::apache::thrift::protocol::TType _vtype258;
  3634. iprot->readMapBegin(_ktype257, _vtype258, _size256);
  3635. uint32_t _i260;
  3636. for (_i260 = 0; _i260 < _size256; ++_i260)
  3637. {
  3638. std::string _key261;
  3639. xfer += iprot->readString(_key261);
  3640. std::vector<std::string> & _val262 = this->success[_key261];
  3641. {
  3642. _val262.clear();
  3643. uint32_t _size263;
  3644. ::apache::thrift::protocol::TType _etype266;
  3645. iprot->readListBegin(_etype266, _size263);
  3646. _val262.resize(_size263);
  3647. uint32_t _i267;
  3648. for (_i267 = 0; _i267 < _size263; ++_i267)
  3649. {
  3650. xfer += iprot->readString(_val262[_i267]);
  3651. }
  3652. iprot->readListEnd();
  3653. }
  3654. }
  3655. iprot->readMapEnd();
  3656. }
  3657. this->__isset.success = true;
  3658. } else {
  3659. xfer += iprot->skip(ftype);
  3660. }
  3661. break;
  3662. case 1:
  3663. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3664. xfer += this->ire.read(iprot);
  3665. this->__isset.ire = true;
  3666. } else {
  3667. xfer += iprot->skip(ftype);
  3668. }
  3669. break;
  3670. default:
  3671. xfer += iprot->skip(ftype);
  3672. break;
  3673. }
  3674. xfer += iprot->readFieldEnd();
  3675. }
  3676. xfer += iprot->readStructEnd();
  3677. return xfer;
  3678. }
  3679. uint32_t Cassandra_describe_schema_versions_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3680. uint32_t xfer = 0;
  3681. xfer += oprot->writeStructBegin("Cassandra_describe_schema_versions_result");
  3682. if (this->__isset.success) {
  3683. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_MAP, 0);
  3684. {
  3685. xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_LIST, static_cast<uint32_t>(this->success.size()));
  3686. std::map<std::string, std::vector<std::string> > ::const_iterator _iter268;
  3687. for (_iter268 = this->success.begin(); _iter268 != this->success.end(); ++_iter268)
  3688. {
  3689. xfer += oprot->writeString(_iter268->first);
  3690. {
  3691. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>(_iter268->second.size()));
  3692. std::vector<std::string> ::const_iterator _iter269;
  3693. for (_iter269 = _iter268->second.begin(); _iter269 != _iter268->second.end(); ++_iter269)
  3694. {
  3695. xfer += oprot->writeString((*_iter269));
  3696. }
  3697. xfer += oprot->writeListEnd();
  3698. }
  3699. }
  3700. xfer += oprot->writeMapEnd();
  3701. }
  3702. xfer += oprot->writeFieldEnd();
  3703. } else if (this->__isset.ire) {
  3704. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  3705. xfer += this->ire.write(oprot);
  3706. xfer += oprot->writeFieldEnd();
  3707. }
  3708. xfer += oprot->writeFieldStop();
  3709. xfer += oprot->writeStructEnd();
  3710. return xfer;
  3711. }
  3712. uint32_t Cassandra_describe_schema_versions_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  3713. uint32_t xfer = 0;
  3714. std::string fname;
  3715. ::apache::thrift::protocol::TType ftype;
  3716. int16_t fid;
  3717. xfer += iprot->readStructBegin(fname);
  3718. using ::apache::thrift::protocol::TProtocolException;
  3719. while (true)
  3720. {
  3721. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3722. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3723. break;
  3724. }
  3725. switch (fid)
  3726. {
  3727. case 0:
  3728. if (ftype == ::apache::thrift::protocol::T_MAP) {
  3729. {
  3730. (*(this->success)).clear();
  3731. uint32_t _size270;
  3732. ::apache::thrift::protocol::TType _ktype271;
  3733. ::apache::thrift::protocol::TType _vtype272;
  3734. iprot->readMapBegin(_ktype271, _vtype272, _size270);
  3735. uint32_t _i274;
  3736. for (_i274 = 0; _i274 < _size270; ++_i274)
  3737. {
  3738. std::string _key275;
  3739. xfer += iprot->readString(_key275);
  3740. std::vector<std::string> & _val276 = (*(this->success))[_key275];
  3741. {
  3742. _val276.clear();
  3743. uint32_t _size277;
  3744. ::apache::thrift::protocol::TType _etype280;
  3745. iprot->readListBegin(_etype280, _size277);
  3746. _val276.resize(_size277);
  3747. uint32_t _i281;
  3748. for (_i281 = 0; _i281 < _size277; ++_i281)
  3749. {
  3750. xfer += iprot->readString(_val276[_i281]);
  3751. }
  3752. iprot->readListEnd();
  3753. }
  3754. }
  3755. iprot->readMapEnd();
  3756. }
  3757. this->__isset.success = true;
  3758. } else {
  3759. xfer += iprot->skip(ftype);
  3760. }
  3761. break;
  3762. case 1:
  3763. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3764. xfer += this->ire.read(iprot);
  3765. this->__isset.ire = true;
  3766. } else {
  3767. xfer += iprot->skip(ftype);
  3768. }
  3769. break;
  3770. default:
  3771. xfer += iprot->skip(ftype);
  3772. break;
  3773. }
  3774. xfer += iprot->readFieldEnd();
  3775. }
  3776. xfer += iprot->readStructEnd();
  3777. return xfer;
  3778. }
  3779. uint32_t Cassandra_describe_keyspaces_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  3780. uint32_t xfer = 0;
  3781. std::string fname;
  3782. ::apache::thrift::protocol::TType ftype;
  3783. int16_t fid;
  3784. xfer += iprot->readStructBegin(fname);
  3785. using ::apache::thrift::protocol::TProtocolException;
  3786. while (true)
  3787. {
  3788. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3789. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3790. break;
  3791. }
  3792. switch (fid)
  3793. {
  3794. default:
  3795. xfer += iprot->skip(ftype);
  3796. break;
  3797. }
  3798. xfer += iprot->readFieldEnd();
  3799. }
  3800. xfer += iprot->readStructEnd();
  3801. return xfer;
  3802. }
  3803. uint32_t Cassandra_describe_keyspaces_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3804. uint32_t xfer = 0;
  3805. xfer += oprot->writeStructBegin("Cassandra_describe_keyspaces_args");
  3806. xfer += oprot->writeFieldStop();
  3807. xfer += oprot->writeStructEnd();
  3808. return xfer;
  3809. }
  3810. uint32_t Cassandra_describe_keyspaces_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3811. uint32_t xfer = 0;
  3812. xfer += oprot->writeStructBegin("Cassandra_describe_keyspaces_pargs");
  3813. xfer += oprot->writeFieldStop();
  3814. xfer += oprot->writeStructEnd();
  3815. return xfer;
  3816. }
  3817. uint32_t Cassandra_describe_keyspaces_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3818. uint32_t xfer = 0;
  3819. std::string fname;
  3820. ::apache::thrift::protocol::TType ftype;
  3821. int16_t fid;
  3822. xfer += iprot->readStructBegin(fname);
  3823. using ::apache::thrift::protocol::TProtocolException;
  3824. while (true)
  3825. {
  3826. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3827. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3828. break;
  3829. }
  3830. switch (fid)
  3831. {
  3832. case 0:
  3833. if (ftype == ::apache::thrift::protocol::T_LIST) {
  3834. {
  3835. this->success.clear();
  3836. uint32_t _size282;
  3837. ::apache::thrift::protocol::TType _etype285;
  3838. iprot->readListBegin(_etype285, _size282);
  3839. this->success.resize(_size282);
  3840. uint32_t _i286;
  3841. for (_i286 = 0; _i286 < _size282; ++_i286)
  3842. {
  3843. xfer += this->success[_i286].read(iprot);
  3844. }
  3845. iprot->readListEnd();
  3846. }
  3847. this->__isset.success = true;
  3848. } else {
  3849. xfer += iprot->skip(ftype);
  3850. }
  3851. break;
  3852. case 1:
  3853. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3854. xfer += this->ire.read(iprot);
  3855. this->__isset.ire = true;
  3856. } else {
  3857. xfer += iprot->skip(ftype);
  3858. }
  3859. break;
  3860. default:
  3861. xfer += iprot->skip(ftype);
  3862. break;
  3863. }
  3864. xfer += iprot->readFieldEnd();
  3865. }
  3866. xfer += iprot->readStructEnd();
  3867. return xfer;
  3868. }
  3869. uint32_t Cassandra_describe_keyspaces_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3870. uint32_t xfer = 0;
  3871. xfer += oprot->writeStructBegin("Cassandra_describe_keyspaces_result");
  3872. if (this->__isset.success) {
  3873. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  3874. {
  3875. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(this->success.size()));
  3876. std::vector<KsDef> ::const_iterator _iter287;
  3877. for (_iter287 = this->success.begin(); _iter287 != this->success.end(); ++_iter287)
  3878. {
  3879. xfer += (*_iter287).write(oprot);
  3880. }
  3881. xfer += oprot->writeListEnd();
  3882. }
  3883. xfer += oprot->writeFieldEnd();
  3884. } else if (this->__isset.ire) {
  3885. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  3886. xfer += this->ire.write(oprot);
  3887. xfer += oprot->writeFieldEnd();
  3888. }
  3889. xfer += oprot->writeFieldStop();
  3890. xfer += oprot->writeStructEnd();
  3891. return xfer;
  3892. }
  3893. uint32_t Cassandra_describe_keyspaces_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  3894. uint32_t xfer = 0;
  3895. std::string fname;
  3896. ::apache::thrift::protocol::TType ftype;
  3897. int16_t fid;
  3898. xfer += iprot->readStructBegin(fname);
  3899. using ::apache::thrift::protocol::TProtocolException;
  3900. while (true)
  3901. {
  3902. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3903. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3904. break;
  3905. }
  3906. switch (fid)
  3907. {
  3908. case 0:
  3909. if (ftype == ::apache::thrift::protocol::T_LIST) {
  3910. {
  3911. (*(this->success)).clear();
  3912. uint32_t _size288;
  3913. ::apache::thrift::protocol::TType _etype291;
  3914. iprot->readListBegin(_etype291, _size288);
  3915. (*(this->success)).resize(_size288);
  3916. uint32_t _i292;
  3917. for (_i292 = 0; _i292 < _size288; ++_i292)
  3918. {
  3919. xfer += (*(this->success))[_i292].read(iprot);
  3920. }
  3921. iprot->readListEnd();
  3922. }
  3923. this->__isset.success = true;
  3924. } else {
  3925. xfer += iprot->skip(ftype);
  3926. }
  3927. break;
  3928. case 1:
  3929. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  3930. xfer += this->ire.read(iprot);
  3931. this->__isset.ire = true;
  3932. } else {
  3933. xfer += iprot->skip(ftype);
  3934. }
  3935. break;
  3936. default:
  3937. xfer += iprot->skip(ftype);
  3938. break;
  3939. }
  3940. xfer += iprot->readFieldEnd();
  3941. }
  3942. xfer += iprot->readStructEnd();
  3943. return xfer;
  3944. }
  3945. uint32_t Cassandra_describe_cluster_name_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  3946. uint32_t xfer = 0;
  3947. std::string fname;
  3948. ::apache::thrift::protocol::TType ftype;
  3949. int16_t fid;
  3950. xfer += iprot->readStructBegin(fname);
  3951. using ::apache::thrift::protocol::TProtocolException;
  3952. while (true)
  3953. {
  3954. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3955. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3956. break;
  3957. }
  3958. switch (fid)
  3959. {
  3960. default:
  3961. xfer += iprot->skip(ftype);
  3962. break;
  3963. }
  3964. xfer += iprot->readFieldEnd();
  3965. }
  3966. xfer += iprot->readStructEnd();
  3967. return xfer;
  3968. }
  3969. uint32_t Cassandra_describe_cluster_name_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3970. uint32_t xfer = 0;
  3971. xfer += oprot->writeStructBegin("Cassandra_describe_cluster_name_args");
  3972. xfer += oprot->writeFieldStop();
  3973. xfer += oprot->writeStructEnd();
  3974. return xfer;
  3975. }
  3976. uint32_t Cassandra_describe_cluster_name_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  3977. uint32_t xfer = 0;
  3978. xfer += oprot->writeStructBegin("Cassandra_describe_cluster_name_pargs");
  3979. xfer += oprot->writeFieldStop();
  3980. xfer += oprot->writeStructEnd();
  3981. return xfer;
  3982. }
  3983. uint32_t Cassandra_describe_cluster_name_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  3984. uint32_t xfer = 0;
  3985. std::string fname;
  3986. ::apache::thrift::protocol::TType ftype;
  3987. int16_t fid;
  3988. xfer += iprot->readStructBegin(fname);
  3989. using ::apache::thrift::protocol::TProtocolException;
  3990. while (true)
  3991. {
  3992. xfer += iprot->readFieldBegin(fname, ftype, fid);
  3993. if (ftype == ::apache::thrift::protocol::T_STOP) {
  3994. break;
  3995. }
  3996. switch (fid)
  3997. {
  3998. case 0:
  3999. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4000. xfer += iprot->readString(this->success);
  4001. this->__isset.success = true;
  4002. } else {
  4003. xfer += iprot->skip(ftype);
  4004. }
  4005. break;
  4006. default:
  4007. xfer += iprot->skip(ftype);
  4008. break;
  4009. }
  4010. xfer += iprot->readFieldEnd();
  4011. }
  4012. xfer += iprot->readStructEnd();
  4013. return xfer;
  4014. }
  4015. uint32_t Cassandra_describe_cluster_name_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4016. uint32_t xfer = 0;
  4017. xfer += oprot->writeStructBegin("Cassandra_describe_cluster_name_result");
  4018. if (this->__isset.success) {
  4019. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  4020. xfer += oprot->writeString(this->success);
  4021. xfer += oprot->writeFieldEnd();
  4022. }
  4023. xfer += oprot->writeFieldStop();
  4024. xfer += oprot->writeStructEnd();
  4025. return xfer;
  4026. }
  4027. uint32_t Cassandra_describe_cluster_name_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4028. uint32_t xfer = 0;
  4029. std::string fname;
  4030. ::apache::thrift::protocol::TType ftype;
  4031. int16_t fid;
  4032. xfer += iprot->readStructBegin(fname);
  4033. using ::apache::thrift::protocol::TProtocolException;
  4034. while (true)
  4035. {
  4036. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4037. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4038. break;
  4039. }
  4040. switch (fid)
  4041. {
  4042. case 0:
  4043. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4044. xfer += iprot->readString((*(this->success)));
  4045. this->__isset.success = true;
  4046. } else {
  4047. xfer += iprot->skip(ftype);
  4048. }
  4049. break;
  4050. default:
  4051. xfer += iprot->skip(ftype);
  4052. break;
  4053. }
  4054. xfer += iprot->readFieldEnd();
  4055. }
  4056. xfer += iprot->readStructEnd();
  4057. return xfer;
  4058. }
  4059. uint32_t Cassandra_describe_version_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4060. uint32_t xfer = 0;
  4061. std::string fname;
  4062. ::apache::thrift::protocol::TType ftype;
  4063. int16_t fid;
  4064. xfer += iprot->readStructBegin(fname);
  4065. using ::apache::thrift::protocol::TProtocolException;
  4066. while (true)
  4067. {
  4068. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4069. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4070. break;
  4071. }
  4072. switch (fid)
  4073. {
  4074. default:
  4075. xfer += iprot->skip(ftype);
  4076. break;
  4077. }
  4078. xfer += iprot->readFieldEnd();
  4079. }
  4080. xfer += iprot->readStructEnd();
  4081. return xfer;
  4082. }
  4083. uint32_t Cassandra_describe_version_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4084. uint32_t xfer = 0;
  4085. xfer += oprot->writeStructBegin("Cassandra_describe_version_args");
  4086. xfer += oprot->writeFieldStop();
  4087. xfer += oprot->writeStructEnd();
  4088. return xfer;
  4089. }
  4090. uint32_t Cassandra_describe_version_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4091. uint32_t xfer = 0;
  4092. xfer += oprot->writeStructBegin("Cassandra_describe_version_pargs");
  4093. xfer += oprot->writeFieldStop();
  4094. xfer += oprot->writeStructEnd();
  4095. return xfer;
  4096. }
  4097. uint32_t Cassandra_describe_version_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4098. uint32_t xfer = 0;
  4099. std::string fname;
  4100. ::apache::thrift::protocol::TType ftype;
  4101. int16_t fid;
  4102. xfer += iprot->readStructBegin(fname);
  4103. using ::apache::thrift::protocol::TProtocolException;
  4104. while (true)
  4105. {
  4106. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4107. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4108. break;
  4109. }
  4110. switch (fid)
  4111. {
  4112. case 0:
  4113. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4114. xfer += iprot->readString(this->success);
  4115. this->__isset.success = true;
  4116. } else {
  4117. xfer += iprot->skip(ftype);
  4118. }
  4119. break;
  4120. default:
  4121. xfer += iprot->skip(ftype);
  4122. break;
  4123. }
  4124. xfer += iprot->readFieldEnd();
  4125. }
  4126. xfer += iprot->readStructEnd();
  4127. return xfer;
  4128. }
  4129. uint32_t Cassandra_describe_version_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4130. uint32_t xfer = 0;
  4131. xfer += oprot->writeStructBegin("Cassandra_describe_version_result");
  4132. if (this->__isset.success) {
  4133. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  4134. xfer += oprot->writeString(this->success);
  4135. xfer += oprot->writeFieldEnd();
  4136. }
  4137. xfer += oprot->writeFieldStop();
  4138. xfer += oprot->writeStructEnd();
  4139. return xfer;
  4140. }
  4141. uint32_t Cassandra_describe_version_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4142. uint32_t xfer = 0;
  4143. std::string fname;
  4144. ::apache::thrift::protocol::TType ftype;
  4145. int16_t fid;
  4146. xfer += iprot->readStructBegin(fname);
  4147. using ::apache::thrift::protocol::TProtocolException;
  4148. while (true)
  4149. {
  4150. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4151. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4152. break;
  4153. }
  4154. switch (fid)
  4155. {
  4156. case 0:
  4157. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4158. xfer += iprot->readString((*(this->success)));
  4159. this->__isset.success = true;
  4160. } else {
  4161. xfer += iprot->skip(ftype);
  4162. }
  4163. break;
  4164. default:
  4165. xfer += iprot->skip(ftype);
  4166. break;
  4167. }
  4168. xfer += iprot->readFieldEnd();
  4169. }
  4170. xfer += iprot->readStructEnd();
  4171. return xfer;
  4172. }
  4173. uint32_t Cassandra_describe_ring_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4174. uint32_t xfer = 0;
  4175. std::string fname;
  4176. ::apache::thrift::protocol::TType ftype;
  4177. int16_t fid;
  4178. xfer += iprot->readStructBegin(fname);
  4179. using ::apache::thrift::protocol::TProtocolException;
  4180. bool isset_keyspace = false;
  4181. while (true)
  4182. {
  4183. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4184. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4185. break;
  4186. }
  4187. switch (fid)
  4188. {
  4189. case 1:
  4190. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4191. xfer += iprot->readString(this->keyspace);
  4192. isset_keyspace = true;
  4193. } else {
  4194. xfer += iprot->skip(ftype);
  4195. }
  4196. break;
  4197. default:
  4198. xfer += iprot->skip(ftype);
  4199. break;
  4200. }
  4201. xfer += iprot->readFieldEnd();
  4202. }
  4203. xfer += iprot->readStructEnd();
  4204. if (!isset_keyspace)
  4205. throw TProtocolException(TProtocolException::INVALID_DATA);
  4206. return xfer;
  4207. }
  4208. uint32_t Cassandra_describe_ring_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4209. uint32_t xfer = 0;
  4210. xfer += oprot->writeStructBegin("Cassandra_describe_ring_args");
  4211. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  4212. xfer += oprot->writeString(this->keyspace);
  4213. xfer += oprot->writeFieldEnd();
  4214. xfer += oprot->writeFieldStop();
  4215. xfer += oprot->writeStructEnd();
  4216. return xfer;
  4217. }
  4218. uint32_t Cassandra_describe_ring_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4219. uint32_t xfer = 0;
  4220. xfer += oprot->writeStructBegin("Cassandra_describe_ring_pargs");
  4221. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  4222. xfer += oprot->writeString((*(this->keyspace)));
  4223. xfer += oprot->writeFieldEnd();
  4224. xfer += oprot->writeFieldStop();
  4225. xfer += oprot->writeStructEnd();
  4226. return xfer;
  4227. }
  4228. uint32_t Cassandra_describe_ring_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4229. uint32_t xfer = 0;
  4230. std::string fname;
  4231. ::apache::thrift::protocol::TType ftype;
  4232. int16_t fid;
  4233. xfer += iprot->readStructBegin(fname);
  4234. using ::apache::thrift::protocol::TProtocolException;
  4235. while (true)
  4236. {
  4237. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4238. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4239. break;
  4240. }
  4241. switch (fid)
  4242. {
  4243. case 0:
  4244. if (ftype == ::apache::thrift::protocol::T_LIST) {
  4245. {
  4246. this->success.clear();
  4247. uint32_t _size293;
  4248. ::apache::thrift::protocol::TType _etype296;
  4249. iprot->readListBegin(_etype296, _size293);
  4250. this->success.resize(_size293);
  4251. uint32_t _i297;
  4252. for (_i297 = 0; _i297 < _size293; ++_i297)
  4253. {
  4254. xfer += this->success[_i297].read(iprot);
  4255. }
  4256. iprot->readListEnd();
  4257. }
  4258. this->__isset.success = true;
  4259. } else {
  4260. xfer += iprot->skip(ftype);
  4261. }
  4262. break;
  4263. case 1:
  4264. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4265. xfer += this->ire.read(iprot);
  4266. this->__isset.ire = true;
  4267. } else {
  4268. xfer += iprot->skip(ftype);
  4269. }
  4270. break;
  4271. default:
  4272. xfer += iprot->skip(ftype);
  4273. break;
  4274. }
  4275. xfer += iprot->readFieldEnd();
  4276. }
  4277. xfer += iprot->readStructEnd();
  4278. return xfer;
  4279. }
  4280. uint32_t Cassandra_describe_ring_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4281. uint32_t xfer = 0;
  4282. xfer += oprot->writeStructBegin("Cassandra_describe_ring_result");
  4283. if (this->__isset.success) {
  4284. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  4285. {
  4286. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast<uint32_t>(this->success.size()));
  4287. std::vector<TokenRange> ::const_iterator _iter298;
  4288. for (_iter298 = this->success.begin(); _iter298 != this->success.end(); ++_iter298)
  4289. {
  4290. xfer += (*_iter298).write(oprot);
  4291. }
  4292. xfer += oprot->writeListEnd();
  4293. }
  4294. xfer += oprot->writeFieldEnd();
  4295. } else if (this->__isset.ire) {
  4296. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  4297. xfer += this->ire.write(oprot);
  4298. xfer += oprot->writeFieldEnd();
  4299. }
  4300. xfer += oprot->writeFieldStop();
  4301. xfer += oprot->writeStructEnd();
  4302. return xfer;
  4303. }
  4304. uint32_t Cassandra_describe_ring_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4305. uint32_t xfer = 0;
  4306. std::string fname;
  4307. ::apache::thrift::protocol::TType ftype;
  4308. int16_t fid;
  4309. xfer += iprot->readStructBegin(fname);
  4310. using ::apache::thrift::protocol::TProtocolException;
  4311. while (true)
  4312. {
  4313. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4314. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4315. break;
  4316. }
  4317. switch (fid)
  4318. {
  4319. case 0:
  4320. if (ftype == ::apache::thrift::protocol::T_LIST) {
  4321. {
  4322. (*(this->success)).clear();
  4323. uint32_t _size299;
  4324. ::apache::thrift::protocol::TType _etype302;
  4325. iprot->readListBegin(_etype302, _size299);
  4326. (*(this->success)).resize(_size299);
  4327. uint32_t _i303;
  4328. for (_i303 = 0; _i303 < _size299; ++_i303)
  4329. {
  4330. xfer += (*(this->success))[_i303].read(iprot);
  4331. }
  4332. iprot->readListEnd();
  4333. }
  4334. this->__isset.success = true;
  4335. } else {
  4336. xfer += iprot->skip(ftype);
  4337. }
  4338. break;
  4339. case 1:
  4340. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4341. xfer += this->ire.read(iprot);
  4342. this->__isset.ire = true;
  4343. } else {
  4344. xfer += iprot->skip(ftype);
  4345. }
  4346. break;
  4347. default:
  4348. xfer += iprot->skip(ftype);
  4349. break;
  4350. }
  4351. xfer += iprot->readFieldEnd();
  4352. }
  4353. xfer += iprot->readStructEnd();
  4354. return xfer;
  4355. }
  4356. uint32_t Cassandra_describe_partitioner_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4357. uint32_t xfer = 0;
  4358. std::string fname;
  4359. ::apache::thrift::protocol::TType ftype;
  4360. int16_t fid;
  4361. xfer += iprot->readStructBegin(fname);
  4362. using ::apache::thrift::protocol::TProtocolException;
  4363. while (true)
  4364. {
  4365. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4366. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4367. break;
  4368. }
  4369. switch (fid)
  4370. {
  4371. default:
  4372. xfer += iprot->skip(ftype);
  4373. break;
  4374. }
  4375. xfer += iprot->readFieldEnd();
  4376. }
  4377. xfer += iprot->readStructEnd();
  4378. return xfer;
  4379. }
  4380. uint32_t Cassandra_describe_partitioner_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4381. uint32_t xfer = 0;
  4382. xfer += oprot->writeStructBegin("Cassandra_describe_partitioner_args");
  4383. xfer += oprot->writeFieldStop();
  4384. xfer += oprot->writeStructEnd();
  4385. return xfer;
  4386. }
  4387. uint32_t Cassandra_describe_partitioner_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4388. uint32_t xfer = 0;
  4389. xfer += oprot->writeStructBegin("Cassandra_describe_partitioner_pargs");
  4390. xfer += oprot->writeFieldStop();
  4391. xfer += oprot->writeStructEnd();
  4392. return xfer;
  4393. }
  4394. uint32_t Cassandra_describe_partitioner_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4395. uint32_t xfer = 0;
  4396. std::string fname;
  4397. ::apache::thrift::protocol::TType ftype;
  4398. int16_t fid;
  4399. xfer += iprot->readStructBegin(fname);
  4400. using ::apache::thrift::protocol::TProtocolException;
  4401. while (true)
  4402. {
  4403. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4404. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4405. break;
  4406. }
  4407. switch (fid)
  4408. {
  4409. case 0:
  4410. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4411. xfer += iprot->readString(this->success);
  4412. this->__isset.success = true;
  4413. } else {
  4414. xfer += iprot->skip(ftype);
  4415. }
  4416. break;
  4417. default:
  4418. xfer += iprot->skip(ftype);
  4419. break;
  4420. }
  4421. xfer += iprot->readFieldEnd();
  4422. }
  4423. xfer += iprot->readStructEnd();
  4424. return xfer;
  4425. }
  4426. uint32_t Cassandra_describe_partitioner_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4427. uint32_t xfer = 0;
  4428. xfer += oprot->writeStructBegin("Cassandra_describe_partitioner_result");
  4429. if (this->__isset.success) {
  4430. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  4431. xfer += oprot->writeString(this->success);
  4432. xfer += oprot->writeFieldEnd();
  4433. }
  4434. xfer += oprot->writeFieldStop();
  4435. xfer += oprot->writeStructEnd();
  4436. return xfer;
  4437. }
  4438. uint32_t Cassandra_describe_partitioner_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4439. uint32_t xfer = 0;
  4440. std::string fname;
  4441. ::apache::thrift::protocol::TType ftype;
  4442. int16_t fid;
  4443. xfer += iprot->readStructBegin(fname);
  4444. using ::apache::thrift::protocol::TProtocolException;
  4445. while (true)
  4446. {
  4447. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4448. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4449. break;
  4450. }
  4451. switch (fid)
  4452. {
  4453. case 0:
  4454. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4455. xfer += iprot->readString((*(this->success)));
  4456. this->__isset.success = true;
  4457. } else {
  4458. xfer += iprot->skip(ftype);
  4459. }
  4460. break;
  4461. default:
  4462. xfer += iprot->skip(ftype);
  4463. break;
  4464. }
  4465. xfer += iprot->readFieldEnd();
  4466. }
  4467. xfer += iprot->readStructEnd();
  4468. return xfer;
  4469. }
  4470. uint32_t Cassandra_describe_snitch_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4471. uint32_t xfer = 0;
  4472. std::string fname;
  4473. ::apache::thrift::protocol::TType ftype;
  4474. int16_t fid;
  4475. xfer += iprot->readStructBegin(fname);
  4476. using ::apache::thrift::protocol::TProtocolException;
  4477. while (true)
  4478. {
  4479. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4480. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4481. break;
  4482. }
  4483. switch (fid)
  4484. {
  4485. default:
  4486. xfer += iprot->skip(ftype);
  4487. break;
  4488. }
  4489. xfer += iprot->readFieldEnd();
  4490. }
  4491. xfer += iprot->readStructEnd();
  4492. return xfer;
  4493. }
  4494. uint32_t Cassandra_describe_snitch_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4495. uint32_t xfer = 0;
  4496. xfer += oprot->writeStructBegin("Cassandra_describe_snitch_args");
  4497. xfer += oprot->writeFieldStop();
  4498. xfer += oprot->writeStructEnd();
  4499. return xfer;
  4500. }
  4501. uint32_t Cassandra_describe_snitch_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4502. uint32_t xfer = 0;
  4503. xfer += oprot->writeStructBegin("Cassandra_describe_snitch_pargs");
  4504. xfer += oprot->writeFieldStop();
  4505. xfer += oprot->writeStructEnd();
  4506. return xfer;
  4507. }
  4508. uint32_t Cassandra_describe_snitch_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4509. uint32_t xfer = 0;
  4510. std::string fname;
  4511. ::apache::thrift::protocol::TType ftype;
  4512. int16_t fid;
  4513. xfer += iprot->readStructBegin(fname);
  4514. using ::apache::thrift::protocol::TProtocolException;
  4515. while (true)
  4516. {
  4517. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4518. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4519. break;
  4520. }
  4521. switch (fid)
  4522. {
  4523. case 0:
  4524. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4525. xfer += iprot->readString(this->success);
  4526. this->__isset.success = true;
  4527. } else {
  4528. xfer += iprot->skip(ftype);
  4529. }
  4530. break;
  4531. default:
  4532. xfer += iprot->skip(ftype);
  4533. break;
  4534. }
  4535. xfer += iprot->readFieldEnd();
  4536. }
  4537. xfer += iprot->readStructEnd();
  4538. return xfer;
  4539. }
  4540. uint32_t Cassandra_describe_snitch_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4541. uint32_t xfer = 0;
  4542. xfer += oprot->writeStructBegin("Cassandra_describe_snitch_result");
  4543. if (this->__isset.success) {
  4544. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  4545. xfer += oprot->writeString(this->success);
  4546. xfer += oprot->writeFieldEnd();
  4547. }
  4548. xfer += oprot->writeFieldStop();
  4549. xfer += oprot->writeStructEnd();
  4550. return xfer;
  4551. }
  4552. uint32_t Cassandra_describe_snitch_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4553. uint32_t xfer = 0;
  4554. std::string fname;
  4555. ::apache::thrift::protocol::TType ftype;
  4556. int16_t fid;
  4557. xfer += iprot->readStructBegin(fname);
  4558. using ::apache::thrift::protocol::TProtocolException;
  4559. while (true)
  4560. {
  4561. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4562. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4563. break;
  4564. }
  4565. switch (fid)
  4566. {
  4567. case 0:
  4568. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4569. xfer += iprot->readString((*(this->success)));
  4570. this->__isset.success = true;
  4571. } else {
  4572. xfer += iprot->skip(ftype);
  4573. }
  4574. break;
  4575. default:
  4576. xfer += iprot->skip(ftype);
  4577. break;
  4578. }
  4579. xfer += iprot->readFieldEnd();
  4580. }
  4581. xfer += iprot->readStructEnd();
  4582. return xfer;
  4583. }
  4584. uint32_t Cassandra_describe_keyspace_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4585. uint32_t xfer = 0;
  4586. std::string fname;
  4587. ::apache::thrift::protocol::TType ftype;
  4588. int16_t fid;
  4589. xfer += iprot->readStructBegin(fname);
  4590. using ::apache::thrift::protocol::TProtocolException;
  4591. bool isset_keyspace = false;
  4592. while (true)
  4593. {
  4594. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4595. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4596. break;
  4597. }
  4598. switch (fid)
  4599. {
  4600. case 1:
  4601. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4602. xfer += iprot->readString(this->keyspace);
  4603. isset_keyspace = true;
  4604. } else {
  4605. xfer += iprot->skip(ftype);
  4606. }
  4607. break;
  4608. default:
  4609. xfer += iprot->skip(ftype);
  4610. break;
  4611. }
  4612. xfer += iprot->readFieldEnd();
  4613. }
  4614. xfer += iprot->readStructEnd();
  4615. if (!isset_keyspace)
  4616. throw TProtocolException(TProtocolException::INVALID_DATA);
  4617. return xfer;
  4618. }
  4619. uint32_t Cassandra_describe_keyspace_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4620. uint32_t xfer = 0;
  4621. xfer += oprot->writeStructBegin("Cassandra_describe_keyspace_args");
  4622. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  4623. xfer += oprot->writeString(this->keyspace);
  4624. xfer += oprot->writeFieldEnd();
  4625. xfer += oprot->writeFieldStop();
  4626. xfer += oprot->writeStructEnd();
  4627. return xfer;
  4628. }
  4629. uint32_t Cassandra_describe_keyspace_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4630. uint32_t xfer = 0;
  4631. xfer += oprot->writeStructBegin("Cassandra_describe_keyspace_pargs");
  4632. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  4633. xfer += oprot->writeString((*(this->keyspace)));
  4634. xfer += oprot->writeFieldEnd();
  4635. xfer += oprot->writeFieldStop();
  4636. xfer += oprot->writeStructEnd();
  4637. return xfer;
  4638. }
  4639. uint32_t Cassandra_describe_keyspace_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4640. uint32_t xfer = 0;
  4641. std::string fname;
  4642. ::apache::thrift::protocol::TType ftype;
  4643. int16_t fid;
  4644. xfer += iprot->readStructBegin(fname);
  4645. using ::apache::thrift::protocol::TProtocolException;
  4646. while (true)
  4647. {
  4648. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4649. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4650. break;
  4651. }
  4652. switch (fid)
  4653. {
  4654. case 0:
  4655. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4656. xfer += this->success.read(iprot);
  4657. this->__isset.success = true;
  4658. } else {
  4659. xfer += iprot->skip(ftype);
  4660. }
  4661. break;
  4662. case 1:
  4663. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4664. xfer += this->nfe.read(iprot);
  4665. this->__isset.nfe = true;
  4666. } else {
  4667. xfer += iprot->skip(ftype);
  4668. }
  4669. break;
  4670. case 2:
  4671. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4672. xfer += this->ire.read(iprot);
  4673. this->__isset.ire = true;
  4674. } else {
  4675. xfer += iprot->skip(ftype);
  4676. }
  4677. break;
  4678. default:
  4679. xfer += iprot->skip(ftype);
  4680. break;
  4681. }
  4682. xfer += iprot->readFieldEnd();
  4683. }
  4684. xfer += iprot->readStructEnd();
  4685. return xfer;
  4686. }
  4687. uint32_t Cassandra_describe_keyspace_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4688. uint32_t xfer = 0;
  4689. xfer += oprot->writeStructBegin("Cassandra_describe_keyspace_result");
  4690. if (this->__isset.success) {
  4691. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRUCT, 0);
  4692. xfer += this->success.write(oprot);
  4693. xfer += oprot->writeFieldEnd();
  4694. } else if (this->__isset.nfe) {
  4695. xfer += oprot->writeFieldBegin("nfe", ::apache::thrift::protocol::T_STRUCT, 1);
  4696. xfer += this->nfe.write(oprot);
  4697. xfer += oprot->writeFieldEnd();
  4698. } else if (this->__isset.ire) {
  4699. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 2);
  4700. xfer += this->ire.write(oprot);
  4701. xfer += oprot->writeFieldEnd();
  4702. }
  4703. xfer += oprot->writeFieldStop();
  4704. xfer += oprot->writeStructEnd();
  4705. return xfer;
  4706. }
  4707. uint32_t Cassandra_describe_keyspace_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4708. uint32_t xfer = 0;
  4709. std::string fname;
  4710. ::apache::thrift::protocol::TType ftype;
  4711. int16_t fid;
  4712. xfer += iprot->readStructBegin(fname);
  4713. using ::apache::thrift::protocol::TProtocolException;
  4714. while (true)
  4715. {
  4716. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4717. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4718. break;
  4719. }
  4720. switch (fid)
  4721. {
  4722. case 0:
  4723. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4724. xfer += (*(this->success)).read(iprot);
  4725. this->__isset.success = true;
  4726. } else {
  4727. xfer += iprot->skip(ftype);
  4728. }
  4729. break;
  4730. case 1:
  4731. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4732. xfer += this->nfe.read(iprot);
  4733. this->__isset.nfe = true;
  4734. } else {
  4735. xfer += iprot->skip(ftype);
  4736. }
  4737. break;
  4738. case 2:
  4739. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4740. xfer += this->ire.read(iprot);
  4741. this->__isset.ire = true;
  4742. } else {
  4743. xfer += iprot->skip(ftype);
  4744. }
  4745. break;
  4746. default:
  4747. xfer += iprot->skip(ftype);
  4748. break;
  4749. }
  4750. xfer += iprot->readFieldEnd();
  4751. }
  4752. xfer += iprot->readStructEnd();
  4753. return xfer;
  4754. }
  4755. uint32_t Cassandra_describe_splits_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4756. uint32_t xfer = 0;
  4757. std::string fname;
  4758. ::apache::thrift::protocol::TType ftype;
  4759. int16_t fid;
  4760. xfer += iprot->readStructBegin(fname);
  4761. using ::apache::thrift::protocol::TProtocolException;
  4762. bool isset_cfName = false;
  4763. bool isset_start_token = false;
  4764. bool isset_end_token = false;
  4765. bool isset_keys_per_split = false;
  4766. while (true)
  4767. {
  4768. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4769. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4770. break;
  4771. }
  4772. switch (fid)
  4773. {
  4774. case 1:
  4775. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4776. xfer += iprot->readString(this->cfName);
  4777. isset_cfName = true;
  4778. } else {
  4779. xfer += iprot->skip(ftype);
  4780. }
  4781. break;
  4782. case 2:
  4783. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4784. xfer += iprot->readString(this->start_token);
  4785. isset_start_token = true;
  4786. } else {
  4787. xfer += iprot->skip(ftype);
  4788. }
  4789. break;
  4790. case 3:
  4791. if (ftype == ::apache::thrift::protocol::T_STRING) {
  4792. xfer += iprot->readString(this->end_token);
  4793. isset_end_token = true;
  4794. } else {
  4795. xfer += iprot->skip(ftype);
  4796. }
  4797. break;
  4798. case 4:
  4799. if (ftype == ::apache::thrift::protocol::T_I32) {
  4800. xfer += iprot->readI32(this->keys_per_split);
  4801. isset_keys_per_split = true;
  4802. } else {
  4803. xfer += iprot->skip(ftype);
  4804. }
  4805. break;
  4806. default:
  4807. xfer += iprot->skip(ftype);
  4808. break;
  4809. }
  4810. xfer += iprot->readFieldEnd();
  4811. }
  4812. xfer += iprot->readStructEnd();
  4813. if (!isset_cfName)
  4814. throw TProtocolException(TProtocolException::INVALID_DATA);
  4815. if (!isset_start_token)
  4816. throw TProtocolException(TProtocolException::INVALID_DATA);
  4817. if (!isset_end_token)
  4818. throw TProtocolException(TProtocolException::INVALID_DATA);
  4819. if (!isset_keys_per_split)
  4820. throw TProtocolException(TProtocolException::INVALID_DATA);
  4821. return xfer;
  4822. }
  4823. uint32_t Cassandra_describe_splits_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4824. uint32_t xfer = 0;
  4825. xfer += oprot->writeStructBegin("Cassandra_describe_splits_args");
  4826. xfer += oprot->writeFieldBegin("cfName", ::apache::thrift::protocol::T_STRING, 1);
  4827. xfer += oprot->writeString(this->cfName);
  4828. xfer += oprot->writeFieldEnd();
  4829. xfer += oprot->writeFieldBegin("start_token", ::apache::thrift::protocol::T_STRING, 2);
  4830. xfer += oprot->writeString(this->start_token);
  4831. xfer += oprot->writeFieldEnd();
  4832. xfer += oprot->writeFieldBegin("end_token", ::apache::thrift::protocol::T_STRING, 3);
  4833. xfer += oprot->writeString(this->end_token);
  4834. xfer += oprot->writeFieldEnd();
  4835. xfer += oprot->writeFieldBegin("keys_per_split", ::apache::thrift::protocol::T_I32, 4);
  4836. xfer += oprot->writeI32(this->keys_per_split);
  4837. xfer += oprot->writeFieldEnd();
  4838. xfer += oprot->writeFieldStop();
  4839. xfer += oprot->writeStructEnd();
  4840. return xfer;
  4841. }
  4842. uint32_t Cassandra_describe_splits_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4843. uint32_t xfer = 0;
  4844. xfer += oprot->writeStructBegin("Cassandra_describe_splits_pargs");
  4845. xfer += oprot->writeFieldBegin("cfName", ::apache::thrift::protocol::T_STRING, 1);
  4846. xfer += oprot->writeString((*(this->cfName)));
  4847. xfer += oprot->writeFieldEnd();
  4848. xfer += oprot->writeFieldBegin("start_token", ::apache::thrift::protocol::T_STRING, 2);
  4849. xfer += oprot->writeString((*(this->start_token)));
  4850. xfer += oprot->writeFieldEnd();
  4851. xfer += oprot->writeFieldBegin("end_token", ::apache::thrift::protocol::T_STRING, 3);
  4852. xfer += oprot->writeString((*(this->end_token)));
  4853. xfer += oprot->writeFieldEnd();
  4854. xfer += oprot->writeFieldBegin("keys_per_split", ::apache::thrift::protocol::T_I32, 4);
  4855. xfer += oprot->writeI32((*(this->keys_per_split)));
  4856. xfer += oprot->writeFieldEnd();
  4857. xfer += oprot->writeFieldStop();
  4858. xfer += oprot->writeStructEnd();
  4859. return xfer;
  4860. }
  4861. uint32_t Cassandra_describe_splits_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  4862. uint32_t xfer = 0;
  4863. std::string fname;
  4864. ::apache::thrift::protocol::TType ftype;
  4865. int16_t fid;
  4866. xfer += iprot->readStructBegin(fname);
  4867. using ::apache::thrift::protocol::TProtocolException;
  4868. while (true)
  4869. {
  4870. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4871. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4872. break;
  4873. }
  4874. switch (fid)
  4875. {
  4876. case 0:
  4877. if (ftype == ::apache::thrift::protocol::T_LIST) {
  4878. {
  4879. this->success.clear();
  4880. uint32_t _size304;
  4881. ::apache::thrift::protocol::TType _etype307;
  4882. iprot->readListBegin(_etype307, _size304);
  4883. this->success.resize(_size304);
  4884. uint32_t _i308;
  4885. for (_i308 = 0; _i308 < _size304; ++_i308)
  4886. {
  4887. xfer += iprot->readString(this->success[_i308]);
  4888. }
  4889. iprot->readListEnd();
  4890. }
  4891. this->__isset.success = true;
  4892. } else {
  4893. xfer += iprot->skip(ftype);
  4894. }
  4895. break;
  4896. case 1:
  4897. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4898. xfer += this->ire.read(iprot);
  4899. this->__isset.ire = true;
  4900. } else {
  4901. xfer += iprot->skip(ftype);
  4902. }
  4903. break;
  4904. default:
  4905. xfer += iprot->skip(ftype);
  4906. break;
  4907. }
  4908. xfer += iprot->readFieldEnd();
  4909. }
  4910. xfer += iprot->readStructEnd();
  4911. return xfer;
  4912. }
  4913. uint32_t Cassandra_describe_splits_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  4914. uint32_t xfer = 0;
  4915. xfer += oprot->writeStructBegin("Cassandra_describe_splits_result");
  4916. if (this->__isset.success) {
  4917. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0);
  4918. {
  4919. xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast<uint32_t>(this->success.size()));
  4920. std::vector<std::string> ::const_iterator _iter309;
  4921. for (_iter309 = this->success.begin(); _iter309 != this->success.end(); ++_iter309)
  4922. {
  4923. xfer += oprot->writeString((*_iter309));
  4924. }
  4925. xfer += oprot->writeListEnd();
  4926. }
  4927. xfer += oprot->writeFieldEnd();
  4928. } else if (this->__isset.ire) {
  4929. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  4930. xfer += this->ire.write(oprot);
  4931. xfer += oprot->writeFieldEnd();
  4932. }
  4933. xfer += oprot->writeFieldStop();
  4934. xfer += oprot->writeStructEnd();
  4935. return xfer;
  4936. }
  4937. uint32_t Cassandra_describe_splits_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  4938. uint32_t xfer = 0;
  4939. std::string fname;
  4940. ::apache::thrift::protocol::TType ftype;
  4941. int16_t fid;
  4942. xfer += iprot->readStructBegin(fname);
  4943. using ::apache::thrift::protocol::TProtocolException;
  4944. while (true)
  4945. {
  4946. xfer += iprot->readFieldBegin(fname, ftype, fid);
  4947. if (ftype == ::apache::thrift::protocol::T_STOP) {
  4948. break;
  4949. }
  4950. switch (fid)
  4951. {
  4952. case 0:
  4953. if (ftype == ::apache::thrift::protocol::T_LIST) {
  4954. {
  4955. (*(this->success)).clear();
  4956. uint32_t _size310;
  4957. ::apache::thrift::protocol::TType _etype313;
  4958. iprot->readListBegin(_etype313, _size310);
  4959. (*(this->success)).resize(_size310);
  4960. uint32_t _i314;
  4961. for (_i314 = 0; _i314 < _size310; ++_i314)
  4962. {
  4963. xfer += iprot->readString((*(this->success))[_i314]);
  4964. }
  4965. iprot->readListEnd();
  4966. }
  4967. this->__isset.success = true;
  4968. } else {
  4969. xfer += iprot->skip(ftype);
  4970. }
  4971. break;
  4972. case 1:
  4973. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  4974. xfer += this->ire.read(iprot);
  4975. this->__isset.ire = true;
  4976. } else {
  4977. xfer += iprot->skip(ftype);
  4978. }
  4979. break;
  4980. default:
  4981. xfer += iprot->skip(ftype);
  4982. break;
  4983. }
  4984. xfer += iprot->readFieldEnd();
  4985. }
  4986. xfer += iprot->readStructEnd();
  4987. return xfer;
  4988. }
  4989. uint32_t Cassandra_system_add_column_family_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  4990. uint32_t xfer = 0;
  4991. std::string fname;
  4992. ::apache::thrift::protocol::TType ftype;
  4993. int16_t fid;
  4994. xfer += iprot->readStructBegin(fname);
  4995. using ::apache::thrift::protocol::TProtocolException;
  4996. bool isset_cf_def = false;
  4997. while (true)
  4998. {
  4999. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5000. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5001. break;
  5002. }
  5003. switch (fid)
  5004. {
  5005. case 1:
  5006. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5007. xfer += this->cf_def.read(iprot);
  5008. isset_cf_def = true;
  5009. } else {
  5010. xfer += iprot->skip(ftype);
  5011. }
  5012. break;
  5013. default:
  5014. xfer += iprot->skip(ftype);
  5015. break;
  5016. }
  5017. xfer += iprot->readFieldEnd();
  5018. }
  5019. xfer += iprot->readStructEnd();
  5020. if (!isset_cf_def)
  5021. throw TProtocolException(TProtocolException::INVALID_DATA);
  5022. return xfer;
  5023. }
  5024. uint32_t Cassandra_system_add_column_family_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5025. uint32_t xfer = 0;
  5026. xfer += oprot->writeStructBegin("Cassandra_system_add_column_family_args");
  5027. xfer += oprot->writeFieldBegin("cf_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5028. xfer += this->cf_def.write(oprot);
  5029. xfer += oprot->writeFieldEnd();
  5030. xfer += oprot->writeFieldStop();
  5031. xfer += oprot->writeStructEnd();
  5032. return xfer;
  5033. }
  5034. uint32_t Cassandra_system_add_column_family_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5035. uint32_t xfer = 0;
  5036. xfer += oprot->writeStructBegin("Cassandra_system_add_column_family_pargs");
  5037. xfer += oprot->writeFieldBegin("cf_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5038. xfer += (*(this->cf_def)).write(oprot);
  5039. xfer += oprot->writeFieldEnd();
  5040. xfer += oprot->writeFieldStop();
  5041. xfer += oprot->writeStructEnd();
  5042. return xfer;
  5043. }
  5044. uint32_t Cassandra_system_add_column_family_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5045. uint32_t xfer = 0;
  5046. std::string fname;
  5047. ::apache::thrift::protocol::TType ftype;
  5048. int16_t fid;
  5049. xfer += iprot->readStructBegin(fname);
  5050. using ::apache::thrift::protocol::TProtocolException;
  5051. while (true)
  5052. {
  5053. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5054. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5055. break;
  5056. }
  5057. switch (fid)
  5058. {
  5059. case 0:
  5060. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5061. xfer += iprot->readString(this->success);
  5062. this->__isset.success = true;
  5063. } else {
  5064. xfer += iprot->skip(ftype);
  5065. }
  5066. break;
  5067. case 1:
  5068. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5069. xfer += this->ire.read(iprot);
  5070. this->__isset.ire = true;
  5071. } else {
  5072. xfer += iprot->skip(ftype);
  5073. }
  5074. break;
  5075. case 2:
  5076. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5077. xfer += this->sde.read(iprot);
  5078. this->__isset.sde = true;
  5079. } else {
  5080. xfer += iprot->skip(ftype);
  5081. }
  5082. break;
  5083. default:
  5084. xfer += iprot->skip(ftype);
  5085. break;
  5086. }
  5087. xfer += iprot->readFieldEnd();
  5088. }
  5089. xfer += iprot->readStructEnd();
  5090. return xfer;
  5091. }
  5092. uint32_t Cassandra_system_add_column_family_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5093. uint32_t xfer = 0;
  5094. xfer += oprot->writeStructBegin("Cassandra_system_add_column_family_result");
  5095. if (this->__isset.success) {
  5096. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5097. xfer += oprot->writeString(this->success);
  5098. xfer += oprot->writeFieldEnd();
  5099. } else if (this->__isset.ire) {
  5100. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5101. xfer += this->ire.write(oprot);
  5102. xfer += oprot->writeFieldEnd();
  5103. } else if (this->__isset.sde) {
  5104. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5105. xfer += this->sde.write(oprot);
  5106. xfer += oprot->writeFieldEnd();
  5107. }
  5108. xfer += oprot->writeFieldStop();
  5109. xfer += oprot->writeStructEnd();
  5110. return xfer;
  5111. }
  5112. uint32_t Cassandra_system_add_column_family_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5113. uint32_t xfer = 0;
  5114. std::string fname;
  5115. ::apache::thrift::protocol::TType ftype;
  5116. int16_t fid;
  5117. xfer += iprot->readStructBegin(fname);
  5118. using ::apache::thrift::protocol::TProtocolException;
  5119. while (true)
  5120. {
  5121. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5122. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5123. break;
  5124. }
  5125. switch (fid)
  5126. {
  5127. case 0:
  5128. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5129. xfer += iprot->readString((*(this->success)));
  5130. this->__isset.success = true;
  5131. } else {
  5132. xfer += iprot->skip(ftype);
  5133. }
  5134. break;
  5135. case 1:
  5136. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5137. xfer += this->ire.read(iprot);
  5138. this->__isset.ire = true;
  5139. } else {
  5140. xfer += iprot->skip(ftype);
  5141. }
  5142. break;
  5143. case 2:
  5144. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5145. xfer += this->sde.read(iprot);
  5146. this->__isset.sde = true;
  5147. } else {
  5148. xfer += iprot->skip(ftype);
  5149. }
  5150. break;
  5151. default:
  5152. xfer += iprot->skip(ftype);
  5153. break;
  5154. }
  5155. xfer += iprot->readFieldEnd();
  5156. }
  5157. xfer += iprot->readStructEnd();
  5158. return xfer;
  5159. }
  5160. uint32_t Cassandra_system_drop_column_family_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  5161. uint32_t xfer = 0;
  5162. std::string fname;
  5163. ::apache::thrift::protocol::TType ftype;
  5164. int16_t fid;
  5165. xfer += iprot->readStructBegin(fname);
  5166. using ::apache::thrift::protocol::TProtocolException;
  5167. bool isset_column_family = false;
  5168. while (true)
  5169. {
  5170. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5171. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5172. break;
  5173. }
  5174. switch (fid)
  5175. {
  5176. case 1:
  5177. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5178. xfer += iprot->readString(this->column_family);
  5179. isset_column_family = true;
  5180. } else {
  5181. xfer += iprot->skip(ftype);
  5182. }
  5183. break;
  5184. default:
  5185. xfer += iprot->skip(ftype);
  5186. break;
  5187. }
  5188. xfer += iprot->readFieldEnd();
  5189. }
  5190. xfer += iprot->readStructEnd();
  5191. if (!isset_column_family)
  5192. throw TProtocolException(TProtocolException::INVALID_DATA);
  5193. return xfer;
  5194. }
  5195. uint32_t Cassandra_system_drop_column_family_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5196. uint32_t xfer = 0;
  5197. xfer += oprot->writeStructBegin("Cassandra_system_drop_column_family_args");
  5198. xfer += oprot->writeFieldBegin("column_family", ::apache::thrift::protocol::T_STRING, 1);
  5199. xfer += oprot->writeString(this->column_family);
  5200. xfer += oprot->writeFieldEnd();
  5201. xfer += oprot->writeFieldStop();
  5202. xfer += oprot->writeStructEnd();
  5203. return xfer;
  5204. }
  5205. uint32_t Cassandra_system_drop_column_family_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5206. uint32_t xfer = 0;
  5207. xfer += oprot->writeStructBegin("Cassandra_system_drop_column_family_pargs");
  5208. xfer += oprot->writeFieldBegin("column_family", ::apache::thrift::protocol::T_STRING, 1);
  5209. xfer += oprot->writeString((*(this->column_family)));
  5210. xfer += oprot->writeFieldEnd();
  5211. xfer += oprot->writeFieldStop();
  5212. xfer += oprot->writeStructEnd();
  5213. return xfer;
  5214. }
  5215. uint32_t Cassandra_system_drop_column_family_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5216. uint32_t xfer = 0;
  5217. std::string fname;
  5218. ::apache::thrift::protocol::TType ftype;
  5219. int16_t fid;
  5220. xfer += iprot->readStructBegin(fname);
  5221. using ::apache::thrift::protocol::TProtocolException;
  5222. while (true)
  5223. {
  5224. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5225. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5226. break;
  5227. }
  5228. switch (fid)
  5229. {
  5230. case 0:
  5231. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5232. xfer += iprot->readString(this->success);
  5233. this->__isset.success = true;
  5234. } else {
  5235. xfer += iprot->skip(ftype);
  5236. }
  5237. break;
  5238. case 1:
  5239. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5240. xfer += this->ire.read(iprot);
  5241. this->__isset.ire = true;
  5242. } else {
  5243. xfer += iprot->skip(ftype);
  5244. }
  5245. break;
  5246. case 2:
  5247. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5248. xfer += this->sde.read(iprot);
  5249. this->__isset.sde = true;
  5250. } else {
  5251. xfer += iprot->skip(ftype);
  5252. }
  5253. break;
  5254. default:
  5255. xfer += iprot->skip(ftype);
  5256. break;
  5257. }
  5258. xfer += iprot->readFieldEnd();
  5259. }
  5260. xfer += iprot->readStructEnd();
  5261. return xfer;
  5262. }
  5263. uint32_t Cassandra_system_drop_column_family_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5264. uint32_t xfer = 0;
  5265. xfer += oprot->writeStructBegin("Cassandra_system_drop_column_family_result");
  5266. if (this->__isset.success) {
  5267. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5268. xfer += oprot->writeString(this->success);
  5269. xfer += oprot->writeFieldEnd();
  5270. } else if (this->__isset.ire) {
  5271. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5272. xfer += this->ire.write(oprot);
  5273. xfer += oprot->writeFieldEnd();
  5274. } else if (this->__isset.sde) {
  5275. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5276. xfer += this->sde.write(oprot);
  5277. xfer += oprot->writeFieldEnd();
  5278. }
  5279. xfer += oprot->writeFieldStop();
  5280. xfer += oprot->writeStructEnd();
  5281. return xfer;
  5282. }
  5283. uint32_t Cassandra_system_drop_column_family_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5284. uint32_t xfer = 0;
  5285. std::string fname;
  5286. ::apache::thrift::protocol::TType ftype;
  5287. int16_t fid;
  5288. xfer += iprot->readStructBegin(fname);
  5289. using ::apache::thrift::protocol::TProtocolException;
  5290. while (true)
  5291. {
  5292. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5293. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5294. break;
  5295. }
  5296. switch (fid)
  5297. {
  5298. case 0:
  5299. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5300. xfer += iprot->readString((*(this->success)));
  5301. this->__isset.success = true;
  5302. } else {
  5303. xfer += iprot->skip(ftype);
  5304. }
  5305. break;
  5306. case 1:
  5307. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5308. xfer += this->ire.read(iprot);
  5309. this->__isset.ire = true;
  5310. } else {
  5311. xfer += iprot->skip(ftype);
  5312. }
  5313. break;
  5314. case 2:
  5315. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5316. xfer += this->sde.read(iprot);
  5317. this->__isset.sde = true;
  5318. } else {
  5319. xfer += iprot->skip(ftype);
  5320. }
  5321. break;
  5322. default:
  5323. xfer += iprot->skip(ftype);
  5324. break;
  5325. }
  5326. xfer += iprot->readFieldEnd();
  5327. }
  5328. xfer += iprot->readStructEnd();
  5329. return xfer;
  5330. }
  5331. uint32_t Cassandra_system_add_keyspace_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  5332. uint32_t xfer = 0;
  5333. std::string fname;
  5334. ::apache::thrift::protocol::TType ftype;
  5335. int16_t fid;
  5336. xfer += iprot->readStructBegin(fname);
  5337. using ::apache::thrift::protocol::TProtocolException;
  5338. bool isset_ks_def = false;
  5339. while (true)
  5340. {
  5341. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5342. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5343. break;
  5344. }
  5345. switch (fid)
  5346. {
  5347. case 1:
  5348. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5349. xfer += this->ks_def.read(iprot);
  5350. isset_ks_def = true;
  5351. } else {
  5352. xfer += iprot->skip(ftype);
  5353. }
  5354. break;
  5355. default:
  5356. xfer += iprot->skip(ftype);
  5357. break;
  5358. }
  5359. xfer += iprot->readFieldEnd();
  5360. }
  5361. xfer += iprot->readStructEnd();
  5362. if (!isset_ks_def)
  5363. throw TProtocolException(TProtocolException::INVALID_DATA);
  5364. return xfer;
  5365. }
  5366. uint32_t Cassandra_system_add_keyspace_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5367. uint32_t xfer = 0;
  5368. xfer += oprot->writeStructBegin("Cassandra_system_add_keyspace_args");
  5369. xfer += oprot->writeFieldBegin("ks_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5370. xfer += this->ks_def.write(oprot);
  5371. xfer += oprot->writeFieldEnd();
  5372. xfer += oprot->writeFieldStop();
  5373. xfer += oprot->writeStructEnd();
  5374. return xfer;
  5375. }
  5376. uint32_t Cassandra_system_add_keyspace_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5377. uint32_t xfer = 0;
  5378. xfer += oprot->writeStructBegin("Cassandra_system_add_keyspace_pargs");
  5379. xfer += oprot->writeFieldBegin("ks_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5380. xfer += (*(this->ks_def)).write(oprot);
  5381. xfer += oprot->writeFieldEnd();
  5382. xfer += oprot->writeFieldStop();
  5383. xfer += oprot->writeStructEnd();
  5384. return xfer;
  5385. }
  5386. uint32_t Cassandra_system_add_keyspace_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5387. uint32_t xfer = 0;
  5388. std::string fname;
  5389. ::apache::thrift::protocol::TType ftype;
  5390. int16_t fid;
  5391. xfer += iprot->readStructBegin(fname);
  5392. using ::apache::thrift::protocol::TProtocolException;
  5393. while (true)
  5394. {
  5395. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5396. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5397. break;
  5398. }
  5399. switch (fid)
  5400. {
  5401. case 0:
  5402. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5403. xfer += iprot->readString(this->success);
  5404. this->__isset.success = true;
  5405. } else {
  5406. xfer += iprot->skip(ftype);
  5407. }
  5408. break;
  5409. case 1:
  5410. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5411. xfer += this->ire.read(iprot);
  5412. this->__isset.ire = true;
  5413. } else {
  5414. xfer += iprot->skip(ftype);
  5415. }
  5416. break;
  5417. case 2:
  5418. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5419. xfer += this->sde.read(iprot);
  5420. this->__isset.sde = true;
  5421. } else {
  5422. xfer += iprot->skip(ftype);
  5423. }
  5424. break;
  5425. default:
  5426. xfer += iprot->skip(ftype);
  5427. break;
  5428. }
  5429. xfer += iprot->readFieldEnd();
  5430. }
  5431. xfer += iprot->readStructEnd();
  5432. return xfer;
  5433. }
  5434. uint32_t Cassandra_system_add_keyspace_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5435. uint32_t xfer = 0;
  5436. xfer += oprot->writeStructBegin("Cassandra_system_add_keyspace_result");
  5437. if (this->__isset.success) {
  5438. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5439. xfer += oprot->writeString(this->success);
  5440. xfer += oprot->writeFieldEnd();
  5441. } else if (this->__isset.ire) {
  5442. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5443. xfer += this->ire.write(oprot);
  5444. xfer += oprot->writeFieldEnd();
  5445. } else if (this->__isset.sde) {
  5446. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5447. xfer += this->sde.write(oprot);
  5448. xfer += oprot->writeFieldEnd();
  5449. }
  5450. xfer += oprot->writeFieldStop();
  5451. xfer += oprot->writeStructEnd();
  5452. return xfer;
  5453. }
  5454. uint32_t Cassandra_system_add_keyspace_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5455. uint32_t xfer = 0;
  5456. std::string fname;
  5457. ::apache::thrift::protocol::TType ftype;
  5458. int16_t fid;
  5459. xfer += iprot->readStructBegin(fname);
  5460. using ::apache::thrift::protocol::TProtocolException;
  5461. while (true)
  5462. {
  5463. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5464. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5465. break;
  5466. }
  5467. switch (fid)
  5468. {
  5469. case 0:
  5470. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5471. xfer += iprot->readString((*(this->success)));
  5472. this->__isset.success = true;
  5473. } else {
  5474. xfer += iprot->skip(ftype);
  5475. }
  5476. break;
  5477. case 1:
  5478. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5479. xfer += this->ire.read(iprot);
  5480. this->__isset.ire = true;
  5481. } else {
  5482. xfer += iprot->skip(ftype);
  5483. }
  5484. break;
  5485. case 2:
  5486. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5487. xfer += this->sde.read(iprot);
  5488. this->__isset.sde = true;
  5489. } else {
  5490. xfer += iprot->skip(ftype);
  5491. }
  5492. break;
  5493. default:
  5494. xfer += iprot->skip(ftype);
  5495. break;
  5496. }
  5497. xfer += iprot->readFieldEnd();
  5498. }
  5499. xfer += iprot->readStructEnd();
  5500. return xfer;
  5501. }
  5502. uint32_t Cassandra_system_drop_keyspace_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  5503. uint32_t xfer = 0;
  5504. std::string fname;
  5505. ::apache::thrift::protocol::TType ftype;
  5506. int16_t fid;
  5507. xfer += iprot->readStructBegin(fname);
  5508. using ::apache::thrift::protocol::TProtocolException;
  5509. bool isset_keyspace = false;
  5510. while (true)
  5511. {
  5512. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5513. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5514. break;
  5515. }
  5516. switch (fid)
  5517. {
  5518. case 1:
  5519. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5520. xfer += iprot->readString(this->keyspace);
  5521. isset_keyspace = true;
  5522. } else {
  5523. xfer += iprot->skip(ftype);
  5524. }
  5525. break;
  5526. default:
  5527. xfer += iprot->skip(ftype);
  5528. break;
  5529. }
  5530. xfer += iprot->readFieldEnd();
  5531. }
  5532. xfer += iprot->readStructEnd();
  5533. if (!isset_keyspace)
  5534. throw TProtocolException(TProtocolException::INVALID_DATA);
  5535. return xfer;
  5536. }
  5537. uint32_t Cassandra_system_drop_keyspace_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5538. uint32_t xfer = 0;
  5539. xfer += oprot->writeStructBegin("Cassandra_system_drop_keyspace_args");
  5540. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  5541. xfer += oprot->writeString(this->keyspace);
  5542. xfer += oprot->writeFieldEnd();
  5543. xfer += oprot->writeFieldStop();
  5544. xfer += oprot->writeStructEnd();
  5545. return xfer;
  5546. }
  5547. uint32_t Cassandra_system_drop_keyspace_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5548. uint32_t xfer = 0;
  5549. xfer += oprot->writeStructBegin("Cassandra_system_drop_keyspace_pargs");
  5550. xfer += oprot->writeFieldBegin("keyspace", ::apache::thrift::protocol::T_STRING, 1);
  5551. xfer += oprot->writeString((*(this->keyspace)));
  5552. xfer += oprot->writeFieldEnd();
  5553. xfer += oprot->writeFieldStop();
  5554. xfer += oprot->writeStructEnd();
  5555. return xfer;
  5556. }
  5557. uint32_t Cassandra_system_drop_keyspace_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5558. uint32_t xfer = 0;
  5559. std::string fname;
  5560. ::apache::thrift::protocol::TType ftype;
  5561. int16_t fid;
  5562. xfer += iprot->readStructBegin(fname);
  5563. using ::apache::thrift::protocol::TProtocolException;
  5564. while (true)
  5565. {
  5566. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5567. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5568. break;
  5569. }
  5570. switch (fid)
  5571. {
  5572. case 0:
  5573. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5574. xfer += iprot->readString(this->success);
  5575. this->__isset.success = true;
  5576. } else {
  5577. xfer += iprot->skip(ftype);
  5578. }
  5579. break;
  5580. case 1:
  5581. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5582. xfer += this->ire.read(iprot);
  5583. this->__isset.ire = true;
  5584. } else {
  5585. xfer += iprot->skip(ftype);
  5586. }
  5587. break;
  5588. case 2:
  5589. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5590. xfer += this->sde.read(iprot);
  5591. this->__isset.sde = true;
  5592. } else {
  5593. xfer += iprot->skip(ftype);
  5594. }
  5595. break;
  5596. default:
  5597. xfer += iprot->skip(ftype);
  5598. break;
  5599. }
  5600. xfer += iprot->readFieldEnd();
  5601. }
  5602. xfer += iprot->readStructEnd();
  5603. return xfer;
  5604. }
  5605. uint32_t Cassandra_system_drop_keyspace_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5606. uint32_t xfer = 0;
  5607. xfer += oprot->writeStructBegin("Cassandra_system_drop_keyspace_result");
  5608. if (this->__isset.success) {
  5609. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5610. xfer += oprot->writeString(this->success);
  5611. xfer += oprot->writeFieldEnd();
  5612. } else if (this->__isset.ire) {
  5613. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5614. xfer += this->ire.write(oprot);
  5615. xfer += oprot->writeFieldEnd();
  5616. } else if (this->__isset.sde) {
  5617. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5618. xfer += this->sde.write(oprot);
  5619. xfer += oprot->writeFieldEnd();
  5620. }
  5621. xfer += oprot->writeFieldStop();
  5622. xfer += oprot->writeStructEnd();
  5623. return xfer;
  5624. }
  5625. uint32_t Cassandra_system_drop_keyspace_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5626. uint32_t xfer = 0;
  5627. std::string fname;
  5628. ::apache::thrift::protocol::TType ftype;
  5629. int16_t fid;
  5630. xfer += iprot->readStructBegin(fname);
  5631. using ::apache::thrift::protocol::TProtocolException;
  5632. while (true)
  5633. {
  5634. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5635. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5636. break;
  5637. }
  5638. switch (fid)
  5639. {
  5640. case 0:
  5641. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5642. xfer += iprot->readString((*(this->success)));
  5643. this->__isset.success = true;
  5644. } else {
  5645. xfer += iprot->skip(ftype);
  5646. }
  5647. break;
  5648. case 1:
  5649. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5650. xfer += this->ire.read(iprot);
  5651. this->__isset.ire = true;
  5652. } else {
  5653. xfer += iprot->skip(ftype);
  5654. }
  5655. break;
  5656. case 2:
  5657. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5658. xfer += this->sde.read(iprot);
  5659. this->__isset.sde = true;
  5660. } else {
  5661. xfer += iprot->skip(ftype);
  5662. }
  5663. break;
  5664. default:
  5665. xfer += iprot->skip(ftype);
  5666. break;
  5667. }
  5668. xfer += iprot->readFieldEnd();
  5669. }
  5670. xfer += iprot->readStructEnd();
  5671. return xfer;
  5672. }
  5673. uint32_t Cassandra_system_update_keyspace_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  5674. uint32_t xfer = 0;
  5675. std::string fname;
  5676. ::apache::thrift::protocol::TType ftype;
  5677. int16_t fid;
  5678. xfer += iprot->readStructBegin(fname);
  5679. using ::apache::thrift::protocol::TProtocolException;
  5680. bool isset_ks_def = false;
  5681. while (true)
  5682. {
  5683. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5684. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5685. break;
  5686. }
  5687. switch (fid)
  5688. {
  5689. case 1:
  5690. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5691. xfer += this->ks_def.read(iprot);
  5692. isset_ks_def = true;
  5693. } else {
  5694. xfer += iprot->skip(ftype);
  5695. }
  5696. break;
  5697. default:
  5698. xfer += iprot->skip(ftype);
  5699. break;
  5700. }
  5701. xfer += iprot->readFieldEnd();
  5702. }
  5703. xfer += iprot->readStructEnd();
  5704. if (!isset_ks_def)
  5705. throw TProtocolException(TProtocolException::INVALID_DATA);
  5706. return xfer;
  5707. }
  5708. uint32_t Cassandra_system_update_keyspace_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5709. uint32_t xfer = 0;
  5710. xfer += oprot->writeStructBegin("Cassandra_system_update_keyspace_args");
  5711. xfer += oprot->writeFieldBegin("ks_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5712. xfer += this->ks_def.write(oprot);
  5713. xfer += oprot->writeFieldEnd();
  5714. xfer += oprot->writeFieldStop();
  5715. xfer += oprot->writeStructEnd();
  5716. return xfer;
  5717. }
  5718. uint32_t Cassandra_system_update_keyspace_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5719. uint32_t xfer = 0;
  5720. xfer += oprot->writeStructBegin("Cassandra_system_update_keyspace_pargs");
  5721. xfer += oprot->writeFieldBegin("ks_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5722. xfer += (*(this->ks_def)).write(oprot);
  5723. xfer += oprot->writeFieldEnd();
  5724. xfer += oprot->writeFieldStop();
  5725. xfer += oprot->writeStructEnd();
  5726. return xfer;
  5727. }
  5728. uint32_t Cassandra_system_update_keyspace_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5729. uint32_t xfer = 0;
  5730. std::string fname;
  5731. ::apache::thrift::protocol::TType ftype;
  5732. int16_t fid;
  5733. xfer += iprot->readStructBegin(fname);
  5734. using ::apache::thrift::protocol::TProtocolException;
  5735. while (true)
  5736. {
  5737. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5738. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5739. break;
  5740. }
  5741. switch (fid)
  5742. {
  5743. case 0:
  5744. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5745. xfer += iprot->readString(this->success);
  5746. this->__isset.success = true;
  5747. } else {
  5748. xfer += iprot->skip(ftype);
  5749. }
  5750. break;
  5751. case 1:
  5752. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5753. xfer += this->ire.read(iprot);
  5754. this->__isset.ire = true;
  5755. } else {
  5756. xfer += iprot->skip(ftype);
  5757. }
  5758. break;
  5759. case 2:
  5760. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5761. xfer += this->sde.read(iprot);
  5762. this->__isset.sde = true;
  5763. } else {
  5764. xfer += iprot->skip(ftype);
  5765. }
  5766. break;
  5767. default:
  5768. xfer += iprot->skip(ftype);
  5769. break;
  5770. }
  5771. xfer += iprot->readFieldEnd();
  5772. }
  5773. xfer += iprot->readStructEnd();
  5774. return xfer;
  5775. }
  5776. uint32_t Cassandra_system_update_keyspace_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5777. uint32_t xfer = 0;
  5778. xfer += oprot->writeStructBegin("Cassandra_system_update_keyspace_result");
  5779. if (this->__isset.success) {
  5780. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5781. xfer += oprot->writeString(this->success);
  5782. xfer += oprot->writeFieldEnd();
  5783. } else if (this->__isset.ire) {
  5784. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5785. xfer += this->ire.write(oprot);
  5786. xfer += oprot->writeFieldEnd();
  5787. } else if (this->__isset.sde) {
  5788. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5789. xfer += this->sde.write(oprot);
  5790. xfer += oprot->writeFieldEnd();
  5791. }
  5792. xfer += oprot->writeFieldStop();
  5793. xfer += oprot->writeStructEnd();
  5794. return xfer;
  5795. }
  5796. uint32_t Cassandra_system_update_keyspace_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5797. uint32_t xfer = 0;
  5798. std::string fname;
  5799. ::apache::thrift::protocol::TType ftype;
  5800. int16_t fid;
  5801. xfer += iprot->readStructBegin(fname);
  5802. using ::apache::thrift::protocol::TProtocolException;
  5803. while (true)
  5804. {
  5805. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5806. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5807. break;
  5808. }
  5809. switch (fid)
  5810. {
  5811. case 0:
  5812. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5813. xfer += iprot->readString((*(this->success)));
  5814. this->__isset.success = true;
  5815. } else {
  5816. xfer += iprot->skip(ftype);
  5817. }
  5818. break;
  5819. case 1:
  5820. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5821. xfer += this->ire.read(iprot);
  5822. this->__isset.ire = true;
  5823. } else {
  5824. xfer += iprot->skip(ftype);
  5825. }
  5826. break;
  5827. case 2:
  5828. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5829. xfer += this->sde.read(iprot);
  5830. this->__isset.sde = true;
  5831. } else {
  5832. xfer += iprot->skip(ftype);
  5833. }
  5834. break;
  5835. default:
  5836. xfer += iprot->skip(ftype);
  5837. break;
  5838. }
  5839. xfer += iprot->readFieldEnd();
  5840. }
  5841. xfer += iprot->readStructEnd();
  5842. return xfer;
  5843. }
  5844. uint32_t Cassandra_system_update_column_family_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  5845. uint32_t xfer = 0;
  5846. std::string fname;
  5847. ::apache::thrift::protocol::TType ftype;
  5848. int16_t fid;
  5849. xfer += iprot->readStructBegin(fname);
  5850. using ::apache::thrift::protocol::TProtocolException;
  5851. bool isset_cf_def = false;
  5852. while (true)
  5853. {
  5854. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5855. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5856. break;
  5857. }
  5858. switch (fid)
  5859. {
  5860. case 1:
  5861. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5862. xfer += this->cf_def.read(iprot);
  5863. isset_cf_def = true;
  5864. } else {
  5865. xfer += iprot->skip(ftype);
  5866. }
  5867. break;
  5868. default:
  5869. xfer += iprot->skip(ftype);
  5870. break;
  5871. }
  5872. xfer += iprot->readFieldEnd();
  5873. }
  5874. xfer += iprot->readStructEnd();
  5875. if (!isset_cf_def)
  5876. throw TProtocolException(TProtocolException::INVALID_DATA);
  5877. return xfer;
  5878. }
  5879. uint32_t Cassandra_system_update_column_family_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5880. uint32_t xfer = 0;
  5881. xfer += oprot->writeStructBegin("Cassandra_system_update_column_family_args");
  5882. xfer += oprot->writeFieldBegin("cf_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5883. xfer += this->cf_def.write(oprot);
  5884. xfer += oprot->writeFieldEnd();
  5885. xfer += oprot->writeFieldStop();
  5886. xfer += oprot->writeStructEnd();
  5887. return xfer;
  5888. }
  5889. uint32_t Cassandra_system_update_column_family_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5890. uint32_t xfer = 0;
  5891. xfer += oprot->writeStructBegin("Cassandra_system_update_column_family_pargs");
  5892. xfer += oprot->writeFieldBegin("cf_def", ::apache::thrift::protocol::T_STRUCT, 1);
  5893. xfer += (*(this->cf_def)).write(oprot);
  5894. xfer += oprot->writeFieldEnd();
  5895. xfer += oprot->writeFieldStop();
  5896. xfer += oprot->writeStructEnd();
  5897. return xfer;
  5898. }
  5899. uint32_t Cassandra_system_update_column_family_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  5900. uint32_t xfer = 0;
  5901. std::string fname;
  5902. ::apache::thrift::protocol::TType ftype;
  5903. int16_t fid;
  5904. xfer += iprot->readStructBegin(fname);
  5905. using ::apache::thrift::protocol::TProtocolException;
  5906. while (true)
  5907. {
  5908. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5909. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5910. break;
  5911. }
  5912. switch (fid)
  5913. {
  5914. case 0:
  5915. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5916. xfer += iprot->readString(this->success);
  5917. this->__isset.success = true;
  5918. } else {
  5919. xfer += iprot->skip(ftype);
  5920. }
  5921. break;
  5922. case 1:
  5923. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5924. xfer += this->ire.read(iprot);
  5925. this->__isset.ire = true;
  5926. } else {
  5927. xfer += iprot->skip(ftype);
  5928. }
  5929. break;
  5930. case 2:
  5931. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5932. xfer += this->sde.read(iprot);
  5933. this->__isset.sde = true;
  5934. } else {
  5935. xfer += iprot->skip(ftype);
  5936. }
  5937. break;
  5938. default:
  5939. xfer += iprot->skip(ftype);
  5940. break;
  5941. }
  5942. xfer += iprot->readFieldEnd();
  5943. }
  5944. xfer += iprot->readStructEnd();
  5945. return xfer;
  5946. }
  5947. uint32_t Cassandra_system_update_column_family_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  5948. uint32_t xfer = 0;
  5949. xfer += oprot->writeStructBegin("Cassandra_system_update_column_family_result");
  5950. if (this->__isset.success) {
  5951. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRING, 0);
  5952. xfer += oprot->writeString(this->success);
  5953. xfer += oprot->writeFieldEnd();
  5954. } else if (this->__isset.ire) {
  5955. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  5956. xfer += this->ire.write(oprot);
  5957. xfer += oprot->writeFieldEnd();
  5958. } else if (this->__isset.sde) {
  5959. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 2);
  5960. xfer += this->sde.write(oprot);
  5961. xfer += oprot->writeFieldEnd();
  5962. }
  5963. xfer += oprot->writeFieldStop();
  5964. xfer += oprot->writeStructEnd();
  5965. return xfer;
  5966. }
  5967. uint32_t Cassandra_system_update_column_family_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  5968. uint32_t xfer = 0;
  5969. std::string fname;
  5970. ::apache::thrift::protocol::TType ftype;
  5971. int16_t fid;
  5972. xfer += iprot->readStructBegin(fname);
  5973. using ::apache::thrift::protocol::TProtocolException;
  5974. while (true)
  5975. {
  5976. xfer += iprot->readFieldBegin(fname, ftype, fid);
  5977. if (ftype == ::apache::thrift::protocol::T_STOP) {
  5978. break;
  5979. }
  5980. switch (fid)
  5981. {
  5982. case 0:
  5983. if (ftype == ::apache::thrift::protocol::T_STRING) {
  5984. xfer += iprot->readString((*(this->success)));
  5985. this->__isset.success = true;
  5986. } else {
  5987. xfer += iprot->skip(ftype);
  5988. }
  5989. break;
  5990. case 1:
  5991. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  5992. xfer += this->ire.read(iprot);
  5993. this->__isset.ire = true;
  5994. } else {
  5995. xfer += iprot->skip(ftype);
  5996. }
  5997. break;
  5998. case 2:
  5999. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6000. xfer += this->sde.read(iprot);
  6001. this->__isset.sde = true;
  6002. } else {
  6003. xfer += iprot->skip(ftype);
  6004. }
  6005. break;
  6006. default:
  6007. xfer += iprot->skip(ftype);
  6008. break;
  6009. }
  6010. xfer += iprot->readFieldEnd();
  6011. }
  6012. xfer += iprot->readStructEnd();
  6013. return xfer;
  6014. }
  6015. uint32_t Cassandra_execute_cql_query_args::read(::apache::thrift::protocol::TProtocol* iprot) {
  6016. uint32_t xfer = 0;
  6017. std::string fname;
  6018. ::apache::thrift::protocol::TType ftype;
  6019. int16_t fid;
  6020. xfer += iprot->readStructBegin(fname);
  6021. using ::apache::thrift::protocol::TProtocolException;
  6022. bool isset_query = false;
  6023. bool isset_compression = false;
  6024. while (true)
  6025. {
  6026. xfer += iprot->readFieldBegin(fname, ftype, fid);
  6027. if (ftype == ::apache::thrift::protocol::T_STOP) {
  6028. break;
  6029. }
  6030. switch (fid)
  6031. {
  6032. case 1:
  6033. if (ftype == ::apache::thrift::protocol::T_STRING) {
  6034. xfer += iprot->readBinary(this->query);
  6035. isset_query = true;
  6036. } else {
  6037. xfer += iprot->skip(ftype);
  6038. }
  6039. break;
  6040. case 2:
  6041. if (ftype == ::apache::thrift::protocol::T_I32) {
  6042. int32_t ecast315;
  6043. xfer += iprot->readI32(ecast315);
  6044. this->compression = (Compression::type)ecast315;
  6045. isset_compression = true;
  6046. } else {
  6047. xfer += iprot->skip(ftype);
  6048. }
  6049. break;
  6050. default:
  6051. xfer += iprot->skip(ftype);
  6052. break;
  6053. }
  6054. xfer += iprot->readFieldEnd();
  6055. }
  6056. xfer += iprot->readStructEnd();
  6057. if (!isset_query)
  6058. throw TProtocolException(TProtocolException::INVALID_DATA);
  6059. if (!isset_compression)
  6060. throw TProtocolException(TProtocolException::INVALID_DATA);
  6061. return xfer;
  6062. }
  6063. uint32_t Cassandra_execute_cql_query_args::write(::apache::thrift::protocol::TProtocol* oprot) const {
  6064. uint32_t xfer = 0;
  6065. xfer += oprot->writeStructBegin("Cassandra_execute_cql_query_args");
  6066. xfer += oprot->writeFieldBegin("query", ::apache::thrift::protocol::T_STRING, 1);
  6067. xfer += oprot->writeBinary(this->query);
  6068. xfer += oprot->writeFieldEnd();
  6069. xfer += oprot->writeFieldBegin("compression", ::apache::thrift::protocol::T_I32, 2);
  6070. xfer += oprot->writeI32((int32_t)this->compression);
  6071. xfer += oprot->writeFieldEnd();
  6072. xfer += oprot->writeFieldStop();
  6073. xfer += oprot->writeStructEnd();
  6074. return xfer;
  6075. }
  6076. uint32_t Cassandra_execute_cql_query_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const {
  6077. uint32_t xfer = 0;
  6078. xfer += oprot->writeStructBegin("Cassandra_execute_cql_query_pargs");
  6079. xfer += oprot->writeFieldBegin("query", ::apache::thrift::protocol::T_STRING, 1);
  6080. xfer += oprot->writeBinary((*(this->query)));
  6081. xfer += oprot->writeFieldEnd();
  6082. xfer += oprot->writeFieldBegin("compression", ::apache::thrift::protocol::T_I32, 2);
  6083. xfer += oprot->writeI32((int32_t)(*(this->compression)));
  6084. xfer += oprot->writeFieldEnd();
  6085. xfer += oprot->writeFieldStop();
  6086. xfer += oprot->writeStructEnd();
  6087. return xfer;
  6088. }
  6089. uint32_t Cassandra_execute_cql_query_result::read(::apache::thrift::protocol::TProtocol* iprot) {
  6090. uint32_t xfer = 0;
  6091. std::string fname;
  6092. ::apache::thrift::protocol::TType ftype;
  6093. int16_t fid;
  6094. xfer += iprot->readStructBegin(fname);
  6095. using ::apache::thrift::protocol::TProtocolException;
  6096. while (true)
  6097. {
  6098. xfer += iprot->readFieldBegin(fname, ftype, fid);
  6099. if (ftype == ::apache::thrift::protocol::T_STOP) {
  6100. break;
  6101. }
  6102. switch (fid)
  6103. {
  6104. case 0:
  6105. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6106. xfer += this->success.read(iprot);
  6107. this->__isset.success = true;
  6108. } else {
  6109. xfer += iprot->skip(ftype);
  6110. }
  6111. break;
  6112. case 1:
  6113. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6114. xfer += this->ire.read(iprot);
  6115. this->__isset.ire = true;
  6116. } else {
  6117. xfer += iprot->skip(ftype);
  6118. }
  6119. break;
  6120. case 2:
  6121. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6122. xfer += this->ue.read(iprot);
  6123. this->__isset.ue = true;
  6124. } else {
  6125. xfer += iprot->skip(ftype);
  6126. }
  6127. break;
  6128. case 3:
  6129. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6130. xfer += this->te.read(iprot);
  6131. this->__isset.te = true;
  6132. } else {
  6133. xfer += iprot->skip(ftype);
  6134. }
  6135. break;
  6136. case 4:
  6137. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6138. xfer += this->sde.read(iprot);
  6139. this->__isset.sde = true;
  6140. } else {
  6141. xfer += iprot->skip(ftype);
  6142. }
  6143. break;
  6144. default:
  6145. xfer += iprot->skip(ftype);
  6146. break;
  6147. }
  6148. xfer += iprot->readFieldEnd();
  6149. }
  6150. xfer += iprot->readStructEnd();
  6151. return xfer;
  6152. }
  6153. uint32_t Cassandra_execute_cql_query_result::write(::apache::thrift::protocol::TProtocol* oprot) const {
  6154. uint32_t xfer = 0;
  6155. xfer += oprot->writeStructBegin("Cassandra_execute_cql_query_result");
  6156. if (this->__isset.success) {
  6157. xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRUCT, 0);
  6158. xfer += this->success.write(oprot);
  6159. xfer += oprot->writeFieldEnd();
  6160. } else if (this->__isset.ire) {
  6161. xfer += oprot->writeFieldBegin("ire", ::apache::thrift::protocol::T_STRUCT, 1);
  6162. xfer += this->ire.write(oprot);
  6163. xfer += oprot->writeFieldEnd();
  6164. } else if (this->__isset.ue) {
  6165. xfer += oprot->writeFieldBegin("ue", ::apache::thrift::protocol::T_STRUCT, 2);
  6166. xfer += this->ue.write(oprot);
  6167. xfer += oprot->writeFieldEnd();
  6168. } else if (this->__isset.te) {
  6169. xfer += oprot->writeFieldBegin("te", ::apache::thrift::protocol::T_STRUCT, 3);
  6170. xfer += this->te.write(oprot);
  6171. xfer += oprot->writeFieldEnd();
  6172. } else if (this->__isset.sde) {
  6173. xfer += oprot->writeFieldBegin("sde", ::apache::thrift::protocol::T_STRUCT, 4);
  6174. xfer += this->sde.write(oprot);
  6175. xfer += oprot->writeFieldEnd();
  6176. }
  6177. xfer += oprot->writeFieldStop();
  6178. xfer += oprot->writeStructEnd();
  6179. return xfer;
  6180. }
  6181. uint32_t Cassandra_execute_cql_query_presult::read(::apache::thrift::protocol::TProtocol* iprot) {
  6182. uint32_t xfer = 0;
  6183. std::string fname;
  6184. ::apache::thrift::protocol::TType ftype;
  6185. int16_t fid;
  6186. xfer += iprot->readStructBegin(fname);
  6187. using ::apache::thrift::protocol::TProtocolException;
  6188. while (true)
  6189. {
  6190. xfer += iprot->readFieldBegin(fname, ftype, fid);
  6191. if (ftype == ::apache::thrift::protocol::T_STOP) {
  6192. break;
  6193. }
  6194. switch (fid)
  6195. {
  6196. case 0:
  6197. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6198. xfer += (*(this->success)).read(iprot);
  6199. this->__isset.success = true;
  6200. } else {
  6201. xfer += iprot->skip(ftype);
  6202. }
  6203. break;
  6204. case 1:
  6205. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6206. xfer += this->ire.read(iprot);
  6207. this->__isset.ire = true;
  6208. } else {
  6209. xfer += iprot->skip(ftype);
  6210. }
  6211. break;
  6212. case 2:
  6213. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6214. xfer += this->ue.read(iprot);
  6215. this->__isset.ue = true;
  6216. } else {
  6217. xfer += iprot->skip(ftype);
  6218. }
  6219. break;
  6220. case 3:
  6221. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6222. xfer += this->te.read(iprot);
  6223. this->__isset.te = true;
  6224. } else {
  6225. xfer += iprot->skip(ftype);
  6226. }
  6227. break;
  6228. case 4:
  6229. if (ftype == ::apache::thrift::protocol::T_STRUCT) {
  6230. xfer += this->sde.read(iprot);
  6231. this->__isset.sde = true;
  6232. } else {
  6233. xfer += iprot->skip(ftype);
  6234. }
  6235. break;
  6236. default:
  6237. xfer += iprot->skip(ftype);
  6238. break;
  6239. }
  6240. xfer += iprot->readFieldEnd();
  6241. }
  6242. xfer += iprot->readStructEnd();
  6243. return xfer;
  6244. }
  6245. void CassandraClient::login(const AuthenticationRequest& auth_request)
  6246. {
  6247. send_login(auth_request);
  6248. recv_login();
  6249. }
  6250. void CassandraClient::send_login(const AuthenticationRequest& auth_request)
  6251. {
  6252. int32_t cseqid = 0;
  6253. oprot_->writeMessageBegin("login", ::apache::thrift::protocol::T_CALL, cseqid);
  6254. Cassandra_login_pargs args;
  6255. args.auth_request = &auth_request;
  6256. args.write(oprot_);
  6257. oprot_->writeMessageEnd();
  6258. oprot_->getTransport()->writeEnd();
  6259. oprot_->getTransport()->flush();
  6260. }
  6261. void CassandraClient::recv_login()
  6262. {
  6263. int32_t rseqid = 0;
  6264. std::string fname;
  6265. ::apache::thrift::protocol::TMessageType mtype;
  6266. iprot_->readMessageBegin(fname, mtype, rseqid);
  6267. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6268. ::apache::thrift::TApplicationException x;
  6269. x.read(iprot_);
  6270. iprot_->readMessageEnd();
  6271. iprot_->getTransport()->readEnd();
  6272. throw x;
  6273. }
  6274. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6275. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6276. iprot_->readMessageEnd();
  6277. iprot_->getTransport()->readEnd();
  6278. }
  6279. if (fname.compare("login") != 0) {
  6280. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6281. iprot_->readMessageEnd();
  6282. iprot_->getTransport()->readEnd();
  6283. }
  6284. Cassandra_login_presult result;
  6285. result.read(iprot_);
  6286. iprot_->readMessageEnd();
  6287. iprot_->getTransport()->readEnd();
  6288. if (result.__isset.authnx) {
  6289. throw result.authnx;
  6290. }
  6291. if (result.__isset.authzx) {
  6292. throw result.authzx;
  6293. }
  6294. return;
  6295. }
  6296. void CassandraClient::set_keyspace(const std::string& keyspace)
  6297. {
  6298. send_set_keyspace(keyspace);
  6299. recv_set_keyspace();
  6300. }
  6301. void CassandraClient::send_set_keyspace(const std::string& keyspace)
  6302. {
  6303. int32_t cseqid = 0;
  6304. oprot_->writeMessageBegin("set_keyspace", ::apache::thrift::protocol::T_CALL, cseqid);
  6305. Cassandra_set_keyspace_pargs args;
  6306. args.keyspace = &keyspace;
  6307. args.write(oprot_);
  6308. oprot_->writeMessageEnd();
  6309. oprot_->getTransport()->writeEnd();
  6310. oprot_->getTransport()->flush();
  6311. }
  6312. void CassandraClient::recv_set_keyspace()
  6313. {
  6314. int32_t rseqid = 0;
  6315. std::string fname;
  6316. ::apache::thrift::protocol::TMessageType mtype;
  6317. iprot_->readMessageBegin(fname, mtype, rseqid);
  6318. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6319. ::apache::thrift::TApplicationException x;
  6320. x.read(iprot_);
  6321. iprot_->readMessageEnd();
  6322. iprot_->getTransport()->readEnd();
  6323. throw x;
  6324. }
  6325. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6326. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6327. iprot_->readMessageEnd();
  6328. iprot_->getTransport()->readEnd();
  6329. }
  6330. if (fname.compare("set_keyspace") != 0) {
  6331. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6332. iprot_->readMessageEnd();
  6333. iprot_->getTransport()->readEnd();
  6334. }
  6335. Cassandra_set_keyspace_presult result;
  6336. result.read(iprot_);
  6337. iprot_->readMessageEnd();
  6338. iprot_->getTransport()->readEnd();
  6339. if (result.__isset.ire) {
  6340. throw result.ire;
  6341. }
  6342. return;
  6343. }
  6344. void CassandraClient::get(ColumnOrSuperColumn& _return, const std::string& key, const ColumnPath& column_path, const ConsistencyLevel::type consistency_level)
  6345. {
  6346. send_get(key, column_path, consistency_level);
  6347. recv_get(_return);
  6348. }
  6349. void CassandraClient::send_get(const std::string& key, const ColumnPath& column_path, const ConsistencyLevel::type consistency_level)
  6350. {
  6351. int32_t cseqid = 0;
  6352. oprot_->writeMessageBegin("get", ::apache::thrift::protocol::T_CALL, cseqid);
  6353. Cassandra_get_pargs args;
  6354. args.key = &key;
  6355. args.column_path = &column_path;
  6356. args.consistency_level = &consistency_level;
  6357. args.write(oprot_);
  6358. oprot_->writeMessageEnd();
  6359. oprot_->getTransport()->writeEnd();
  6360. oprot_->getTransport()->flush();
  6361. }
  6362. void CassandraClient::recv_get(ColumnOrSuperColumn& _return)
  6363. {
  6364. int32_t rseqid = 0;
  6365. std::string fname;
  6366. ::apache::thrift::protocol::TMessageType mtype;
  6367. iprot_->readMessageBegin(fname, mtype, rseqid);
  6368. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6369. ::apache::thrift::TApplicationException x;
  6370. x.read(iprot_);
  6371. iprot_->readMessageEnd();
  6372. iprot_->getTransport()->readEnd();
  6373. throw x;
  6374. }
  6375. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6376. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6377. iprot_->readMessageEnd();
  6378. iprot_->getTransport()->readEnd();
  6379. }
  6380. if (fname.compare("get") != 0) {
  6381. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6382. iprot_->readMessageEnd();
  6383. iprot_->getTransport()->readEnd();
  6384. }
  6385. Cassandra_get_presult result;
  6386. result.success = &_return;
  6387. result.read(iprot_);
  6388. iprot_->readMessageEnd();
  6389. iprot_->getTransport()->readEnd();
  6390. if (result.__isset.success) {
  6391. // _return pointer has now been filled
  6392. return;
  6393. }
  6394. if (result.__isset.ire) {
  6395. throw result.ire;
  6396. }
  6397. if (result.__isset.nfe) {
  6398. throw result.nfe;
  6399. }
  6400. if (result.__isset.ue) {
  6401. throw result.ue;
  6402. }
  6403. if (result.__isset.te) {
  6404. throw result.te;
  6405. }
  6406. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get failed: unknown result");
  6407. }
  6408. void CassandraClient::get_slice(std::vector<ColumnOrSuperColumn> & _return, const std::string& key, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6409. {
  6410. send_get_slice(key, column_parent, predicate, consistency_level);
  6411. recv_get_slice(_return);
  6412. }
  6413. void CassandraClient::send_get_slice(const std::string& key, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6414. {
  6415. int32_t cseqid = 0;
  6416. oprot_->writeMessageBegin("get_slice", ::apache::thrift::protocol::T_CALL, cseqid);
  6417. Cassandra_get_slice_pargs args;
  6418. args.key = &key;
  6419. args.column_parent = &column_parent;
  6420. args.predicate = &predicate;
  6421. args.consistency_level = &consistency_level;
  6422. args.write(oprot_);
  6423. oprot_->writeMessageEnd();
  6424. oprot_->getTransport()->writeEnd();
  6425. oprot_->getTransport()->flush();
  6426. }
  6427. void CassandraClient::recv_get_slice(std::vector<ColumnOrSuperColumn> & _return)
  6428. {
  6429. int32_t rseqid = 0;
  6430. std::string fname;
  6431. ::apache::thrift::protocol::TMessageType mtype;
  6432. iprot_->readMessageBegin(fname, mtype, rseqid);
  6433. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6434. ::apache::thrift::TApplicationException x;
  6435. x.read(iprot_);
  6436. iprot_->readMessageEnd();
  6437. iprot_->getTransport()->readEnd();
  6438. throw x;
  6439. }
  6440. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6441. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6442. iprot_->readMessageEnd();
  6443. iprot_->getTransport()->readEnd();
  6444. }
  6445. if (fname.compare("get_slice") != 0) {
  6446. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6447. iprot_->readMessageEnd();
  6448. iprot_->getTransport()->readEnd();
  6449. }
  6450. Cassandra_get_slice_presult result;
  6451. result.success = &_return;
  6452. result.read(iprot_);
  6453. iprot_->readMessageEnd();
  6454. iprot_->getTransport()->readEnd();
  6455. if (result.__isset.success) {
  6456. // _return pointer has now been filled
  6457. return;
  6458. }
  6459. if (result.__isset.ire) {
  6460. throw result.ire;
  6461. }
  6462. if (result.__isset.ue) {
  6463. throw result.ue;
  6464. }
  6465. if (result.__isset.te) {
  6466. throw result.te;
  6467. }
  6468. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_slice failed: unknown result");
  6469. }
  6470. int32_t CassandraClient::get_count(const std::string& key, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6471. {
  6472. send_get_count(key, column_parent, predicate, consistency_level);
  6473. return recv_get_count();
  6474. }
  6475. void CassandraClient::send_get_count(const std::string& key, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6476. {
  6477. int32_t cseqid = 0;
  6478. oprot_->writeMessageBegin("get_count", ::apache::thrift::protocol::T_CALL, cseqid);
  6479. Cassandra_get_count_pargs args;
  6480. args.key = &key;
  6481. args.column_parent = &column_parent;
  6482. args.predicate = &predicate;
  6483. args.consistency_level = &consistency_level;
  6484. args.write(oprot_);
  6485. oprot_->writeMessageEnd();
  6486. oprot_->getTransport()->writeEnd();
  6487. oprot_->getTransport()->flush();
  6488. }
  6489. int32_t CassandraClient::recv_get_count()
  6490. {
  6491. int32_t rseqid = 0;
  6492. std::string fname;
  6493. ::apache::thrift::protocol::TMessageType mtype;
  6494. iprot_->readMessageBegin(fname, mtype, rseqid);
  6495. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6496. ::apache::thrift::TApplicationException x;
  6497. x.read(iprot_);
  6498. iprot_->readMessageEnd();
  6499. iprot_->getTransport()->readEnd();
  6500. throw x;
  6501. }
  6502. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6503. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6504. iprot_->readMessageEnd();
  6505. iprot_->getTransport()->readEnd();
  6506. }
  6507. if (fname.compare("get_count") != 0) {
  6508. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6509. iprot_->readMessageEnd();
  6510. iprot_->getTransport()->readEnd();
  6511. }
  6512. int32_t _return;
  6513. Cassandra_get_count_presult result;
  6514. result.success = &_return;
  6515. result.read(iprot_);
  6516. iprot_->readMessageEnd();
  6517. iprot_->getTransport()->readEnd();
  6518. if (result.__isset.success) {
  6519. return _return;
  6520. }
  6521. if (result.__isset.ire) {
  6522. throw result.ire;
  6523. }
  6524. if (result.__isset.ue) {
  6525. throw result.ue;
  6526. }
  6527. if (result.__isset.te) {
  6528. throw result.te;
  6529. }
  6530. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_count failed: unknown result");
  6531. }
  6532. void CassandraClient::multiget_slice(std::map<std::string, std::vector<ColumnOrSuperColumn> > & _return, const std::vector<std::string> & keys, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6533. {
  6534. send_multiget_slice(keys, column_parent, predicate, consistency_level);
  6535. recv_multiget_slice(_return);
  6536. }
  6537. void CassandraClient::send_multiget_slice(const std::vector<std::string> & keys, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6538. {
  6539. int32_t cseqid = 0;
  6540. oprot_->writeMessageBegin("multiget_slice", ::apache::thrift::protocol::T_CALL, cseqid);
  6541. Cassandra_multiget_slice_pargs args;
  6542. args.keys = &keys;
  6543. args.column_parent = &column_parent;
  6544. args.predicate = &predicate;
  6545. args.consistency_level = &consistency_level;
  6546. args.write(oprot_);
  6547. oprot_->writeMessageEnd();
  6548. oprot_->getTransport()->writeEnd();
  6549. oprot_->getTransport()->flush();
  6550. }
  6551. void CassandraClient::recv_multiget_slice(std::map<std::string, std::vector<ColumnOrSuperColumn> > & _return)
  6552. {
  6553. int32_t rseqid = 0;
  6554. std::string fname;
  6555. ::apache::thrift::protocol::TMessageType mtype;
  6556. iprot_->readMessageBegin(fname, mtype, rseqid);
  6557. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6558. ::apache::thrift::TApplicationException x;
  6559. x.read(iprot_);
  6560. iprot_->readMessageEnd();
  6561. iprot_->getTransport()->readEnd();
  6562. throw x;
  6563. }
  6564. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6565. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6566. iprot_->readMessageEnd();
  6567. iprot_->getTransport()->readEnd();
  6568. }
  6569. if (fname.compare("multiget_slice") != 0) {
  6570. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6571. iprot_->readMessageEnd();
  6572. iprot_->getTransport()->readEnd();
  6573. }
  6574. Cassandra_multiget_slice_presult result;
  6575. result.success = &_return;
  6576. result.read(iprot_);
  6577. iprot_->readMessageEnd();
  6578. iprot_->getTransport()->readEnd();
  6579. if (result.__isset.success) {
  6580. // _return pointer has now been filled
  6581. return;
  6582. }
  6583. if (result.__isset.ire) {
  6584. throw result.ire;
  6585. }
  6586. if (result.__isset.ue) {
  6587. throw result.ue;
  6588. }
  6589. if (result.__isset.te) {
  6590. throw result.te;
  6591. }
  6592. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "multiget_slice failed: unknown result");
  6593. }
  6594. void CassandraClient::multiget_count(std::map<std::string, int32_t> & _return, const std::vector<std::string> & keys, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6595. {
  6596. send_multiget_count(keys, column_parent, predicate, consistency_level);
  6597. recv_multiget_count(_return);
  6598. }
  6599. void CassandraClient::send_multiget_count(const std::vector<std::string> & keys, const ColumnParent& column_parent, const SlicePredicate& predicate, const ConsistencyLevel::type consistency_level)
  6600. {
  6601. int32_t cseqid = 0;
  6602. oprot_->writeMessageBegin("multiget_count", ::apache::thrift::protocol::T_CALL, cseqid);
  6603. Cassandra_multiget_count_pargs args;
  6604. args.keys = &keys;
  6605. args.column_parent = &column_parent;
  6606. args.predicate = &predicate;
  6607. args.consistency_level = &consistency_level;
  6608. args.write(oprot_);
  6609. oprot_->writeMessageEnd();
  6610. oprot_->getTransport()->writeEnd();
  6611. oprot_->getTransport()->flush();
  6612. }
  6613. void CassandraClient::recv_multiget_count(std::map<std::string, int32_t> & _return)
  6614. {
  6615. int32_t rseqid = 0;
  6616. std::string fname;
  6617. ::apache::thrift::protocol::TMessageType mtype;
  6618. iprot_->readMessageBegin(fname, mtype, rseqid);
  6619. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6620. ::apache::thrift::TApplicationException x;
  6621. x.read(iprot_);
  6622. iprot_->readMessageEnd();
  6623. iprot_->getTransport()->readEnd();
  6624. throw x;
  6625. }
  6626. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6627. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6628. iprot_->readMessageEnd();
  6629. iprot_->getTransport()->readEnd();
  6630. }
  6631. if (fname.compare("multiget_count") != 0) {
  6632. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6633. iprot_->readMessageEnd();
  6634. iprot_->getTransport()->readEnd();
  6635. }
  6636. Cassandra_multiget_count_presult result;
  6637. result.success = &_return;
  6638. result.read(iprot_);
  6639. iprot_->readMessageEnd();
  6640. iprot_->getTransport()->readEnd();
  6641. if (result.__isset.success) {
  6642. // _return pointer has now been filled
  6643. return;
  6644. }
  6645. if (result.__isset.ire) {
  6646. throw result.ire;
  6647. }
  6648. if (result.__isset.ue) {
  6649. throw result.ue;
  6650. }
  6651. if (result.__isset.te) {
  6652. throw result.te;
  6653. }
  6654. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "multiget_count failed: unknown result");
  6655. }
  6656. void CassandraClient::get_range_slices(std::vector<KeySlice> & _return, const ColumnParent& column_parent, const SlicePredicate& predicate, const KeyRange& range, const ConsistencyLevel::type consistency_level)
  6657. {
  6658. send_get_range_slices(column_parent, predicate, range, consistency_level);
  6659. recv_get_range_slices(_return);
  6660. }
  6661. void CassandraClient::send_get_range_slices(const ColumnParent& column_parent, const SlicePredicate& predicate, const KeyRange& range, const ConsistencyLevel::type consistency_level)
  6662. {
  6663. int32_t cseqid = 0;
  6664. oprot_->writeMessageBegin("get_range_slices", ::apache::thrift::protocol::T_CALL, cseqid);
  6665. Cassandra_get_range_slices_pargs args;
  6666. args.column_parent = &column_parent;
  6667. args.predicate = &predicate;
  6668. args.range = &range;
  6669. args.consistency_level = &consistency_level;
  6670. args.write(oprot_);
  6671. oprot_->writeMessageEnd();
  6672. oprot_->getTransport()->writeEnd();
  6673. oprot_->getTransport()->flush();
  6674. }
  6675. void CassandraClient::recv_get_range_slices(std::vector<KeySlice> & _return)
  6676. {
  6677. int32_t rseqid = 0;
  6678. std::string fname;
  6679. ::apache::thrift::protocol::TMessageType mtype;
  6680. iprot_->readMessageBegin(fname, mtype, rseqid);
  6681. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6682. ::apache::thrift::TApplicationException x;
  6683. x.read(iprot_);
  6684. iprot_->readMessageEnd();
  6685. iprot_->getTransport()->readEnd();
  6686. throw x;
  6687. }
  6688. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6689. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6690. iprot_->readMessageEnd();
  6691. iprot_->getTransport()->readEnd();
  6692. }
  6693. if (fname.compare("get_range_slices") != 0) {
  6694. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6695. iprot_->readMessageEnd();
  6696. iprot_->getTransport()->readEnd();
  6697. }
  6698. Cassandra_get_range_slices_presult result;
  6699. result.success = &_return;
  6700. result.read(iprot_);
  6701. iprot_->readMessageEnd();
  6702. iprot_->getTransport()->readEnd();
  6703. if (result.__isset.success) {
  6704. // _return pointer has now been filled
  6705. return;
  6706. }
  6707. if (result.__isset.ire) {
  6708. throw result.ire;
  6709. }
  6710. if (result.__isset.ue) {
  6711. throw result.ue;
  6712. }
  6713. if (result.__isset.te) {
  6714. throw result.te;
  6715. }
  6716. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_range_slices failed: unknown result");
  6717. }
  6718. void CassandraClient::get_indexed_slices(std::vector<KeySlice> & _return, const ColumnParent& column_parent, const IndexClause& index_clause, const SlicePredicate& column_predicate, const ConsistencyLevel::type consistency_level)
  6719. {
  6720. send_get_indexed_slices(column_parent, index_clause, column_predicate, consistency_level);
  6721. recv_get_indexed_slices(_return);
  6722. }
  6723. void CassandraClient::send_get_indexed_slices(const ColumnParent& column_parent, const IndexClause& index_clause, const SlicePredicate& column_predicate, const ConsistencyLevel::type consistency_level)
  6724. {
  6725. int32_t cseqid = 0;
  6726. oprot_->writeMessageBegin("get_indexed_slices", ::apache::thrift::protocol::T_CALL, cseqid);
  6727. Cassandra_get_indexed_slices_pargs args;
  6728. args.column_parent = &column_parent;
  6729. args.index_clause = &index_clause;
  6730. args.column_predicate = &column_predicate;
  6731. args.consistency_level = &consistency_level;
  6732. args.write(oprot_);
  6733. oprot_->writeMessageEnd();
  6734. oprot_->getTransport()->writeEnd();
  6735. oprot_->getTransport()->flush();
  6736. }
  6737. void CassandraClient::recv_get_indexed_slices(std::vector<KeySlice> & _return)
  6738. {
  6739. int32_t rseqid = 0;
  6740. std::string fname;
  6741. ::apache::thrift::protocol::TMessageType mtype;
  6742. iprot_->readMessageBegin(fname, mtype, rseqid);
  6743. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6744. ::apache::thrift::TApplicationException x;
  6745. x.read(iprot_);
  6746. iprot_->readMessageEnd();
  6747. iprot_->getTransport()->readEnd();
  6748. throw x;
  6749. }
  6750. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6751. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6752. iprot_->readMessageEnd();
  6753. iprot_->getTransport()->readEnd();
  6754. }
  6755. if (fname.compare("get_indexed_slices") != 0) {
  6756. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6757. iprot_->readMessageEnd();
  6758. iprot_->getTransport()->readEnd();
  6759. }
  6760. Cassandra_get_indexed_slices_presult result;
  6761. result.success = &_return;
  6762. result.read(iprot_);
  6763. iprot_->readMessageEnd();
  6764. iprot_->getTransport()->readEnd();
  6765. if (result.__isset.success) {
  6766. // _return pointer has now been filled
  6767. return;
  6768. }
  6769. if (result.__isset.ire) {
  6770. throw result.ire;
  6771. }
  6772. if (result.__isset.ue) {
  6773. throw result.ue;
  6774. }
  6775. if (result.__isset.te) {
  6776. throw result.te;
  6777. }
  6778. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_indexed_slices failed: unknown result");
  6779. }
  6780. void CassandraClient::insert(const std::string& key, const ColumnParent& column_parent, const Column& column, const ConsistencyLevel::type consistency_level)
  6781. {
  6782. send_insert(key, column_parent, column, consistency_level);
  6783. recv_insert();
  6784. }
  6785. void CassandraClient::send_insert(const std::string& key, const ColumnParent& column_parent, const Column& column, const ConsistencyLevel::type consistency_level)
  6786. {
  6787. int32_t cseqid = 0;
  6788. oprot_->writeMessageBegin("insert", ::apache::thrift::protocol::T_CALL, cseqid);
  6789. Cassandra_insert_pargs args;
  6790. args.key = &key;
  6791. args.column_parent = &column_parent;
  6792. args.column = &column;
  6793. args.consistency_level = &consistency_level;
  6794. args.write(oprot_);
  6795. oprot_->writeMessageEnd();
  6796. oprot_->getTransport()->writeEnd();
  6797. oprot_->getTransport()->flush();
  6798. }
  6799. void CassandraClient::recv_insert()
  6800. {
  6801. int32_t rseqid = 0;
  6802. std::string fname;
  6803. ::apache::thrift::protocol::TMessageType mtype;
  6804. iprot_->readMessageBegin(fname, mtype, rseqid);
  6805. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6806. ::apache::thrift::TApplicationException x;
  6807. x.read(iprot_);
  6808. iprot_->readMessageEnd();
  6809. iprot_->getTransport()->readEnd();
  6810. throw x;
  6811. }
  6812. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6813. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6814. iprot_->readMessageEnd();
  6815. iprot_->getTransport()->readEnd();
  6816. }
  6817. if (fname.compare("insert") != 0) {
  6818. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6819. iprot_->readMessageEnd();
  6820. iprot_->getTransport()->readEnd();
  6821. }
  6822. Cassandra_insert_presult result;
  6823. result.read(iprot_);
  6824. iprot_->readMessageEnd();
  6825. iprot_->getTransport()->readEnd();
  6826. if (result.__isset.ire) {
  6827. throw result.ire;
  6828. }
  6829. if (result.__isset.ue) {
  6830. throw result.ue;
  6831. }
  6832. if (result.__isset.te) {
  6833. throw result.te;
  6834. }
  6835. return;
  6836. }
  6837. void CassandraClient::add(const std::string& key, const ColumnParent& column_parent, const CounterColumn& column, const ConsistencyLevel::type consistency_level)
  6838. {
  6839. send_add(key, column_parent, column, consistency_level);
  6840. recv_add();
  6841. }
  6842. void CassandraClient::send_add(const std::string& key, const ColumnParent& column_parent, const CounterColumn& column, const ConsistencyLevel::type consistency_level)
  6843. {
  6844. int32_t cseqid = 0;
  6845. oprot_->writeMessageBegin("add", ::apache::thrift::protocol::T_CALL, cseqid);
  6846. Cassandra_add_pargs args;
  6847. args.key = &key;
  6848. args.column_parent = &column_parent;
  6849. args.column = &column;
  6850. args.consistency_level = &consistency_level;
  6851. args.write(oprot_);
  6852. oprot_->writeMessageEnd();
  6853. oprot_->getTransport()->writeEnd();
  6854. oprot_->getTransport()->flush();
  6855. }
  6856. void CassandraClient::recv_add()
  6857. {
  6858. int32_t rseqid = 0;
  6859. std::string fname;
  6860. ::apache::thrift::protocol::TMessageType mtype;
  6861. iprot_->readMessageBegin(fname, mtype, rseqid);
  6862. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6863. ::apache::thrift::TApplicationException x;
  6864. x.read(iprot_);
  6865. iprot_->readMessageEnd();
  6866. iprot_->getTransport()->readEnd();
  6867. throw x;
  6868. }
  6869. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6870. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6871. iprot_->readMessageEnd();
  6872. iprot_->getTransport()->readEnd();
  6873. }
  6874. if (fname.compare("add") != 0) {
  6875. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6876. iprot_->readMessageEnd();
  6877. iprot_->getTransport()->readEnd();
  6878. }
  6879. Cassandra_add_presult result;
  6880. result.read(iprot_);
  6881. iprot_->readMessageEnd();
  6882. iprot_->getTransport()->readEnd();
  6883. if (result.__isset.ire) {
  6884. throw result.ire;
  6885. }
  6886. if (result.__isset.ue) {
  6887. throw result.ue;
  6888. }
  6889. if (result.__isset.te) {
  6890. throw result.te;
  6891. }
  6892. return;
  6893. }
  6894. void CassandraClient::remove(const std::string& key, const ColumnPath& column_path, const int64_t timestamp, const ConsistencyLevel::type consistency_level)
  6895. {
  6896. send_remove(key, column_path, timestamp, consistency_level);
  6897. recv_remove();
  6898. }
  6899. void CassandraClient::send_remove(const std::string& key, const ColumnPath& column_path, const int64_t timestamp, const ConsistencyLevel::type consistency_level)
  6900. {
  6901. int32_t cseqid = 0;
  6902. oprot_->writeMessageBegin("remove", ::apache::thrift::protocol::T_CALL, cseqid);
  6903. Cassandra_remove_pargs args;
  6904. args.key = &key;
  6905. args.column_path = &column_path;
  6906. args.timestamp = &timestamp;
  6907. args.consistency_level = &consistency_level;
  6908. args.write(oprot_);
  6909. oprot_->writeMessageEnd();
  6910. oprot_->getTransport()->writeEnd();
  6911. oprot_->getTransport()->flush();
  6912. }
  6913. void CassandraClient::recv_remove()
  6914. {
  6915. int32_t rseqid = 0;
  6916. std::string fname;
  6917. ::apache::thrift::protocol::TMessageType mtype;
  6918. iprot_->readMessageBegin(fname, mtype, rseqid);
  6919. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6920. ::apache::thrift::TApplicationException x;
  6921. x.read(iprot_);
  6922. iprot_->readMessageEnd();
  6923. iprot_->getTransport()->readEnd();
  6924. throw x;
  6925. }
  6926. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6927. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6928. iprot_->readMessageEnd();
  6929. iprot_->getTransport()->readEnd();
  6930. }
  6931. if (fname.compare("remove") != 0) {
  6932. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6933. iprot_->readMessageEnd();
  6934. iprot_->getTransport()->readEnd();
  6935. }
  6936. Cassandra_remove_presult result;
  6937. result.read(iprot_);
  6938. iprot_->readMessageEnd();
  6939. iprot_->getTransport()->readEnd();
  6940. if (result.__isset.ire) {
  6941. throw result.ire;
  6942. }
  6943. if (result.__isset.ue) {
  6944. throw result.ue;
  6945. }
  6946. if (result.__isset.te) {
  6947. throw result.te;
  6948. }
  6949. return;
  6950. }
  6951. void CassandraClient::remove_counter(const std::string& key, const ColumnPath& path, const ConsistencyLevel::type consistency_level)
  6952. {
  6953. send_remove_counter(key, path, consistency_level);
  6954. recv_remove_counter();
  6955. }
  6956. void CassandraClient::send_remove_counter(const std::string& key, const ColumnPath& path, const ConsistencyLevel::type consistency_level)
  6957. {
  6958. int32_t cseqid = 0;
  6959. oprot_->writeMessageBegin("remove_counter", ::apache::thrift::protocol::T_CALL, cseqid);
  6960. Cassandra_remove_counter_pargs args;
  6961. args.key = &key;
  6962. args.path = &path;
  6963. args.consistency_level = &consistency_level;
  6964. args.write(oprot_);
  6965. oprot_->writeMessageEnd();
  6966. oprot_->getTransport()->writeEnd();
  6967. oprot_->getTransport()->flush();
  6968. }
  6969. void CassandraClient::recv_remove_counter()
  6970. {
  6971. int32_t rseqid = 0;
  6972. std::string fname;
  6973. ::apache::thrift::protocol::TMessageType mtype;
  6974. iprot_->readMessageBegin(fname, mtype, rseqid);
  6975. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  6976. ::apache::thrift::TApplicationException x;
  6977. x.read(iprot_);
  6978. iprot_->readMessageEnd();
  6979. iprot_->getTransport()->readEnd();
  6980. throw x;
  6981. }
  6982. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  6983. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6984. iprot_->readMessageEnd();
  6985. iprot_->getTransport()->readEnd();
  6986. }
  6987. if (fname.compare("remove_counter") != 0) {
  6988. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  6989. iprot_->readMessageEnd();
  6990. iprot_->getTransport()->readEnd();
  6991. }
  6992. Cassandra_remove_counter_presult result;
  6993. result.read(iprot_);
  6994. iprot_->readMessageEnd();
  6995. iprot_->getTransport()->readEnd();
  6996. if (result.__isset.ire) {
  6997. throw result.ire;
  6998. }
  6999. if (result.__isset.ue) {
  7000. throw result.ue;
  7001. }
  7002. if (result.__isset.te) {
  7003. throw result.te;
  7004. }
  7005. return;
  7006. }
  7007. void CassandraClient::batch_mutate(const std::map<std::string, std::map<std::string, std::vector<Mutation> > > & mutation_map, const ConsistencyLevel::type consistency_level)
  7008. {
  7009. send_batch_mutate(mutation_map, consistency_level);
  7010. recv_batch_mutate();
  7011. }
  7012. void CassandraClient::send_batch_mutate(const std::map<std::string, std::map<std::string, std::vector<Mutation> > > & mutation_map, const ConsistencyLevel::type consistency_level)
  7013. {
  7014. int32_t cseqid = 0;
  7015. oprot_->writeMessageBegin("batch_mutate", ::apache::thrift::protocol::T_CALL, cseqid);
  7016. Cassandra_batch_mutate_pargs args;
  7017. args.mutation_map = &mutation_map;
  7018. args.consistency_level = &consistency_level;
  7019. args.write(oprot_);
  7020. oprot_->writeMessageEnd();
  7021. oprot_->getTransport()->writeEnd();
  7022. oprot_->getTransport()->flush();
  7023. }
  7024. void CassandraClient::recv_batch_mutate()
  7025. {
  7026. int32_t rseqid = 0;
  7027. std::string fname;
  7028. ::apache::thrift::protocol::TMessageType mtype;
  7029. iprot_->readMessageBegin(fname, mtype, rseqid);
  7030. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7031. ::apache::thrift::TApplicationException x;
  7032. x.read(iprot_);
  7033. iprot_->readMessageEnd();
  7034. iprot_->getTransport()->readEnd();
  7035. throw x;
  7036. }
  7037. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7038. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7039. iprot_->readMessageEnd();
  7040. iprot_->getTransport()->readEnd();
  7041. }
  7042. if (fname.compare("batch_mutate") != 0) {
  7043. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7044. iprot_->readMessageEnd();
  7045. iprot_->getTransport()->readEnd();
  7046. }
  7047. Cassandra_batch_mutate_presult result;
  7048. result.read(iprot_);
  7049. iprot_->readMessageEnd();
  7050. iprot_->getTransport()->readEnd();
  7051. if (result.__isset.ire) {
  7052. throw result.ire;
  7053. }
  7054. if (result.__isset.ue) {
  7055. throw result.ue;
  7056. }
  7057. if (result.__isset.te) {
  7058. throw result.te;
  7059. }
  7060. return;
  7061. }
  7062. void CassandraClient::truncate(const std::string& cfname)
  7063. {
  7064. send_truncate(cfname);
  7065. recv_truncate();
  7066. }
  7067. void CassandraClient::send_truncate(const std::string& cfname)
  7068. {
  7069. int32_t cseqid = 0;
  7070. oprot_->writeMessageBegin("truncate", ::apache::thrift::protocol::T_CALL, cseqid);
  7071. Cassandra_truncate_pargs args;
  7072. args.cfname = &cfname;
  7073. args.write(oprot_);
  7074. oprot_->writeMessageEnd();
  7075. oprot_->getTransport()->writeEnd();
  7076. oprot_->getTransport()->flush();
  7077. }
  7078. void CassandraClient::recv_truncate()
  7079. {
  7080. int32_t rseqid = 0;
  7081. std::string fname;
  7082. ::apache::thrift::protocol::TMessageType mtype;
  7083. iprot_->readMessageBegin(fname, mtype, rseqid);
  7084. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7085. ::apache::thrift::TApplicationException x;
  7086. x.read(iprot_);
  7087. iprot_->readMessageEnd();
  7088. iprot_->getTransport()->readEnd();
  7089. throw x;
  7090. }
  7091. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7092. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7093. iprot_->readMessageEnd();
  7094. iprot_->getTransport()->readEnd();
  7095. }
  7096. if (fname.compare("truncate") != 0) {
  7097. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7098. iprot_->readMessageEnd();
  7099. iprot_->getTransport()->readEnd();
  7100. }
  7101. Cassandra_truncate_presult result;
  7102. result.read(iprot_);
  7103. iprot_->readMessageEnd();
  7104. iprot_->getTransport()->readEnd();
  7105. if (result.__isset.ire) {
  7106. throw result.ire;
  7107. }
  7108. if (result.__isset.ue) {
  7109. throw result.ue;
  7110. }
  7111. return;
  7112. }
  7113. void CassandraClient::describe_schema_versions(std::map<std::string, std::vector<std::string> > & _return)
  7114. {
  7115. send_describe_schema_versions();
  7116. recv_describe_schema_versions(_return);
  7117. }
  7118. void CassandraClient::send_describe_schema_versions()
  7119. {
  7120. int32_t cseqid = 0;
  7121. oprot_->writeMessageBegin("describe_schema_versions", ::apache::thrift::protocol::T_CALL, cseqid);
  7122. Cassandra_describe_schema_versions_pargs args;
  7123. args.write(oprot_);
  7124. oprot_->writeMessageEnd();
  7125. oprot_->getTransport()->writeEnd();
  7126. oprot_->getTransport()->flush();
  7127. }
  7128. void CassandraClient::recv_describe_schema_versions(std::map<std::string, std::vector<std::string> > & _return)
  7129. {
  7130. int32_t rseqid = 0;
  7131. std::string fname;
  7132. ::apache::thrift::protocol::TMessageType mtype;
  7133. iprot_->readMessageBegin(fname, mtype, rseqid);
  7134. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7135. ::apache::thrift::TApplicationException x;
  7136. x.read(iprot_);
  7137. iprot_->readMessageEnd();
  7138. iprot_->getTransport()->readEnd();
  7139. throw x;
  7140. }
  7141. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7142. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7143. iprot_->readMessageEnd();
  7144. iprot_->getTransport()->readEnd();
  7145. }
  7146. if (fname.compare("describe_schema_versions") != 0) {
  7147. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7148. iprot_->readMessageEnd();
  7149. iprot_->getTransport()->readEnd();
  7150. }
  7151. Cassandra_describe_schema_versions_presult result;
  7152. result.success = &_return;
  7153. result.read(iprot_);
  7154. iprot_->readMessageEnd();
  7155. iprot_->getTransport()->readEnd();
  7156. if (result.__isset.success) {
  7157. // _return pointer has now been filled
  7158. return;
  7159. }
  7160. if (result.__isset.ire) {
  7161. throw result.ire;
  7162. }
  7163. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_schema_versions failed: unknown result");
  7164. }
  7165. void CassandraClient::describe_keyspaces(std::vector<KsDef> & _return)
  7166. {
  7167. send_describe_keyspaces();
  7168. recv_describe_keyspaces(_return);
  7169. }
  7170. void CassandraClient::send_describe_keyspaces()
  7171. {
  7172. int32_t cseqid = 0;
  7173. oprot_->writeMessageBegin("describe_keyspaces", ::apache::thrift::protocol::T_CALL, cseqid);
  7174. Cassandra_describe_keyspaces_pargs args;
  7175. args.write(oprot_);
  7176. oprot_->writeMessageEnd();
  7177. oprot_->getTransport()->writeEnd();
  7178. oprot_->getTransport()->flush();
  7179. }
  7180. void CassandraClient::recv_describe_keyspaces(std::vector<KsDef> & _return)
  7181. {
  7182. int32_t rseqid = 0;
  7183. std::string fname;
  7184. ::apache::thrift::protocol::TMessageType mtype;
  7185. iprot_->readMessageBegin(fname, mtype, rseqid);
  7186. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7187. ::apache::thrift::TApplicationException x;
  7188. x.read(iprot_);
  7189. iprot_->readMessageEnd();
  7190. iprot_->getTransport()->readEnd();
  7191. throw x;
  7192. }
  7193. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7194. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7195. iprot_->readMessageEnd();
  7196. iprot_->getTransport()->readEnd();
  7197. }
  7198. if (fname.compare("describe_keyspaces") != 0) {
  7199. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7200. iprot_->readMessageEnd();
  7201. iprot_->getTransport()->readEnd();
  7202. }
  7203. Cassandra_describe_keyspaces_presult result;
  7204. result.success = &_return;
  7205. result.read(iprot_);
  7206. iprot_->readMessageEnd();
  7207. iprot_->getTransport()->readEnd();
  7208. if (result.__isset.success) {
  7209. // _return pointer has now been filled
  7210. return;
  7211. }
  7212. if (result.__isset.ire) {
  7213. throw result.ire;
  7214. }
  7215. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_keyspaces failed: unknown result");
  7216. }
  7217. void CassandraClient::describe_cluster_name(std::string& _return)
  7218. {
  7219. send_describe_cluster_name();
  7220. recv_describe_cluster_name(_return);
  7221. }
  7222. void CassandraClient::send_describe_cluster_name()
  7223. {
  7224. int32_t cseqid = 0;
  7225. oprot_->writeMessageBegin("describe_cluster_name", ::apache::thrift::protocol::T_CALL, cseqid);
  7226. Cassandra_describe_cluster_name_pargs args;
  7227. args.write(oprot_);
  7228. oprot_->writeMessageEnd();
  7229. oprot_->getTransport()->writeEnd();
  7230. oprot_->getTransport()->flush();
  7231. }
  7232. void CassandraClient::recv_describe_cluster_name(std::string& _return)
  7233. {
  7234. int32_t rseqid = 0;
  7235. std::string fname;
  7236. ::apache::thrift::protocol::TMessageType mtype;
  7237. iprot_->readMessageBegin(fname, mtype, rseqid);
  7238. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7239. ::apache::thrift::TApplicationException x;
  7240. x.read(iprot_);
  7241. iprot_->readMessageEnd();
  7242. iprot_->getTransport()->readEnd();
  7243. throw x;
  7244. }
  7245. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7246. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7247. iprot_->readMessageEnd();
  7248. iprot_->getTransport()->readEnd();
  7249. }
  7250. if (fname.compare("describe_cluster_name") != 0) {
  7251. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7252. iprot_->readMessageEnd();
  7253. iprot_->getTransport()->readEnd();
  7254. }
  7255. Cassandra_describe_cluster_name_presult result;
  7256. result.success = &_return;
  7257. result.read(iprot_);
  7258. iprot_->readMessageEnd();
  7259. iprot_->getTransport()->readEnd();
  7260. if (result.__isset.success) {
  7261. // _return pointer has now been filled
  7262. return;
  7263. }
  7264. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_cluster_name failed: unknown result");
  7265. }
  7266. void CassandraClient::describe_version(std::string& _return)
  7267. {
  7268. send_describe_version();
  7269. recv_describe_version(_return);
  7270. }
  7271. void CassandraClient::send_describe_version()
  7272. {
  7273. int32_t cseqid = 0;
  7274. oprot_->writeMessageBegin("describe_version", ::apache::thrift::protocol::T_CALL, cseqid);
  7275. Cassandra_describe_version_pargs args;
  7276. args.write(oprot_);
  7277. oprot_->writeMessageEnd();
  7278. oprot_->getTransport()->writeEnd();
  7279. oprot_->getTransport()->flush();
  7280. }
  7281. void CassandraClient::recv_describe_version(std::string& _return)
  7282. {
  7283. int32_t rseqid = 0;
  7284. std::string fname;
  7285. ::apache::thrift::protocol::TMessageType mtype;
  7286. iprot_->readMessageBegin(fname, mtype, rseqid);
  7287. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7288. ::apache::thrift::TApplicationException x;
  7289. x.read(iprot_);
  7290. iprot_->readMessageEnd();
  7291. iprot_->getTransport()->readEnd();
  7292. throw x;
  7293. }
  7294. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7295. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7296. iprot_->readMessageEnd();
  7297. iprot_->getTransport()->readEnd();
  7298. }
  7299. if (fname.compare("describe_version") != 0) {
  7300. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7301. iprot_->readMessageEnd();
  7302. iprot_->getTransport()->readEnd();
  7303. }
  7304. Cassandra_describe_version_presult result;
  7305. result.success = &_return;
  7306. result.read(iprot_);
  7307. iprot_->readMessageEnd();
  7308. iprot_->getTransport()->readEnd();
  7309. if (result.__isset.success) {
  7310. // _return pointer has now been filled
  7311. return;
  7312. }
  7313. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_version failed: unknown result");
  7314. }
  7315. void CassandraClient::describe_ring(std::vector<TokenRange> & _return, const std::string& keyspace)
  7316. {
  7317. send_describe_ring(keyspace);
  7318. recv_describe_ring(_return);
  7319. }
  7320. void CassandraClient::send_describe_ring(const std::string& keyspace)
  7321. {
  7322. int32_t cseqid = 0;
  7323. oprot_->writeMessageBegin("describe_ring", ::apache::thrift::protocol::T_CALL, cseqid);
  7324. Cassandra_describe_ring_pargs args;
  7325. args.keyspace = &keyspace;
  7326. args.write(oprot_);
  7327. oprot_->writeMessageEnd();
  7328. oprot_->getTransport()->writeEnd();
  7329. oprot_->getTransport()->flush();
  7330. }
  7331. void CassandraClient::recv_describe_ring(std::vector<TokenRange> & _return)
  7332. {
  7333. int32_t rseqid = 0;
  7334. std::string fname;
  7335. ::apache::thrift::protocol::TMessageType mtype;
  7336. iprot_->readMessageBegin(fname, mtype, rseqid);
  7337. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7338. ::apache::thrift::TApplicationException x;
  7339. x.read(iprot_);
  7340. iprot_->readMessageEnd();
  7341. iprot_->getTransport()->readEnd();
  7342. throw x;
  7343. }
  7344. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7345. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7346. iprot_->readMessageEnd();
  7347. iprot_->getTransport()->readEnd();
  7348. }
  7349. if (fname.compare("describe_ring") != 0) {
  7350. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7351. iprot_->readMessageEnd();
  7352. iprot_->getTransport()->readEnd();
  7353. }
  7354. Cassandra_describe_ring_presult result;
  7355. result.success = &_return;
  7356. result.read(iprot_);
  7357. iprot_->readMessageEnd();
  7358. iprot_->getTransport()->readEnd();
  7359. if (result.__isset.success) {
  7360. // _return pointer has now been filled
  7361. return;
  7362. }
  7363. if (result.__isset.ire) {
  7364. throw result.ire;
  7365. }
  7366. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_ring failed: unknown result");
  7367. }
  7368. void CassandraClient::describe_partitioner(std::string& _return)
  7369. {
  7370. send_describe_partitioner();
  7371. recv_describe_partitioner(_return);
  7372. }
  7373. void CassandraClient::send_describe_partitioner()
  7374. {
  7375. int32_t cseqid = 0;
  7376. oprot_->writeMessageBegin("describe_partitioner", ::apache::thrift::protocol::T_CALL, cseqid);
  7377. Cassandra_describe_partitioner_pargs args;
  7378. args.write(oprot_);
  7379. oprot_->writeMessageEnd();
  7380. oprot_->getTransport()->writeEnd();
  7381. oprot_->getTransport()->flush();
  7382. }
  7383. void CassandraClient::recv_describe_partitioner(std::string& _return)
  7384. {
  7385. int32_t rseqid = 0;
  7386. std::string fname;
  7387. ::apache::thrift::protocol::TMessageType mtype;
  7388. iprot_->readMessageBegin(fname, mtype, rseqid);
  7389. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7390. ::apache::thrift::TApplicationException x;
  7391. x.read(iprot_);
  7392. iprot_->readMessageEnd();
  7393. iprot_->getTransport()->readEnd();
  7394. throw x;
  7395. }
  7396. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7397. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7398. iprot_->readMessageEnd();
  7399. iprot_->getTransport()->readEnd();
  7400. }
  7401. if (fname.compare("describe_partitioner") != 0) {
  7402. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7403. iprot_->readMessageEnd();
  7404. iprot_->getTransport()->readEnd();
  7405. }
  7406. Cassandra_describe_partitioner_presult result;
  7407. result.success = &_return;
  7408. result.read(iprot_);
  7409. iprot_->readMessageEnd();
  7410. iprot_->getTransport()->readEnd();
  7411. if (result.__isset.success) {
  7412. // _return pointer has now been filled
  7413. return;
  7414. }
  7415. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_partitioner failed: unknown result");
  7416. }
  7417. void CassandraClient::describe_snitch(std::string& _return)
  7418. {
  7419. send_describe_snitch();
  7420. recv_describe_snitch(_return);
  7421. }
  7422. void CassandraClient::send_describe_snitch()
  7423. {
  7424. int32_t cseqid = 0;
  7425. oprot_->writeMessageBegin("describe_snitch", ::apache::thrift::protocol::T_CALL, cseqid);
  7426. Cassandra_describe_snitch_pargs args;
  7427. args.write(oprot_);
  7428. oprot_->writeMessageEnd();
  7429. oprot_->getTransport()->writeEnd();
  7430. oprot_->getTransport()->flush();
  7431. }
  7432. void CassandraClient::recv_describe_snitch(std::string& _return)
  7433. {
  7434. int32_t rseqid = 0;
  7435. std::string fname;
  7436. ::apache::thrift::protocol::TMessageType mtype;
  7437. iprot_->readMessageBegin(fname, mtype, rseqid);
  7438. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7439. ::apache::thrift::TApplicationException x;
  7440. x.read(iprot_);
  7441. iprot_->readMessageEnd();
  7442. iprot_->getTransport()->readEnd();
  7443. throw x;
  7444. }
  7445. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7446. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7447. iprot_->readMessageEnd();
  7448. iprot_->getTransport()->readEnd();
  7449. }
  7450. if (fname.compare("describe_snitch") != 0) {
  7451. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7452. iprot_->readMessageEnd();
  7453. iprot_->getTransport()->readEnd();
  7454. }
  7455. Cassandra_describe_snitch_presult result;
  7456. result.success = &_return;
  7457. result.read(iprot_);
  7458. iprot_->readMessageEnd();
  7459. iprot_->getTransport()->readEnd();
  7460. if (result.__isset.success) {
  7461. // _return pointer has now been filled
  7462. return;
  7463. }
  7464. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_snitch failed: unknown result");
  7465. }
  7466. void CassandraClient::describe_keyspace(KsDef& _return, const std::string& keyspace)
  7467. {
  7468. send_describe_keyspace(keyspace);
  7469. recv_describe_keyspace(_return);
  7470. }
  7471. void CassandraClient::send_describe_keyspace(const std::string& keyspace)
  7472. {
  7473. int32_t cseqid = 0;
  7474. oprot_->writeMessageBegin("describe_keyspace", ::apache::thrift::protocol::T_CALL, cseqid);
  7475. Cassandra_describe_keyspace_pargs args;
  7476. args.keyspace = &keyspace;
  7477. args.write(oprot_);
  7478. oprot_->writeMessageEnd();
  7479. oprot_->getTransport()->writeEnd();
  7480. oprot_->getTransport()->flush();
  7481. }
  7482. void CassandraClient::recv_describe_keyspace(KsDef& _return)
  7483. {
  7484. int32_t rseqid = 0;
  7485. std::string fname;
  7486. ::apache::thrift::protocol::TMessageType mtype;
  7487. iprot_->readMessageBegin(fname, mtype, rseqid);
  7488. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7489. ::apache::thrift::TApplicationException x;
  7490. x.read(iprot_);
  7491. iprot_->readMessageEnd();
  7492. iprot_->getTransport()->readEnd();
  7493. throw x;
  7494. }
  7495. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7496. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7497. iprot_->readMessageEnd();
  7498. iprot_->getTransport()->readEnd();
  7499. }
  7500. if (fname.compare("describe_keyspace") != 0) {
  7501. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7502. iprot_->readMessageEnd();
  7503. iprot_->getTransport()->readEnd();
  7504. }
  7505. Cassandra_describe_keyspace_presult result;
  7506. result.success = &_return;
  7507. result.read(iprot_);
  7508. iprot_->readMessageEnd();
  7509. iprot_->getTransport()->readEnd();
  7510. if (result.__isset.success) {
  7511. // _return pointer has now been filled
  7512. return;
  7513. }
  7514. if (result.__isset.nfe) {
  7515. throw result.nfe;
  7516. }
  7517. if (result.__isset.ire) {
  7518. throw result.ire;
  7519. }
  7520. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_keyspace failed: unknown result");
  7521. }
  7522. void CassandraClient::describe_splits(std::vector<std::string> & _return, const std::string& cfName, const std::string& start_token, const std::string& end_token, const int32_t keys_per_split)
  7523. {
  7524. send_describe_splits(cfName, start_token, end_token, keys_per_split);
  7525. recv_describe_splits(_return);
  7526. }
  7527. void CassandraClient::send_describe_splits(const std::string& cfName, const std::string& start_token, const std::string& end_token, const int32_t keys_per_split)
  7528. {
  7529. int32_t cseqid = 0;
  7530. oprot_->writeMessageBegin("describe_splits", ::apache::thrift::protocol::T_CALL, cseqid);
  7531. Cassandra_describe_splits_pargs args;
  7532. args.cfName = &cfName;
  7533. args.start_token = &start_token;
  7534. args.end_token = &end_token;
  7535. args.keys_per_split = &keys_per_split;
  7536. args.write(oprot_);
  7537. oprot_->writeMessageEnd();
  7538. oprot_->getTransport()->writeEnd();
  7539. oprot_->getTransport()->flush();
  7540. }
  7541. void CassandraClient::recv_describe_splits(std::vector<std::string> & _return)
  7542. {
  7543. int32_t rseqid = 0;
  7544. std::string fname;
  7545. ::apache::thrift::protocol::TMessageType mtype;
  7546. iprot_->readMessageBegin(fname, mtype, rseqid);
  7547. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7548. ::apache::thrift::TApplicationException x;
  7549. x.read(iprot_);
  7550. iprot_->readMessageEnd();
  7551. iprot_->getTransport()->readEnd();
  7552. throw x;
  7553. }
  7554. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7555. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7556. iprot_->readMessageEnd();
  7557. iprot_->getTransport()->readEnd();
  7558. }
  7559. if (fname.compare("describe_splits") != 0) {
  7560. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7561. iprot_->readMessageEnd();
  7562. iprot_->getTransport()->readEnd();
  7563. }
  7564. Cassandra_describe_splits_presult result;
  7565. result.success = &_return;
  7566. result.read(iprot_);
  7567. iprot_->readMessageEnd();
  7568. iprot_->getTransport()->readEnd();
  7569. if (result.__isset.success) {
  7570. // _return pointer has now been filled
  7571. return;
  7572. }
  7573. if (result.__isset.ire) {
  7574. throw result.ire;
  7575. }
  7576. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "describe_splits failed: unknown result");
  7577. }
  7578. void CassandraClient::system_add_column_family(std::string& _return, const CfDef& cf_def)
  7579. {
  7580. send_system_add_column_family(cf_def);
  7581. recv_system_add_column_family(_return);
  7582. }
  7583. void CassandraClient::send_system_add_column_family(const CfDef& cf_def)
  7584. {
  7585. int32_t cseqid = 0;
  7586. oprot_->writeMessageBegin("system_add_column_family", ::apache::thrift::protocol::T_CALL, cseqid);
  7587. Cassandra_system_add_column_family_pargs args;
  7588. args.cf_def = &cf_def;
  7589. args.write(oprot_);
  7590. oprot_->writeMessageEnd();
  7591. oprot_->getTransport()->writeEnd();
  7592. oprot_->getTransport()->flush();
  7593. }
  7594. void CassandraClient::recv_system_add_column_family(std::string& _return)
  7595. {
  7596. int32_t rseqid = 0;
  7597. std::string fname;
  7598. ::apache::thrift::protocol::TMessageType mtype;
  7599. iprot_->readMessageBegin(fname, mtype, rseqid);
  7600. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7601. ::apache::thrift::TApplicationException x;
  7602. x.read(iprot_);
  7603. iprot_->readMessageEnd();
  7604. iprot_->getTransport()->readEnd();
  7605. throw x;
  7606. }
  7607. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7608. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7609. iprot_->readMessageEnd();
  7610. iprot_->getTransport()->readEnd();
  7611. }
  7612. if (fname.compare("system_add_column_family") != 0) {
  7613. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7614. iprot_->readMessageEnd();
  7615. iprot_->getTransport()->readEnd();
  7616. }
  7617. Cassandra_system_add_column_family_presult result;
  7618. result.success = &_return;
  7619. result.read(iprot_);
  7620. iprot_->readMessageEnd();
  7621. iprot_->getTransport()->readEnd();
  7622. if (result.__isset.success) {
  7623. // _return pointer has now been filled
  7624. return;
  7625. }
  7626. if (result.__isset.ire) {
  7627. throw result.ire;
  7628. }
  7629. if (result.__isset.sde) {
  7630. throw result.sde;
  7631. }
  7632. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_add_column_family failed: unknown result");
  7633. }
  7634. void CassandraClient::system_drop_column_family(std::string& _return, const std::string& column_family)
  7635. {
  7636. send_system_drop_column_family(column_family);
  7637. recv_system_drop_column_family(_return);
  7638. }
  7639. void CassandraClient::send_system_drop_column_family(const std::string& column_family)
  7640. {
  7641. int32_t cseqid = 0;
  7642. oprot_->writeMessageBegin("system_drop_column_family", ::apache::thrift::protocol::T_CALL, cseqid);
  7643. Cassandra_system_drop_column_family_pargs args;
  7644. args.column_family = &column_family;
  7645. args.write(oprot_);
  7646. oprot_->writeMessageEnd();
  7647. oprot_->getTransport()->writeEnd();
  7648. oprot_->getTransport()->flush();
  7649. }
  7650. void CassandraClient::recv_system_drop_column_family(std::string& _return)
  7651. {
  7652. int32_t rseqid = 0;
  7653. std::string fname;
  7654. ::apache::thrift::protocol::TMessageType mtype;
  7655. iprot_->readMessageBegin(fname, mtype, rseqid);
  7656. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7657. ::apache::thrift::TApplicationException x;
  7658. x.read(iprot_);
  7659. iprot_->readMessageEnd();
  7660. iprot_->getTransport()->readEnd();
  7661. throw x;
  7662. }
  7663. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7664. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7665. iprot_->readMessageEnd();
  7666. iprot_->getTransport()->readEnd();
  7667. }
  7668. if (fname.compare("system_drop_column_family") != 0) {
  7669. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7670. iprot_->readMessageEnd();
  7671. iprot_->getTransport()->readEnd();
  7672. }
  7673. Cassandra_system_drop_column_family_presult result;
  7674. result.success = &_return;
  7675. result.read(iprot_);
  7676. iprot_->readMessageEnd();
  7677. iprot_->getTransport()->readEnd();
  7678. if (result.__isset.success) {
  7679. // _return pointer has now been filled
  7680. return;
  7681. }
  7682. if (result.__isset.ire) {
  7683. throw result.ire;
  7684. }
  7685. if (result.__isset.sde) {
  7686. throw result.sde;
  7687. }
  7688. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_drop_column_family failed: unknown result");
  7689. }
  7690. void CassandraClient::system_add_keyspace(std::string& _return, const KsDef& ks_def)
  7691. {
  7692. send_system_add_keyspace(ks_def);
  7693. recv_system_add_keyspace(_return);
  7694. }
  7695. void CassandraClient::send_system_add_keyspace(const KsDef& ks_def)
  7696. {
  7697. int32_t cseqid = 0;
  7698. oprot_->writeMessageBegin("system_add_keyspace", ::apache::thrift::protocol::T_CALL, cseqid);
  7699. Cassandra_system_add_keyspace_pargs args;
  7700. args.ks_def = &ks_def;
  7701. args.write(oprot_);
  7702. oprot_->writeMessageEnd();
  7703. oprot_->getTransport()->writeEnd();
  7704. oprot_->getTransport()->flush();
  7705. }
  7706. void CassandraClient::recv_system_add_keyspace(std::string& _return)
  7707. {
  7708. int32_t rseqid = 0;
  7709. std::string fname;
  7710. ::apache::thrift::protocol::TMessageType mtype;
  7711. iprot_->readMessageBegin(fname, mtype, rseqid);
  7712. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7713. ::apache::thrift::TApplicationException x;
  7714. x.read(iprot_);
  7715. iprot_->readMessageEnd();
  7716. iprot_->getTransport()->readEnd();
  7717. throw x;
  7718. }
  7719. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7720. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7721. iprot_->readMessageEnd();
  7722. iprot_->getTransport()->readEnd();
  7723. }
  7724. if (fname.compare("system_add_keyspace") != 0) {
  7725. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7726. iprot_->readMessageEnd();
  7727. iprot_->getTransport()->readEnd();
  7728. }
  7729. Cassandra_system_add_keyspace_presult result;
  7730. result.success = &_return;
  7731. result.read(iprot_);
  7732. iprot_->readMessageEnd();
  7733. iprot_->getTransport()->readEnd();
  7734. if (result.__isset.success) {
  7735. // _return pointer has now been filled
  7736. return;
  7737. }
  7738. if (result.__isset.ire) {
  7739. throw result.ire;
  7740. }
  7741. if (result.__isset.sde) {
  7742. throw result.sde;
  7743. }
  7744. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_add_keyspace failed: unknown result");
  7745. }
  7746. void CassandraClient::system_drop_keyspace(std::string& _return, const std::string& keyspace)
  7747. {
  7748. send_system_drop_keyspace(keyspace);
  7749. recv_system_drop_keyspace(_return);
  7750. }
  7751. void CassandraClient::send_system_drop_keyspace(const std::string& keyspace)
  7752. {
  7753. int32_t cseqid = 0;
  7754. oprot_->writeMessageBegin("system_drop_keyspace", ::apache::thrift::protocol::T_CALL, cseqid);
  7755. Cassandra_system_drop_keyspace_pargs args;
  7756. args.keyspace = &keyspace;
  7757. args.write(oprot_);
  7758. oprot_->writeMessageEnd();
  7759. oprot_->getTransport()->writeEnd();
  7760. oprot_->getTransport()->flush();
  7761. }
  7762. void CassandraClient::recv_system_drop_keyspace(std::string& _return)
  7763. {
  7764. int32_t rseqid = 0;
  7765. std::string fname;
  7766. ::apache::thrift::protocol::TMessageType mtype;
  7767. iprot_->readMessageBegin(fname, mtype, rseqid);
  7768. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7769. ::apache::thrift::TApplicationException x;
  7770. x.read(iprot_);
  7771. iprot_->readMessageEnd();
  7772. iprot_->getTransport()->readEnd();
  7773. throw x;
  7774. }
  7775. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7776. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7777. iprot_->readMessageEnd();
  7778. iprot_->getTransport()->readEnd();
  7779. }
  7780. if (fname.compare("system_drop_keyspace") != 0) {
  7781. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7782. iprot_->readMessageEnd();
  7783. iprot_->getTransport()->readEnd();
  7784. }
  7785. Cassandra_system_drop_keyspace_presult result;
  7786. result.success = &_return;
  7787. result.read(iprot_);
  7788. iprot_->readMessageEnd();
  7789. iprot_->getTransport()->readEnd();
  7790. if (result.__isset.success) {
  7791. // _return pointer has now been filled
  7792. return;
  7793. }
  7794. if (result.__isset.ire) {
  7795. throw result.ire;
  7796. }
  7797. if (result.__isset.sde) {
  7798. throw result.sde;
  7799. }
  7800. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_drop_keyspace failed: unknown result");
  7801. }
  7802. void CassandraClient::system_update_keyspace(std::string& _return, const KsDef& ks_def)
  7803. {
  7804. send_system_update_keyspace(ks_def);
  7805. recv_system_update_keyspace(_return);
  7806. }
  7807. void CassandraClient::send_system_update_keyspace(const KsDef& ks_def)
  7808. {
  7809. int32_t cseqid = 0;
  7810. oprot_->writeMessageBegin("system_update_keyspace", ::apache::thrift::protocol::T_CALL, cseqid);
  7811. Cassandra_system_update_keyspace_pargs args;
  7812. args.ks_def = &ks_def;
  7813. args.write(oprot_);
  7814. oprot_->writeMessageEnd();
  7815. oprot_->getTransport()->writeEnd();
  7816. oprot_->getTransport()->flush();
  7817. }
  7818. void CassandraClient::recv_system_update_keyspace(std::string& _return)
  7819. {
  7820. int32_t rseqid = 0;
  7821. std::string fname;
  7822. ::apache::thrift::protocol::TMessageType mtype;
  7823. iprot_->readMessageBegin(fname, mtype, rseqid);
  7824. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7825. ::apache::thrift::TApplicationException x;
  7826. x.read(iprot_);
  7827. iprot_->readMessageEnd();
  7828. iprot_->getTransport()->readEnd();
  7829. throw x;
  7830. }
  7831. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7832. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7833. iprot_->readMessageEnd();
  7834. iprot_->getTransport()->readEnd();
  7835. }
  7836. if (fname.compare("system_update_keyspace") != 0) {
  7837. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7838. iprot_->readMessageEnd();
  7839. iprot_->getTransport()->readEnd();
  7840. }
  7841. Cassandra_system_update_keyspace_presult result;
  7842. result.success = &_return;
  7843. result.read(iprot_);
  7844. iprot_->readMessageEnd();
  7845. iprot_->getTransport()->readEnd();
  7846. if (result.__isset.success) {
  7847. // _return pointer has now been filled
  7848. return;
  7849. }
  7850. if (result.__isset.ire) {
  7851. throw result.ire;
  7852. }
  7853. if (result.__isset.sde) {
  7854. throw result.sde;
  7855. }
  7856. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_update_keyspace failed: unknown result");
  7857. }
  7858. void CassandraClient::system_update_column_family(std::string& _return, const CfDef& cf_def)
  7859. {
  7860. send_system_update_column_family(cf_def);
  7861. recv_system_update_column_family(_return);
  7862. }
  7863. void CassandraClient::send_system_update_column_family(const CfDef& cf_def)
  7864. {
  7865. int32_t cseqid = 0;
  7866. oprot_->writeMessageBegin("system_update_column_family", ::apache::thrift::protocol::T_CALL, cseqid);
  7867. Cassandra_system_update_column_family_pargs args;
  7868. args.cf_def = &cf_def;
  7869. args.write(oprot_);
  7870. oprot_->writeMessageEnd();
  7871. oprot_->getTransport()->writeEnd();
  7872. oprot_->getTransport()->flush();
  7873. }
  7874. void CassandraClient::recv_system_update_column_family(std::string& _return)
  7875. {
  7876. int32_t rseqid = 0;
  7877. std::string fname;
  7878. ::apache::thrift::protocol::TMessageType mtype;
  7879. iprot_->readMessageBegin(fname, mtype, rseqid);
  7880. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7881. ::apache::thrift::TApplicationException x;
  7882. x.read(iprot_);
  7883. iprot_->readMessageEnd();
  7884. iprot_->getTransport()->readEnd();
  7885. throw x;
  7886. }
  7887. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7888. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7889. iprot_->readMessageEnd();
  7890. iprot_->getTransport()->readEnd();
  7891. }
  7892. if (fname.compare("system_update_column_family") != 0) {
  7893. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7894. iprot_->readMessageEnd();
  7895. iprot_->getTransport()->readEnd();
  7896. }
  7897. Cassandra_system_update_column_family_presult result;
  7898. result.success = &_return;
  7899. result.read(iprot_);
  7900. iprot_->readMessageEnd();
  7901. iprot_->getTransport()->readEnd();
  7902. if (result.__isset.success) {
  7903. // _return pointer has now been filled
  7904. return;
  7905. }
  7906. if (result.__isset.ire) {
  7907. throw result.ire;
  7908. }
  7909. if (result.__isset.sde) {
  7910. throw result.sde;
  7911. }
  7912. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "system_update_column_family failed: unknown result");
  7913. }
  7914. void CassandraClient::execute_cql_query(CqlResult& _return, const std::string& query, const Compression::type compression)
  7915. {
  7916. send_execute_cql_query(query, compression);
  7917. recv_execute_cql_query(_return);
  7918. }
  7919. void CassandraClient::send_execute_cql_query(const std::string& query, const Compression::type compression)
  7920. {
  7921. int32_t cseqid = 0;
  7922. oprot_->writeMessageBegin("execute_cql_query", ::apache::thrift::protocol::T_CALL, cseqid);
  7923. Cassandra_execute_cql_query_pargs args;
  7924. args.query = &query;
  7925. args.compression = &compression;
  7926. args.write(oprot_);
  7927. oprot_->writeMessageEnd();
  7928. oprot_->getTransport()->writeEnd();
  7929. oprot_->getTransport()->flush();
  7930. }
  7931. void CassandraClient::recv_execute_cql_query(CqlResult& _return)
  7932. {
  7933. int32_t rseqid = 0;
  7934. std::string fname;
  7935. ::apache::thrift::protocol::TMessageType mtype;
  7936. iprot_->readMessageBegin(fname, mtype, rseqid);
  7937. if (mtype == ::apache::thrift::protocol::T_EXCEPTION) {
  7938. ::apache::thrift::TApplicationException x;
  7939. x.read(iprot_);
  7940. iprot_->readMessageEnd();
  7941. iprot_->getTransport()->readEnd();
  7942. throw x;
  7943. }
  7944. if (mtype != ::apache::thrift::protocol::T_REPLY) {
  7945. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7946. iprot_->readMessageEnd();
  7947. iprot_->getTransport()->readEnd();
  7948. }
  7949. if (fname.compare("execute_cql_query") != 0) {
  7950. iprot_->skip(::apache::thrift::protocol::T_STRUCT);
  7951. iprot_->readMessageEnd();
  7952. iprot_->getTransport()->readEnd();
  7953. }
  7954. Cassandra_execute_cql_query_presult result;
  7955. result.success = &_return;
  7956. result.read(iprot_);
  7957. iprot_->readMessageEnd();
  7958. iprot_->getTransport()->readEnd();
  7959. if (result.__isset.success) {
  7960. // _return pointer has now been filled
  7961. return;
  7962. }
  7963. if (result.__isset.ire) {
  7964. throw result.ire;
  7965. }
  7966. if (result.__isset.ue) {
  7967. throw result.ue;
  7968. }
  7969. if (result.__isset.te) {
  7970. throw result.te;
  7971. }
  7972. if (result.__isset.sde) {
  7973. throw result.sde;
  7974. }
  7975. throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "execute_cql_query failed: unknown result");
  7976. }
  7977. bool CassandraProcessor::process(boost::shared_ptr< ::apache::thrift::protocol::TProtocol> piprot, boost::shared_ptr< ::apache::thrift::protocol::TProtocol> poprot, void* callContext) {
  7978. ::apache::thrift::protocol::TProtocol* iprot = piprot.get();
  7979. ::apache::thrift::protocol::TProtocol* oprot = poprot.get();
  7980. std::string fname;
  7981. ::apache::thrift::protocol::TMessageType mtype;
  7982. int32_t seqid;
  7983. iprot->readMessageBegin(fname, mtype, seqid);
  7984. if (mtype != ::apache::thrift::protocol::T_CALL && mtype != ::apache::thrift::protocol::T_ONEWAY) {
  7985. iprot->skip(::apache::thrift::protocol::T_STRUCT);
  7986. iprot->readMessageEnd();
  7987. iprot->getTransport()->readEnd();
  7988. ::apache::thrift::TApplicationException x(::apache::thrift::TApplicationException::INVALID_MESSAGE_TYPE);
  7989. oprot->writeMessageBegin(fname, ::apache::thrift::protocol::T_EXCEPTION, seqid);
  7990. x.write(oprot);
  7991. oprot->writeMessageEnd();
  7992. oprot->getTransport()->writeEnd();
  7993. oprot->getTransport()->flush();
  7994. return false;
  7995. }
  7996. return process_fn(iprot, oprot, fname, seqid, callContext);
  7997. }
  7998. bool CassandraProcessor::process_fn(::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, std::string& fname, int32_t seqid, void* callContext) {
  7999. std::map<std::string, void (CassandraProcessor::*)(int32_t, ::apache::thrift::protocol::TProtocol*, ::apache::thrift::protocol::TProtocol*, void*)>::iterator pfn;
  8000. pfn = processMap_.find(fname);
  8001. if (pfn == processMap_.end()) {
  8002. iprot->skip(::apache::thrift::protocol::T_STRUCT);
  8003. iprot->readMessageEnd();
  8004. iprot->getTransport()->readEnd();
  8005. ::apache::thrift::TApplicationException x(::apache::thrift::TApplicationException::UNKNOWN_METHOD, "Invalid method name: '"+fname+"'");
  8006. oprot->writeMessageBegin(fname, ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8007. x.write(oprot);
  8008. oprot->writeMessageEnd();
  8009. oprot->getTransport()->writeEnd();
  8010. oprot->getTransport()->flush();
  8011. return false;
  8012. }
  8013. (this->*(pfn->second))(seqid, iprot, oprot, callContext);
  8014. return true;
  8015. }
  8016. void CassandraProcessor::process_login(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8017. {
  8018. void* ctx = NULL;
  8019. if (eventHandler_.get() != NULL) {
  8020. ctx = eventHandler_->getContext("Cassandra.login", callContext);
  8021. }
  8022. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.login");
  8023. if (eventHandler_.get() != NULL) {
  8024. eventHandler_->preRead(ctx, "Cassandra.login");
  8025. }
  8026. Cassandra_login_args args;
  8027. args.read(iprot);
  8028. iprot->readMessageEnd();
  8029. uint32_t bytes = iprot->getTransport()->readEnd();
  8030. if (eventHandler_.get() != NULL) {
  8031. eventHandler_->postRead(ctx, "Cassandra.login", bytes);
  8032. }
  8033. Cassandra_login_result result;
  8034. try {
  8035. iface_->login(args.auth_request);
  8036. } catch (AuthenticationException &authnx) {
  8037. result.authnx = authnx;
  8038. result.__isset.authnx = true;
  8039. } catch (AuthorizationException &authzx) {
  8040. result.authzx = authzx;
  8041. result.__isset.authzx = true;
  8042. } catch (const std::exception& e) {
  8043. if (eventHandler_.get() != NULL) {
  8044. eventHandler_->handlerError(ctx, "Cassandra.login");
  8045. }
  8046. ::apache::thrift::TApplicationException x(e.what());
  8047. oprot->writeMessageBegin("login", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8048. x.write(oprot);
  8049. oprot->writeMessageEnd();
  8050. oprot->getTransport()->writeEnd();
  8051. oprot->getTransport()->flush();
  8052. return;
  8053. }
  8054. if (eventHandler_.get() != NULL) {
  8055. eventHandler_->preWrite(ctx, "Cassandra.login");
  8056. }
  8057. oprot->writeMessageBegin("login", ::apache::thrift::protocol::T_REPLY, seqid);
  8058. result.write(oprot);
  8059. oprot->writeMessageEnd();
  8060. bytes = oprot->getTransport()->writeEnd();
  8061. oprot->getTransport()->flush();
  8062. if (eventHandler_.get() != NULL) {
  8063. eventHandler_->postWrite(ctx, "Cassandra.login", bytes);
  8064. }
  8065. }
  8066. void CassandraProcessor::process_set_keyspace(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8067. {
  8068. void* ctx = NULL;
  8069. if (eventHandler_.get() != NULL) {
  8070. ctx = eventHandler_->getContext("Cassandra.set_keyspace", callContext);
  8071. }
  8072. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.set_keyspace");
  8073. if (eventHandler_.get() != NULL) {
  8074. eventHandler_->preRead(ctx, "Cassandra.set_keyspace");
  8075. }
  8076. Cassandra_set_keyspace_args args;
  8077. args.read(iprot);
  8078. iprot->readMessageEnd();
  8079. uint32_t bytes = iprot->getTransport()->readEnd();
  8080. if (eventHandler_.get() != NULL) {
  8081. eventHandler_->postRead(ctx, "Cassandra.set_keyspace", bytes);
  8082. }
  8083. Cassandra_set_keyspace_result result;
  8084. try {
  8085. iface_->set_keyspace(args.keyspace);
  8086. } catch (InvalidRequestException &ire) {
  8087. result.ire = ire;
  8088. result.__isset.ire = true;
  8089. } catch (const std::exception& e) {
  8090. if (eventHandler_.get() != NULL) {
  8091. eventHandler_->handlerError(ctx, "Cassandra.set_keyspace");
  8092. }
  8093. ::apache::thrift::TApplicationException x(e.what());
  8094. oprot->writeMessageBegin("set_keyspace", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8095. x.write(oprot);
  8096. oprot->writeMessageEnd();
  8097. oprot->getTransport()->writeEnd();
  8098. oprot->getTransport()->flush();
  8099. return;
  8100. }
  8101. if (eventHandler_.get() != NULL) {
  8102. eventHandler_->preWrite(ctx, "Cassandra.set_keyspace");
  8103. }
  8104. oprot->writeMessageBegin("set_keyspace", ::apache::thrift::protocol::T_REPLY, seqid);
  8105. result.write(oprot);
  8106. oprot->writeMessageEnd();
  8107. bytes = oprot->getTransport()->writeEnd();
  8108. oprot->getTransport()->flush();
  8109. if (eventHandler_.get() != NULL) {
  8110. eventHandler_->postWrite(ctx, "Cassandra.set_keyspace", bytes);
  8111. }
  8112. }
  8113. void CassandraProcessor::process_get(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8114. {
  8115. void* ctx = NULL;
  8116. if (eventHandler_.get() != NULL) {
  8117. ctx = eventHandler_->getContext("Cassandra.get", callContext);
  8118. }
  8119. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.get");
  8120. if (eventHandler_.get() != NULL) {
  8121. eventHandler_->preRead(ctx, "Cassandra.get");
  8122. }
  8123. Cassandra_get_args args;
  8124. args.read(iprot);
  8125. iprot->readMessageEnd();
  8126. uint32_t bytes = iprot->getTransport()->readEnd();
  8127. if (eventHandler_.get() != NULL) {
  8128. eventHandler_->postRead(ctx, "Cassandra.get", bytes);
  8129. }
  8130. Cassandra_get_result result;
  8131. try {
  8132. iface_->get(result.success, args.key, args.column_path, args.consistency_level);
  8133. result.__isset.success = true;
  8134. } catch (InvalidRequestException &ire) {
  8135. result.ire = ire;
  8136. result.__isset.ire = true;
  8137. } catch (NotFoundException &nfe) {
  8138. result.nfe = nfe;
  8139. result.__isset.nfe = true;
  8140. } catch (UnavailableException &ue) {
  8141. result.ue = ue;
  8142. result.__isset.ue = true;
  8143. } catch (TimedOutException &te) {
  8144. result.te = te;
  8145. result.__isset.te = true;
  8146. } catch (const std::exception& e) {
  8147. if (eventHandler_.get() != NULL) {
  8148. eventHandler_->handlerError(ctx, "Cassandra.get");
  8149. }
  8150. ::apache::thrift::TApplicationException x(e.what());
  8151. oprot->writeMessageBegin("get", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8152. x.write(oprot);
  8153. oprot->writeMessageEnd();
  8154. oprot->getTransport()->writeEnd();
  8155. oprot->getTransport()->flush();
  8156. return;
  8157. }
  8158. if (eventHandler_.get() != NULL) {
  8159. eventHandler_->preWrite(ctx, "Cassandra.get");
  8160. }
  8161. oprot->writeMessageBegin("get", ::apache::thrift::protocol::T_REPLY, seqid);
  8162. result.write(oprot);
  8163. oprot->writeMessageEnd();
  8164. bytes = oprot->getTransport()->writeEnd();
  8165. oprot->getTransport()->flush();
  8166. if (eventHandler_.get() != NULL) {
  8167. eventHandler_->postWrite(ctx, "Cassandra.get", bytes);
  8168. }
  8169. }
  8170. void CassandraProcessor::process_get_slice(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8171. {
  8172. void* ctx = NULL;
  8173. if (eventHandler_.get() != NULL) {
  8174. ctx = eventHandler_->getContext("Cassandra.get_slice", callContext);
  8175. }
  8176. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.get_slice");
  8177. if (eventHandler_.get() != NULL) {
  8178. eventHandler_->preRead(ctx, "Cassandra.get_slice");
  8179. }
  8180. Cassandra_get_slice_args args;
  8181. args.read(iprot);
  8182. iprot->readMessageEnd();
  8183. uint32_t bytes = iprot->getTransport()->readEnd();
  8184. if (eventHandler_.get() != NULL) {
  8185. eventHandler_->postRead(ctx, "Cassandra.get_slice", bytes);
  8186. }
  8187. Cassandra_get_slice_result result;
  8188. try {
  8189. iface_->get_slice(result.success, args.key, args.column_parent, args.predicate, args.consistency_level);
  8190. result.__isset.success = true;
  8191. } catch (InvalidRequestException &ire) {
  8192. result.ire = ire;
  8193. result.__isset.ire = true;
  8194. } catch (UnavailableException &ue) {
  8195. result.ue = ue;
  8196. result.__isset.ue = true;
  8197. } catch (TimedOutException &te) {
  8198. result.te = te;
  8199. result.__isset.te = true;
  8200. } catch (const std::exception& e) {
  8201. if (eventHandler_.get() != NULL) {
  8202. eventHandler_->handlerError(ctx, "Cassandra.get_slice");
  8203. }
  8204. ::apache::thrift::TApplicationException x(e.what());
  8205. oprot->writeMessageBegin("get_slice", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8206. x.write(oprot);
  8207. oprot->writeMessageEnd();
  8208. oprot->getTransport()->writeEnd();
  8209. oprot->getTransport()->flush();
  8210. return;
  8211. }
  8212. if (eventHandler_.get() != NULL) {
  8213. eventHandler_->preWrite(ctx, "Cassandra.get_slice");
  8214. }
  8215. oprot->writeMessageBegin("get_slice", ::apache::thrift::protocol::T_REPLY, seqid);
  8216. result.write(oprot);
  8217. oprot->writeMessageEnd();
  8218. bytes = oprot->getTransport()->writeEnd();
  8219. oprot->getTransport()->flush();
  8220. if (eventHandler_.get() != NULL) {
  8221. eventHandler_->postWrite(ctx, "Cassandra.get_slice", bytes);
  8222. }
  8223. }
  8224. void CassandraProcessor::process_get_count(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8225. {
  8226. void* ctx = NULL;
  8227. if (eventHandler_.get() != NULL) {
  8228. ctx = eventHandler_->getContext("Cassandra.get_count", callContext);
  8229. }
  8230. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.get_count");
  8231. if (eventHandler_.get() != NULL) {
  8232. eventHandler_->preRead(ctx, "Cassandra.get_count");
  8233. }
  8234. Cassandra_get_count_args args;
  8235. args.read(iprot);
  8236. iprot->readMessageEnd();
  8237. uint32_t bytes = iprot->getTransport()->readEnd();
  8238. if (eventHandler_.get() != NULL) {
  8239. eventHandler_->postRead(ctx, "Cassandra.get_count", bytes);
  8240. }
  8241. Cassandra_get_count_result result;
  8242. try {
  8243. result.success = iface_->get_count(args.key, args.column_parent, args.predicate, args.consistency_level);
  8244. result.__isset.success = true;
  8245. } catch (InvalidRequestException &ire) {
  8246. result.ire = ire;
  8247. result.__isset.ire = true;
  8248. } catch (UnavailableException &ue) {
  8249. result.ue = ue;
  8250. result.__isset.ue = true;
  8251. } catch (TimedOutException &te) {
  8252. result.te = te;
  8253. result.__isset.te = true;
  8254. } catch (const std::exception& e) {
  8255. if (eventHandler_.get() != NULL) {
  8256. eventHandler_->handlerError(ctx, "Cassandra.get_count");
  8257. }
  8258. ::apache::thrift::TApplicationException x(e.what());
  8259. oprot->writeMessageBegin("get_count", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8260. x.write(oprot);
  8261. oprot->writeMessageEnd();
  8262. oprot->getTransport()->writeEnd();
  8263. oprot->getTransport()->flush();
  8264. return;
  8265. }
  8266. if (eventHandler_.get() != NULL) {
  8267. eventHandler_->preWrite(ctx, "Cassandra.get_count");
  8268. }
  8269. oprot->writeMessageBegin("get_count", ::apache::thrift::protocol::T_REPLY, seqid);
  8270. result.write(oprot);
  8271. oprot->writeMessageEnd();
  8272. bytes = oprot->getTransport()->writeEnd();
  8273. oprot->getTransport()->flush();
  8274. if (eventHandler_.get() != NULL) {
  8275. eventHandler_->postWrite(ctx, "Cassandra.get_count", bytes);
  8276. }
  8277. }
  8278. void CassandraProcessor::process_multiget_slice(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8279. {
  8280. void* ctx = NULL;
  8281. if (eventHandler_.get() != NULL) {
  8282. ctx = eventHandler_->getContext("Cassandra.multiget_slice", callContext);
  8283. }
  8284. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.multiget_slice");
  8285. if (eventHandler_.get() != NULL) {
  8286. eventHandler_->preRead(ctx, "Cassandra.multiget_slice");
  8287. }
  8288. Cassandra_multiget_slice_args args;
  8289. args.read(iprot);
  8290. iprot->readMessageEnd();
  8291. uint32_t bytes = iprot->getTransport()->readEnd();
  8292. if (eventHandler_.get() != NULL) {
  8293. eventHandler_->postRead(ctx, "Cassandra.multiget_slice", bytes);
  8294. }
  8295. Cassandra_multiget_slice_result result;
  8296. try {
  8297. iface_->multiget_slice(result.success, args.keys, args.column_parent, args.predicate, args.consistency_level);
  8298. result.__isset.success = true;
  8299. } catch (InvalidRequestException &ire) {
  8300. result.ire = ire;
  8301. result.__isset.ire = true;
  8302. } catch (UnavailableException &ue) {
  8303. result.ue = ue;
  8304. result.__isset.ue = true;
  8305. } catch (TimedOutException &te) {
  8306. result.te = te;
  8307. result.__isset.te = true;
  8308. } catch (const std::exception& e) {
  8309. if (eventHandler_.get() != NULL) {
  8310. eventHandler_->handlerError(ctx, "Cassandra.multiget_slice");
  8311. }
  8312. ::apache::thrift::TApplicationException x(e.what());
  8313. oprot->writeMessageBegin("multiget_slice", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8314. x.write(oprot);
  8315. oprot->writeMessageEnd();
  8316. oprot->getTransport()->writeEnd();
  8317. oprot->getTransport()->flush();
  8318. return;
  8319. }
  8320. if (eventHandler_.get() != NULL) {
  8321. eventHandler_->preWrite(ctx, "Cassandra.multiget_slice");
  8322. }
  8323. oprot->writeMessageBegin("multiget_slice", ::apache::thrift::protocol::T_REPLY, seqid);
  8324. result.write(oprot);
  8325. oprot->writeMessageEnd();
  8326. bytes = oprot->getTransport()->writeEnd();
  8327. oprot->getTransport()->flush();
  8328. if (eventHandler_.get() != NULL) {
  8329. eventHandler_->postWrite(ctx, "Cassandra.multiget_slice", bytes);
  8330. }
  8331. }
  8332. void CassandraProcessor::process_multiget_count(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8333. {
  8334. void* ctx = NULL;
  8335. if (eventHandler_.get() != NULL) {
  8336. ctx = eventHandler_->getContext("Cassandra.multiget_count", callContext);
  8337. }
  8338. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.multiget_count");
  8339. if (eventHandler_.get() != NULL) {
  8340. eventHandler_->preRead(ctx, "Cassandra.multiget_count");
  8341. }
  8342. Cassandra_multiget_count_args args;
  8343. args.read(iprot);
  8344. iprot->readMessageEnd();
  8345. uint32_t bytes = iprot->getTransport()->readEnd();
  8346. if (eventHandler_.get() != NULL) {
  8347. eventHandler_->postRead(ctx, "Cassandra.multiget_count", bytes);
  8348. }
  8349. Cassandra_multiget_count_result result;
  8350. try {
  8351. iface_->multiget_count(result.success, args.keys, args.column_parent, args.predicate, args.consistency_level);
  8352. result.__isset.success = true;
  8353. } catch (InvalidRequestException &ire) {
  8354. result.ire = ire;
  8355. result.__isset.ire = true;
  8356. } catch (UnavailableException &ue) {
  8357. result.ue = ue;
  8358. result.__isset.ue = true;
  8359. } catch (TimedOutException &te) {
  8360. result.te = te;
  8361. result.__isset.te = true;
  8362. } catch (const std::exception& e) {
  8363. if (eventHandler_.get() != NULL) {
  8364. eventHandler_->handlerError(ctx, "Cassandra.multiget_count");
  8365. }
  8366. ::apache::thrift::TApplicationException x(e.what());
  8367. oprot->writeMessageBegin("multiget_count", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8368. x.write(oprot);
  8369. oprot->writeMessageEnd();
  8370. oprot->getTransport()->writeEnd();
  8371. oprot->getTransport()->flush();
  8372. return;
  8373. }
  8374. if (eventHandler_.get() != NULL) {
  8375. eventHandler_->preWrite(ctx, "Cassandra.multiget_count");
  8376. }
  8377. oprot->writeMessageBegin("multiget_count", ::apache::thrift::protocol::T_REPLY, seqid);
  8378. result.write(oprot);
  8379. oprot->writeMessageEnd();
  8380. bytes = oprot->getTransport()->writeEnd();
  8381. oprot->getTransport()->flush();
  8382. if (eventHandler_.get() != NULL) {
  8383. eventHandler_->postWrite(ctx, "Cassandra.multiget_count", bytes);
  8384. }
  8385. }
  8386. void CassandraProcessor::process_get_range_slices(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8387. {
  8388. void* ctx = NULL;
  8389. if (eventHandler_.get() != NULL) {
  8390. ctx = eventHandler_->getContext("Cassandra.get_range_slices", callContext);
  8391. }
  8392. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.get_range_slices");
  8393. if (eventHandler_.get() != NULL) {
  8394. eventHandler_->preRead(ctx, "Cassandra.get_range_slices");
  8395. }
  8396. Cassandra_get_range_slices_args args;
  8397. args.read(iprot);
  8398. iprot->readMessageEnd();
  8399. uint32_t bytes = iprot->getTransport()->readEnd();
  8400. if (eventHandler_.get() != NULL) {
  8401. eventHandler_->postRead(ctx, "Cassandra.get_range_slices", bytes);
  8402. }
  8403. Cassandra_get_range_slices_result result;
  8404. try {
  8405. iface_->get_range_slices(result.success, args.column_parent, args.predicate, args.range, args.consistency_level);
  8406. result.__isset.success = true;
  8407. } catch (InvalidRequestException &ire) {
  8408. result.ire = ire;
  8409. result.__isset.ire = true;
  8410. } catch (UnavailableException &ue) {
  8411. result.ue = ue;
  8412. result.__isset.ue = true;
  8413. } catch (TimedOutException &te) {
  8414. result.te = te;
  8415. result.__isset.te = true;
  8416. } catch (const std::exception& e) {
  8417. if (eventHandler_.get() != NULL) {
  8418. eventHandler_->handlerError(ctx, "Cassandra.get_range_slices");
  8419. }
  8420. ::apache::thrift::TApplicationException x(e.what());
  8421. oprot->writeMessageBegin("get_range_slices", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8422. x.write(oprot);
  8423. oprot->writeMessageEnd();
  8424. oprot->getTransport()->writeEnd();
  8425. oprot->getTransport()->flush();
  8426. return;
  8427. }
  8428. if (eventHandler_.get() != NULL) {
  8429. eventHandler_->preWrite(ctx, "Cassandra.get_range_slices");
  8430. }
  8431. oprot->writeMessageBegin("get_range_slices", ::apache::thrift::protocol::T_REPLY, seqid);
  8432. result.write(oprot);
  8433. oprot->writeMessageEnd();
  8434. bytes = oprot->getTransport()->writeEnd();
  8435. oprot->getTransport()->flush();
  8436. if (eventHandler_.get() != NULL) {
  8437. eventHandler_->postWrite(ctx, "Cassandra.get_range_slices", bytes);
  8438. }
  8439. }
  8440. void CassandraProcessor::process_get_indexed_slices(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8441. {
  8442. void* ctx = NULL;
  8443. if (eventHandler_.get() != NULL) {
  8444. ctx = eventHandler_->getContext("Cassandra.get_indexed_slices", callContext);
  8445. }
  8446. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.get_indexed_slices");
  8447. if (eventHandler_.get() != NULL) {
  8448. eventHandler_->preRead(ctx, "Cassandra.get_indexed_slices");
  8449. }
  8450. Cassandra_get_indexed_slices_args args;
  8451. args.read(iprot);
  8452. iprot->readMessageEnd();
  8453. uint32_t bytes = iprot->getTransport()->readEnd();
  8454. if (eventHandler_.get() != NULL) {
  8455. eventHandler_->postRead(ctx, "Cassandra.get_indexed_slices", bytes);
  8456. }
  8457. Cassandra_get_indexed_slices_result result;
  8458. try {
  8459. iface_->get_indexed_slices(result.success, args.column_parent, args.index_clause, args.column_predicate, args.consistency_level);
  8460. result.__isset.success = true;
  8461. } catch (InvalidRequestException &ire) {
  8462. result.ire = ire;
  8463. result.__isset.ire = true;
  8464. } catch (UnavailableException &ue) {
  8465. result.ue = ue;
  8466. result.__isset.ue = true;
  8467. } catch (TimedOutException &te) {
  8468. result.te = te;
  8469. result.__isset.te = true;
  8470. } catch (const std::exception& e) {
  8471. if (eventHandler_.get() != NULL) {
  8472. eventHandler_->handlerError(ctx, "Cassandra.get_indexed_slices");
  8473. }
  8474. ::apache::thrift::TApplicationException x(e.what());
  8475. oprot->writeMessageBegin("get_indexed_slices", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8476. x.write(oprot);
  8477. oprot->writeMessageEnd();
  8478. oprot->getTransport()->writeEnd();
  8479. oprot->getTransport()->flush();
  8480. return;
  8481. }
  8482. if (eventHandler_.get() != NULL) {
  8483. eventHandler_->preWrite(ctx, "Cassandra.get_indexed_slices");
  8484. }
  8485. oprot->writeMessageBegin("get_indexed_slices", ::apache::thrift::protocol::T_REPLY, seqid);
  8486. result.write(oprot);
  8487. oprot->writeMessageEnd();
  8488. bytes = oprot->getTransport()->writeEnd();
  8489. oprot->getTransport()->flush();
  8490. if (eventHandler_.get() != NULL) {
  8491. eventHandler_->postWrite(ctx, "Cassandra.get_indexed_slices", bytes);
  8492. }
  8493. }
  8494. void CassandraProcessor::process_insert(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8495. {
  8496. void* ctx = NULL;
  8497. if (eventHandler_.get() != NULL) {
  8498. ctx = eventHandler_->getContext("Cassandra.insert", callContext);
  8499. }
  8500. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.insert");
  8501. if (eventHandler_.get() != NULL) {
  8502. eventHandler_->preRead(ctx, "Cassandra.insert");
  8503. }
  8504. Cassandra_insert_args args;
  8505. args.read(iprot);
  8506. iprot->readMessageEnd();
  8507. uint32_t bytes = iprot->getTransport()->readEnd();
  8508. if (eventHandler_.get() != NULL) {
  8509. eventHandler_->postRead(ctx, "Cassandra.insert", bytes);
  8510. }
  8511. Cassandra_insert_result result;
  8512. try {
  8513. iface_->insert(args.key, args.column_parent, args.column, args.consistency_level);
  8514. } catch (InvalidRequestException &ire) {
  8515. result.ire = ire;
  8516. result.__isset.ire = true;
  8517. } catch (UnavailableException &ue) {
  8518. result.ue = ue;
  8519. result.__isset.ue = true;
  8520. } catch (TimedOutException &te) {
  8521. result.te = te;
  8522. result.__isset.te = true;
  8523. } catch (const std::exception& e) {
  8524. if (eventHandler_.get() != NULL) {
  8525. eventHandler_->handlerError(ctx, "Cassandra.insert");
  8526. }
  8527. ::apache::thrift::TApplicationException x(e.what());
  8528. oprot->writeMessageBegin("insert", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8529. x.write(oprot);
  8530. oprot->writeMessageEnd();
  8531. oprot->getTransport()->writeEnd();
  8532. oprot->getTransport()->flush();
  8533. return;
  8534. }
  8535. if (eventHandler_.get() != NULL) {
  8536. eventHandler_->preWrite(ctx, "Cassandra.insert");
  8537. }
  8538. oprot->writeMessageBegin("insert", ::apache::thrift::protocol::T_REPLY, seqid);
  8539. result.write(oprot);
  8540. oprot->writeMessageEnd();
  8541. bytes = oprot->getTransport()->writeEnd();
  8542. oprot->getTransport()->flush();
  8543. if (eventHandler_.get() != NULL) {
  8544. eventHandler_->postWrite(ctx, "Cassandra.insert", bytes);
  8545. }
  8546. }
  8547. void CassandraProcessor::process_add(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8548. {
  8549. void* ctx = NULL;
  8550. if (eventHandler_.get() != NULL) {
  8551. ctx = eventHandler_->getContext("Cassandra.add", callContext);
  8552. }
  8553. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.add");
  8554. if (eventHandler_.get() != NULL) {
  8555. eventHandler_->preRead(ctx, "Cassandra.add");
  8556. }
  8557. Cassandra_add_args args;
  8558. args.read(iprot);
  8559. iprot->readMessageEnd();
  8560. uint32_t bytes = iprot->getTransport()->readEnd();
  8561. if (eventHandler_.get() != NULL) {
  8562. eventHandler_->postRead(ctx, "Cassandra.add", bytes);
  8563. }
  8564. Cassandra_add_result result;
  8565. try {
  8566. iface_->add(args.key, args.column_parent, args.column, args.consistency_level);
  8567. } catch (InvalidRequestException &ire) {
  8568. result.ire = ire;
  8569. result.__isset.ire = true;
  8570. } catch (UnavailableException &ue) {
  8571. result.ue = ue;
  8572. result.__isset.ue = true;
  8573. } catch (TimedOutException &te) {
  8574. result.te = te;
  8575. result.__isset.te = true;
  8576. } catch (const std::exception& e) {
  8577. if (eventHandler_.get() != NULL) {
  8578. eventHandler_->handlerError(ctx, "Cassandra.add");
  8579. }
  8580. ::apache::thrift::TApplicationException x(e.what());
  8581. oprot->writeMessageBegin("add", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8582. x.write(oprot);
  8583. oprot->writeMessageEnd();
  8584. oprot->getTransport()->writeEnd();
  8585. oprot->getTransport()->flush();
  8586. return;
  8587. }
  8588. if (eventHandler_.get() != NULL) {
  8589. eventHandler_->preWrite(ctx, "Cassandra.add");
  8590. }
  8591. oprot->writeMessageBegin("add", ::apache::thrift::protocol::T_REPLY, seqid);
  8592. result.write(oprot);
  8593. oprot->writeMessageEnd();
  8594. bytes = oprot->getTransport()->writeEnd();
  8595. oprot->getTransport()->flush();
  8596. if (eventHandler_.get() != NULL) {
  8597. eventHandler_->postWrite(ctx, "Cassandra.add", bytes);
  8598. }
  8599. }
  8600. void CassandraProcessor::process_remove(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8601. {
  8602. void* ctx = NULL;
  8603. if (eventHandler_.get() != NULL) {
  8604. ctx = eventHandler_->getContext("Cassandra.remove", callContext);
  8605. }
  8606. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.remove");
  8607. if (eventHandler_.get() != NULL) {
  8608. eventHandler_->preRead(ctx, "Cassandra.remove");
  8609. }
  8610. Cassandra_remove_args args;
  8611. args.read(iprot);
  8612. iprot->readMessageEnd();
  8613. uint32_t bytes = iprot->getTransport()->readEnd();
  8614. if (eventHandler_.get() != NULL) {
  8615. eventHandler_->postRead(ctx, "Cassandra.remove", bytes);
  8616. }
  8617. Cassandra_remove_result result;
  8618. try {
  8619. iface_->remove(args.key, args.column_path, args.timestamp, args.consistency_level);
  8620. } catch (InvalidRequestException &ire) {
  8621. result.ire = ire;
  8622. result.__isset.ire = true;
  8623. } catch (UnavailableException &ue) {
  8624. result.ue = ue;
  8625. result.__isset.ue = true;
  8626. } catch (TimedOutException &te) {
  8627. result.te = te;
  8628. result.__isset.te = true;
  8629. } catch (const std::exception& e) {
  8630. if (eventHandler_.get() != NULL) {
  8631. eventHandler_->handlerError(ctx, "Cassandra.remove");
  8632. }
  8633. ::apache::thrift::TApplicationException x(e.what());
  8634. oprot->writeMessageBegin("remove", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8635. x.write(oprot);
  8636. oprot->writeMessageEnd();
  8637. oprot->getTransport()->writeEnd();
  8638. oprot->getTransport()->flush();
  8639. return;
  8640. }
  8641. if (eventHandler_.get() != NULL) {
  8642. eventHandler_->preWrite(ctx, "Cassandra.remove");
  8643. }
  8644. oprot->writeMessageBegin("remove", ::apache::thrift::protocol::T_REPLY, seqid);
  8645. result.write(oprot);
  8646. oprot->writeMessageEnd();
  8647. bytes = oprot->getTransport()->writeEnd();
  8648. oprot->getTransport()->flush();
  8649. if (eventHandler_.get() != NULL) {
  8650. eventHandler_->postWrite(ctx, "Cassandra.remove", bytes);
  8651. }
  8652. }
  8653. void CassandraProcessor::process_remove_counter(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8654. {
  8655. void* ctx = NULL;
  8656. if (eventHandler_.get() != NULL) {
  8657. ctx = eventHandler_->getContext("Cassandra.remove_counter", callContext);
  8658. }
  8659. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.remove_counter");
  8660. if (eventHandler_.get() != NULL) {
  8661. eventHandler_->preRead(ctx, "Cassandra.remove_counter");
  8662. }
  8663. Cassandra_remove_counter_args args;
  8664. args.read(iprot);
  8665. iprot->readMessageEnd();
  8666. uint32_t bytes = iprot->getTransport()->readEnd();
  8667. if (eventHandler_.get() != NULL) {
  8668. eventHandler_->postRead(ctx, "Cassandra.remove_counter", bytes);
  8669. }
  8670. Cassandra_remove_counter_result result;
  8671. try {
  8672. iface_->remove_counter(args.key, args.path, args.consistency_level);
  8673. } catch (InvalidRequestException &ire) {
  8674. result.ire = ire;
  8675. result.__isset.ire = true;
  8676. } catch (UnavailableException &ue) {
  8677. result.ue = ue;
  8678. result.__isset.ue = true;
  8679. } catch (TimedOutException &te) {
  8680. result.te = te;
  8681. result.__isset.te = true;
  8682. } catch (const std::exception& e) {
  8683. if (eventHandler_.get() != NULL) {
  8684. eventHandler_->handlerError(ctx, "Cassandra.remove_counter");
  8685. }
  8686. ::apache::thrift::TApplicationException x(e.what());
  8687. oprot->writeMessageBegin("remove_counter", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8688. x.write(oprot);
  8689. oprot->writeMessageEnd();
  8690. oprot->getTransport()->writeEnd();
  8691. oprot->getTransport()->flush();
  8692. return;
  8693. }
  8694. if (eventHandler_.get() != NULL) {
  8695. eventHandler_->preWrite(ctx, "Cassandra.remove_counter");
  8696. }
  8697. oprot->writeMessageBegin("remove_counter", ::apache::thrift::protocol::T_REPLY, seqid);
  8698. result.write(oprot);
  8699. oprot->writeMessageEnd();
  8700. bytes = oprot->getTransport()->writeEnd();
  8701. oprot->getTransport()->flush();
  8702. if (eventHandler_.get() != NULL) {
  8703. eventHandler_->postWrite(ctx, "Cassandra.remove_counter", bytes);
  8704. }
  8705. }
  8706. void CassandraProcessor::process_batch_mutate(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8707. {
  8708. void* ctx = NULL;
  8709. if (eventHandler_.get() != NULL) {
  8710. ctx = eventHandler_->getContext("Cassandra.batch_mutate", callContext);
  8711. }
  8712. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.batch_mutate");
  8713. if (eventHandler_.get() != NULL) {
  8714. eventHandler_->preRead(ctx, "Cassandra.batch_mutate");
  8715. }
  8716. Cassandra_batch_mutate_args args;
  8717. args.read(iprot);
  8718. iprot->readMessageEnd();
  8719. uint32_t bytes = iprot->getTransport()->readEnd();
  8720. if (eventHandler_.get() != NULL) {
  8721. eventHandler_->postRead(ctx, "Cassandra.batch_mutate", bytes);
  8722. }
  8723. Cassandra_batch_mutate_result result;
  8724. try {
  8725. iface_->batch_mutate(args.mutation_map, args.consistency_level);
  8726. } catch (InvalidRequestException &ire) {
  8727. result.ire = ire;
  8728. result.__isset.ire = true;
  8729. } catch (UnavailableException &ue) {
  8730. result.ue = ue;
  8731. result.__isset.ue = true;
  8732. } catch (TimedOutException &te) {
  8733. result.te = te;
  8734. result.__isset.te = true;
  8735. } catch (const std::exception& e) {
  8736. if (eventHandler_.get() != NULL) {
  8737. eventHandler_->handlerError(ctx, "Cassandra.batch_mutate");
  8738. }
  8739. ::apache::thrift::TApplicationException x(e.what());
  8740. oprot->writeMessageBegin("batch_mutate", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8741. x.write(oprot);
  8742. oprot->writeMessageEnd();
  8743. oprot->getTransport()->writeEnd();
  8744. oprot->getTransport()->flush();
  8745. return;
  8746. }
  8747. if (eventHandler_.get() != NULL) {
  8748. eventHandler_->preWrite(ctx, "Cassandra.batch_mutate");
  8749. }
  8750. oprot->writeMessageBegin("batch_mutate", ::apache::thrift::protocol::T_REPLY, seqid);
  8751. result.write(oprot);
  8752. oprot->writeMessageEnd();
  8753. bytes = oprot->getTransport()->writeEnd();
  8754. oprot->getTransport()->flush();
  8755. if (eventHandler_.get() != NULL) {
  8756. eventHandler_->postWrite(ctx, "Cassandra.batch_mutate", bytes);
  8757. }
  8758. }
  8759. void CassandraProcessor::process_truncate(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8760. {
  8761. void* ctx = NULL;
  8762. if (eventHandler_.get() != NULL) {
  8763. ctx = eventHandler_->getContext("Cassandra.truncate", callContext);
  8764. }
  8765. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.truncate");
  8766. if (eventHandler_.get() != NULL) {
  8767. eventHandler_->preRead(ctx, "Cassandra.truncate");
  8768. }
  8769. Cassandra_truncate_args args;
  8770. args.read(iprot);
  8771. iprot->readMessageEnd();
  8772. uint32_t bytes = iprot->getTransport()->readEnd();
  8773. if (eventHandler_.get() != NULL) {
  8774. eventHandler_->postRead(ctx, "Cassandra.truncate", bytes);
  8775. }
  8776. Cassandra_truncate_result result;
  8777. try {
  8778. iface_->truncate(args.cfname);
  8779. } catch (InvalidRequestException &ire) {
  8780. result.ire = ire;
  8781. result.__isset.ire = true;
  8782. } catch (UnavailableException &ue) {
  8783. result.ue = ue;
  8784. result.__isset.ue = true;
  8785. } catch (const std::exception& e) {
  8786. if (eventHandler_.get() != NULL) {
  8787. eventHandler_->handlerError(ctx, "Cassandra.truncate");
  8788. }
  8789. ::apache::thrift::TApplicationException x(e.what());
  8790. oprot->writeMessageBegin("truncate", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8791. x.write(oprot);
  8792. oprot->writeMessageEnd();
  8793. oprot->getTransport()->writeEnd();
  8794. oprot->getTransport()->flush();
  8795. return;
  8796. }
  8797. if (eventHandler_.get() != NULL) {
  8798. eventHandler_->preWrite(ctx, "Cassandra.truncate");
  8799. }
  8800. oprot->writeMessageBegin("truncate", ::apache::thrift::protocol::T_REPLY, seqid);
  8801. result.write(oprot);
  8802. oprot->writeMessageEnd();
  8803. bytes = oprot->getTransport()->writeEnd();
  8804. oprot->getTransport()->flush();
  8805. if (eventHandler_.get() != NULL) {
  8806. eventHandler_->postWrite(ctx, "Cassandra.truncate", bytes);
  8807. }
  8808. }
  8809. void CassandraProcessor::process_describe_schema_versions(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8810. {
  8811. void* ctx = NULL;
  8812. if (eventHandler_.get() != NULL) {
  8813. ctx = eventHandler_->getContext("Cassandra.describe_schema_versions", callContext);
  8814. }
  8815. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_schema_versions");
  8816. if (eventHandler_.get() != NULL) {
  8817. eventHandler_->preRead(ctx, "Cassandra.describe_schema_versions");
  8818. }
  8819. Cassandra_describe_schema_versions_args args;
  8820. args.read(iprot);
  8821. iprot->readMessageEnd();
  8822. uint32_t bytes = iprot->getTransport()->readEnd();
  8823. if (eventHandler_.get() != NULL) {
  8824. eventHandler_->postRead(ctx, "Cassandra.describe_schema_versions", bytes);
  8825. }
  8826. Cassandra_describe_schema_versions_result result;
  8827. try {
  8828. iface_->describe_schema_versions(result.success);
  8829. result.__isset.success = true;
  8830. } catch (InvalidRequestException &ire) {
  8831. result.ire = ire;
  8832. result.__isset.ire = true;
  8833. } catch (const std::exception& e) {
  8834. if (eventHandler_.get() != NULL) {
  8835. eventHandler_->handlerError(ctx, "Cassandra.describe_schema_versions");
  8836. }
  8837. ::apache::thrift::TApplicationException x(e.what());
  8838. oprot->writeMessageBegin("describe_schema_versions", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8839. x.write(oprot);
  8840. oprot->writeMessageEnd();
  8841. oprot->getTransport()->writeEnd();
  8842. oprot->getTransport()->flush();
  8843. return;
  8844. }
  8845. if (eventHandler_.get() != NULL) {
  8846. eventHandler_->preWrite(ctx, "Cassandra.describe_schema_versions");
  8847. }
  8848. oprot->writeMessageBegin("describe_schema_versions", ::apache::thrift::protocol::T_REPLY, seqid);
  8849. result.write(oprot);
  8850. oprot->writeMessageEnd();
  8851. bytes = oprot->getTransport()->writeEnd();
  8852. oprot->getTransport()->flush();
  8853. if (eventHandler_.get() != NULL) {
  8854. eventHandler_->postWrite(ctx, "Cassandra.describe_schema_versions", bytes);
  8855. }
  8856. }
  8857. void CassandraProcessor::process_describe_keyspaces(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8858. {
  8859. void* ctx = NULL;
  8860. if (eventHandler_.get() != NULL) {
  8861. ctx = eventHandler_->getContext("Cassandra.describe_keyspaces", callContext);
  8862. }
  8863. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_keyspaces");
  8864. if (eventHandler_.get() != NULL) {
  8865. eventHandler_->preRead(ctx, "Cassandra.describe_keyspaces");
  8866. }
  8867. Cassandra_describe_keyspaces_args args;
  8868. args.read(iprot);
  8869. iprot->readMessageEnd();
  8870. uint32_t bytes = iprot->getTransport()->readEnd();
  8871. if (eventHandler_.get() != NULL) {
  8872. eventHandler_->postRead(ctx, "Cassandra.describe_keyspaces", bytes);
  8873. }
  8874. Cassandra_describe_keyspaces_result result;
  8875. try {
  8876. iface_->describe_keyspaces(result.success);
  8877. result.__isset.success = true;
  8878. } catch (InvalidRequestException &ire) {
  8879. result.ire = ire;
  8880. result.__isset.ire = true;
  8881. } catch (const std::exception& e) {
  8882. if (eventHandler_.get() != NULL) {
  8883. eventHandler_->handlerError(ctx, "Cassandra.describe_keyspaces");
  8884. }
  8885. ::apache::thrift::TApplicationException x(e.what());
  8886. oprot->writeMessageBegin("describe_keyspaces", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8887. x.write(oprot);
  8888. oprot->writeMessageEnd();
  8889. oprot->getTransport()->writeEnd();
  8890. oprot->getTransport()->flush();
  8891. return;
  8892. }
  8893. if (eventHandler_.get() != NULL) {
  8894. eventHandler_->preWrite(ctx, "Cassandra.describe_keyspaces");
  8895. }
  8896. oprot->writeMessageBegin("describe_keyspaces", ::apache::thrift::protocol::T_REPLY, seqid);
  8897. result.write(oprot);
  8898. oprot->writeMessageEnd();
  8899. bytes = oprot->getTransport()->writeEnd();
  8900. oprot->getTransport()->flush();
  8901. if (eventHandler_.get() != NULL) {
  8902. eventHandler_->postWrite(ctx, "Cassandra.describe_keyspaces", bytes);
  8903. }
  8904. }
  8905. void CassandraProcessor::process_describe_cluster_name(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8906. {
  8907. void* ctx = NULL;
  8908. if (eventHandler_.get() != NULL) {
  8909. ctx = eventHandler_->getContext("Cassandra.describe_cluster_name", callContext);
  8910. }
  8911. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_cluster_name");
  8912. if (eventHandler_.get() != NULL) {
  8913. eventHandler_->preRead(ctx, "Cassandra.describe_cluster_name");
  8914. }
  8915. Cassandra_describe_cluster_name_args args;
  8916. args.read(iprot);
  8917. iprot->readMessageEnd();
  8918. uint32_t bytes = iprot->getTransport()->readEnd();
  8919. if (eventHandler_.get() != NULL) {
  8920. eventHandler_->postRead(ctx, "Cassandra.describe_cluster_name", bytes);
  8921. }
  8922. Cassandra_describe_cluster_name_result result;
  8923. try {
  8924. iface_->describe_cluster_name(result.success);
  8925. result.__isset.success = true;
  8926. } catch (const std::exception& e) {
  8927. if (eventHandler_.get() != NULL) {
  8928. eventHandler_->handlerError(ctx, "Cassandra.describe_cluster_name");
  8929. }
  8930. ::apache::thrift::TApplicationException x(e.what());
  8931. oprot->writeMessageBegin("describe_cluster_name", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8932. x.write(oprot);
  8933. oprot->writeMessageEnd();
  8934. oprot->getTransport()->writeEnd();
  8935. oprot->getTransport()->flush();
  8936. return;
  8937. }
  8938. if (eventHandler_.get() != NULL) {
  8939. eventHandler_->preWrite(ctx, "Cassandra.describe_cluster_name");
  8940. }
  8941. oprot->writeMessageBegin("describe_cluster_name", ::apache::thrift::protocol::T_REPLY, seqid);
  8942. result.write(oprot);
  8943. oprot->writeMessageEnd();
  8944. bytes = oprot->getTransport()->writeEnd();
  8945. oprot->getTransport()->flush();
  8946. if (eventHandler_.get() != NULL) {
  8947. eventHandler_->postWrite(ctx, "Cassandra.describe_cluster_name", bytes);
  8948. }
  8949. }
  8950. void CassandraProcessor::process_describe_version(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8951. {
  8952. void* ctx = NULL;
  8953. if (eventHandler_.get() != NULL) {
  8954. ctx = eventHandler_->getContext("Cassandra.describe_version", callContext);
  8955. }
  8956. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_version");
  8957. if (eventHandler_.get() != NULL) {
  8958. eventHandler_->preRead(ctx, "Cassandra.describe_version");
  8959. }
  8960. Cassandra_describe_version_args args;
  8961. args.read(iprot);
  8962. iprot->readMessageEnd();
  8963. uint32_t bytes = iprot->getTransport()->readEnd();
  8964. if (eventHandler_.get() != NULL) {
  8965. eventHandler_->postRead(ctx, "Cassandra.describe_version", bytes);
  8966. }
  8967. Cassandra_describe_version_result result;
  8968. try {
  8969. iface_->describe_version(result.success);
  8970. result.__isset.success = true;
  8971. } catch (const std::exception& e) {
  8972. if (eventHandler_.get() != NULL) {
  8973. eventHandler_->handlerError(ctx, "Cassandra.describe_version");
  8974. }
  8975. ::apache::thrift::TApplicationException x(e.what());
  8976. oprot->writeMessageBegin("describe_version", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  8977. x.write(oprot);
  8978. oprot->writeMessageEnd();
  8979. oprot->getTransport()->writeEnd();
  8980. oprot->getTransport()->flush();
  8981. return;
  8982. }
  8983. if (eventHandler_.get() != NULL) {
  8984. eventHandler_->preWrite(ctx, "Cassandra.describe_version");
  8985. }
  8986. oprot->writeMessageBegin("describe_version", ::apache::thrift::protocol::T_REPLY, seqid);
  8987. result.write(oprot);
  8988. oprot->writeMessageEnd();
  8989. bytes = oprot->getTransport()->writeEnd();
  8990. oprot->getTransport()->flush();
  8991. if (eventHandler_.get() != NULL) {
  8992. eventHandler_->postWrite(ctx, "Cassandra.describe_version", bytes);
  8993. }
  8994. }
  8995. void CassandraProcessor::process_describe_ring(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  8996. {
  8997. void* ctx = NULL;
  8998. if (eventHandler_.get() != NULL) {
  8999. ctx = eventHandler_->getContext("Cassandra.describe_ring", callContext);
  9000. }
  9001. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_ring");
  9002. if (eventHandler_.get() != NULL) {
  9003. eventHandler_->preRead(ctx, "Cassandra.describe_ring");
  9004. }
  9005. Cassandra_describe_ring_args args;
  9006. args.read(iprot);
  9007. iprot->readMessageEnd();
  9008. uint32_t bytes = iprot->getTransport()->readEnd();
  9009. if (eventHandler_.get() != NULL) {
  9010. eventHandler_->postRead(ctx, "Cassandra.describe_ring", bytes);
  9011. }
  9012. Cassandra_describe_ring_result result;
  9013. try {
  9014. iface_->describe_ring(result.success, args.keyspace);
  9015. result.__isset.success = true;
  9016. } catch (InvalidRequestException &ire) {
  9017. result.ire = ire;
  9018. result.__isset.ire = true;
  9019. } catch (const std::exception& e) {
  9020. if (eventHandler_.get() != NULL) {
  9021. eventHandler_->handlerError(ctx, "Cassandra.describe_ring");
  9022. }
  9023. ::apache::thrift::TApplicationException x(e.what());
  9024. oprot->writeMessageBegin("describe_ring", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9025. x.write(oprot);
  9026. oprot->writeMessageEnd();
  9027. oprot->getTransport()->writeEnd();
  9028. oprot->getTransport()->flush();
  9029. return;
  9030. }
  9031. if (eventHandler_.get() != NULL) {
  9032. eventHandler_->preWrite(ctx, "Cassandra.describe_ring");
  9033. }
  9034. oprot->writeMessageBegin("describe_ring", ::apache::thrift::protocol::T_REPLY, seqid);
  9035. result.write(oprot);
  9036. oprot->writeMessageEnd();
  9037. bytes = oprot->getTransport()->writeEnd();
  9038. oprot->getTransport()->flush();
  9039. if (eventHandler_.get() != NULL) {
  9040. eventHandler_->postWrite(ctx, "Cassandra.describe_ring", bytes);
  9041. }
  9042. }
  9043. void CassandraProcessor::process_describe_partitioner(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9044. {
  9045. void* ctx = NULL;
  9046. if (eventHandler_.get() != NULL) {
  9047. ctx = eventHandler_->getContext("Cassandra.describe_partitioner", callContext);
  9048. }
  9049. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_partitioner");
  9050. if (eventHandler_.get() != NULL) {
  9051. eventHandler_->preRead(ctx, "Cassandra.describe_partitioner");
  9052. }
  9053. Cassandra_describe_partitioner_args args;
  9054. args.read(iprot);
  9055. iprot->readMessageEnd();
  9056. uint32_t bytes = iprot->getTransport()->readEnd();
  9057. if (eventHandler_.get() != NULL) {
  9058. eventHandler_->postRead(ctx, "Cassandra.describe_partitioner", bytes);
  9059. }
  9060. Cassandra_describe_partitioner_result result;
  9061. try {
  9062. iface_->describe_partitioner(result.success);
  9063. result.__isset.success = true;
  9064. } catch (const std::exception& e) {
  9065. if (eventHandler_.get() != NULL) {
  9066. eventHandler_->handlerError(ctx, "Cassandra.describe_partitioner");
  9067. }
  9068. ::apache::thrift::TApplicationException x(e.what());
  9069. oprot->writeMessageBegin("describe_partitioner", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9070. x.write(oprot);
  9071. oprot->writeMessageEnd();
  9072. oprot->getTransport()->writeEnd();
  9073. oprot->getTransport()->flush();
  9074. return;
  9075. }
  9076. if (eventHandler_.get() != NULL) {
  9077. eventHandler_->preWrite(ctx, "Cassandra.describe_partitioner");
  9078. }
  9079. oprot->writeMessageBegin("describe_partitioner", ::apache::thrift::protocol::T_REPLY, seqid);
  9080. result.write(oprot);
  9081. oprot->writeMessageEnd();
  9082. bytes = oprot->getTransport()->writeEnd();
  9083. oprot->getTransport()->flush();
  9084. if (eventHandler_.get() != NULL) {
  9085. eventHandler_->postWrite(ctx, "Cassandra.describe_partitioner", bytes);
  9086. }
  9087. }
  9088. void CassandraProcessor::process_describe_snitch(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9089. {
  9090. void* ctx = NULL;
  9091. if (eventHandler_.get() != NULL) {
  9092. ctx = eventHandler_->getContext("Cassandra.describe_snitch", callContext);
  9093. }
  9094. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_snitch");
  9095. if (eventHandler_.get() != NULL) {
  9096. eventHandler_->preRead(ctx, "Cassandra.describe_snitch");
  9097. }
  9098. Cassandra_describe_snitch_args args;
  9099. args.read(iprot);
  9100. iprot->readMessageEnd();
  9101. uint32_t bytes = iprot->getTransport()->readEnd();
  9102. if (eventHandler_.get() != NULL) {
  9103. eventHandler_->postRead(ctx, "Cassandra.describe_snitch", bytes);
  9104. }
  9105. Cassandra_describe_snitch_result result;
  9106. try {
  9107. iface_->describe_snitch(result.success);
  9108. result.__isset.success = true;
  9109. } catch (const std::exception& e) {
  9110. if (eventHandler_.get() != NULL) {
  9111. eventHandler_->handlerError(ctx, "Cassandra.describe_snitch");
  9112. }
  9113. ::apache::thrift::TApplicationException x(e.what());
  9114. oprot->writeMessageBegin("describe_snitch", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9115. x.write(oprot);
  9116. oprot->writeMessageEnd();
  9117. oprot->getTransport()->writeEnd();
  9118. oprot->getTransport()->flush();
  9119. return;
  9120. }
  9121. if (eventHandler_.get() != NULL) {
  9122. eventHandler_->preWrite(ctx, "Cassandra.describe_snitch");
  9123. }
  9124. oprot->writeMessageBegin("describe_snitch", ::apache::thrift::protocol::T_REPLY, seqid);
  9125. result.write(oprot);
  9126. oprot->writeMessageEnd();
  9127. bytes = oprot->getTransport()->writeEnd();
  9128. oprot->getTransport()->flush();
  9129. if (eventHandler_.get() != NULL) {
  9130. eventHandler_->postWrite(ctx, "Cassandra.describe_snitch", bytes);
  9131. }
  9132. }
  9133. void CassandraProcessor::process_describe_keyspace(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9134. {
  9135. void* ctx = NULL;
  9136. if (eventHandler_.get() != NULL) {
  9137. ctx = eventHandler_->getContext("Cassandra.describe_keyspace", callContext);
  9138. }
  9139. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_keyspace");
  9140. if (eventHandler_.get() != NULL) {
  9141. eventHandler_->preRead(ctx, "Cassandra.describe_keyspace");
  9142. }
  9143. Cassandra_describe_keyspace_args args;
  9144. args.read(iprot);
  9145. iprot->readMessageEnd();
  9146. uint32_t bytes = iprot->getTransport()->readEnd();
  9147. if (eventHandler_.get() != NULL) {
  9148. eventHandler_->postRead(ctx, "Cassandra.describe_keyspace", bytes);
  9149. }
  9150. Cassandra_describe_keyspace_result result;
  9151. try {
  9152. iface_->describe_keyspace(result.success, args.keyspace);
  9153. result.__isset.success = true;
  9154. } catch (NotFoundException &nfe) {
  9155. result.nfe = nfe;
  9156. result.__isset.nfe = true;
  9157. } catch (InvalidRequestException &ire) {
  9158. result.ire = ire;
  9159. result.__isset.ire = true;
  9160. } catch (const std::exception& e) {
  9161. if (eventHandler_.get() != NULL) {
  9162. eventHandler_->handlerError(ctx, "Cassandra.describe_keyspace");
  9163. }
  9164. ::apache::thrift::TApplicationException x(e.what());
  9165. oprot->writeMessageBegin("describe_keyspace", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9166. x.write(oprot);
  9167. oprot->writeMessageEnd();
  9168. oprot->getTransport()->writeEnd();
  9169. oprot->getTransport()->flush();
  9170. return;
  9171. }
  9172. if (eventHandler_.get() != NULL) {
  9173. eventHandler_->preWrite(ctx, "Cassandra.describe_keyspace");
  9174. }
  9175. oprot->writeMessageBegin("describe_keyspace", ::apache::thrift::protocol::T_REPLY, seqid);
  9176. result.write(oprot);
  9177. oprot->writeMessageEnd();
  9178. bytes = oprot->getTransport()->writeEnd();
  9179. oprot->getTransport()->flush();
  9180. if (eventHandler_.get() != NULL) {
  9181. eventHandler_->postWrite(ctx, "Cassandra.describe_keyspace", bytes);
  9182. }
  9183. }
  9184. void CassandraProcessor::process_describe_splits(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9185. {
  9186. void* ctx = NULL;
  9187. if (eventHandler_.get() != NULL) {
  9188. ctx = eventHandler_->getContext("Cassandra.describe_splits", callContext);
  9189. }
  9190. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.describe_splits");
  9191. if (eventHandler_.get() != NULL) {
  9192. eventHandler_->preRead(ctx, "Cassandra.describe_splits");
  9193. }
  9194. Cassandra_describe_splits_args args;
  9195. args.read(iprot);
  9196. iprot->readMessageEnd();
  9197. uint32_t bytes = iprot->getTransport()->readEnd();
  9198. if (eventHandler_.get() != NULL) {
  9199. eventHandler_->postRead(ctx, "Cassandra.describe_splits", bytes);
  9200. }
  9201. Cassandra_describe_splits_result result;
  9202. try {
  9203. iface_->describe_splits(result.success, args.cfName, args.start_token, args.end_token, args.keys_per_split);
  9204. result.__isset.success = true;
  9205. } catch (InvalidRequestException &ire) {
  9206. result.ire = ire;
  9207. result.__isset.ire = true;
  9208. } catch (const std::exception& e) {
  9209. if (eventHandler_.get() != NULL) {
  9210. eventHandler_->handlerError(ctx, "Cassandra.describe_splits");
  9211. }
  9212. ::apache::thrift::TApplicationException x(e.what());
  9213. oprot->writeMessageBegin("describe_splits", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9214. x.write(oprot);
  9215. oprot->writeMessageEnd();
  9216. oprot->getTransport()->writeEnd();
  9217. oprot->getTransport()->flush();
  9218. return;
  9219. }
  9220. if (eventHandler_.get() != NULL) {
  9221. eventHandler_->preWrite(ctx, "Cassandra.describe_splits");
  9222. }
  9223. oprot->writeMessageBegin("describe_splits", ::apache::thrift::protocol::T_REPLY, seqid);
  9224. result.write(oprot);
  9225. oprot->writeMessageEnd();
  9226. bytes = oprot->getTransport()->writeEnd();
  9227. oprot->getTransport()->flush();
  9228. if (eventHandler_.get() != NULL) {
  9229. eventHandler_->postWrite(ctx, "Cassandra.describe_splits", bytes);
  9230. }
  9231. }
  9232. void CassandraProcessor::process_system_add_column_family(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9233. {
  9234. void* ctx = NULL;
  9235. if (eventHandler_.get() != NULL) {
  9236. ctx = eventHandler_->getContext("Cassandra.system_add_column_family", callContext);
  9237. }
  9238. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_add_column_family");
  9239. if (eventHandler_.get() != NULL) {
  9240. eventHandler_->preRead(ctx, "Cassandra.system_add_column_family");
  9241. }
  9242. Cassandra_system_add_column_family_args args;
  9243. args.read(iprot);
  9244. iprot->readMessageEnd();
  9245. uint32_t bytes = iprot->getTransport()->readEnd();
  9246. if (eventHandler_.get() != NULL) {
  9247. eventHandler_->postRead(ctx, "Cassandra.system_add_column_family", bytes);
  9248. }
  9249. Cassandra_system_add_column_family_result result;
  9250. try {
  9251. iface_->system_add_column_family(result.success, args.cf_def);
  9252. result.__isset.success = true;
  9253. } catch (InvalidRequestException &ire) {
  9254. result.ire = ire;
  9255. result.__isset.ire = true;
  9256. } catch (SchemaDisagreementException &sde) {
  9257. result.sde = sde;
  9258. result.__isset.sde = true;
  9259. } catch (const std::exception& e) {
  9260. if (eventHandler_.get() != NULL) {
  9261. eventHandler_->handlerError(ctx, "Cassandra.system_add_column_family");
  9262. }
  9263. ::apache::thrift::TApplicationException x(e.what());
  9264. oprot->writeMessageBegin("system_add_column_family", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9265. x.write(oprot);
  9266. oprot->writeMessageEnd();
  9267. oprot->getTransport()->writeEnd();
  9268. oprot->getTransport()->flush();
  9269. return;
  9270. }
  9271. if (eventHandler_.get() != NULL) {
  9272. eventHandler_->preWrite(ctx, "Cassandra.system_add_column_family");
  9273. }
  9274. oprot->writeMessageBegin("system_add_column_family", ::apache::thrift::protocol::T_REPLY, seqid);
  9275. result.write(oprot);
  9276. oprot->writeMessageEnd();
  9277. bytes = oprot->getTransport()->writeEnd();
  9278. oprot->getTransport()->flush();
  9279. if (eventHandler_.get() != NULL) {
  9280. eventHandler_->postWrite(ctx, "Cassandra.system_add_column_family", bytes);
  9281. }
  9282. }
  9283. void CassandraProcessor::process_system_drop_column_family(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9284. {
  9285. void* ctx = NULL;
  9286. if (eventHandler_.get() != NULL) {
  9287. ctx = eventHandler_->getContext("Cassandra.system_drop_column_family", callContext);
  9288. }
  9289. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_drop_column_family");
  9290. if (eventHandler_.get() != NULL) {
  9291. eventHandler_->preRead(ctx, "Cassandra.system_drop_column_family");
  9292. }
  9293. Cassandra_system_drop_column_family_args args;
  9294. args.read(iprot);
  9295. iprot->readMessageEnd();
  9296. uint32_t bytes = iprot->getTransport()->readEnd();
  9297. if (eventHandler_.get() != NULL) {
  9298. eventHandler_->postRead(ctx, "Cassandra.system_drop_column_family", bytes);
  9299. }
  9300. Cassandra_system_drop_column_family_result result;
  9301. try {
  9302. iface_->system_drop_column_family(result.success, args.column_family);
  9303. result.__isset.success = true;
  9304. } catch (InvalidRequestException &ire) {
  9305. result.ire = ire;
  9306. result.__isset.ire = true;
  9307. } catch (SchemaDisagreementException &sde) {
  9308. result.sde = sde;
  9309. result.__isset.sde = true;
  9310. } catch (const std::exception& e) {
  9311. if (eventHandler_.get() != NULL) {
  9312. eventHandler_->handlerError(ctx, "Cassandra.system_drop_column_family");
  9313. }
  9314. ::apache::thrift::TApplicationException x(e.what());
  9315. oprot->writeMessageBegin("system_drop_column_family", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9316. x.write(oprot);
  9317. oprot->writeMessageEnd();
  9318. oprot->getTransport()->writeEnd();
  9319. oprot->getTransport()->flush();
  9320. return;
  9321. }
  9322. if (eventHandler_.get() != NULL) {
  9323. eventHandler_->preWrite(ctx, "Cassandra.system_drop_column_family");
  9324. }
  9325. oprot->writeMessageBegin("system_drop_column_family", ::apache::thrift::protocol::T_REPLY, seqid);
  9326. result.write(oprot);
  9327. oprot->writeMessageEnd();
  9328. bytes = oprot->getTransport()->writeEnd();
  9329. oprot->getTransport()->flush();
  9330. if (eventHandler_.get() != NULL) {
  9331. eventHandler_->postWrite(ctx, "Cassandra.system_drop_column_family", bytes);
  9332. }
  9333. }
  9334. void CassandraProcessor::process_system_add_keyspace(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9335. {
  9336. void* ctx = NULL;
  9337. if (eventHandler_.get() != NULL) {
  9338. ctx = eventHandler_->getContext("Cassandra.system_add_keyspace", callContext);
  9339. }
  9340. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_add_keyspace");
  9341. if (eventHandler_.get() != NULL) {
  9342. eventHandler_->preRead(ctx, "Cassandra.system_add_keyspace");
  9343. }
  9344. Cassandra_system_add_keyspace_args args;
  9345. args.read(iprot);
  9346. iprot->readMessageEnd();
  9347. uint32_t bytes = iprot->getTransport()->readEnd();
  9348. if (eventHandler_.get() != NULL) {
  9349. eventHandler_->postRead(ctx, "Cassandra.system_add_keyspace", bytes);
  9350. }
  9351. Cassandra_system_add_keyspace_result result;
  9352. try {
  9353. iface_->system_add_keyspace(result.success, args.ks_def);
  9354. result.__isset.success = true;
  9355. } catch (InvalidRequestException &ire) {
  9356. result.ire = ire;
  9357. result.__isset.ire = true;
  9358. } catch (SchemaDisagreementException &sde) {
  9359. result.sde = sde;
  9360. result.__isset.sde = true;
  9361. } catch (const std::exception& e) {
  9362. if (eventHandler_.get() != NULL) {
  9363. eventHandler_->handlerError(ctx, "Cassandra.system_add_keyspace");
  9364. }
  9365. ::apache::thrift::TApplicationException x(e.what());
  9366. oprot->writeMessageBegin("system_add_keyspace", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9367. x.write(oprot);
  9368. oprot->writeMessageEnd();
  9369. oprot->getTransport()->writeEnd();
  9370. oprot->getTransport()->flush();
  9371. return;
  9372. }
  9373. if (eventHandler_.get() != NULL) {
  9374. eventHandler_->preWrite(ctx, "Cassandra.system_add_keyspace");
  9375. }
  9376. oprot->writeMessageBegin("system_add_keyspace", ::apache::thrift::protocol::T_REPLY, seqid);
  9377. result.write(oprot);
  9378. oprot->writeMessageEnd();
  9379. bytes = oprot->getTransport()->writeEnd();
  9380. oprot->getTransport()->flush();
  9381. if (eventHandler_.get() != NULL) {
  9382. eventHandler_->postWrite(ctx, "Cassandra.system_add_keyspace", bytes);
  9383. }
  9384. }
  9385. void CassandraProcessor::process_system_drop_keyspace(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9386. {
  9387. void* ctx = NULL;
  9388. if (eventHandler_.get() != NULL) {
  9389. ctx = eventHandler_->getContext("Cassandra.system_drop_keyspace", callContext);
  9390. }
  9391. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_drop_keyspace");
  9392. if (eventHandler_.get() != NULL) {
  9393. eventHandler_->preRead(ctx, "Cassandra.system_drop_keyspace");
  9394. }
  9395. Cassandra_system_drop_keyspace_args args;
  9396. args.read(iprot);
  9397. iprot->readMessageEnd();
  9398. uint32_t bytes = iprot->getTransport()->readEnd();
  9399. if (eventHandler_.get() != NULL) {
  9400. eventHandler_->postRead(ctx, "Cassandra.system_drop_keyspace", bytes);
  9401. }
  9402. Cassandra_system_drop_keyspace_result result;
  9403. try {
  9404. iface_->system_drop_keyspace(result.success, args.keyspace);
  9405. result.__isset.success = true;
  9406. } catch (InvalidRequestException &ire) {
  9407. result.ire = ire;
  9408. result.__isset.ire = true;
  9409. } catch (SchemaDisagreementException &sde) {
  9410. result.sde = sde;
  9411. result.__isset.sde = true;
  9412. } catch (const std::exception& e) {
  9413. if (eventHandler_.get() != NULL) {
  9414. eventHandler_->handlerError(ctx, "Cassandra.system_drop_keyspace");
  9415. }
  9416. ::apache::thrift::TApplicationException x(e.what());
  9417. oprot->writeMessageBegin("system_drop_keyspace", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9418. x.write(oprot);
  9419. oprot->writeMessageEnd();
  9420. oprot->getTransport()->writeEnd();
  9421. oprot->getTransport()->flush();
  9422. return;
  9423. }
  9424. if (eventHandler_.get() != NULL) {
  9425. eventHandler_->preWrite(ctx, "Cassandra.system_drop_keyspace");
  9426. }
  9427. oprot->writeMessageBegin("system_drop_keyspace", ::apache::thrift::protocol::T_REPLY, seqid);
  9428. result.write(oprot);
  9429. oprot->writeMessageEnd();
  9430. bytes = oprot->getTransport()->writeEnd();
  9431. oprot->getTransport()->flush();
  9432. if (eventHandler_.get() != NULL) {
  9433. eventHandler_->postWrite(ctx, "Cassandra.system_drop_keyspace", bytes);
  9434. }
  9435. }
  9436. void CassandraProcessor::process_system_update_keyspace(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9437. {
  9438. void* ctx = NULL;
  9439. if (eventHandler_.get() != NULL) {
  9440. ctx = eventHandler_->getContext("Cassandra.system_update_keyspace", callContext);
  9441. }
  9442. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_update_keyspace");
  9443. if (eventHandler_.get() != NULL) {
  9444. eventHandler_->preRead(ctx, "Cassandra.system_update_keyspace");
  9445. }
  9446. Cassandra_system_update_keyspace_args args;
  9447. args.read(iprot);
  9448. iprot->readMessageEnd();
  9449. uint32_t bytes = iprot->getTransport()->readEnd();
  9450. if (eventHandler_.get() != NULL) {
  9451. eventHandler_->postRead(ctx, "Cassandra.system_update_keyspace", bytes);
  9452. }
  9453. Cassandra_system_update_keyspace_result result;
  9454. try {
  9455. iface_->system_update_keyspace(result.success, args.ks_def);
  9456. result.__isset.success = true;
  9457. } catch (InvalidRequestException &ire) {
  9458. result.ire = ire;
  9459. result.__isset.ire = true;
  9460. } catch (SchemaDisagreementException &sde) {
  9461. result.sde = sde;
  9462. result.__isset.sde = true;
  9463. } catch (const std::exception& e) {
  9464. if (eventHandler_.get() != NULL) {
  9465. eventHandler_->handlerError(ctx, "Cassandra.system_update_keyspace");
  9466. }
  9467. ::apache::thrift::TApplicationException x(e.what());
  9468. oprot->writeMessageBegin("system_update_keyspace", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9469. x.write(oprot);
  9470. oprot->writeMessageEnd();
  9471. oprot->getTransport()->writeEnd();
  9472. oprot->getTransport()->flush();
  9473. return;
  9474. }
  9475. if (eventHandler_.get() != NULL) {
  9476. eventHandler_->preWrite(ctx, "Cassandra.system_update_keyspace");
  9477. }
  9478. oprot->writeMessageBegin("system_update_keyspace", ::apache::thrift::protocol::T_REPLY, seqid);
  9479. result.write(oprot);
  9480. oprot->writeMessageEnd();
  9481. bytes = oprot->getTransport()->writeEnd();
  9482. oprot->getTransport()->flush();
  9483. if (eventHandler_.get() != NULL) {
  9484. eventHandler_->postWrite(ctx, "Cassandra.system_update_keyspace", bytes);
  9485. }
  9486. }
  9487. void CassandraProcessor::process_system_update_column_family(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9488. {
  9489. void* ctx = NULL;
  9490. if (eventHandler_.get() != NULL) {
  9491. ctx = eventHandler_->getContext("Cassandra.system_update_column_family", callContext);
  9492. }
  9493. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.system_update_column_family");
  9494. if (eventHandler_.get() != NULL) {
  9495. eventHandler_->preRead(ctx, "Cassandra.system_update_column_family");
  9496. }
  9497. Cassandra_system_update_column_family_args args;
  9498. args.read(iprot);
  9499. iprot->readMessageEnd();
  9500. uint32_t bytes = iprot->getTransport()->readEnd();
  9501. if (eventHandler_.get() != NULL) {
  9502. eventHandler_->postRead(ctx, "Cassandra.system_update_column_family", bytes);
  9503. }
  9504. Cassandra_system_update_column_family_result result;
  9505. try {
  9506. iface_->system_update_column_family(result.success, args.cf_def);
  9507. result.__isset.success = true;
  9508. } catch (InvalidRequestException &ire) {
  9509. result.ire = ire;
  9510. result.__isset.ire = true;
  9511. } catch (SchemaDisagreementException &sde) {
  9512. result.sde = sde;
  9513. result.__isset.sde = true;
  9514. } catch (const std::exception& e) {
  9515. if (eventHandler_.get() != NULL) {
  9516. eventHandler_->handlerError(ctx, "Cassandra.system_update_column_family");
  9517. }
  9518. ::apache::thrift::TApplicationException x(e.what());
  9519. oprot->writeMessageBegin("system_update_column_family", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9520. x.write(oprot);
  9521. oprot->writeMessageEnd();
  9522. oprot->getTransport()->writeEnd();
  9523. oprot->getTransport()->flush();
  9524. return;
  9525. }
  9526. if (eventHandler_.get() != NULL) {
  9527. eventHandler_->preWrite(ctx, "Cassandra.system_update_column_family");
  9528. }
  9529. oprot->writeMessageBegin("system_update_column_family", ::apache::thrift::protocol::T_REPLY, seqid);
  9530. result.write(oprot);
  9531. oprot->writeMessageEnd();
  9532. bytes = oprot->getTransport()->writeEnd();
  9533. oprot->getTransport()->flush();
  9534. if (eventHandler_.get() != NULL) {
  9535. eventHandler_->postWrite(ctx, "Cassandra.system_update_column_family", bytes);
  9536. }
  9537. }
  9538. void CassandraProcessor::process_execute_cql_query(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext)
  9539. {
  9540. void* ctx = NULL;
  9541. if (eventHandler_.get() != NULL) {
  9542. ctx = eventHandler_->getContext("Cassandra.execute_cql_query", callContext);
  9543. }
  9544. ::apache::thrift::TProcessorContextFreer freer(eventHandler_.get(), ctx, "Cassandra.execute_cql_query");
  9545. if (eventHandler_.get() != NULL) {
  9546. eventHandler_->preRead(ctx, "Cassandra.execute_cql_query");
  9547. }
  9548. Cassandra_execute_cql_query_args args;
  9549. args.read(iprot);
  9550. iprot->readMessageEnd();
  9551. uint32_t bytes = iprot->getTransport()->readEnd();
  9552. if (eventHandler_.get() != NULL) {
  9553. eventHandler_->postRead(ctx, "Cassandra.execute_cql_query", bytes);
  9554. }
  9555. Cassandra_execute_cql_query_result result;
  9556. try {
  9557. iface_->execute_cql_query(result.success, args.query, args.compression);
  9558. result.__isset.success = true;
  9559. } catch (InvalidRequestException &ire) {
  9560. result.ire = ire;
  9561. result.__isset.ire = true;
  9562. } catch (UnavailableException &ue) {
  9563. result.ue = ue;
  9564. result.__isset.ue = true;
  9565. } catch (TimedOutException &te) {
  9566. result.te = te;
  9567. result.__isset.te = true;
  9568. } catch (SchemaDisagreementException &sde) {
  9569. result.sde = sde;
  9570. result.__isset.sde = true;
  9571. } catch (const std::exception& e) {
  9572. if (eventHandler_.get() != NULL) {
  9573. eventHandler_->handlerError(ctx, "Cassandra.execute_cql_query");
  9574. }
  9575. ::apache::thrift::TApplicationException x(e.what());
  9576. oprot->writeMessageBegin("execute_cql_query", ::apache::thrift::protocol::T_EXCEPTION, seqid);
  9577. x.write(oprot);
  9578. oprot->writeMessageEnd();
  9579. oprot->getTransport()->writeEnd();
  9580. oprot->getTransport()->flush();
  9581. return;
  9582. }
  9583. if (eventHandler_.get() != NULL) {
  9584. eventHandler_->preWrite(ctx, "Cassandra.execute_cql_query");
  9585. }
  9586. oprot->writeMessageBegin("execute_cql_query", ::apache::thrift::protocol::T_REPLY, seqid);
  9587. result.write(oprot);
  9588. oprot->writeMessageEnd();
  9589. bytes = oprot->getTransport()->writeEnd();
  9590. oprot->getTransport()->flush();
  9591. if (eventHandler_.get() != NULL) {
  9592. eventHandler_->postWrite(ctx, "Cassandra.execute_cql_query", bytes);
  9593. }
  9594. }
  9595. }}} // namespace