json_format_proto3.pb.cc 401 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771
  1. // Generated by the protocol buffer compiler. DO NOT EDIT!
  2. // source: google/protobuf/util/json_format_proto3.proto
  3. #include <google/protobuf/util/json_format_proto3.pb.h>
  4. #include <algorithm>
  5. #include <google/protobuf/stubs/common.h>
  6. #include <google/protobuf/stubs/port.h>
  7. #include <google/protobuf/io/coded_stream.h>
  8. #include <google/protobuf/wire_format_lite_inl.h>
  9. #include <google/protobuf/descriptor.h>
  10. #include <google/protobuf/generated_message_reflection.h>
  11. #include <google/protobuf/reflection_ops.h>
  12. #include <google/protobuf/wire_format.h>
  13. // This is a temporary google only hack
  14. #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
  15. #include "third_party/protobuf/version.h"
  16. #endif
  17. // @@protoc_insertion_point(includes)
  18. namespace protobuf_google_2fprotobuf_2fany_2eproto {
  19. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fany_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Any;
  20. } // namespace protobuf_google_2fprotobuf_2fany_2eproto
  21. namespace protobuf_google_2fprotobuf_2fduration_2eproto {
  22. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fduration_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Duration;
  23. } // namespace protobuf_google_2fprotobuf_2fduration_2eproto
  24. namespace protobuf_google_2fprotobuf_2ffield_5fmask_2eproto {
  25. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2ffield_5fmask_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_FieldMask;
  26. } // namespace protobuf_google_2fprotobuf_2ffield_5fmask_2eproto
  27. namespace protobuf_google_2fprotobuf_2fstruct_2eproto {
  28. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fstruct_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_ListValue;
  29. } // namespace protobuf_google_2fprotobuf_2fstruct_2eproto
  30. namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto {
  31. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2ftimestamp_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Timestamp;
  32. } // namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto
  33. namespace protobuf_google_2fprotobuf_2funittest_2eproto {
  34. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2funittest_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestAllExtensions;
  35. } // namespace protobuf_google_2fprotobuf_2funittest_2eproto
  36. namespace protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto {
  37. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_MessageType;
  38. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestBoolValue_BoolMapEntry_DoNotUse;
  39. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_BoolMapEntry_DoNotUse;
  40. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Int32MapEntry_DoNotUse;
  41. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Int64MapEntry_DoNotUse;
  42. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_StringMapEntry_DoNotUse;
  43. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Uint32MapEntry_DoNotUse;
  44. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Uint64MapEntry_DoNotUse;
  45. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_BoolMapEntry_DoNotUse;
  46. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Int32MapEntry_DoNotUse;
  47. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Int64MapEntry_DoNotUse;
  48. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_StringMapEntry_DoNotUse;
  49. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Uint32MapEntry_DoNotUse;
  50. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Uint64MapEntry_DoNotUse;
  51. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto ::google::protobuf::internal::SCCInfo<6> scc_info_TestNestedMap;
  52. } // namespace protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto
  53. namespace protobuf_google_2fprotobuf_2fwrappers_2eproto {
  54. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_BoolValue;
  55. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_BytesValue;
  56. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_DoubleValue;
  57. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_FloatValue;
  58. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Int32Value;
  59. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Int64Value;
  60. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_StringValue;
  61. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_UInt32Value;
  62. extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fwrappers_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_UInt64Value;
  63. } // namespace protobuf_google_2fprotobuf_2fwrappers_2eproto
  64. namespace proto3 {
  65. class MessageTypeDefaultTypeInternal {
  66. public:
  67. ::google::protobuf::internal::ExplicitlyConstructed<MessageType>
  68. _instance;
  69. } _MessageType_default_instance_;
  70. class TestMessageDefaultTypeInternal {
  71. public:
  72. ::google::protobuf::internal::ExplicitlyConstructed<TestMessage>
  73. _instance;
  74. } _TestMessage_default_instance_;
  75. class TestOneofDefaultTypeInternal {
  76. public:
  77. ::google::protobuf::internal::ExplicitlyConstructed<TestOneof>
  78. _instance;
  79. ::google::protobuf::int32 oneof_int32_value_;
  80. ::google::protobuf::internal::ArenaStringPtr oneof_string_value_;
  81. ::google::protobuf::internal::ArenaStringPtr oneof_bytes_value_;
  82. int oneof_enum_value_;
  83. const ::proto3::MessageType* oneof_message_value_;
  84. } _TestOneof_default_instance_;
  85. class TestMap_BoolMapEntry_DoNotUseDefaultTypeInternal {
  86. public:
  87. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_BoolMapEntry_DoNotUse>
  88. _instance;
  89. } _TestMap_BoolMapEntry_DoNotUse_default_instance_;
  90. class TestMap_Int32MapEntry_DoNotUseDefaultTypeInternal {
  91. public:
  92. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_Int32MapEntry_DoNotUse>
  93. _instance;
  94. } _TestMap_Int32MapEntry_DoNotUse_default_instance_;
  95. class TestMap_Int64MapEntry_DoNotUseDefaultTypeInternal {
  96. public:
  97. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_Int64MapEntry_DoNotUse>
  98. _instance;
  99. } _TestMap_Int64MapEntry_DoNotUse_default_instance_;
  100. class TestMap_Uint32MapEntry_DoNotUseDefaultTypeInternal {
  101. public:
  102. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_Uint32MapEntry_DoNotUse>
  103. _instance;
  104. } _TestMap_Uint32MapEntry_DoNotUse_default_instance_;
  105. class TestMap_Uint64MapEntry_DoNotUseDefaultTypeInternal {
  106. public:
  107. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_Uint64MapEntry_DoNotUse>
  108. _instance;
  109. } _TestMap_Uint64MapEntry_DoNotUse_default_instance_;
  110. class TestMap_StringMapEntry_DoNotUseDefaultTypeInternal {
  111. public:
  112. ::google::protobuf::internal::ExplicitlyConstructed<TestMap_StringMapEntry_DoNotUse>
  113. _instance;
  114. } _TestMap_StringMapEntry_DoNotUse_default_instance_;
  115. class TestMapDefaultTypeInternal {
  116. public:
  117. ::google::protobuf::internal::ExplicitlyConstructed<TestMap>
  118. _instance;
  119. } _TestMap_default_instance_;
  120. class TestNestedMap_BoolMapEntry_DoNotUseDefaultTypeInternal {
  121. public:
  122. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_BoolMapEntry_DoNotUse>
  123. _instance;
  124. } _TestNestedMap_BoolMapEntry_DoNotUse_default_instance_;
  125. class TestNestedMap_Int32MapEntry_DoNotUseDefaultTypeInternal {
  126. public:
  127. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_Int32MapEntry_DoNotUse>
  128. _instance;
  129. } _TestNestedMap_Int32MapEntry_DoNotUse_default_instance_;
  130. class TestNestedMap_Int64MapEntry_DoNotUseDefaultTypeInternal {
  131. public:
  132. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_Int64MapEntry_DoNotUse>
  133. _instance;
  134. } _TestNestedMap_Int64MapEntry_DoNotUse_default_instance_;
  135. class TestNestedMap_Uint32MapEntry_DoNotUseDefaultTypeInternal {
  136. public:
  137. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_Uint32MapEntry_DoNotUse>
  138. _instance;
  139. } _TestNestedMap_Uint32MapEntry_DoNotUse_default_instance_;
  140. class TestNestedMap_Uint64MapEntry_DoNotUseDefaultTypeInternal {
  141. public:
  142. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_Uint64MapEntry_DoNotUse>
  143. _instance;
  144. } _TestNestedMap_Uint64MapEntry_DoNotUse_default_instance_;
  145. class TestNestedMap_StringMapEntry_DoNotUseDefaultTypeInternal {
  146. public:
  147. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_StringMapEntry_DoNotUse>
  148. _instance;
  149. } _TestNestedMap_StringMapEntry_DoNotUse_default_instance_;
  150. class TestNestedMap_MapMapEntry_DoNotUseDefaultTypeInternal {
  151. public:
  152. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap_MapMapEntry_DoNotUse>
  153. _instance;
  154. } _TestNestedMap_MapMapEntry_DoNotUse_default_instance_;
  155. class TestNestedMapDefaultTypeInternal {
  156. public:
  157. ::google::protobuf::internal::ExplicitlyConstructed<TestNestedMap>
  158. _instance;
  159. } _TestNestedMap_default_instance_;
  160. class TestWrapperDefaultTypeInternal {
  161. public:
  162. ::google::protobuf::internal::ExplicitlyConstructed<TestWrapper>
  163. _instance;
  164. } _TestWrapper_default_instance_;
  165. class TestTimestampDefaultTypeInternal {
  166. public:
  167. ::google::protobuf::internal::ExplicitlyConstructed<TestTimestamp>
  168. _instance;
  169. } _TestTimestamp_default_instance_;
  170. class TestDurationDefaultTypeInternal {
  171. public:
  172. ::google::protobuf::internal::ExplicitlyConstructed<TestDuration>
  173. _instance;
  174. } _TestDuration_default_instance_;
  175. class TestFieldMaskDefaultTypeInternal {
  176. public:
  177. ::google::protobuf::internal::ExplicitlyConstructed<TestFieldMask>
  178. _instance;
  179. } _TestFieldMask_default_instance_;
  180. class TestStructDefaultTypeInternal {
  181. public:
  182. ::google::protobuf::internal::ExplicitlyConstructed<TestStruct>
  183. _instance;
  184. } _TestStruct_default_instance_;
  185. class TestAnyDefaultTypeInternal {
  186. public:
  187. ::google::protobuf::internal::ExplicitlyConstructed<TestAny>
  188. _instance;
  189. } _TestAny_default_instance_;
  190. class TestValueDefaultTypeInternal {
  191. public:
  192. ::google::protobuf::internal::ExplicitlyConstructed<TestValue>
  193. _instance;
  194. } _TestValue_default_instance_;
  195. class TestListValueDefaultTypeInternal {
  196. public:
  197. ::google::protobuf::internal::ExplicitlyConstructed<TestListValue>
  198. _instance;
  199. } _TestListValue_default_instance_;
  200. class TestBoolValue_BoolMapEntry_DoNotUseDefaultTypeInternal {
  201. public:
  202. ::google::protobuf::internal::ExplicitlyConstructed<TestBoolValue_BoolMapEntry_DoNotUse>
  203. _instance;
  204. } _TestBoolValue_BoolMapEntry_DoNotUse_default_instance_;
  205. class TestBoolValueDefaultTypeInternal {
  206. public:
  207. ::google::protobuf::internal::ExplicitlyConstructed<TestBoolValue>
  208. _instance;
  209. } _TestBoolValue_default_instance_;
  210. class TestCustomJsonNameDefaultTypeInternal {
  211. public:
  212. ::google::protobuf::internal::ExplicitlyConstructed<TestCustomJsonName>
  213. _instance;
  214. } _TestCustomJsonName_default_instance_;
  215. class TestExtensionsDefaultTypeInternal {
  216. public:
  217. ::google::protobuf::internal::ExplicitlyConstructed<TestExtensions>
  218. _instance;
  219. } _TestExtensions_default_instance_;
  220. class TestEnumValueDefaultTypeInternal {
  221. public:
  222. ::google::protobuf::internal::ExplicitlyConstructed<TestEnumValue>
  223. _instance;
  224. } _TestEnumValue_default_instance_;
  225. } // namespace proto3
  226. namespace protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto {
  227. static void InitDefaultsMessageType() {
  228. GOOGLE_PROTOBUF_VERIFY_VERSION;
  229. {
  230. void* ptr = &::proto3::_MessageType_default_instance_;
  231. new (ptr) ::proto3::MessageType();
  232. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  233. }
  234. ::proto3::MessageType::InitAsDefaultInstance();
  235. }
  236. ::google::protobuf::internal::SCCInfo<0> scc_info_MessageType =
  237. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsMessageType}, {}};
  238. static void InitDefaultsTestMessage() {
  239. GOOGLE_PROTOBUF_VERIFY_VERSION;
  240. {
  241. void* ptr = &::proto3::_TestMessage_default_instance_;
  242. new (ptr) ::proto3::TestMessage();
  243. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  244. }
  245. ::proto3::TestMessage::InitAsDefaultInstance();
  246. }
  247. ::google::protobuf::internal::SCCInfo<1> scc_info_TestMessage =
  248. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestMessage}, {
  249. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_MessageType.base,}};
  250. static void InitDefaultsTestOneof() {
  251. GOOGLE_PROTOBUF_VERIFY_VERSION;
  252. {
  253. void* ptr = &::proto3::_TestOneof_default_instance_;
  254. new (ptr) ::proto3::TestOneof();
  255. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  256. }
  257. ::proto3::TestOneof::InitAsDefaultInstance();
  258. }
  259. ::google::protobuf::internal::SCCInfo<1> scc_info_TestOneof =
  260. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestOneof}, {
  261. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_MessageType.base,}};
  262. static void InitDefaultsTestMap_BoolMapEntry_DoNotUse() {
  263. GOOGLE_PROTOBUF_VERIFY_VERSION;
  264. {
  265. void* ptr = &::proto3::_TestMap_BoolMapEntry_DoNotUse_default_instance_;
  266. new (ptr) ::proto3::TestMap_BoolMapEntry_DoNotUse();
  267. }
  268. ::proto3::TestMap_BoolMapEntry_DoNotUse::InitAsDefaultInstance();
  269. }
  270. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_BoolMapEntry_DoNotUse =
  271. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_BoolMapEntry_DoNotUse}, {}};
  272. static void InitDefaultsTestMap_Int32MapEntry_DoNotUse() {
  273. GOOGLE_PROTOBUF_VERIFY_VERSION;
  274. {
  275. void* ptr = &::proto3::_TestMap_Int32MapEntry_DoNotUse_default_instance_;
  276. new (ptr) ::proto3::TestMap_Int32MapEntry_DoNotUse();
  277. }
  278. ::proto3::TestMap_Int32MapEntry_DoNotUse::InitAsDefaultInstance();
  279. }
  280. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Int32MapEntry_DoNotUse =
  281. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_Int32MapEntry_DoNotUse}, {}};
  282. static void InitDefaultsTestMap_Int64MapEntry_DoNotUse() {
  283. GOOGLE_PROTOBUF_VERIFY_VERSION;
  284. {
  285. void* ptr = &::proto3::_TestMap_Int64MapEntry_DoNotUse_default_instance_;
  286. new (ptr) ::proto3::TestMap_Int64MapEntry_DoNotUse();
  287. }
  288. ::proto3::TestMap_Int64MapEntry_DoNotUse::InitAsDefaultInstance();
  289. }
  290. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Int64MapEntry_DoNotUse =
  291. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_Int64MapEntry_DoNotUse}, {}};
  292. static void InitDefaultsTestMap_Uint32MapEntry_DoNotUse() {
  293. GOOGLE_PROTOBUF_VERIFY_VERSION;
  294. {
  295. void* ptr = &::proto3::_TestMap_Uint32MapEntry_DoNotUse_default_instance_;
  296. new (ptr) ::proto3::TestMap_Uint32MapEntry_DoNotUse();
  297. }
  298. ::proto3::TestMap_Uint32MapEntry_DoNotUse::InitAsDefaultInstance();
  299. }
  300. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Uint32MapEntry_DoNotUse =
  301. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_Uint32MapEntry_DoNotUse}, {}};
  302. static void InitDefaultsTestMap_Uint64MapEntry_DoNotUse() {
  303. GOOGLE_PROTOBUF_VERIFY_VERSION;
  304. {
  305. void* ptr = &::proto3::_TestMap_Uint64MapEntry_DoNotUse_default_instance_;
  306. new (ptr) ::proto3::TestMap_Uint64MapEntry_DoNotUse();
  307. }
  308. ::proto3::TestMap_Uint64MapEntry_DoNotUse::InitAsDefaultInstance();
  309. }
  310. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_Uint64MapEntry_DoNotUse =
  311. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_Uint64MapEntry_DoNotUse}, {}};
  312. static void InitDefaultsTestMap_StringMapEntry_DoNotUse() {
  313. GOOGLE_PROTOBUF_VERIFY_VERSION;
  314. {
  315. void* ptr = &::proto3::_TestMap_StringMapEntry_DoNotUse_default_instance_;
  316. new (ptr) ::proto3::TestMap_StringMapEntry_DoNotUse();
  317. }
  318. ::proto3::TestMap_StringMapEntry_DoNotUse::InitAsDefaultInstance();
  319. }
  320. ::google::protobuf::internal::SCCInfo<0> scc_info_TestMap_StringMapEntry_DoNotUse =
  321. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestMap_StringMapEntry_DoNotUse}, {}};
  322. static void InitDefaultsTestMap() {
  323. GOOGLE_PROTOBUF_VERIFY_VERSION;
  324. {
  325. void* ptr = &::proto3::_TestMap_default_instance_;
  326. new (ptr) ::proto3::TestMap();
  327. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  328. }
  329. ::proto3::TestMap::InitAsDefaultInstance();
  330. }
  331. ::google::protobuf::internal::SCCInfo<6> scc_info_TestMap =
  332. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 6, InitDefaultsTestMap}, {
  333. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_BoolMapEntry_DoNotUse.base,
  334. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_Int32MapEntry_DoNotUse.base,
  335. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_Int64MapEntry_DoNotUse.base,
  336. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_Uint32MapEntry_DoNotUse.base,
  337. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_Uint64MapEntry_DoNotUse.base,
  338. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap_StringMapEntry_DoNotUse.base,}};
  339. static void InitDefaultsTestNestedMap_BoolMapEntry_DoNotUse() {
  340. GOOGLE_PROTOBUF_VERIFY_VERSION;
  341. {
  342. void* ptr = &::proto3::_TestNestedMap_BoolMapEntry_DoNotUse_default_instance_;
  343. new (ptr) ::proto3::TestNestedMap_BoolMapEntry_DoNotUse();
  344. }
  345. ::proto3::TestNestedMap_BoolMapEntry_DoNotUse::InitAsDefaultInstance();
  346. }
  347. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_BoolMapEntry_DoNotUse =
  348. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_BoolMapEntry_DoNotUse}, {}};
  349. static void InitDefaultsTestNestedMap_Int32MapEntry_DoNotUse() {
  350. GOOGLE_PROTOBUF_VERIFY_VERSION;
  351. {
  352. void* ptr = &::proto3::_TestNestedMap_Int32MapEntry_DoNotUse_default_instance_;
  353. new (ptr) ::proto3::TestNestedMap_Int32MapEntry_DoNotUse();
  354. }
  355. ::proto3::TestNestedMap_Int32MapEntry_DoNotUse::InitAsDefaultInstance();
  356. }
  357. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Int32MapEntry_DoNotUse =
  358. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_Int32MapEntry_DoNotUse}, {}};
  359. static void InitDefaultsTestNestedMap_Int64MapEntry_DoNotUse() {
  360. GOOGLE_PROTOBUF_VERIFY_VERSION;
  361. {
  362. void* ptr = &::proto3::_TestNestedMap_Int64MapEntry_DoNotUse_default_instance_;
  363. new (ptr) ::proto3::TestNestedMap_Int64MapEntry_DoNotUse();
  364. }
  365. ::proto3::TestNestedMap_Int64MapEntry_DoNotUse::InitAsDefaultInstance();
  366. }
  367. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Int64MapEntry_DoNotUse =
  368. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_Int64MapEntry_DoNotUse}, {}};
  369. static void InitDefaultsTestNestedMap_Uint32MapEntry_DoNotUse() {
  370. GOOGLE_PROTOBUF_VERIFY_VERSION;
  371. {
  372. void* ptr = &::proto3::_TestNestedMap_Uint32MapEntry_DoNotUse_default_instance_;
  373. new (ptr) ::proto3::TestNestedMap_Uint32MapEntry_DoNotUse();
  374. }
  375. ::proto3::TestNestedMap_Uint32MapEntry_DoNotUse::InitAsDefaultInstance();
  376. }
  377. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Uint32MapEntry_DoNotUse =
  378. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_Uint32MapEntry_DoNotUse}, {}};
  379. static void InitDefaultsTestNestedMap_Uint64MapEntry_DoNotUse() {
  380. GOOGLE_PROTOBUF_VERIFY_VERSION;
  381. {
  382. void* ptr = &::proto3::_TestNestedMap_Uint64MapEntry_DoNotUse_default_instance_;
  383. new (ptr) ::proto3::TestNestedMap_Uint64MapEntry_DoNotUse();
  384. }
  385. ::proto3::TestNestedMap_Uint64MapEntry_DoNotUse::InitAsDefaultInstance();
  386. }
  387. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_Uint64MapEntry_DoNotUse =
  388. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_Uint64MapEntry_DoNotUse}, {}};
  389. static void InitDefaultsTestNestedMap_StringMapEntry_DoNotUse() {
  390. GOOGLE_PROTOBUF_VERIFY_VERSION;
  391. {
  392. void* ptr = &::proto3::_TestNestedMap_StringMapEntry_DoNotUse_default_instance_;
  393. new (ptr) ::proto3::TestNestedMap_StringMapEntry_DoNotUse();
  394. }
  395. ::proto3::TestNestedMap_StringMapEntry_DoNotUse::InitAsDefaultInstance();
  396. }
  397. ::google::protobuf::internal::SCCInfo<0> scc_info_TestNestedMap_StringMapEntry_DoNotUse =
  398. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestNestedMap_StringMapEntry_DoNotUse}, {}};
  399. static void InitDefaultsTestNestedMap() {
  400. GOOGLE_PROTOBUF_VERIFY_VERSION;
  401. {
  402. void* ptr = &::proto3::_TestNestedMap_MapMapEntry_DoNotUse_default_instance_;
  403. new (ptr) ::proto3::TestNestedMap_MapMapEntry_DoNotUse();
  404. }
  405. {
  406. void* ptr = &::proto3::_TestNestedMap_default_instance_;
  407. new (ptr) ::proto3::TestNestedMap();
  408. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  409. }
  410. ::proto3::TestNestedMap_MapMapEntry_DoNotUse::InitAsDefaultInstance();
  411. ::proto3::TestNestedMap::InitAsDefaultInstance();
  412. }
  413. ::google::protobuf::internal::SCCInfo<6> scc_info_TestNestedMap =
  414. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 6, InitDefaultsTestNestedMap}, {
  415. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_BoolMapEntry_DoNotUse.base,
  416. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_Int32MapEntry_DoNotUse.base,
  417. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_Int64MapEntry_DoNotUse.base,
  418. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_Uint32MapEntry_DoNotUse.base,
  419. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_Uint64MapEntry_DoNotUse.base,
  420. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap_StringMapEntry_DoNotUse.base,}};
  421. static void InitDefaultsTestWrapper() {
  422. GOOGLE_PROTOBUF_VERIFY_VERSION;
  423. {
  424. void* ptr = &::proto3::_TestWrapper_default_instance_;
  425. new (ptr) ::proto3::TestWrapper();
  426. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  427. }
  428. ::proto3::TestWrapper::InitAsDefaultInstance();
  429. }
  430. ::google::protobuf::internal::SCCInfo<9> scc_info_TestWrapper =
  431. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 9, InitDefaultsTestWrapper}, {
  432. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_BoolValue.base,
  433. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_Int32Value.base,
  434. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_Int64Value.base,
  435. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_UInt32Value.base,
  436. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_UInt64Value.base,
  437. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_FloatValue.base,
  438. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_DoubleValue.base,
  439. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_StringValue.base,
  440. &protobuf_google_2fprotobuf_2fwrappers_2eproto::scc_info_BytesValue.base,}};
  441. static void InitDefaultsTestTimestamp() {
  442. GOOGLE_PROTOBUF_VERIFY_VERSION;
  443. {
  444. void* ptr = &::proto3::_TestTimestamp_default_instance_;
  445. new (ptr) ::proto3::TestTimestamp();
  446. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  447. }
  448. ::proto3::TestTimestamp::InitAsDefaultInstance();
  449. }
  450. ::google::protobuf::internal::SCCInfo<1> scc_info_TestTimestamp =
  451. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestTimestamp}, {
  452. &protobuf_google_2fprotobuf_2ftimestamp_2eproto::scc_info_Timestamp.base,}};
  453. static void InitDefaultsTestDuration() {
  454. GOOGLE_PROTOBUF_VERIFY_VERSION;
  455. {
  456. void* ptr = &::proto3::_TestDuration_default_instance_;
  457. new (ptr) ::proto3::TestDuration();
  458. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  459. }
  460. ::proto3::TestDuration::InitAsDefaultInstance();
  461. }
  462. ::google::protobuf::internal::SCCInfo<1> scc_info_TestDuration =
  463. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestDuration}, {
  464. &protobuf_google_2fprotobuf_2fduration_2eproto::scc_info_Duration.base,}};
  465. static void InitDefaultsTestFieldMask() {
  466. GOOGLE_PROTOBUF_VERIFY_VERSION;
  467. {
  468. void* ptr = &::proto3::_TestFieldMask_default_instance_;
  469. new (ptr) ::proto3::TestFieldMask();
  470. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  471. }
  472. ::proto3::TestFieldMask::InitAsDefaultInstance();
  473. }
  474. ::google::protobuf::internal::SCCInfo<1> scc_info_TestFieldMask =
  475. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestFieldMask}, {
  476. &protobuf_google_2fprotobuf_2ffield_5fmask_2eproto::scc_info_FieldMask.base,}};
  477. static void InitDefaultsTestStruct() {
  478. GOOGLE_PROTOBUF_VERIFY_VERSION;
  479. {
  480. void* ptr = &::proto3::_TestStruct_default_instance_;
  481. new (ptr) ::proto3::TestStruct();
  482. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  483. }
  484. ::proto3::TestStruct::InitAsDefaultInstance();
  485. }
  486. ::google::protobuf::internal::SCCInfo<1> scc_info_TestStruct =
  487. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestStruct}, {
  488. &protobuf_google_2fprotobuf_2fstruct_2eproto::scc_info_ListValue.base,}};
  489. static void InitDefaultsTestAny() {
  490. GOOGLE_PROTOBUF_VERIFY_VERSION;
  491. {
  492. void* ptr = &::proto3::_TestAny_default_instance_;
  493. new (ptr) ::proto3::TestAny();
  494. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  495. }
  496. ::proto3::TestAny::InitAsDefaultInstance();
  497. }
  498. ::google::protobuf::internal::SCCInfo<1> scc_info_TestAny =
  499. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestAny}, {
  500. &protobuf_google_2fprotobuf_2fany_2eproto::scc_info_Any.base,}};
  501. static void InitDefaultsTestValue() {
  502. GOOGLE_PROTOBUF_VERIFY_VERSION;
  503. {
  504. void* ptr = &::proto3::_TestValue_default_instance_;
  505. new (ptr) ::proto3::TestValue();
  506. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  507. }
  508. ::proto3::TestValue::InitAsDefaultInstance();
  509. }
  510. ::google::protobuf::internal::SCCInfo<1> scc_info_TestValue =
  511. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestValue}, {
  512. &protobuf_google_2fprotobuf_2fstruct_2eproto::scc_info_ListValue.base,}};
  513. static void InitDefaultsTestListValue() {
  514. GOOGLE_PROTOBUF_VERIFY_VERSION;
  515. {
  516. void* ptr = &::proto3::_TestListValue_default_instance_;
  517. new (ptr) ::proto3::TestListValue();
  518. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  519. }
  520. ::proto3::TestListValue::InitAsDefaultInstance();
  521. }
  522. ::google::protobuf::internal::SCCInfo<1> scc_info_TestListValue =
  523. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestListValue}, {
  524. &protobuf_google_2fprotobuf_2fstruct_2eproto::scc_info_ListValue.base,}};
  525. static void InitDefaultsTestBoolValue_BoolMapEntry_DoNotUse() {
  526. GOOGLE_PROTOBUF_VERIFY_VERSION;
  527. {
  528. void* ptr = &::proto3::_TestBoolValue_BoolMapEntry_DoNotUse_default_instance_;
  529. new (ptr) ::proto3::TestBoolValue_BoolMapEntry_DoNotUse();
  530. }
  531. ::proto3::TestBoolValue_BoolMapEntry_DoNotUse::InitAsDefaultInstance();
  532. }
  533. ::google::protobuf::internal::SCCInfo<0> scc_info_TestBoolValue_BoolMapEntry_DoNotUse =
  534. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestBoolValue_BoolMapEntry_DoNotUse}, {}};
  535. static void InitDefaultsTestBoolValue() {
  536. GOOGLE_PROTOBUF_VERIFY_VERSION;
  537. {
  538. void* ptr = &::proto3::_TestBoolValue_default_instance_;
  539. new (ptr) ::proto3::TestBoolValue();
  540. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  541. }
  542. ::proto3::TestBoolValue::InitAsDefaultInstance();
  543. }
  544. ::google::protobuf::internal::SCCInfo<1> scc_info_TestBoolValue =
  545. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestBoolValue}, {
  546. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestBoolValue_BoolMapEntry_DoNotUse.base,}};
  547. static void InitDefaultsTestCustomJsonName() {
  548. GOOGLE_PROTOBUF_VERIFY_VERSION;
  549. {
  550. void* ptr = &::proto3::_TestCustomJsonName_default_instance_;
  551. new (ptr) ::proto3::TestCustomJsonName();
  552. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  553. }
  554. ::proto3::TestCustomJsonName::InitAsDefaultInstance();
  555. }
  556. ::google::protobuf::internal::SCCInfo<0> scc_info_TestCustomJsonName =
  557. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestCustomJsonName}, {}};
  558. static void InitDefaultsTestExtensions() {
  559. GOOGLE_PROTOBUF_VERIFY_VERSION;
  560. {
  561. void* ptr = &::proto3::_TestExtensions_default_instance_;
  562. new (ptr) ::proto3::TestExtensions();
  563. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  564. }
  565. ::proto3::TestExtensions::InitAsDefaultInstance();
  566. }
  567. ::google::protobuf::internal::SCCInfo<1> scc_info_TestExtensions =
  568. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsTestExtensions}, {
  569. &protobuf_google_2fprotobuf_2funittest_2eproto::scc_info_TestAllExtensions.base,}};
  570. static void InitDefaultsTestEnumValue() {
  571. GOOGLE_PROTOBUF_VERIFY_VERSION;
  572. {
  573. void* ptr = &::proto3::_TestEnumValue_default_instance_;
  574. new (ptr) ::proto3::TestEnumValue();
  575. ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
  576. }
  577. ::proto3::TestEnumValue::InitAsDefaultInstance();
  578. }
  579. ::google::protobuf::internal::SCCInfo<0> scc_info_TestEnumValue =
  580. {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsTestEnumValue}, {}};
  581. void InitDefaults() {
  582. ::google::protobuf::internal::InitSCC(&scc_info_MessageType.base);
  583. ::google::protobuf::internal::InitSCC(&scc_info_TestMessage.base);
  584. ::google::protobuf::internal::InitSCC(&scc_info_TestOneof.base);
  585. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_BoolMapEntry_DoNotUse.base);
  586. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_Int32MapEntry_DoNotUse.base);
  587. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_Int64MapEntry_DoNotUse.base);
  588. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_Uint32MapEntry_DoNotUse.base);
  589. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_Uint64MapEntry_DoNotUse.base);
  590. ::google::protobuf::internal::InitSCC(&scc_info_TestMap_StringMapEntry_DoNotUse.base);
  591. ::google::protobuf::internal::InitSCC(&scc_info_TestMap.base);
  592. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_BoolMapEntry_DoNotUse.base);
  593. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_Int32MapEntry_DoNotUse.base);
  594. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_Int64MapEntry_DoNotUse.base);
  595. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_Uint32MapEntry_DoNotUse.base);
  596. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_Uint64MapEntry_DoNotUse.base);
  597. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap_StringMapEntry_DoNotUse.base);
  598. ::google::protobuf::internal::InitSCC(&scc_info_TestNestedMap.base);
  599. ::google::protobuf::internal::InitSCC(&scc_info_TestWrapper.base);
  600. ::google::protobuf::internal::InitSCC(&scc_info_TestTimestamp.base);
  601. ::google::protobuf::internal::InitSCC(&scc_info_TestDuration.base);
  602. ::google::protobuf::internal::InitSCC(&scc_info_TestFieldMask.base);
  603. ::google::protobuf::internal::InitSCC(&scc_info_TestStruct.base);
  604. ::google::protobuf::internal::InitSCC(&scc_info_TestAny.base);
  605. ::google::protobuf::internal::InitSCC(&scc_info_TestValue.base);
  606. ::google::protobuf::internal::InitSCC(&scc_info_TestListValue.base);
  607. ::google::protobuf::internal::InitSCC(&scc_info_TestBoolValue_BoolMapEntry_DoNotUse.base);
  608. ::google::protobuf::internal::InitSCC(&scc_info_TestBoolValue.base);
  609. ::google::protobuf::internal::InitSCC(&scc_info_TestCustomJsonName.base);
  610. ::google::protobuf::internal::InitSCC(&scc_info_TestExtensions.base);
  611. ::google::protobuf::internal::InitSCC(&scc_info_TestEnumValue.base);
  612. }
  613. ::google::protobuf::Metadata file_level_metadata[31];
  614. const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1];
  615. const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  616. ~0u, // no _has_bits_
  617. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::MessageType, _internal_metadata_),
  618. ~0u, // no _extensions_
  619. ~0u, // no _oneof_case_
  620. ~0u, // no _weak_field_map_
  621. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::MessageType, value_),
  622. ~0u, // no _has_bits_
  623. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, _internal_metadata_),
  624. ~0u, // no _extensions_
  625. ~0u, // no _oneof_case_
  626. ~0u, // no _weak_field_map_
  627. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, bool_value_),
  628. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, int32_value_),
  629. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, int64_value_),
  630. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, uint32_value_),
  631. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, uint64_value_),
  632. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, float_value_),
  633. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, double_value_),
  634. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, string_value_),
  635. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, bytes_value_),
  636. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, enum_value_),
  637. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, message_value_),
  638. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_bool_value_),
  639. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_int32_value_),
  640. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_int64_value_),
  641. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_uint32_value_),
  642. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_uint64_value_),
  643. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_float_value_),
  644. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_double_value_),
  645. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_string_value_),
  646. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_bytes_value_),
  647. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_enum_value_),
  648. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMessage, repeated_message_value_),
  649. ~0u, // no _has_bits_
  650. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestOneof, _internal_metadata_),
  651. ~0u, // no _extensions_
  652. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestOneof, _oneof_case_[0]),
  653. ~0u, // no _weak_field_map_
  654. offsetof(::proto3::TestOneofDefaultTypeInternal, oneof_int32_value_),
  655. offsetof(::proto3::TestOneofDefaultTypeInternal, oneof_string_value_),
  656. offsetof(::proto3::TestOneofDefaultTypeInternal, oneof_bytes_value_),
  657. offsetof(::proto3::TestOneofDefaultTypeInternal, oneof_enum_value_),
  658. offsetof(::proto3::TestOneofDefaultTypeInternal, oneof_message_value_),
  659. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestOneof, oneof_value_),
  660. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_BoolMapEntry_DoNotUse, _has_bits_),
  661. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_BoolMapEntry_DoNotUse, _internal_metadata_),
  662. ~0u, // no _extensions_
  663. ~0u, // no _oneof_case_
  664. ~0u, // no _weak_field_map_
  665. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_BoolMapEntry_DoNotUse, key_),
  666. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_BoolMapEntry_DoNotUse, value_),
  667. 0,
  668. 1,
  669. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int32MapEntry_DoNotUse, _has_bits_),
  670. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int32MapEntry_DoNotUse, _internal_metadata_),
  671. ~0u, // no _extensions_
  672. ~0u, // no _oneof_case_
  673. ~0u, // no _weak_field_map_
  674. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int32MapEntry_DoNotUse, key_),
  675. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int32MapEntry_DoNotUse, value_),
  676. 0,
  677. 1,
  678. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int64MapEntry_DoNotUse, _has_bits_),
  679. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int64MapEntry_DoNotUse, _internal_metadata_),
  680. ~0u, // no _extensions_
  681. ~0u, // no _oneof_case_
  682. ~0u, // no _weak_field_map_
  683. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int64MapEntry_DoNotUse, key_),
  684. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Int64MapEntry_DoNotUse, value_),
  685. 0,
  686. 1,
  687. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint32MapEntry_DoNotUse, _has_bits_),
  688. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint32MapEntry_DoNotUse, _internal_metadata_),
  689. ~0u, // no _extensions_
  690. ~0u, // no _oneof_case_
  691. ~0u, // no _weak_field_map_
  692. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint32MapEntry_DoNotUse, key_),
  693. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint32MapEntry_DoNotUse, value_),
  694. 0,
  695. 1,
  696. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint64MapEntry_DoNotUse, _has_bits_),
  697. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint64MapEntry_DoNotUse, _internal_metadata_),
  698. ~0u, // no _extensions_
  699. ~0u, // no _oneof_case_
  700. ~0u, // no _weak_field_map_
  701. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint64MapEntry_DoNotUse, key_),
  702. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_Uint64MapEntry_DoNotUse, value_),
  703. 0,
  704. 1,
  705. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_StringMapEntry_DoNotUse, _has_bits_),
  706. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_StringMapEntry_DoNotUse, _internal_metadata_),
  707. ~0u, // no _extensions_
  708. ~0u, // no _oneof_case_
  709. ~0u, // no _weak_field_map_
  710. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_StringMapEntry_DoNotUse, key_),
  711. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap_StringMapEntry_DoNotUse, value_),
  712. 0,
  713. 1,
  714. ~0u, // no _has_bits_
  715. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, _internal_metadata_),
  716. ~0u, // no _extensions_
  717. ~0u, // no _oneof_case_
  718. ~0u, // no _weak_field_map_
  719. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, bool_map_),
  720. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, int32_map_),
  721. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, int64_map_),
  722. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, uint32_map_),
  723. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, uint64_map_),
  724. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestMap, string_map_),
  725. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_BoolMapEntry_DoNotUse, _has_bits_),
  726. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_BoolMapEntry_DoNotUse, _internal_metadata_),
  727. ~0u, // no _extensions_
  728. ~0u, // no _oneof_case_
  729. ~0u, // no _weak_field_map_
  730. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_BoolMapEntry_DoNotUse, key_),
  731. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_BoolMapEntry_DoNotUse, value_),
  732. 0,
  733. 1,
  734. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int32MapEntry_DoNotUse, _has_bits_),
  735. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int32MapEntry_DoNotUse, _internal_metadata_),
  736. ~0u, // no _extensions_
  737. ~0u, // no _oneof_case_
  738. ~0u, // no _weak_field_map_
  739. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int32MapEntry_DoNotUse, key_),
  740. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int32MapEntry_DoNotUse, value_),
  741. 0,
  742. 1,
  743. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int64MapEntry_DoNotUse, _has_bits_),
  744. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int64MapEntry_DoNotUse, _internal_metadata_),
  745. ~0u, // no _extensions_
  746. ~0u, // no _oneof_case_
  747. ~0u, // no _weak_field_map_
  748. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int64MapEntry_DoNotUse, key_),
  749. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Int64MapEntry_DoNotUse, value_),
  750. 0,
  751. 1,
  752. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint32MapEntry_DoNotUse, _has_bits_),
  753. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint32MapEntry_DoNotUse, _internal_metadata_),
  754. ~0u, // no _extensions_
  755. ~0u, // no _oneof_case_
  756. ~0u, // no _weak_field_map_
  757. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint32MapEntry_DoNotUse, key_),
  758. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint32MapEntry_DoNotUse, value_),
  759. 0,
  760. 1,
  761. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint64MapEntry_DoNotUse, _has_bits_),
  762. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint64MapEntry_DoNotUse, _internal_metadata_),
  763. ~0u, // no _extensions_
  764. ~0u, // no _oneof_case_
  765. ~0u, // no _weak_field_map_
  766. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint64MapEntry_DoNotUse, key_),
  767. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_Uint64MapEntry_DoNotUse, value_),
  768. 0,
  769. 1,
  770. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_StringMapEntry_DoNotUse, _has_bits_),
  771. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_StringMapEntry_DoNotUse, _internal_metadata_),
  772. ~0u, // no _extensions_
  773. ~0u, // no _oneof_case_
  774. ~0u, // no _weak_field_map_
  775. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_StringMapEntry_DoNotUse, key_),
  776. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_StringMapEntry_DoNotUse, value_),
  777. 0,
  778. 1,
  779. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_MapMapEntry_DoNotUse, _has_bits_),
  780. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_MapMapEntry_DoNotUse, _internal_metadata_),
  781. ~0u, // no _extensions_
  782. ~0u, // no _oneof_case_
  783. ~0u, // no _weak_field_map_
  784. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_MapMapEntry_DoNotUse, key_),
  785. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap_MapMapEntry_DoNotUse, value_),
  786. 0,
  787. 1,
  788. ~0u, // no _has_bits_
  789. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, _internal_metadata_),
  790. ~0u, // no _extensions_
  791. ~0u, // no _oneof_case_
  792. ~0u, // no _weak_field_map_
  793. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, bool_map_),
  794. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, int32_map_),
  795. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, int64_map_),
  796. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, uint32_map_),
  797. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, uint64_map_),
  798. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, string_map_),
  799. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestNestedMap, map_map_),
  800. ~0u, // no _has_bits_
  801. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, _internal_metadata_),
  802. ~0u, // no _extensions_
  803. ~0u, // no _oneof_case_
  804. ~0u, // no _weak_field_map_
  805. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, bool_value_),
  806. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, int32_value_),
  807. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, int64_value_),
  808. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, uint32_value_),
  809. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, uint64_value_),
  810. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, float_value_),
  811. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, double_value_),
  812. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, string_value_),
  813. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, bytes_value_),
  814. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_bool_value_),
  815. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_int32_value_),
  816. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_int64_value_),
  817. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_uint32_value_),
  818. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_uint64_value_),
  819. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_float_value_),
  820. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_double_value_),
  821. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_string_value_),
  822. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestWrapper, repeated_bytes_value_),
  823. ~0u, // no _has_bits_
  824. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestTimestamp, _internal_metadata_),
  825. ~0u, // no _extensions_
  826. ~0u, // no _oneof_case_
  827. ~0u, // no _weak_field_map_
  828. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestTimestamp, value_),
  829. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestTimestamp, repeated_value_),
  830. ~0u, // no _has_bits_
  831. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestDuration, _internal_metadata_),
  832. ~0u, // no _extensions_
  833. ~0u, // no _oneof_case_
  834. ~0u, // no _weak_field_map_
  835. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestDuration, value_),
  836. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestDuration, repeated_value_),
  837. ~0u, // no _has_bits_
  838. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestFieldMask, _internal_metadata_),
  839. ~0u, // no _extensions_
  840. ~0u, // no _oneof_case_
  841. ~0u, // no _weak_field_map_
  842. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestFieldMask, value_),
  843. ~0u, // no _has_bits_
  844. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestStruct, _internal_metadata_),
  845. ~0u, // no _extensions_
  846. ~0u, // no _oneof_case_
  847. ~0u, // no _weak_field_map_
  848. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestStruct, value_),
  849. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestStruct, repeated_value_),
  850. ~0u, // no _has_bits_
  851. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestAny, _internal_metadata_),
  852. ~0u, // no _extensions_
  853. ~0u, // no _oneof_case_
  854. ~0u, // no _weak_field_map_
  855. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestAny, value_),
  856. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestAny, repeated_value_),
  857. ~0u, // no _has_bits_
  858. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestValue, _internal_metadata_),
  859. ~0u, // no _extensions_
  860. ~0u, // no _oneof_case_
  861. ~0u, // no _weak_field_map_
  862. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestValue, value_),
  863. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestValue, repeated_value_),
  864. ~0u, // no _has_bits_
  865. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestListValue, _internal_metadata_),
  866. ~0u, // no _extensions_
  867. ~0u, // no _oneof_case_
  868. ~0u, // no _weak_field_map_
  869. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestListValue, value_),
  870. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestListValue, repeated_value_),
  871. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue_BoolMapEntry_DoNotUse, _has_bits_),
  872. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue_BoolMapEntry_DoNotUse, _internal_metadata_),
  873. ~0u, // no _extensions_
  874. ~0u, // no _oneof_case_
  875. ~0u, // no _weak_field_map_
  876. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue_BoolMapEntry_DoNotUse, key_),
  877. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue_BoolMapEntry_DoNotUse, value_),
  878. 0,
  879. 1,
  880. ~0u, // no _has_bits_
  881. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue, _internal_metadata_),
  882. ~0u, // no _extensions_
  883. ~0u, // no _oneof_case_
  884. ~0u, // no _weak_field_map_
  885. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue, bool_value_),
  886. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestBoolValue, bool_map_),
  887. ~0u, // no _has_bits_
  888. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestCustomJsonName, _internal_metadata_),
  889. ~0u, // no _extensions_
  890. ~0u, // no _oneof_case_
  891. ~0u, // no _weak_field_map_
  892. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestCustomJsonName, value_),
  893. ~0u, // no _has_bits_
  894. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestExtensions, _internal_metadata_),
  895. ~0u, // no _extensions_
  896. ~0u, // no _oneof_case_
  897. ~0u, // no _weak_field_map_
  898. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestExtensions, extensions_),
  899. ~0u, // no _has_bits_
  900. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestEnumValue, _internal_metadata_),
  901. ~0u, // no _extensions_
  902. ~0u, // no _oneof_case_
  903. ~0u, // no _weak_field_map_
  904. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestEnumValue, enum_value1_),
  905. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestEnumValue, enum_value2_),
  906. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::proto3::TestEnumValue, enum_value3_),
  907. };
  908. static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  909. { 0, -1, sizeof(::proto3::MessageType)},
  910. { 6, -1, sizeof(::proto3::TestMessage)},
  911. { 33, -1, sizeof(::proto3::TestOneof)},
  912. { 44, 51, sizeof(::proto3::TestMap_BoolMapEntry_DoNotUse)},
  913. { 53, 60, sizeof(::proto3::TestMap_Int32MapEntry_DoNotUse)},
  914. { 62, 69, sizeof(::proto3::TestMap_Int64MapEntry_DoNotUse)},
  915. { 71, 78, sizeof(::proto3::TestMap_Uint32MapEntry_DoNotUse)},
  916. { 80, 87, sizeof(::proto3::TestMap_Uint64MapEntry_DoNotUse)},
  917. { 89, 96, sizeof(::proto3::TestMap_StringMapEntry_DoNotUse)},
  918. { 98, -1, sizeof(::proto3::TestMap)},
  919. { 109, 116, sizeof(::proto3::TestNestedMap_BoolMapEntry_DoNotUse)},
  920. { 118, 125, sizeof(::proto3::TestNestedMap_Int32MapEntry_DoNotUse)},
  921. { 127, 134, sizeof(::proto3::TestNestedMap_Int64MapEntry_DoNotUse)},
  922. { 136, 143, sizeof(::proto3::TestNestedMap_Uint32MapEntry_DoNotUse)},
  923. { 145, 152, sizeof(::proto3::TestNestedMap_Uint64MapEntry_DoNotUse)},
  924. { 154, 161, sizeof(::proto3::TestNestedMap_StringMapEntry_DoNotUse)},
  925. { 163, 170, sizeof(::proto3::TestNestedMap_MapMapEntry_DoNotUse)},
  926. { 172, -1, sizeof(::proto3::TestNestedMap)},
  927. { 184, -1, sizeof(::proto3::TestWrapper)},
  928. { 207, -1, sizeof(::proto3::TestTimestamp)},
  929. { 214, -1, sizeof(::proto3::TestDuration)},
  930. { 221, -1, sizeof(::proto3::TestFieldMask)},
  931. { 227, -1, sizeof(::proto3::TestStruct)},
  932. { 234, -1, sizeof(::proto3::TestAny)},
  933. { 241, -1, sizeof(::proto3::TestValue)},
  934. { 248, -1, sizeof(::proto3::TestListValue)},
  935. { 255, 262, sizeof(::proto3::TestBoolValue_BoolMapEntry_DoNotUse)},
  936. { 264, -1, sizeof(::proto3::TestBoolValue)},
  937. { 271, -1, sizeof(::proto3::TestCustomJsonName)},
  938. { 277, -1, sizeof(::proto3::TestExtensions)},
  939. { 283, -1, sizeof(::proto3::TestEnumValue)},
  940. };
  941. static ::google::protobuf::Message const * const file_default_instances[] = {
  942. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_MessageType_default_instance_),
  943. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMessage_default_instance_),
  944. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestOneof_default_instance_),
  945. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_BoolMapEntry_DoNotUse_default_instance_),
  946. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_Int32MapEntry_DoNotUse_default_instance_),
  947. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_Int64MapEntry_DoNotUse_default_instance_),
  948. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_Uint32MapEntry_DoNotUse_default_instance_),
  949. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_Uint64MapEntry_DoNotUse_default_instance_),
  950. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_StringMapEntry_DoNotUse_default_instance_),
  951. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestMap_default_instance_),
  952. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_BoolMapEntry_DoNotUse_default_instance_),
  953. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_Int32MapEntry_DoNotUse_default_instance_),
  954. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_Int64MapEntry_DoNotUse_default_instance_),
  955. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_Uint32MapEntry_DoNotUse_default_instance_),
  956. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_Uint64MapEntry_DoNotUse_default_instance_),
  957. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_StringMapEntry_DoNotUse_default_instance_),
  958. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_MapMapEntry_DoNotUse_default_instance_),
  959. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestNestedMap_default_instance_),
  960. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestWrapper_default_instance_),
  961. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestTimestamp_default_instance_),
  962. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestDuration_default_instance_),
  963. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestFieldMask_default_instance_),
  964. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestStruct_default_instance_),
  965. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestAny_default_instance_),
  966. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestValue_default_instance_),
  967. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestListValue_default_instance_),
  968. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestBoolValue_BoolMapEntry_DoNotUse_default_instance_),
  969. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestBoolValue_default_instance_),
  970. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestCustomJsonName_default_instance_),
  971. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestExtensions_default_instance_),
  972. reinterpret_cast<const ::google::protobuf::Message*>(&::proto3::_TestEnumValue_default_instance_),
  973. };
  974. void protobuf_AssignDescriptors() {
  975. AddDescriptors();
  976. AssignDescriptors(
  977. "google/protobuf/util/json_format_proto3.proto", schemas, file_default_instances, TableStruct::offsets,
  978. file_level_metadata, file_level_enum_descriptors, NULL);
  979. }
  980. void protobuf_AssignDescriptorsOnce() {
  981. static ::google::protobuf::internal::once_flag once;
  982. ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
  983. }
  984. void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
  985. void protobuf_RegisterTypes(const ::std::string&) {
  986. protobuf_AssignDescriptorsOnce();
  987. ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 31);
  988. }
  989. void AddDescriptorsImpl() {
  990. InitDefaults();
  991. static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  992. "\n-google/protobuf/util/json_format_proto"
  993. "3.proto\022\006proto3\032\036google/protobuf/duratio"
  994. "n.proto\032\037google/protobuf/timestamp.proto"
  995. "\032\036google/protobuf/wrappers.proto\032\034google"
  996. "/protobuf/struct.proto\032\031google/protobuf/"
  997. "any.proto\032 google/protobuf/field_mask.pr"
  998. "oto\032\036google/protobuf/unittest.proto\"\034\n\013M"
  999. "essageType\022\r\n\005value\030\001 \001(\005\"\224\005\n\013TestMessag"
  1000. "e\022\022\n\nbool_value\030\001 \001(\010\022\023\n\013int32_value\030\002 \001"
  1001. "(\005\022\023\n\013int64_value\030\003 \001(\003\022\024\n\014uint32_value\030"
  1002. "\004 \001(\r\022\024\n\014uint64_value\030\005 \001(\004\022\023\n\013float_val"
  1003. "ue\030\006 \001(\002\022\024\n\014double_value\030\007 \001(\001\022\024\n\014string"
  1004. "_value\030\010 \001(\t\022\023\n\013bytes_value\030\t \001(\014\022$\n\nenu"
  1005. "m_value\030\n \001(\0162\020.proto3.EnumType\022*\n\rmessa"
  1006. "ge_value\030\013 \001(\0132\023.proto3.MessageType\022\033\n\023r"
  1007. "epeated_bool_value\030\025 \003(\010\022\034\n\024repeated_int"
  1008. "32_value\030\026 \003(\005\022\034\n\024repeated_int64_value\030\027"
  1009. " \003(\003\022\035\n\025repeated_uint32_value\030\030 \003(\r\022\035\n\025r"
  1010. "epeated_uint64_value\030\031 \003(\004\022\034\n\024repeated_f"
  1011. "loat_value\030\032 \003(\002\022\035\n\025repeated_double_valu"
  1012. "e\030\033 \003(\001\022\035\n\025repeated_string_value\030\034 \003(\t\022\034"
  1013. "\n\024repeated_bytes_value\030\035 \003(\014\022-\n\023repeated"
  1014. "_enum_value\030\036 \003(\0162\020.proto3.EnumType\0223\n\026r"
  1015. "epeated_message_value\030\037 \003(\0132\023.proto3.Mes"
  1016. "sageType\"\324\001\n\tTestOneof\022\033\n\021oneof_int32_va"
  1017. "lue\030\001 \001(\005H\000\022\034\n\022oneof_string_value\030\002 \001(\tH"
  1018. "\000\022\033\n\021oneof_bytes_value\030\003 \001(\014H\000\022,\n\020oneof_"
  1019. "enum_value\030\004 \001(\0162\020.proto3.EnumTypeH\000\0222\n\023"
  1020. "oneof_message_value\030\005 \001(\0132\023.proto3.Messa"
  1021. "geTypeH\000B\r\n\013oneof_value\"\341\004\n\007TestMap\022.\n\010b"
  1022. "ool_map\030\001 \003(\0132\034.proto3.TestMap.BoolMapEn"
  1023. "try\0220\n\tint32_map\030\002 \003(\0132\035.proto3.TestMap."
  1024. "Int32MapEntry\0220\n\tint64_map\030\003 \003(\0132\035.proto"
  1025. "3.TestMap.Int64MapEntry\0222\n\nuint32_map\030\004 "
  1026. "\003(\0132\036.proto3.TestMap.Uint32MapEntry\0222\n\nu"
  1027. "int64_map\030\005 \003(\0132\036.proto3.TestMap.Uint64M"
  1028. "apEntry\0222\n\nstring_map\030\006 \003(\0132\036.proto3.Tes"
  1029. "tMap.StringMapEntry\032.\n\014BoolMapEntry\022\013\n\003k"
  1030. "ey\030\001 \001(\010\022\r\n\005value\030\002 \001(\005:\0028\001\032/\n\rInt32MapE"
  1031. "ntry\022\013\n\003key\030\001 \001(\005\022\r\n\005value\030\002 \001(\005:\0028\001\032/\n\r"
  1032. "Int64MapEntry\022\013\n\003key\030\001 \001(\003\022\r\n\005value\030\002 \001("
  1033. "\005:\0028\001\0320\n\016Uint32MapEntry\022\013\n\003key\030\001 \001(\r\022\r\n\005"
  1034. "value\030\002 \001(\005:\0028\001\0320\n\016Uint64MapEntry\022\013\n\003key"
  1035. "\030\001 \001(\004\022\r\n\005value\030\002 \001(\005:\0028\001\0320\n\016StringMapEn"
  1036. "try\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\005:\0028\001\"\205\006\n\r"
  1037. "TestNestedMap\0224\n\010bool_map\030\001 \003(\0132\".proto3"
  1038. ".TestNestedMap.BoolMapEntry\0226\n\tint32_map"
  1039. "\030\002 \003(\0132#.proto3.TestNestedMap.Int32MapEn"
  1040. "try\0226\n\tint64_map\030\003 \003(\0132#.proto3.TestNest"
  1041. "edMap.Int64MapEntry\0228\n\nuint32_map\030\004 \003(\0132"
  1042. "$.proto3.TestNestedMap.Uint32MapEntry\0228\n"
  1043. "\nuint64_map\030\005 \003(\0132$.proto3.TestNestedMap"
  1044. ".Uint64MapEntry\0228\n\nstring_map\030\006 \003(\0132$.pr"
  1045. "oto3.TestNestedMap.StringMapEntry\0222\n\007map"
  1046. "_map\030\007 \003(\0132!.proto3.TestNestedMap.MapMap"
  1047. "Entry\032.\n\014BoolMapEntry\022\013\n\003key\030\001 \001(\010\022\r\n\005va"
  1048. "lue\030\002 \001(\005:\0028\001\032/\n\rInt32MapEntry\022\013\n\003key\030\001 "
  1049. "\001(\005\022\r\n\005value\030\002 \001(\005:\0028\001\032/\n\rInt64MapEntry\022"
  1050. "\013\n\003key\030\001 \001(\003\022\r\n\005value\030\002 \001(\005:\0028\001\0320\n\016Uint3"
  1051. "2MapEntry\022\013\n\003key\030\001 \001(\r\022\r\n\005value\030\002 \001(\005:\0028"
  1052. "\001\0320\n\016Uint64MapEntry\022\013\n\003key\030\001 \001(\004\022\r\n\005valu"
  1053. "e\030\002 \001(\005:\0028\001\0320\n\016StringMapEntry\022\013\n\003key\030\001 \001"
  1054. "(\t\022\r\n\005value\030\002 \001(\005:\0028\001\032D\n\013MapMapEntry\022\013\n\003"
  1055. "key\030\001 \001(\t\022$\n\005value\030\002 \001(\0132\025.proto3.TestNe"
  1056. "stedMap:\0028\001\"\356\007\n\013TestWrapper\022.\n\nbool_valu"
  1057. "e\030\001 \001(\0132\032.google.protobuf.BoolValue\0220\n\013i"
  1058. "nt32_value\030\002 \001(\0132\033.google.protobuf.Int32"
  1059. "Value\0220\n\013int64_value\030\003 \001(\0132\033.google.prot"
  1060. "obuf.Int64Value\0222\n\014uint32_value\030\004 \001(\0132\034."
  1061. "google.protobuf.UInt32Value\0222\n\014uint64_va"
  1062. "lue\030\005 \001(\0132\034.google.protobuf.UInt64Value\022"
  1063. "0\n\013float_value\030\006 \001(\0132\033.google.protobuf.F"
  1064. "loatValue\0222\n\014double_value\030\007 \001(\0132\034.google"
  1065. ".protobuf.DoubleValue\0222\n\014string_value\030\010 "
  1066. "\001(\0132\034.google.protobuf.StringValue\0220\n\013byt"
  1067. "es_value\030\t \001(\0132\033.google.protobuf.BytesVa"
  1068. "lue\0227\n\023repeated_bool_value\030\013 \003(\0132\032.googl"
  1069. "e.protobuf.BoolValue\0229\n\024repeated_int32_v"
  1070. "alue\030\014 \003(\0132\033.google.protobuf.Int32Value\022"
  1071. "9\n\024repeated_int64_value\030\r \003(\0132\033.google.p"
  1072. "rotobuf.Int64Value\022;\n\025repeated_uint32_va"
  1073. "lue\030\016 \003(\0132\034.google.protobuf.UInt32Value\022"
  1074. ";\n\025repeated_uint64_value\030\017 \003(\0132\034.google."
  1075. "protobuf.UInt64Value\0229\n\024repeated_float_v"
  1076. "alue\030\020 \003(\0132\033.google.protobuf.FloatValue\022"
  1077. ";\n\025repeated_double_value\030\021 \003(\0132\034.google."
  1078. "protobuf.DoubleValue\022;\n\025repeated_string_"
  1079. "value\030\022 \003(\0132\034.google.protobuf.StringValu"
  1080. "e\0229\n\024repeated_bytes_value\030\023 \003(\0132\033.google"
  1081. ".protobuf.BytesValue\"n\n\rTestTimestamp\022)\n"
  1082. "\005value\030\001 \001(\0132\032.google.protobuf.Timestamp"
  1083. "\0222\n\016repeated_value\030\002 \003(\0132\032.google.protob"
  1084. "uf.Timestamp\"k\n\014TestDuration\022(\n\005value\030\001 "
  1085. "\001(\0132\031.google.protobuf.Duration\0221\n\016repeat"
  1086. "ed_value\030\002 \003(\0132\031.google.protobuf.Duratio"
  1087. "n\":\n\rTestFieldMask\022)\n\005value\030\001 \001(\0132\032.goog"
  1088. "le.protobuf.FieldMask\"e\n\nTestStruct\022&\n\005v"
  1089. "alue\030\001 \001(\0132\027.google.protobuf.Struct\022/\n\016r"
  1090. "epeated_value\030\002 \003(\0132\027.google.protobuf.St"
  1091. "ruct\"\\\n\007TestAny\022#\n\005value\030\001 \001(\0132\024.google."
  1092. "protobuf.Any\022,\n\016repeated_value\030\002 \003(\0132\024.g"
  1093. "oogle.protobuf.Any\"b\n\tTestValue\022%\n\005value"
  1094. "\030\001 \001(\0132\026.google.protobuf.Value\022.\n\016repeat"
  1095. "ed_value\030\002 \003(\0132\026.google.protobuf.Value\"n"
  1096. "\n\rTestListValue\022)\n\005value\030\001 \001(\0132\032.google."
  1097. "protobuf.ListValue\0222\n\016repeated_value\030\002 \003"
  1098. "(\0132\032.google.protobuf.ListValue\"\211\001\n\rTestB"
  1099. "oolValue\022\022\n\nbool_value\030\001 \001(\010\0224\n\010bool_map"
  1100. "\030\002 \003(\0132\".proto3.TestBoolValue.BoolMapEnt"
  1101. "ry\032.\n\014BoolMapEntry\022\013\n\003key\030\001 \001(\010\022\r\n\005value"
  1102. "\030\002 \001(\005:\0028\001\"+\n\022TestCustomJsonName\022\025\n\005valu"
  1103. "e\030\001 \001(\005R\006@value\"J\n\016TestExtensions\0228\n\next"
  1104. "ensions\030\001 \001(\0132$.protobuf_unittest.TestAl"
  1105. "lExtensions\"\204\001\n\rTestEnumValue\022%\n\013enum_va"
  1106. "lue1\030\001 \001(\0162\020.proto3.EnumType\022%\n\013enum_val"
  1107. "ue2\030\002 \001(\0162\020.proto3.EnumType\022%\n\013enum_valu"
  1108. "e3\030\003 \001(\0162\020.proto3.EnumType*\034\n\010EnumType\022\007"
  1109. "\n\003FOO\020\000\022\007\n\003BAR\020\001B,\n\030com.google.protobuf."
  1110. "utilB\020JsonFormatProto3b\006proto3"
  1111. };
  1112. ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
  1113. descriptor, 4750);
  1114. ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
  1115. "google/protobuf/util/json_format_proto3.proto", &protobuf_RegisterTypes);
  1116. ::protobuf_google_2fprotobuf_2fduration_2eproto::AddDescriptors();
  1117. ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::AddDescriptors();
  1118. ::protobuf_google_2fprotobuf_2fwrappers_2eproto::AddDescriptors();
  1119. ::protobuf_google_2fprotobuf_2fstruct_2eproto::AddDescriptors();
  1120. ::protobuf_google_2fprotobuf_2fany_2eproto::AddDescriptors();
  1121. ::protobuf_google_2fprotobuf_2ffield_5fmask_2eproto::AddDescriptors();
  1122. ::protobuf_google_2fprotobuf_2funittest_2eproto::AddDescriptors();
  1123. }
  1124. void AddDescriptors() {
  1125. static ::google::protobuf::internal::once_flag once;
  1126. ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
  1127. }
  1128. // Force AddDescriptors() to be called at dynamic initialization time.
  1129. struct StaticDescriptorInitializer {
  1130. StaticDescriptorInitializer() {
  1131. AddDescriptors();
  1132. }
  1133. } static_descriptor_initializer;
  1134. } // namespace protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto
  1135. namespace proto3 {
  1136. const ::google::protobuf::EnumDescriptor* EnumType_descriptor() {
  1137. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  1138. return protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_enum_descriptors[0];
  1139. }
  1140. bool EnumType_IsValid(int value) {
  1141. switch (value) {
  1142. case 0:
  1143. case 1:
  1144. return true;
  1145. default:
  1146. return false;
  1147. }
  1148. }
  1149. // ===================================================================
  1150. void MessageType::InitAsDefaultInstance() {
  1151. }
  1152. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  1153. const int MessageType::kValueFieldNumber;
  1154. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  1155. MessageType::MessageType()
  1156. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  1157. ::google::protobuf::internal::InitSCC(
  1158. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_MessageType.base);
  1159. SharedCtor();
  1160. // @@protoc_insertion_point(constructor:proto3.MessageType)
  1161. }
  1162. MessageType::MessageType(const MessageType& from)
  1163. : ::google::protobuf::Message(),
  1164. _internal_metadata_(NULL) {
  1165. _internal_metadata_.MergeFrom(from._internal_metadata_);
  1166. value_ = from.value_;
  1167. // @@protoc_insertion_point(copy_constructor:proto3.MessageType)
  1168. }
  1169. void MessageType::SharedCtor() {
  1170. value_ = 0;
  1171. }
  1172. MessageType::~MessageType() {
  1173. // @@protoc_insertion_point(destructor:proto3.MessageType)
  1174. SharedDtor();
  1175. }
  1176. void MessageType::SharedDtor() {
  1177. }
  1178. void MessageType::SetCachedSize(int size) const {
  1179. _cached_size_.Set(size);
  1180. }
  1181. const ::google::protobuf::Descriptor* MessageType::descriptor() {
  1182. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  1183. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  1184. }
  1185. const MessageType& MessageType::default_instance() {
  1186. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_MessageType.base);
  1187. return *internal_default_instance();
  1188. }
  1189. void MessageType::Clear() {
  1190. // @@protoc_insertion_point(message_clear_start:proto3.MessageType)
  1191. ::google::protobuf::uint32 cached_has_bits = 0;
  1192. // Prevent compiler warnings about cached_has_bits being unused
  1193. (void) cached_has_bits;
  1194. value_ = 0;
  1195. _internal_metadata_.Clear();
  1196. }
  1197. bool MessageType::MergePartialFromCodedStream(
  1198. ::google::protobuf::io::CodedInputStream* input) {
  1199. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  1200. ::google::protobuf::uint32 tag;
  1201. // @@protoc_insertion_point(parse_start:proto3.MessageType)
  1202. for (;;) {
  1203. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  1204. tag = p.first;
  1205. if (!p.second) goto handle_unusual;
  1206. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1207. // int32 value = 1;
  1208. case 1: {
  1209. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1210. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  1211. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1212. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  1213. input, &value_)));
  1214. } else {
  1215. goto handle_unusual;
  1216. }
  1217. break;
  1218. }
  1219. default: {
  1220. handle_unusual:
  1221. if (tag == 0) {
  1222. goto success;
  1223. }
  1224. DO_(::google::protobuf::internal::WireFormat::SkipField(
  1225. input, tag, _internal_metadata_.mutable_unknown_fields()));
  1226. break;
  1227. }
  1228. }
  1229. }
  1230. success:
  1231. // @@protoc_insertion_point(parse_success:proto3.MessageType)
  1232. return true;
  1233. failure:
  1234. // @@protoc_insertion_point(parse_failure:proto3.MessageType)
  1235. return false;
  1236. #undef DO_
  1237. }
  1238. void MessageType::SerializeWithCachedSizes(
  1239. ::google::protobuf::io::CodedOutputStream* output) const {
  1240. // @@protoc_insertion_point(serialize_start:proto3.MessageType)
  1241. ::google::protobuf::uint32 cached_has_bits = 0;
  1242. (void) cached_has_bits;
  1243. // int32 value = 1;
  1244. if (this->value() != 0) {
  1245. ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->value(), output);
  1246. }
  1247. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  1248. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  1249. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  1250. }
  1251. // @@protoc_insertion_point(serialize_end:proto3.MessageType)
  1252. }
  1253. ::google::protobuf::uint8* MessageType::InternalSerializeWithCachedSizesToArray(
  1254. bool deterministic, ::google::protobuf::uint8* target) const {
  1255. (void)deterministic; // Unused
  1256. // @@protoc_insertion_point(serialize_to_array_start:proto3.MessageType)
  1257. ::google::protobuf::uint32 cached_has_bits = 0;
  1258. (void) cached_has_bits;
  1259. // int32 value = 1;
  1260. if (this->value() != 0) {
  1261. target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->value(), target);
  1262. }
  1263. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  1264. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  1265. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  1266. }
  1267. // @@protoc_insertion_point(serialize_to_array_end:proto3.MessageType)
  1268. return target;
  1269. }
  1270. size_t MessageType::ByteSizeLong() const {
  1271. // @@protoc_insertion_point(message_byte_size_start:proto3.MessageType)
  1272. size_t total_size = 0;
  1273. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  1274. total_size +=
  1275. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  1276. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  1277. }
  1278. // int32 value = 1;
  1279. if (this->value() != 0) {
  1280. total_size += 1 +
  1281. ::google::protobuf::internal::WireFormatLite::Int32Size(
  1282. this->value());
  1283. }
  1284. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  1285. SetCachedSize(cached_size);
  1286. return total_size;
  1287. }
  1288. void MessageType::MergeFrom(const ::google::protobuf::Message& from) {
  1289. // @@protoc_insertion_point(generalized_merge_from_start:proto3.MessageType)
  1290. GOOGLE_DCHECK_NE(&from, this);
  1291. const MessageType* source =
  1292. ::google::protobuf::internal::DynamicCastToGenerated<const MessageType>(
  1293. &from);
  1294. if (source == NULL) {
  1295. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.MessageType)
  1296. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  1297. } else {
  1298. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.MessageType)
  1299. MergeFrom(*source);
  1300. }
  1301. }
  1302. void MessageType::MergeFrom(const MessageType& from) {
  1303. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.MessageType)
  1304. GOOGLE_DCHECK_NE(&from, this);
  1305. _internal_metadata_.MergeFrom(from._internal_metadata_);
  1306. ::google::protobuf::uint32 cached_has_bits = 0;
  1307. (void) cached_has_bits;
  1308. if (from.value() != 0) {
  1309. set_value(from.value());
  1310. }
  1311. }
  1312. void MessageType::CopyFrom(const ::google::protobuf::Message& from) {
  1313. // @@protoc_insertion_point(generalized_copy_from_start:proto3.MessageType)
  1314. if (&from == this) return;
  1315. Clear();
  1316. MergeFrom(from);
  1317. }
  1318. void MessageType::CopyFrom(const MessageType& from) {
  1319. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.MessageType)
  1320. if (&from == this) return;
  1321. Clear();
  1322. MergeFrom(from);
  1323. }
  1324. bool MessageType::IsInitialized() const {
  1325. return true;
  1326. }
  1327. void MessageType::Swap(MessageType* other) {
  1328. if (other == this) return;
  1329. InternalSwap(other);
  1330. }
  1331. void MessageType::InternalSwap(MessageType* other) {
  1332. using std::swap;
  1333. swap(value_, other->value_);
  1334. _internal_metadata_.Swap(&other->_internal_metadata_);
  1335. }
  1336. ::google::protobuf::Metadata MessageType::GetMetadata() const {
  1337. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  1338. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  1339. }
  1340. // ===================================================================
  1341. void TestMessage::InitAsDefaultInstance() {
  1342. ::proto3::_TestMessage_default_instance_._instance.get_mutable()->message_value_ = const_cast< ::proto3::MessageType*>(
  1343. ::proto3::MessageType::internal_default_instance());
  1344. }
  1345. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  1346. const int TestMessage::kBoolValueFieldNumber;
  1347. const int TestMessage::kInt32ValueFieldNumber;
  1348. const int TestMessage::kInt64ValueFieldNumber;
  1349. const int TestMessage::kUint32ValueFieldNumber;
  1350. const int TestMessage::kUint64ValueFieldNumber;
  1351. const int TestMessage::kFloatValueFieldNumber;
  1352. const int TestMessage::kDoubleValueFieldNumber;
  1353. const int TestMessage::kStringValueFieldNumber;
  1354. const int TestMessage::kBytesValueFieldNumber;
  1355. const int TestMessage::kEnumValueFieldNumber;
  1356. const int TestMessage::kMessageValueFieldNumber;
  1357. const int TestMessage::kRepeatedBoolValueFieldNumber;
  1358. const int TestMessage::kRepeatedInt32ValueFieldNumber;
  1359. const int TestMessage::kRepeatedInt64ValueFieldNumber;
  1360. const int TestMessage::kRepeatedUint32ValueFieldNumber;
  1361. const int TestMessage::kRepeatedUint64ValueFieldNumber;
  1362. const int TestMessage::kRepeatedFloatValueFieldNumber;
  1363. const int TestMessage::kRepeatedDoubleValueFieldNumber;
  1364. const int TestMessage::kRepeatedStringValueFieldNumber;
  1365. const int TestMessage::kRepeatedBytesValueFieldNumber;
  1366. const int TestMessage::kRepeatedEnumValueFieldNumber;
  1367. const int TestMessage::kRepeatedMessageValueFieldNumber;
  1368. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  1369. TestMessage::TestMessage()
  1370. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  1371. ::google::protobuf::internal::InitSCC(
  1372. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMessage.base);
  1373. SharedCtor();
  1374. // @@protoc_insertion_point(constructor:proto3.TestMessage)
  1375. }
  1376. TestMessage::TestMessage(const TestMessage& from)
  1377. : ::google::protobuf::Message(),
  1378. _internal_metadata_(NULL),
  1379. repeated_bool_value_(from.repeated_bool_value_),
  1380. repeated_int32_value_(from.repeated_int32_value_),
  1381. repeated_int64_value_(from.repeated_int64_value_),
  1382. repeated_uint32_value_(from.repeated_uint32_value_),
  1383. repeated_uint64_value_(from.repeated_uint64_value_),
  1384. repeated_float_value_(from.repeated_float_value_),
  1385. repeated_double_value_(from.repeated_double_value_),
  1386. repeated_string_value_(from.repeated_string_value_),
  1387. repeated_bytes_value_(from.repeated_bytes_value_),
  1388. repeated_enum_value_(from.repeated_enum_value_),
  1389. repeated_message_value_(from.repeated_message_value_) {
  1390. _internal_metadata_.MergeFrom(from._internal_metadata_);
  1391. string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1392. if (from.string_value().size() > 0) {
  1393. string_value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.string_value_);
  1394. }
  1395. bytes_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1396. if (from.bytes_value().size() > 0) {
  1397. bytes_value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.bytes_value_);
  1398. }
  1399. if (from.has_message_value()) {
  1400. message_value_ = new ::proto3::MessageType(*from.message_value_);
  1401. } else {
  1402. message_value_ = NULL;
  1403. }
  1404. ::memcpy(&bool_value_, &from.bool_value_,
  1405. static_cast<size_t>(reinterpret_cast<char*>(&enum_value_) -
  1406. reinterpret_cast<char*>(&bool_value_)) + sizeof(enum_value_));
  1407. // @@protoc_insertion_point(copy_constructor:proto3.TestMessage)
  1408. }
  1409. void TestMessage::SharedCtor() {
  1410. string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1411. bytes_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1412. ::memset(&message_value_, 0, static_cast<size_t>(
  1413. reinterpret_cast<char*>(&enum_value_) -
  1414. reinterpret_cast<char*>(&message_value_)) + sizeof(enum_value_));
  1415. }
  1416. TestMessage::~TestMessage() {
  1417. // @@protoc_insertion_point(destructor:proto3.TestMessage)
  1418. SharedDtor();
  1419. }
  1420. void TestMessage::SharedDtor() {
  1421. string_value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1422. bytes_value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1423. if (this != internal_default_instance()) delete message_value_;
  1424. }
  1425. void TestMessage::SetCachedSize(int size) const {
  1426. _cached_size_.Set(size);
  1427. }
  1428. const ::google::protobuf::Descriptor* TestMessage::descriptor() {
  1429. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  1430. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  1431. }
  1432. const TestMessage& TestMessage::default_instance() {
  1433. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMessage.base);
  1434. return *internal_default_instance();
  1435. }
  1436. void TestMessage::Clear() {
  1437. // @@protoc_insertion_point(message_clear_start:proto3.TestMessage)
  1438. ::google::protobuf::uint32 cached_has_bits = 0;
  1439. // Prevent compiler warnings about cached_has_bits being unused
  1440. (void) cached_has_bits;
  1441. repeated_bool_value_.Clear();
  1442. repeated_int32_value_.Clear();
  1443. repeated_int64_value_.Clear();
  1444. repeated_uint32_value_.Clear();
  1445. repeated_uint64_value_.Clear();
  1446. repeated_float_value_.Clear();
  1447. repeated_double_value_.Clear();
  1448. repeated_string_value_.Clear();
  1449. repeated_bytes_value_.Clear();
  1450. repeated_enum_value_.Clear();
  1451. repeated_message_value_.Clear();
  1452. string_value_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1453. bytes_value_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1454. if (GetArenaNoVirtual() == NULL && message_value_ != NULL) {
  1455. delete message_value_;
  1456. }
  1457. message_value_ = NULL;
  1458. ::memset(&bool_value_, 0, static_cast<size_t>(
  1459. reinterpret_cast<char*>(&enum_value_) -
  1460. reinterpret_cast<char*>(&bool_value_)) + sizeof(enum_value_));
  1461. _internal_metadata_.Clear();
  1462. }
  1463. bool TestMessage::MergePartialFromCodedStream(
  1464. ::google::protobuf::io::CodedInputStream* input) {
  1465. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  1466. ::google::protobuf::uint32 tag;
  1467. // @@protoc_insertion_point(parse_start:proto3.TestMessage)
  1468. for (;;) {
  1469. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(16383u);
  1470. tag = p.first;
  1471. if (!p.second) goto handle_unusual;
  1472. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1473. // bool bool_value = 1;
  1474. case 1: {
  1475. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1476. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  1477. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1478. bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
  1479. input, &bool_value_)));
  1480. } else {
  1481. goto handle_unusual;
  1482. }
  1483. break;
  1484. }
  1485. // int32 int32_value = 2;
  1486. case 2: {
  1487. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1488. static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
  1489. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1490. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  1491. input, &int32_value_)));
  1492. } else {
  1493. goto handle_unusual;
  1494. }
  1495. break;
  1496. }
  1497. // int64 int64_value = 3;
  1498. case 3: {
  1499. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1500. static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) {
  1501. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1502. ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
  1503. input, &int64_value_)));
  1504. } else {
  1505. goto handle_unusual;
  1506. }
  1507. break;
  1508. }
  1509. // uint32 uint32_value = 4;
  1510. case 4: {
  1511. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1512. static_cast< ::google::protobuf::uint8>(32u /* 32 & 0xFF */)) {
  1513. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1514. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  1515. input, &uint32_value_)));
  1516. } else {
  1517. goto handle_unusual;
  1518. }
  1519. break;
  1520. }
  1521. // uint64 uint64_value = 5;
  1522. case 5: {
  1523. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1524. static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) {
  1525. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1526. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1527. input, &uint64_value_)));
  1528. } else {
  1529. goto handle_unusual;
  1530. }
  1531. break;
  1532. }
  1533. // float float_value = 6;
  1534. case 6: {
  1535. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1536. static_cast< ::google::protobuf::uint8>(53u /* 53 & 0xFF */)) {
  1537. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1538. float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
  1539. input, &float_value_)));
  1540. } else {
  1541. goto handle_unusual;
  1542. }
  1543. break;
  1544. }
  1545. // double double_value = 7;
  1546. case 7: {
  1547. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1548. static_cast< ::google::protobuf::uint8>(57u /* 57 & 0xFF */)) {
  1549. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1550. double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
  1551. input, &double_value_)));
  1552. } else {
  1553. goto handle_unusual;
  1554. }
  1555. break;
  1556. }
  1557. // string string_value = 8;
  1558. case 8: {
  1559. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1560. static_cast< ::google::protobuf::uint8>(66u /* 66 & 0xFF */)) {
  1561. DO_(::google::protobuf::internal::WireFormatLite::ReadString(
  1562. input, this->mutable_string_value()));
  1563. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1564. this->string_value().data(), static_cast<int>(this->string_value().length()),
  1565. ::google::protobuf::internal::WireFormatLite::PARSE,
  1566. "proto3.TestMessage.string_value"));
  1567. } else {
  1568. goto handle_unusual;
  1569. }
  1570. break;
  1571. }
  1572. // bytes bytes_value = 9;
  1573. case 9: {
  1574. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1575. static_cast< ::google::protobuf::uint8>(74u /* 74 & 0xFF */)) {
  1576. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  1577. input, this->mutable_bytes_value()));
  1578. } else {
  1579. goto handle_unusual;
  1580. }
  1581. break;
  1582. }
  1583. // .proto3.EnumType enum_value = 10;
  1584. case 10: {
  1585. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1586. static_cast< ::google::protobuf::uint8>(80u /* 80 & 0xFF */)) {
  1587. int value;
  1588. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1589. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  1590. input, &value)));
  1591. set_enum_value(static_cast< ::proto3::EnumType >(value));
  1592. } else {
  1593. goto handle_unusual;
  1594. }
  1595. break;
  1596. }
  1597. // .proto3.MessageType message_value = 11;
  1598. case 11: {
  1599. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1600. static_cast< ::google::protobuf::uint8>(90u /* 90 & 0xFF */)) {
  1601. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1602. input, mutable_message_value()));
  1603. } else {
  1604. goto handle_unusual;
  1605. }
  1606. break;
  1607. }
  1608. // repeated bool repeated_bool_value = 21;
  1609. case 21: {
  1610. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1611. static_cast< ::google::protobuf::uint8>(170u /* 170 & 0xFF */)) {
  1612. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1613. bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
  1614. input, this->mutable_repeated_bool_value())));
  1615. } else if (
  1616. static_cast< ::google::protobuf::uint8>(tag) ==
  1617. static_cast< ::google::protobuf::uint8>(168u /* 168 & 0xFF */)) {
  1618. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1619. bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
  1620. 2, 170u, input, this->mutable_repeated_bool_value())));
  1621. } else {
  1622. goto handle_unusual;
  1623. }
  1624. break;
  1625. }
  1626. // repeated int32 repeated_int32_value = 22;
  1627. case 22: {
  1628. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1629. static_cast< ::google::protobuf::uint8>(178u /* 178 & 0xFF */)) {
  1630. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1631. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  1632. input, this->mutable_repeated_int32_value())));
  1633. } else if (
  1634. static_cast< ::google::protobuf::uint8>(tag) ==
  1635. static_cast< ::google::protobuf::uint8>(176u /* 176 & 0xFF */)) {
  1636. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1637. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  1638. 2, 178u, input, this->mutable_repeated_int32_value())));
  1639. } else {
  1640. goto handle_unusual;
  1641. }
  1642. break;
  1643. }
  1644. // repeated int64 repeated_int64_value = 23;
  1645. case 23: {
  1646. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1647. static_cast< ::google::protobuf::uint8>(186u /* 186 & 0xFF */)) {
  1648. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1649. ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
  1650. input, this->mutable_repeated_int64_value())));
  1651. } else if (
  1652. static_cast< ::google::protobuf::uint8>(tag) ==
  1653. static_cast< ::google::protobuf::uint8>(184u /* 184 & 0xFF */)) {
  1654. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1655. ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
  1656. 2, 186u, input, this->mutable_repeated_int64_value())));
  1657. } else {
  1658. goto handle_unusual;
  1659. }
  1660. break;
  1661. }
  1662. // repeated uint32 repeated_uint32_value = 24;
  1663. case 24: {
  1664. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1665. static_cast< ::google::protobuf::uint8>(194u /* 194 & 0xFF */)) {
  1666. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1667. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  1668. input, this->mutable_repeated_uint32_value())));
  1669. } else if (
  1670. static_cast< ::google::protobuf::uint8>(tag) ==
  1671. static_cast< ::google::protobuf::uint8>(192u /* 192 & 0xFF */)) {
  1672. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1673. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  1674. 2, 194u, input, this->mutable_repeated_uint32_value())));
  1675. } else {
  1676. goto handle_unusual;
  1677. }
  1678. break;
  1679. }
  1680. // repeated uint64 repeated_uint64_value = 25;
  1681. case 25: {
  1682. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1683. static_cast< ::google::protobuf::uint8>(202u /* 202 & 0xFF */)) {
  1684. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1685. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1686. input, this->mutable_repeated_uint64_value())));
  1687. } else if (
  1688. static_cast< ::google::protobuf::uint8>(tag) ==
  1689. static_cast< ::google::protobuf::uint8>(200u /* 200 & 0xFF */)) {
  1690. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1691. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1692. 2, 202u, input, this->mutable_repeated_uint64_value())));
  1693. } else {
  1694. goto handle_unusual;
  1695. }
  1696. break;
  1697. }
  1698. // repeated float repeated_float_value = 26;
  1699. case 26: {
  1700. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1701. static_cast< ::google::protobuf::uint8>(210u /* 210 & 0xFF */)) {
  1702. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1703. float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
  1704. input, this->mutable_repeated_float_value())));
  1705. } else if (
  1706. static_cast< ::google::protobuf::uint8>(tag) ==
  1707. static_cast< ::google::protobuf::uint8>(213u /* 213 & 0xFF */)) {
  1708. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1709. float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
  1710. 2, 210u, input, this->mutable_repeated_float_value())));
  1711. } else {
  1712. goto handle_unusual;
  1713. }
  1714. break;
  1715. }
  1716. // repeated double repeated_double_value = 27;
  1717. case 27: {
  1718. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1719. static_cast< ::google::protobuf::uint8>(218u /* 218 & 0xFF */)) {
  1720. DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
  1721. double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
  1722. input, this->mutable_repeated_double_value())));
  1723. } else if (
  1724. static_cast< ::google::protobuf::uint8>(tag) ==
  1725. static_cast< ::google::protobuf::uint8>(217u /* 217 & 0xFF */)) {
  1726. DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
  1727. double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
  1728. 2, 218u, input, this->mutable_repeated_double_value())));
  1729. } else {
  1730. goto handle_unusual;
  1731. }
  1732. break;
  1733. }
  1734. // repeated string repeated_string_value = 28;
  1735. case 28: {
  1736. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1737. static_cast< ::google::protobuf::uint8>(226u /* 226 & 0xFF */)) {
  1738. DO_(::google::protobuf::internal::WireFormatLite::ReadString(
  1739. input, this->add_repeated_string_value()));
  1740. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1741. this->repeated_string_value(this->repeated_string_value_size() - 1).data(),
  1742. static_cast<int>(this->repeated_string_value(this->repeated_string_value_size() - 1).length()),
  1743. ::google::protobuf::internal::WireFormatLite::PARSE,
  1744. "proto3.TestMessage.repeated_string_value"));
  1745. } else {
  1746. goto handle_unusual;
  1747. }
  1748. break;
  1749. }
  1750. // repeated bytes repeated_bytes_value = 29;
  1751. case 29: {
  1752. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1753. static_cast< ::google::protobuf::uint8>(234u /* 234 & 0xFF */)) {
  1754. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  1755. input, this->add_repeated_bytes_value()));
  1756. } else {
  1757. goto handle_unusual;
  1758. }
  1759. break;
  1760. }
  1761. // repeated .proto3.EnumType repeated_enum_value = 30;
  1762. case 30: {
  1763. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1764. static_cast< ::google::protobuf::uint8>(242u /* 242 & 0xFF */)) {
  1765. ::google::protobuf::uint32 length;
  1766. DO_(input->ReadVarint32(&length));
  1767. ::google::protobuf::io::CodedInputStream::Limit limit = input->PushLimit(static_cast<int>(length));
  1768. while (input->BytesUntilLimit() > 0) {
  1769. int value;
  1770. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1771. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  1772. input, &value)));
  1773. add_repeated_enum_value(static_cast< ::proto3::EnumType >(value));
  1774. }
  1775. input->PopLimit(limit);
  1776. } else if (
  1777. static_cast< ::google::protobuf::uint8>(tag) ==
  1778. static_cast< ::google::protobuf::uint8>(240u /* 240 & 0xFF */)) {
  1779. int value;
  1780. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1781. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  1782. input, &value)));
  1783. add_repeated_enum_value(static_cast< ::proto3::EnumType >(value));
  1784. } else {
  1785. goto handle_unusual;
  1786. }
  1787. break;
  1788. }
  1789. // repeated .proto3.MessageType repeated_message_value = 31;
  1790. case 31: {
  1791. if (static_cast< ::google::protobuf::uint8>(tag) ==
  1792. static_cast< ::google::protobuf::uint8>(250u /* 250 & 0xFF */)) {
  1793. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1794. input, add_repeated_message_value()));
  1795. } else {
  1796. goto handle_unusual;
  1797. }
  1798. break;
  1799. }
  1800. default: {
  1801. handle_unusual:
  1802. if (tag == 0) {
  1803. goto success;
  1804. }
  1805. DO_(::google::protobuf::internal::WireFormat::SkipField(
  1806. input, tag, _internal_metadata_.mutable_unknown_fields()));
  1807. break;
  1808. }
  1809. }
  1810. }
  1811. success:
  1812. // @@protoc_insertion_point(parse_success:proto3.TestMessage)
  1813. return true;
  1814. failure:
  1815. // @@protoc_insertion_point(parse_failure:proto3.TestMessage)
  1816. return false;
  1817. #undef DO_
  1818. }
  1819. void TestMessage::SerializeWithCachedSizes(
  1820. ::google::protobuf::io::CodedOutputStream* output) const {
  1821. // @@protoc_insertion_point(serialize_start:proto3.TestMessage)
  1822. ::google::protobuf::uint32 cached_has_bits = 0;
  1823. (void) cached_has_bits;
  1824. // bool bool_value = 1;
  1825. if (this->bool_value() != 0) {
  1826. ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->bool_value(), output);
  1827. }
  1828. // int32 int32_value = 2;
  1829. if (this->int32_value() != 0) {
  1830. ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->int32_value(), output);
  1831. }
  1832. // int64 int64_value = 3;
  1833. if (this->int64_value() != 0) {
  1834. ::google::protobuf::internal::WireFormatLite::WriteInt64(3, this->int64_value(), output);
  1835. }
  1836. // uint32 uint32_value = 4;
  1837. if (this->uint32_value() != 0) {
  1838. ::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->uint32_value(), output);
  1839. }
  1840. // uint64 uint64_value = 5;
  1841. if (this->uint64_value() != 0) {
  1842. ::google::protobuf::internal::WireFormatLite::WriteUInt64(5, this->uint64_value(), output);
  1843. }
  1844. // float float_value = 6;
  1845. if (this->float_value() != 0) {
  1846. ::google::protobuf::internal::WireFormatLite::WriteFloat(6, this->float_value(), output);
  1847. }
  1848. // double double_value = 7;
  1849. if (this->double_value() != 0) {
  1850. ::google::protobuf::internal::WireFormatLite::WriteDouble(7, this->double_value(), output);
  1851. }
  1852. // string string_value = 8;
  1853. if (this->string_value().size() > 0) {
  1854. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1855. this->string_value().data(), static_cast<int>(this->string_value().length()),
  1856. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1857. "proto3.TestMessage.string_value");
  1858. ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
  1859. 8, this->string_value(), output);
  1860. }
  1861. // bytes bytes_value = 9;
  1862. if (this->bytes_value().size() > 0) {
  1863. ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
  1864. 9, this->bytes_value(), output);
  1865. }
  1866. // .proto3.EnumType enum_value = 10;
  1867. if (this->enum_value() != 0) {
  1868. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  1869. 10, this->enum_value(), output);
  1870. }
  1871. // .proto3.MessageType message_value = 11;
  1872. if (this->has_message_value()) {
  1873. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  1874. 11, this->_internal_message_value(), output);
  1875. }
  1876. // repeated bool repeated_bool_value = 21;
  1877. if (this->repeated_bool_value_size() > 0) {
  1878. ::google::protobuf::internal::WireFormatLite::WriteTag(21, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1879. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1880. _repeated_bool_value_cached_byte_size_));
  1881. ::google::protobuf::internal::WireFormatLite::WriteBoolArray(
  1882. this->repeated_bool_value().data(), this->repeated_bool_value_size(), output);
  1883. }
  1884. // repeated int32 repeated_int32_value = 22;
  1885. if (this->repeated_int32_value_size() > 0) {
  1886. ::google::protobuf::internal::WireFormatLite::WriteTag(22, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1887. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1888. _repeated_int32_value_cached_byte_size_));
  1889. }
  1890. for (int i = 0, n = this->repeated_int32_value_size(); i < n; i++) {
  1891. ::google::protobuf::internal::WireFormatLite::WriteInt32NoTag(
  1892. this->repeated_int32_value(i), output);
  1893. }
  1894. // repeated int64 repeated_int64_value = 23;
  1895. if (this->repeated_int64_value_size() > 0) {
  1896. ::google::protobuf::internal::WireFormatLite::WriteTag(23, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1897. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1898. _repeated_int64_value_cached_byte_size_));
  1899. }
  1900. for (int i = 0, n = this->repeated_int64_value_size(); i < n; i++) {
  1901. ::google::protobuf::internal::WireFormatLite::WriteInt64NoTag(
  1902. this->repeated_int64_value(i), output);
  1903. }
  1904. // repeated uint32 repeated_uint32_value = 24;
  1905. if (this->repeated_uint32_value_size() > 0) {
  1906. ::google::protobuf::internal::WireFormatLite::WriteTag(24, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1907. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1908. _repeated_uint32_value_cached_byte_size_));
  1909. }
  1910. for (int i = 0, n = this->repeated_uint32_value_size(); i < n; i++) {
  1911. ::google::protobuf::internal::WireFormatLite::WriteUInt32NoTag(
  1912. this->repeated_uint32_value(i), output);
  1913. }
  1914. // repeated uint64 repeated_uint64_value = 25;
  1915. if (this->repeated_uint64_value_size() > 0) {
  1916. ::google::protobuf::internal::WireFormatLite::WriteTag(25, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1917. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1918. _repeated_uint64_value_cached_byte_size_));
  1919. }
  1920. for (int i = 0, n = this->repeated_uint64_value_size(); i < n; i++) {
  1921. ::google::protobuf::internal::WireFormatLite::WriteUInt64NoTag(
  1922. this->repeated_uint64_value(i), output);
  1923. }
  1924. // repeated float repeated_float_value = 26;
  1925. if (this->repeated_float_value_size() > 0) {
  1926. ::google::protobuf::internal::WireFormatLite::WriteTag(26, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1927. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1928. _repeated_float_value_cached_byte_size_));
  1929. ::google::protobuf::internal::WireFormatLite::WriteFloatArray(
  1930. this->repeated_float_value().data(), this->repeated_float_value_size(), output);
  1931. }
  1932. // repeated double repeated_double_value = 27;
  1933. if (this->repeated_double_value_size() > 0) {
  1934. ::google::protobuf::internal::WireFormatLite::WriteTag(27, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
  1935. output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
  1936. _repeated_double_value_cached_byte_size_));
  1937. ::google::protobuf::internal::WireFormatLite::WriteDoubleArray(
  1938. this->repeated_double_value().data(), this->repeated_double_value_size(), output);
  1939. }
  1940. // repeated string repeated_string_value = 28;
  1941. for (int i = 0, n = this->repeated_string_value_size(); i < n; i++) {
  1942. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1943. this->repeated_string_value(i).data(), static_cast<int>(this->repeated_string_value(i).length()),
  1944. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1945. "proto3.TestMessage.repeated_string_value");
  1946. ::google::protobuf::internal::WireFormatLite::WriteString(
  1947. 28, this->repeated_string_value(i), output);
  1948. }
  1949. // repeated bytes repeated_bytes_value = 29;
  1950. for (int i = 0, n = this->repeated_bytes_value_size(); i < n; i++) {
  1951. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  1952. 29, this->repeated_bytes_value(i), output);
  1953. }
  1954. // repeated .proto3.EnumType repeated_enum_value = 30;
  1955. if (this->repeated_enum_value_size() > 0) {
  1956. ::google::protobuf::internal::WireFormatLite::WriteTag(
  1957. 30,
  1958. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  1959. output);
  1960. output->WriteVarint32(
  1961. static_cast< ::google::protobuf::uint32>(_repeated_enum_value_cached_byte_size_));
  1962. }
  1963. for (int i = 0, n = this->repeated_enum_value_size(); i < n; i++) {
  1964. ::google::protobuf::internal::WireFormatLite::WriteEnumNoTag(
  1965. this->repeated_enum_value(i), output);
  1966. }
  1967. // repeated .proto3.MessageType repeated_message_value = 31;
  1968. for (unsigned int i = 0,
  1969. n = static_cast<unsigned int>(this->repeated_message_value_size()); i < n; i++) {
  1970. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  1971. 31,
  1972. this->repeated_message_value(static_cast<int>(i)),
  1973. output);
  1974. }
  1975. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  1976. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  1977. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  1978. }
  1979. // @@protoc_insertion_point(serialize_end:proto3.TestMessage)
  1980. }
  1981. ::google::protobuf::uint8* TestMessage::InternalSerializeWithCachedSizesToArray(
  1982. bool deterministic, ::google::protobuf::uint8* target) const {
  1983. (void)deterministic; // Unused
  1984. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestMessage)
  1985. ::google::protobuf::uint32 cached_has_bits = 0;
  1986. (void) cached_has_bits;
  1987. // bool bool_value = 1;
  1988. if (this->bool_value() != 0) {
  1989. target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->bool_value(), target);
  1990. }
  1991. // int32 int32_value = 2;
  1992. if (this->int32_value() != 0) {
  1993. target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->int32_value(), target);
  1994. }
  1995. // int64 int64_value = 3;
  1996. if (this->int64_value() != 0) {
  1997. target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(3, this->int64_value(), target);
  1998. }
  1999. // uint32 uint32_value = 4;
  2000. if (this->uint32_value() != 0) {
  2001. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->uint32_value(), target);
  2002. }
  2003. // uint64 uint64_value = 5;
  2004. if (this->uint64_value() != 0) {
  2005. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(5, this->uint64_value(), target);
  2006. }
  2007. // float float_value = 6;
  2008. if (this->float_value() != 0) {
  2009. target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(6, this->float_value(), target);
  2010. }
  2011. // double double_value = 7;
  2012. if (this->double_value() != 0) {
  2013. target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(7, this->double_value(), target);
  2014. }
  2015. // string string_value = 8;
  2016. if (this->string_value().size() > 0) {
  2017. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  2018. this->string_value().data(), static_cast<int>(this->string_value().length()),
  2019. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  2020. "proto3.TestMessage.string_value");
  2021. target =
  2022. ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
  2023. 8, this->string_value(), target);
  2024. }
  2025. // bytes bytes_value = 9;
  2026. if (this->bytes_value().size() > 0) {
  2027. target =
  2028. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  2029. 9, this->bytes_value(), target);
  2030. }
  2031. // .proto3.EnumType enum_value = 10;
  2032. if (this->enum_value() != 0) {
  2033. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  2034. 10, this->enum_value(), target);
  2035. }
  2036. // .proto3.MessageType message_value = 11;
  2037. if (this->has_message_value()) {
  2038. target = ::google::protobuf::internal::WireFormatLite::
  2039. InternalWriteMessageToArray(
  2040. 11, this->_internal_message_value(), deterministic, target);
  2041. }
  2042. // repeated bool repeated_bool_value = 21;
  2043. if (this->repeated_bool_value_size() > 0) {
  2044. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2045. 21,
  2046. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2047. target);
  2048. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2049. static_cast< ::google::protobuf::int32>(
  2050. _repeated_bool_value_cached_byte_size_), target);
  2051. target = ::google::protobuf::internal::WireFormatLite::
  2052. WriteBoolNoTagToArray(this->repeated_bool_value_, target);
  2053. }
  2054. // repeated int32 repeated_int32_value = 22;
  2055. if (this->repeated_int32_value_size() > 0) {
  2056. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2057. 22,
  2058. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2059. target);
  2060. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2061. static_cast< ::google::protobuf::int32>(
  2062. _repeated_int32_value_cached_byte_size_), target);
  2063. target = ::google::protobuf::internal::WireFormatLite::
  2064. WriteInt32NoTagToArray(this->repeated_int32_value_, target);
  2065. }
  2066. // repeated int64 repeated_int64_value = 23;
  2067. if (this->repeated_int64_value_size() > 0) {
  2068. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2069. 23,
  2070. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2071. target);
  2072. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2073. static_cast< ::google::protobuf::int32>(
  2074. _repeated_int64_value_cached_byte_size_), target);
  2075. target = ::google::protobuf::internal::WireFormatLite::
  2076. WriteInt64NoTagToArray(this->repeated_int64_value_, target);
  2077. }
  2078. // repeated uint32 repeated_uint32_value = 24;
  2079. if (this->repeated_uint32_value_size() > 0) {
  2080. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2081. 24,
  2082. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2083. target);
  2084. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2085. static_cast< ::google::protobuf::int32>(
  2086. _repeated_uint32_value_cached_byte_size_), target);
  2087. target = ::google::protobuf::internal::WireFormatLite::
  2088. WriteUInt32NoTagToArray(this->repeated_uint32_value_, target);
  2089. }
  2090. // repeated uint64 repeated_uint64_value = 25;
  2091. if (this->repeated_uint64_value_size() > 0) {
  2092. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2093. 25,
  2094. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2095. target);
  2096. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2097. static_cast< ::google::protobuf::int32>(
  2098. _repeated_uint64_value_cached_byte_size_), target);
  2099. target = ::google::protobuf::internal::WireFormatLite::
  2100. WriteUInt64NoTagToArray(this->repeated_uint64_value_, target);
  2101. }
  2102. // repeated float repeated_float_value = 26;
  2103. if (this->repeated_float_value_size() > 0) {
  2104. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2105. 26,
  2106. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2107. target);
  2108. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2109. static_cast< ::google::protobuf::int32>(
  2110. _repeated_float_value_cached_byte_size_), target);
  2111. target = ::google::protobuf::internal::WireFormatLite::
  2112. WriteFloatNoTagToArray(this->repeated_float_value_, target);
  2113. }
  2114. // repeated double repeated_double_value = 27;
  2115. if (this->repeated_double_value_size() > 0) {
  2116. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2117. 27,
  2118. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2119. target);
  2120. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
  2121. static_cast< ::google::protobuf::int32>(
  2122. _repeated_double_value_cached_byte_size_), target);
  2123. target = ::google::protobuf::internal::WireFormatLite::
  2124. WriteDoubleNoTagToArray(this->repeated_double_value_, target);
  2125. }
  2126. // repeated string repeated_string_value = 28;
  2127. for (int i = 0, n = this->repeated_string_value_size(); i < n; i++) {
  2128. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  2129. this->repeated_string_value(i).data(), static_cast<int>(this->repeated_string_value(i).length()),
  2130. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  2131. "proto3.TestMessage.repeated_string_value");
  2132. target = ::google::protobuf::internal::WireFormatLite::
  2133. WriteStringToArray(28, this->repeated_string_value(i), target);
  2134. }
  2135. // repeated bytes repeated_bytes_value = 29;
  2136. for (int i = 0, n = this->repeated_bytes_value_size(); i < n; i++) {
  2137. target = ::google::protobuf::internal::WireFormatLite::
  2138. WriteBytesToArray(29, this->repeated_bytes_value(i), target);
  2139. }
  2140. // repeated .proto3.EnumType repeated_enum_value = 30;
  2141. if (this->repeated_enum_value_size() > 0) {
  2142. target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
  2143. 30,
  2144. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
  2145. target);
  2146. target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray( static_cast< ::google::protobuf::uint32>(
  2147. _repeated_enum_value_cached_byte_size_), target);
  2148. target = ::google::protobuf::internal::WireFormatLite::WriteEnumNoTagToArray(
  2149. this->repeated_enum_value_, target);
  2150. }
  2151. // repeated .proto3.MessageType repeated_message_value = 31;
  2152. for (unsigned int i = 0,
  2153. n = static_cast<unsigned int>(this->repeated_message_value_size()); i < n; i++) {
  2154. target = ::google::protobuf::internal::WireFormatLite::
  2155. InternalWriteMessageToArray(
  2156. 31, this->repeated_message_value(static_cast<int>(i)), deterministic, target);
  2157. }
  2158. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  2159. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  2160. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  2161. }
  2162. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestMessage)
  2163. return target;
  2164. }
  2165. size_t TestMessage::ByteSizeLong() const {
  2166. // @@protoc_insertion_point(message_byte_size_start:proto3.TestMessage)
  2167. size_t total_size = 0;
  2168. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  2169. total_size +=
  2170. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  2171. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  2172. }
  2173. // repeated bool repeated_bool_value = 21;
  2174. {
  2175. unsigned int count = static_cast<unsigned int>(this->repeated_bool_value_size());
  2176. size_t data_size = 1UL * count;
  2177. if (data_size > 0) {
  2178. total_size += 2 +
  2179. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2180. static_cast< ::google::protobuf::int32>(data_size));
  2181. }
  2182. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2183. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2184. _repeated_bool_value_cached_byte_size_ = cached_size;
  2185. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2186. total_size += data_size;
  2187. }
  2188. // repeated int32 repeated_int32_value = 22;
  2189. {
  2190. size_t data_size = ::google::protobuf::internal::WireFormatLite::
  2191. Int32Size(this->repeated_int32_value_);
  2192. if (data_size > 0) {
  2193. total_size += 2 +
  2194. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2195. static_cast< ::google::protobuf::int32>(data_size));
  2196. }
  2197. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2198. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2199. _repeated_int32_value_cached_byte_size_ = cached_size;
  2200. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2201. total_size += data_size;
  2202. }
  2203. // repeated int64 repeated_int64_value = 23;
  2204. {
  2205. size_t data_size = ::google::protobuf::internal::WireFormatLite::
  2206. Int64Size(this->repeated_int64_value_);
  2207. if (data_size > 0) {
  2208. total_size += 2 +
  2209. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2210. static_cast< ::google::protobuf::int32>(data_size));
  2211. }
  2212. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2213. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2214. _repeated_int64_value_cached_byte_size_ = cached_size;
  2215. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2216. total_size += data_size;
  2217. }
  2218. // repeated uint32 repeated_uint32_value = 24;
  2219. {
  2220. size_t data_size = ::google::protobuf::internal::WireFormatLite::
  2221. UInt32Size(this->repeated_uint32_value_);
  2222. if (data_size > 0) {
  2223. total_size += 2 +
  2224. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2225. static_cast< ::google::protobuf::int32>(data_size));
  2226. }
  2227. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2228. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2229. _repeated_uint32_value_cached_byte_size_ = cached_size;
  2230. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2231. total_size += data_size;
  2232. }
  2233. // repeated uint64 repeated_uint64_value = 25;
  2234. {
  2235. size_t data_size = ::google::protobuf::internal::WireFormatLite::
  2236. UInt64Size(this->repeated_uint64_value_);
  2237. if (data_size > 0) {
  2238. total_size += 2 +
  2239. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2240. static_cast< ::google::protobuf::int32>(data_size));
  2241. }
  2242. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2243. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2244. _repeated_uint64_value_cached_byte_size_ = cached_size;
  2245. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2246. total_size += data_size;
  2247. }
  2248. // repeated float repeated_float_value = 26;
  2249. {
  2250. unsigned int count = static_cast<unsigned int>(this->repeated_float_value_size());
  2251. size_t data_size = 4UL * count;
  2252. if (data_size > 0) {
  2253. total_size += 2 +
  2254. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2255. static_cast< ::google::protobuf::int32>(data_size));
  2256. }
  2257. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2258. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2259. _repeated_float_value_cached_byte_size_ = cached_size;
  2260. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2261. total_size += data_size;
  2262. }
  2263. // repeated double repeated_double_value = 27;
  2264. {
  2265. unsigned int count = static_cast<unsigned int>(this->repeated_double_value_size());
  2266. size_t data_size = 8UL * count;
  2267. if (data_size > 0) {
  2268. total_size += 2 +
  2269. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2270. static_cast< ::google::protobuf::int32>(data_size));
  2271. }
  2272. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2273. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2274. _repeated_double_value_cached_byte_size_ = cached_size;
  2275. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2276. total_size += data_size;
  2277. }
  2278. // repeated string repeated_string_value = 28;
  2279. total_size += 2 *
  2280. ::google::protobuf::internal::FromIntSize(this->repeated_string_value_size());
  2281. for (int i = 0, n = this->repeated_string_value_size(); i < n; i++) {
  2282. total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
  2283. this->repeated_string_value(i));
  2284. }
  2285. // repeated bytes repeated_bytes_value = 29;
  2286. total_size += 2 *
  2287. ::google::protobuf::internal::FromIntSize(this->repeated_bytes_value_size());
  2288. for (int i = 0, n = this->repeated_bytes_value_size(); i < n; i++) {
  2289. total_size += ::google::protobuf::internal::WireFormatLite::BytesSize(
  2290. this->repeated_bytes_value(i));
  2291. }
  2292. // repeated .proto3.EnumType repeated_enum_value = 30;
  2293. {
  2294. size_t data_size = 0;
  2295. unsigned int count = static_cast<unsigned int>(this->repeated_enum_value_size());for (unsigned int i = 0; i < count; i++) {
  2296. data_size += ::google::protobuf::internal::WireFormatLite::EnumSize(
  2297. this->repeated_enum_value(static_cast<int>(i)));
  2298. }
  2299. if (data_size > 0) {
  2300. total_size += 2 +
  2301. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2302. static_cast< ::google::protobuf::int32>(data_size));
  2303. }
  2304. int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
  2305. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  2306. _repeated_enum_value_cached_byte_size_ = cached_size;
  2307. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  2308. total_size += data_size;
  2309. }
  2310. // repeated .proto3.MessageType repeated_message_value = 31;
  2311. {
  2312. unsigned int count = static_cast<unsigned int>(this->repeated_message_value_size());
  2313. total_size += 2UL * count;
  2314. for (unsigned int i = 0; i < count; i++) {
  2315. total_size +=
  2316. ::google::protobuf::internal::WireFormatLite::MessageSize(
  2317. this->repeated_message_value(static_cast<int>(i)));
  2318. }
  2319. }
  2320. // string string_value = 8;
  2321. if (this->string_value().size() > 0) {
  2322. total_size += 1 +
  2323. ::google::protobuf::internal::WireFormatLite::StringSize(
  2324. this->string_value());
  2325. }
  2326. // bytes bytes_value = 9;
  2327. if (this->bytes_value().size() > 0) {
  2328. total_size += 1 +
  2329. ::google::protobuf::internal::WireFormatLite::BytesSize(
  2330. this->bytes_value());
  2331. }
  2332. // .proto3.MessageType message_value = 11;
  2333. if (this->has_message_value()) {
  2334. total_size += 1 +
  2335. ::google::protobuf::internal::WireFormatLite::MessageSize(
  2336. *message_value_);
  2337. }
  2338. // bool bool_value = 1;
  2339. if (this->bool_value() != 0) {
  2340. total_size += 1 + 1;
  2341. }
  2342. // int32 int32_value = 2;
  2343. if (this->int32_value() != 0) {
  2344. total_size += 1 +
  2345. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2346. this->int32_value());
  2347. }
  2348. // int64 int64_value = 3;
  2349. if (this->int64_value() != 0) {
  2350. total_size += 1 +
  2351. ::google::protobuf::internal::WireFormatLite::Int64Size(
  2352. this->int64_value());
  2353. }
  2354. // uint64 uint64_value = 5;
  2355. if (this->uint64_value() != 0) {
  2356. total_size += 1 +
  2357. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  2358. this->uint64_value());
  2359. }
  2360. // uint32 uint32_value = 4;
  2361. if (this->uint32_value() != 0) {
  2362. total_size += 1 +
  2363. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  2364. this->uint32_value());
  2365. }
  2366. // float float_value = 6;
  2367. if (this->float_value() != 0) {
  2368. total_size += 1 + 4;
  2369. }
  2370. // double double_value = 7;
  2371. if (this->double_value() != 0) {
  2372. total_size += 1 + 8;
  2373. }
  2374. // .proto3.EnumType enum_value = 10;
  2375. if (this->enum_value() != 0) {
  2376. total_size += 1 +
  2377. ::google::protobuf::internal::WireFormatLite::EnumSize(this->enum_value());
  2378. }
  2379. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  2380. SetCachedSize(cached_size);
  2381. return total_size;
  2382. }
  2383. void TestMessage::MergeFrom(const ::google::protobuf::Message& from) {
  2384. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestMessage)
  2385. GOOGLE_DCHECK_NE(&from, this);
  2386. const TestMessage* source =
  2387. ::google::protobuf::internal::DynamicCastToGenerated<const TestMessage>(
  2388. &from);
  2389. if (source == NULL) {
  2390. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestMessage)
  2391. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  2392. } else {
  2393. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestMessage)
  2394. MergeFrom(*source);
  2395. }
  2396. }
  2397. void TestMessage::MergeFrom(const TestMessage& from) {
  2398. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestMessage)
  2399. GOOGLE_DCHECK_NE(&from, this);
  2400. _internal_metadata_.MergeFrom(from._internal_metadata_);
  2401. ::google::protobuf::uint32 cached_has_bits = 0;
  2402. (void) cached_has_bits;
  2403. repeated_bool_value_.MergeFrom(from.repeated_bool_value_);
  2404. repeated_int32_value_.MergeFrom(from.repeated_int32_value_);
  2405. repeated_int64_value_.MergeFrom(from.repeated_int64_value_);
  2406. repeated_uint32_value_.MergeFrom(from.repeated_uint32_value_);
  2407. repeated_uint64_value_.MergeFrom(from.repeated_uint64_value_);
  2408. repeated_float_value_.MergeFrom(from.repeated_float_value_);
  2409. repeated_double_value_.MergeFrom(from.repeated_double_value_);
  2410. repeated_string_value_.MergeFrom(from.repeated_string_value_);
  2411. repeated_bytes_value_.MergeFrom(from.repeated_bytes_value_);
  2412. repeated_enum_value_.MergeFrom(from.repeated_enum_value_);
  2413. repeated_message_value_.MergeFrom(from.repeated_message_value_);
  2414. if (from.string_value().size() > 0) {
  2415. string_value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.string_value_);
  2416. }
  2417. if (from.bytes_value().size() > 0) {
  2418. bytes_value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.bytes_value_);
  2419. }
  2420. if (from.has_message_value()) {
  2421. mutable_message_value()->::proto3::MessageType::MergeFrom(from.message_value());
  2422. }
  2423. if (from.bool_value() != 0) {
  2424. set_bool_value(from.bool_value());
  2425. }
  2426. if (from.int32_value() != 0) {
  2427. set_int32_value(from.int32_value());
  2428. }
  2429. if (from.int64_value() != 0) {
  2430. set_int64_value(from.int64_value());
  2431. }
  2432. if (from.uint64_value() != 0) {
  2433. set_uint64_value(from.uint64_value());
  2434. }
  2435. if (from.uint32_value() != 0) {
  2436. set_uint32_value(from.uint32_value());
  2437. }
  2438. if (from.float_value() != 0) {
  2439. set_float_value(from.float_value());
  2440. }
  2441. if (from.double_value() != 0) {
  2442. set_double_value(from.double_value());
  2443. }
  2444. if (from.enum_value() != 0) {
  2445. set_enum_value(from.enum_value());
  2446. }
  2447. }
  2448. void TestMessage::CopyFrom(const ::google::protobuf::Message& from) {
  2449. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestMessage)
  2450. if (&from == this) return;
  2451. Clear();
  2452. MergeFrom(from);
  2453. }
  2454. void TestMessage::CopyFrom(const TestMessage& from) {
  2455. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestMessage)
  2456. if (&from == this) return;
  2457. Clear();
  2458. MergeFrom(from);
  2459. }
  2460. bool TestMessage::IsInitialized() const {
  2461. return true;
  2462. }
  2463. void TestMessage::Swap(TestMessage* other) {
  2464. if (other == this) return;
  2465. InternalSwap(other);
  2466. }
  2467. void TestMessage::InternalSwap(TestMessage* other) {
  2468. using std::swap;
  2469. repeated_bool_value_.InternalSwap(&other->repeated_bool_value_);
  2470. repeated_int32_value_.InternalSwap(&other->repeated_int32_value_);
  2471. repeated_int64_value_.InternalSwap(&other->repeated_int64_value_);
  2472. repeated_uint32_value_.InternalSwap(&other->repeated_uint32_value_);
  2473. repeated_uint64_value_.InternalSwap(&other->repeated_uint64_value_);
  2474. repeated_float_value_.InternalSwap(&other->repeated_float_value_);
  2475. repeated_double_value_.InternalSwap(&other->repeated_double_value_);
  2476. repeated_string_value_.InternalSwap(CastToBase(&other->repeated_string_value_));
  2477. repeated_bytes_value_.InternalSwap(CastToBase(&other->repeated_bytes_value_));
  2478. repeated_enum_value_.InternalSwap(&other->repeated_enum_value_);
  2479. CastToBase(&repeated_message_value_)->InternalSwap(CastToBase(&other->repeated_message_value_));
  2480. string_value_.Swap(&other->string_value_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  2481. GetArenaNoVirtual());
  2482. bytes_value_.Swap(&other->bytes_value_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  2483. GetArenaNoVirtual());
  2484. swap(message_value_, other->message_value_);
  2485. swap(bool_value_, other->bool_value_);
  2486. swap(int32_value_, other->int32_value_);
  2487. swap(int64_value_, other->int64_value_);
  2488. swap(uint64_value_, other->uint64_value_);
  2489. swap(uint32_value_, other->uint32_value_);
  2490. swap(float_value_, other->float_value_);
  2491. swap(double_value_, other->double_value_);
  2492. swap(enum_value_, other->enum_value_);
  2493. _internal_metadata_.Swap(&other->_internal_metadata_);
  2494. }
  2495. ::google::protobuf::Metadata TestMessage::GetMetadata() const {
  2496. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2497. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  2498. }
  2499. // ===================================================================
  2500. void TestOneof::InitAsDefaultInstance() {
  2501. ::proto3::_TestOneof_default_instance_.oneof_int32_value_ = 0;
  2502. ::proto3::_TestOneof_default_instance_.oneof_string_value_.UnsafeSetDefault(
  2503. &::google::protobuf::internal::GetEmptyStringAlreadyInited());
  2504. ::proto3::_TestOneof_default_instance_.oneof_bytes_value_.UnsafeSetDefault(
  2505. &::google::protobuf::internal::GetEmptyStringAlreadyInited());
  2506. ::proto3::_TestOneof_default_instance_.oneof_enum_value_ = 0;
  2507. ::proto3::_TestOneof_default_instance_.oneof_message_value_ = const_cast< ::proto3::MessageType*>(
  2508. ::proto3::MessageType::internal_default_instance());
  2509. }
  2510. void TestOneof::set_allocated_oneof_message_value(::proto3::MessageType* oneof_message_value) {
  2511. ::google::protobuf::Arena* message_arena = GetArenaNoVirtual();
  2512. clear_oneof_value();
  2513. if (oneof_message_value) {
  2514. ::google::protobuf::Arena* submessage_arena = NULL;
  2515. if (message_arena != submessage_arena) {
  2516. oneof_message_value = ::google::protobuf::internal::GetOwnedMessage(
  2517. message_arena, oneof_message_value, submessage_arena);
  2518. }
  2519. set_has_oneof_message_value();
  2520. oneof_value_.oneof_message_value_ = oneof_message_value;
  2521. }
  2522. // @@protoc_insertion_point(field_set_allocated:proto3.TestOneof.oneof_message_value)
  2523. }
  2524. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  2525. const int TestOneof::kOneofInt32ValueFieldNumber;
  2526. const int TestOneof::kOneofStringValueFieldNumber;
  2527. const int TestOneof::kOneofBytesValueFieldNumber;
  2528. const int TestOneof::kOneofEnumValueFieldNumber;
  2529. const int TestOneof::kOneofMessageValueFieldNumber;
  2530. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  2531. TestOneof::TestOneof()
  2532. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  2533. ::google::protobuf::internal::InitSCC(
  2534. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestOneof.base);
  2535. SharedCtor();
  2536. // @@protoc_insertion_point(constructor:proto3.TestOneof)
  2537. }
  2538. TestOneof::TestOneof(const TestOneof& from)
  2539. : ::google::protobuf::Message(),
  2540. _internal_metadata_(NULL) {
  2541. _internal_metadata_.MergeFrom(from._internal_metadata_);
  2542. clear_has_oneof_value();
  2543. switch (from.oneof_value_case()) {
  2544. case kOneofInt32Value: {
  2545. set_oneof_int32_value(from.oneof_int32_value());
  2546. break;
  2547. }
  2548. case kOneofStringValue: {
  2549. set_oneof_string_value(from.oneof_string_value());
  2550. break;
  2551. }
  2552. case kOneofBytesValue: {
  2553. set_oneof_bytes_value(from.oneof_bytes_value());
  2554. break;
  2555. }
  2556. case kOneofEnumValue: {
  2557. set_oneof_enum_value(from.oneof_enum_value());
  2558. break;
  2559. }
  2560. case kOneofMessageValue: {
  2561. mutable_oneof_message_value()->::proto3::MessageType::MergeFrom(from.oneof_message_value());
  2562. break;
  2563. }
  2564. case ONEOF_VALUE_NOT_SET: {
  2565. break;
  2566. }
  2567. }
  2568. // @@protoc_insertion_point(copy_constructor:proto3.TestOneof)
  2569. }
  2570. void TestOneof::SharedCtor() {
  2571. clear_has_oneof_value();
  2572. }
  2573. TestOneof::~TestOneof() {
  2574. // @@protoc_insertion_point(destructor:proto3.TestOneof)
  2575. SharedDtor();
  2576. }
  2577. void TestOneof::SharedDtor() {
  2578. if (has_oneof_value()) {
  2579. clear_oneof_value();
  2580. }
  2581. }
  2582. void TestOneof::SetCachedSize(int size) const {
  2583. _cached_size_.Set(size);
  2584. }
  2585. const ::google::protobuf::Descriptor* TestOneof::descriptor() {
  2586. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2587. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  2588. }
  2589. const TestOneof& TestOneof::default_instance() {
  2590. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestOneof.base);
  2591. return *internal_default_instance();
  2592. }
  2593. void TestOneof::clear_oneof_value() {
  2594. // @@protoc_insertion_point(one_of_clear_start:proto3.TestOneof)
  2595. switch (oneof_value_case()) {
  2596. case kOneofInt32Value: {
  2597. // No need to clear
  2598. break;
  2599. }
  2600. case kOneofStringValue: {
  2601. oneof_value_.oneof_string_value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  2602. break;
  2603. }
  2604. case kOneofBytesValue: {
  2605. oneof_value_.oneof_bytes_value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  2606. break;
  2607. }
  2608. case kOneofEnumValue: {
  2609. // No need to clear
  2610. break;
  2611. }
  2612. case kOneofMessageValue: {
  2613. delete oneof_value_.oneof_message_value_;
  2614. break;
  2615. }
  2616. case ONEOF_VALUE_NOT_SET: {
  2617. break;
  2618. }
  2619. }
  2620. _oneof_case_[0] = ONEOF_VALUE_NOT_SET;
  2621. }
  2622. void TestOneof::Clear() {
  2623. // @@protoc_insertion_point(message_clear_start:proto3.TestOneof)
  2624. ::google::protobuf::uint32 cached_has_bits = 0;
  2625. // Prevent compiler warnings about cached_has_bits being unused
  2626. (void) cached_has_bits;
  2627. clear_oneof_value();
  2628. _internal_metadata_.Clear();
  2629. }
  2630. bool TestOneof::MergePartialFromCodedStream(
  2631. ::google::protobuf::io::CodedInputStream* input) {
  2632. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  2633. ::google::protobuf::uint32 tag;
  2634. // @@protoc_insertion_point(parse_start:proto3.TestOneof)
  2635. for (;;) {
  2636. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  2637. tag = p.first;
  2638. if (!p.second) goto handle_unusual;
  2639. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  2640. // int32 oneof_int32_value = 1;
  2641. case 1: {
  2642. if (static_cast< ::google::protobuf::uint8>(tag) ==
  2643. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  2644. clear_oneof_value();
  2645. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  2646. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  2647. input, &oneof_value_.oneof_int32_value_)));
  2648. set_has_oneof_int32_value();
  2649. } else {
  2650. goto handle_unusual;
  2651. }
  2652. break;
  2653. }
  2654. // string oneof_string_value = 2;
  2655. case 2: {
  2656. if (static_cast< ::google::protobuf::uint8>(tag) ==
  2657. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  2658. DO_(::google::protobuf::internal::WireFormatLite::ReadString(
  2659. input, this->mutable_oneof_string_value()));
  2660. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  2661. this->oneof_string_value().data(), static_cast<int>(this->oneof_string_value().length()),
  2662. ::google::protobuf::internal::WireFormatLite::PARSE,
  2663. "proto3.TestOneof.oneof_string_value"));
  2664. } else {
  2665. goto handle_unusual;
  2666. }
  2667. break;
  2668. }
  2669. // bytes oneof_bytes_value = 3;
  2670. case 3: {
  2671. if (static_cast< ::google::protobuf::uint8>(tag) ==
  2672. static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
  2673. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  2674. input, this->mutable_oneof_bytes_value()));
  2675. } else {
  2676. goto handle_unusual;
  2677. }
  2678. break;
  2679. }
  2680. // .proto3.EnumType oneof_enum_value = 4;
  2681. case 4: {
  2682. if (static_cast< ::google::protobuf::uint8>(tag) ==
  2683. static_cast< ::google::protobuf::uint8>(32u /* 32 & 0xFF */)) {
  2684. int value;
  2685. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  2686. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  2687. input, &value)));
  2688. set_oneof_enum_value(static_cast< ::proto3::EnumType >(value));
  2689. } else {
  2690. goto handle_unusual;
  2691. }
  2692. break;
  2693. }
  2694. // .proto3.MessageType oneof_message_value = 5;
  2695. case 5: {
  2696. if (static_cast< ::google::protobuf::uint8>(tag) ==
  2697. static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
  2698. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  2699. input, mutable_oneof_message_value()));
  2700. } else {
  2701. goto handle_unusual;
  2702. }
  2703. break;
  2704. }
  2705. default: {
  2706. handle_unusual:
  2707. if (tag == 0) {
  2708. goto success;
  2709. }
  2710. DO_(::google::protobuf::internal::WireFormat::SkipField(
  2711. input, tag, _internal_metadata_.mutable_unknown_fields()));
  2712. break;
  2713. }
  2714. }
  2715. }
  2716. success:
  2717. // @@protoc_insertion_point(parse_success:proto3.TestOneof)
  2718. return true;
  2719. failure:
  2720. // @@protoc_insertion_point(parse_failure:proto3.TestOneof)
  2721. return false;
  2722. #undef DO_
  2723. }
  2724. void TestOneof::SerializeWithCachedSizes(
  2725. ::google::protobuf::io::CodedOutputStream* output) const {
  2726. // @@protoc_insertion_point(serialize_start:proto3.TestOneof)
  2727. ::google::protobuf::uint32 cached_has_bits = 0;
  2728. (void) cached_has_bits;
  2729. // int32 oneof_int32_value = 1;
  2730. if (has_oneof_int32_value()) {
  2731. ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->oneof_int32_value(), output);
  2732. }
  2733. // string oneof_string_value = 2;
  2734. if (has_oneof_string_value()) {
  2735. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  2736. this->oneof_string_value().data(), static_cast<int>(this->oneof_string_value().length()),
  2737. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  2738. "proto3.TestOneof.oneof_string_value");
  2739. ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
  2740. 2, this->oneof_string_value(), output);
  2741. }
  2742. // bytes oneof_bytes_value = 3;
  2743. if (has_oneof_bytes_value()) {
  2744. ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
  2745. 3, this->oneof_bytes_value(), output);
  2746. }
  2747. // .proto3.EnumType oneof_enum_value = 4;
  2748. if (has_oneof_enum_value()) {
  2749. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  2750. 4, this->oneof_enum_value(), output);
  2751. }
  2752. // .proto3.MessageType oneof_message_value = 5;
  2753. if (has_oneof_message_value()) {
  2754. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  2755. 5, this->_internal_oneof_message_value(), output);
  2756. }
  2757. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  2758. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  2759. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  2760. }
  2761. // @@protoc_insertion_point(serialize_end:proto3.TestOneof)
  2762. }
  2763. ::google::protobuf::uint8* TestOneof::InternalSerializeWithCachedSizesToArray(
  2764. bool deterministic, ::google::protobuf::uint8* target) const {
  2765. (void)deterministic; // Unused
  2766. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestOneof)
  2767. ::google::protobuf::uint32 cached_has_bits = 0;
  2768. (void) cached_has_bits;
  2769. // int32 oneof_int32_value = 1;
  2770. if (has_oneof_int32_value()) {
  2771. target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->oneof_int32_value(), target);
  2772. }
  2773. // string oneof_string_value = 2;
  2774. if (has_oneof_string_value()) {
  2775. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  2776. this->oneof_string_value().data(), static_cast<int>(this->oneof_string_value().length()),
  2777. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  2778. "proto3.TestOneof.oneof_string_value");
  2779. target =
  2780. ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
  2781. 2, this->oneof_string_value(), target);
  2782. }
  2783. // bytes oneof_bytes_value = 3;
  2784. if (has_oneof_bytes_value()) {
  2785. target =
  2786. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  2787. 3, this->oneof_bytes_value(), target);
  2788. }
  2789. // .proto3.EnumType oneof_enum_value = 4;
  2790. if (has_oneof_enum_value()) {
  2791. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  2792. 4, this->oneof_enum_value(), target);
  2793. }
  2794. // .proto3.MessageType oneof_message_value = 5;
  2795. if (has_oneof_message_value()) {
  2796. target = ::google::protobuf::internal::WireFormatLite::
  2797. InternalWriteMessageToArray(
  2798. 5, this->_internal_oneof_message_value(), deterministic, target);
  2799. }
  2800. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  2801. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  2802. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  2803. }
  2804. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestOneof)
  2805. return target;
  2806. }
  2807. size_t TestOneof::ByteSizeLong() const {
  2808. // @@protoc_insertion_point(message_byte_size_start:proto3.TestOneof)
  2809. size_t total_size = 0;
  2810. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  2811. total_size +=
  2812. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  2813. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  2814. }
  2815. switch (oneof_value_case()) {
  2816. // int32 oneof_int32_value = 1;
  2817. case kOneofInt32Value: {
  2818. total_size += 1 +
  2819. ::google::protobuf::internal::WireFormatLite::Int32Size(
  2820. this->oneof_int32_value());
  2821. break;
  2822. }
  2823. // string oneof_string_value = 2;
  2824. case kOneofStringValue: {
  2825. total_size += 1 +
  2826. ::google::protobuf::internal::WireFormatLite::StringSize(
  2827. this->oneof_string_value());
  2828. break;
  2829. }
  2830. // bytes oneof_bytes_value = 3;
  2831. case kOneofBytesValue: {
  2832. total_size += 1 +
  2833. ::google::protobuf::internal::WireFormatLite::BytesSize(
  2834. this->oneof_bytes_value());
  2835. break;
  2836. }
  2837. // .proto3.EnumType oneof_enum_value = 4;
  2838. case kOneofEnumValue: {
  2839. total_size += 1 +
  2840. ::google::protobuf::internal::WireFormatLite::EnumSize(this->oneof_enum_value());
  2841. break;
  2842. }
  2843. // .proto3.MessageType oneof_message_value = 5;
  2844. case kOneofMessageValue: {
  2845. total_size += 1 +
  2846. ::google::protobuf::internal::WireFormatLite::MessageSize(
  2847. *oneof_value_.oneof_message_value_);
  2848. break;
  2849. }
  2850. case ONEOF_VALUE_NOT_SET: {
  2851. break;
  2852. }
  2853. }
  2854. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  2855. SetCachedSize(cached_size);
  2856. return total_size;
  2857. }
  2858. void TestOneof::MergeFrom(const ::google::protobuf::Message& from) {
  2859. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestOneof)
  2860. GOOGLE_DCHECK_NE(&from, this);
  2861. const TestOneof* source =
  2862. ::google::protobuf::internal::DynamicCastToGenerated<const TestOneof>(
  2863. &from);
  2864. if (source == NULL) {
  2865. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestOneof)
  2866. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  2867. } else {
  2868. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestOneof)
  2869. MergeFrom(*source);
  2870. }
  2871. }
  2872. void TestOneof::MergeFrom(const TestOneof& from) {
  2873. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestOneof)
  2874. GOOGLE_DCHECK_NE(&from, this);
  2875. _internal_metadata_.MergeFrom(from._internal_metadata_);
  2876. ::google::protobuf::uint32 cached_has_bits = 0;
  2877. (void) cached_has_bits;
  2878. switch (from.oneof_value_case()) {
  2879. case kOneofInt32Value: {
  2880. set_oneof_int32_value(from.oneof_int32_value());
  2881. break;
  2882. }
  2883. case kOneofStringValue: {
  2884. set_oneof_string_value(from.oneof_string_value());
  2885. break;
  2886. }
  2887. case kOneofBytesValue: {
  2888. set_oneof_bytes_value(from.oneof_bytes_value());
  2889. break;
  2890. }
  2891. case kOneofEnumValue: {
  2892. set_oneof_enum_value(from.oneof_enum_value());
  2893. break;
  2894. }
  2895. case kOneofMessageValue: {
  2896. mutable_oneof_message_value()->::proto3::MessageType::MergeFrom(from.oneof_message_value());
  2897. break;
  2898. }
  2899. case ONEOF_VALUE_NOT_SET: {
  2900. break;
  2901. }
  2902. }
  2903. }
  2904. void TestOneof::CopyFrom(const ::google::protobuf::Message& from) {
  2905. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestOneof)
  2906. if (&from == this) return;
  2907. Clear();
  2908. MergeFrom(from);
  2909. }
  2910. void TestOneof::CopyFrom(const TestOneof& from) {
  2911. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestOneof)
  2912. if (&from == this) return;
  2913. Clear();
  2914. MergeFrom(from);
  2915. }
  2916. bool TestOneof::IsInitialized() const {
  2917. return true;
  2918. }
  2919. void TestOneof::Swap(TestOneof* other) {
  2920. if (other == this) return;
  2921. InternalSwap(other);
  2922. }
  2923. void TestOneof::InternalSwap(TestOneof* other) {
  2924. using std::swap;
  2925. swap(oneof_value_, other->oneof_value_);
  2926. swap(_oneof_case_[0], other->_oneof_case_[0]);
  2927. _internal_metadata_.Swap(&other->_internal_metadata_);
  2928. }
  2929. ::google::protobuf::Metadata TestOneof::GetMetadata() const {
  2930. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2931. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  2932. }
  2933. // ===================================================================
  2934. TestMap_BoolMapEntry_DoNotUse::TestMap_BoolMapEntry_DoNotUse() {}
  2935. TestMap_BoolMapEntry_DoNotUse::TestMap_BoolMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  2936. void TestMap_BoolMapEntry_DoNotUse::MergeFrom(const TestMap_BoolMapEntry_DoNotUse& other) {
  2937. MergeFromInternal(other);
  2938. }
  2939. ::google::protobuf::Metadata TestMap_BoolMapEntry_DoNotUse::GetMetadata() const {
  2940. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2941. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[3];
  2942. }
  2943. void TestMap_BoolMapEntry_DoNotUse::MergeFrom(
  2944. const ::google::protobuf::Message& other) {
  2945. ::google::protobuf::Message::MergeFrom(other);
  2946. }
  2947. // ===================================================================
  2948. TestMap_Int32MapEntry_DoNotUse::TestMap_Int32MapEntry_DoNotUse() {}
  2949. TestMap_Int32MapEntry_DoNotUse::TestMap_Int32MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  2950. void TestMap_Int32MapEntry_DoNotUse::MergeFrom(const TestMap_Int32MapEntry_DoNotUse& other) {
  2951. MergeFromInternal(other);
  2952. }
  2953. ::google::protobuf::Metadata TestMap_Int32MapEntry_DoNotUse::GetMetadata() const {
  2954. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2955. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[4];
  2956. }
  2957. void TestMap_Int32MapEntry_DoNotUse::MergeFrom(
  2958. const ::google::protobuf::Message& other) {
  2959. ::google::protobuf::Message::MergeFrom(other);
  2960. }
  2961. // ===================================================================
  2962. TestMap_Int64MapEntry_DoNotUse::TestMap_Int64MapEntry_DoNotUse() {}
  2963. TestMap_Int64MapEntry_DoNotUse::TestMap_Int64MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  2964. void TestMap_Int64MapEntry_DoNotUse::MergeFrom(const TestMap_Int64MapEntry_DoNotUse& other) {
  2965. MergeFromInternal(other);
  2966. }
  2967. ::google::protobuf::Metadata TestMap_Int64MapEntry_DoNotUse::GetMetadata() const {
  2968. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2969. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[5];
  2970. }
  2971. void TestMap_Int64MapEntry_DoNotUse::MergeFrom(
  2972. const ::google::protobuf::Message& other) {
  2973. ::google::protobuf::Message::MergeFrom(other);
  2974. }
  2975. // ===================================================================
  2976. TestMap_Uint32MapEntry_DoNotUse::TestMap_Uint32MapEntry_DoNotUse() {}
  2977. TestMap_Uint32MapEntry_DoNotUse::TestMap_Uint32MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  2978. void TestMap_Uint32MapEntry_DoNotUse::MergeFrom(const TestMap_Uint32MapEntry_DoNotUse& other) {
  2979. MergeFromInternal(other);
  2980. }
  2981. ::google::protobuf::Metadata TestMap_Uint32MapEntry_DoNotUse::GetMetadata() const {
  2982. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2983. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[6];
  2984. }
  2985. void TestMap_Uint32MapEntry_DoNotUse::MergeFrom(
  2986. const ::google::protobuf::Message& other) {
  2987. ::google::protobuf::Message::MergeFrom(other);
  2988. }
  2989. // ===================================================================
  2990. TestMap_Uint64MapEntry_DoNotUse::TestMap_Uint64MapEntry_DoNotUse() {}
  2991. TestMap_Uint64MapEntry_DoNotUse::TestMap_Uint64MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  2992. void TestMap_Uint64MapEntry_DoNotUse::MergeFrom(const TestMap_Uint64MapEntry_DoNotUse& other) {
  2993. MergeFromInternal(other);
  2994. }
  2995. ::google::protobuf::Metadata TestMap_Uint64MapEntry_DoNotUse::GetMetadata() const {
  2996. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  2997. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[7];
  2998. }
  2999. void TestMap_Uint64MapEntry_DoNotUse::MergeFrom(
  3000. const ::google::protobuf::Message& other) {
  3001. ::google::protobuf::Message::MergeFrom(other);
  3002. }
  3003. // ===================================================================
  3004. TestMap_StringMapEntry_DoNotUse::TestMap_StringMapEntry_DoNotUse() {}
  3005. TestMap_StringMapEntry_DoNotUse::TestMap_StringMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3006. void TestMap_StringMapEntry_DoNotUse::MergeFrom(const TestMap_StringMapEntry_DoNotUse& other) {
  3007. MergeFromInternal(other);
  3008. }
  3009. ::google::protobuf::Metadata TestMap_StringMapEntry_DoNotUse::GetMetadata() const {
  3010. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3011. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[8];
  3012. }
  3013. void TestMap_StringMapEntry_DoNotUse::MergeFrom(
  3014. const ::google::protobuf::Message& other) {
  3015. ::google::protobuf::Message::MergeFrom(other);
  3016. }
  3017. // ===================================================================
  3018. void TestMap::InitAsDefaultInstance() {
  3019. }
  3020. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  3021. const int TestMap::kBoolMapFieldNumber;
  3022. const int TestMap::kInt32MapFieldNumber;
  3023. const int TestMap::kInt64MapFieldNumber;
  3024. const int TestMap::kUint32MapFieldNumber;
  3025. const int TestMap::kUint64MapFieldNumber;
  3026. const int TestMap::kStringMapFieldNumber;
  3027. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  3028. TestMap::TestMap()
  3029. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  3030. ::google::protobuf::internal::InitSCC(
  3031. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap.base);
  3032. SharedCtor();
  3033. // @@protoc_insertion_point(constructor:proto3.TestMap)
  3034. }
  3035. TestMap::TestMap(const TestMap& from)
  3036. : ::google::protobuf::Message(),
  3037. _internal_metadata_(NULL) {
  3038. _internal_metadata_.MergeFrom(from._internal_metadata_);
  3039. bool_map_.MergeFrom(from.bool_map_);
  3040. int32_map_.MergeFrom(from.int32_map_);
  3041. int64_map_.MergeFrom(from.int64_map_);
  3042. uint32_map_.MergeFrom(from.uint32_map_);
  3043. uint64_map_.MergeFrom(from.uint64_map_);
  3044. string_map_.MergeFrom(from.string_map_);
  3045. // @@protoc_insertion_point(copy_constructor:proto3.TestMap)
  3046. }
  3047. void TestMap::SharedCtor() {
  3048. }
  3049. TestMap::~TestMap() {
  3050. // @@protoc_insertion_point(destructor:proto3.TestMap)
  3051. SharedDtor();
  3052. }
  3053. void TestMap::SharedDtor() {
  3054. }
  3055. void TestMap::SetCachedSize(int size) const {
  3056. _cached_size_.Set(size);
  3057. }
  3058. const ::google::protobuf::Descriptor* TestMap::descriptor() {
  3059. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3060. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  3061. }
  3062. const TestMap& TestMap::default_instance() {
  3063. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestMap.base);
  3064. return *internal_default_instance();
  3065. }
  3066. void TestMap::Clear() {
  3067. // @@protoc_insertion_point(message_clear_start:proto3.TestMap)
  3068. ::google::protobuf::uint32 cached_has_bits = 0;
  3069. // Prevent compiler warnings about cached_has_bits being unused
  3070. (void) cached_has_bits;
  3071. bool_map_.Clear();
  3072. int32_map_.Clear();
  3073. int64_map_.Clear();
  3074. uint32_map_.Clear();
  3075. uint64_map_.Clear();
  3076. string_map_.Clear();
  3077. _internal_metadata_.Clear();
  3078. }
  3079. bool TestMap::MergePartialFromCodedStream(
  3080. ::google::protobuf::io::CodedInputStream* input) {
  3081. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  3082. ::google::protobuf::uint32 tag;
  3083. // @@protoc_insertion_point(parse_start:proto3.TestMap)
  3084. for (;;) {
  3085. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  3086. tag = p.first;
  3087. if (!p.second) goto handle_unusual;
  3088. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  3089. // map<bool, int32> bool_map = 1;
  3090. case 1: {
  3091. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3092. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  3093. TestMap_BoolMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3094. TestMap_BoolMapEntry_DoNotUse,
  3095. bool, ::google::protobuf::int32,
  3096. ::google::protobuf::internal::WireFormatLite::TYPE_BOOL,
  3097. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3098. 0 >,
  3099. ::google::protobuf::Map< bool, ::google::protobuf::int32 > > parser(&bool_map_);
  3100. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3101. input, &parser));
  3102. } else {
  3103. goto handle_unusual;
  3104. }
  3105. break;
  3106. }
  3107. // map<int32, int32> int32_map = 2;
  3108. case 2: {
  3109. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3110. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  3111. TestMap_Int32MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3112. TestMap_Int32MapEntry_DoNotUse,
  3113. ::google::protobuf::int32, ::google::protobuf::int32,
  3114. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3115. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3116. 0 >,
  3117. ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 > > parser(&int32_map_);
  3118. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3119. input, &parser));
  3120. } else {
  3121. goto handle_unusual;
  3122. }
  3123. break;
  3124. }
  3125. // map<int64, int32> int64_map = 3;
  3126. case 3: {
  3127. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3128. static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
  3129. TestMap_Int64MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3130. TestMap_Int64MapEntry_DoNotUse,
  3131. ::google::protobuf::int64, ::google::protobuf::int32,
  3132. ::google::protobuf::internal::WireFormatLite::TYPE_INT64,
  3133. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3134. 0 >,
  3135. ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 > > parser(&int64_map_);
  3136. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3137. input, &parser));
  3138. } else {
  3139. goto handle_unusual;
  3140. }
  3141. break;
  3142. }
  3143. // map<uint32, int32> uint32_map = 4;
  3144. case 4: {
  3145. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3146. static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
  3147. TestMap_Uint32MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3148. TestMap_Uint32MapEntry_DoNotUse,
  3149. ::google::protobuf::uint32, ::google::protobuf::int32,
  3150. ::google::protobuf::internal::WireFormatLite::TYPE_UINT32,
  3151. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3152. 0 >,
  3153. ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 > > parser(&uint32_map_);
  3154. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3155. input, &parser));
  3156. } else {
  3157. goto handle_unusual;
  3158. }
  3159. break;
  3160. }
  3161. // map<uint64, int32> uint64_map = 5;
  3162. case 5: {
  3163. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3164. static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
  3165. TestMap_Uint64MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3166. TestMap_Uint64MapEntry_DoNotUse,
  3167. ::google::protobuf::uint64, ::google::protobuf::int32,
  3168. ::google::protobuf::internal::WireFormatLite::TYPE_UINT64,
  3169. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3170. 0 >,
  3171. ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 > > parser(&uint64_map_);
  3172. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3173. input, &parser));
  3174. } else {
  3175. goto handle_unusual;
  3176. }
  3177. break;
  3178. }
  3179. // map<string, int32> string_map = 6;
  3180. case 6: {
  3181. if (static_cast< ::google::protobuf::uint8>(tag) ==
  3182. static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
  3183. TestMap_StringMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  3184. TestMap_StringMapEntry_DoNotUse,
  3185. ::std::string, ::google::protobuf::int32,
  3186. ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
  3187. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  3188. 0 >,
  3189. ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 > > parser(&string_map_);
  3190. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  3191. input, &parser));
  3192. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  3193. parser.key().data(), static_cast<int>(parser.key().length()),
  3194. ::google::protobuf::internal::WireFormatLite::PARSE,
  3195. "proto3.TestMap.StringMapEntry.key"));
  3196. } else {
  3197. goto handle_unusual;
  3198. }
  3199. break;
  3200. }
  3201. default: {
  3202. handle_unusual:
  3203. if (tag == 0) {
  3204. goto success;
  3205. }
  3206. DO_(::google::protobuf::internal::WireFormat::SkipField(
  3207. input, tag, _internal_metadata_.mutable_unknown_fields()));
  3208. break;
  3209. }
  3210. }
  3211. }
  3212. success:
  3213. // @@protoc_insertion_point(parse_success:proto3.TestMap)
  3214. return true;
  3215. failure:
  3216. // @@protoc_insertion_point(parse_failure:proto3.TestMap)
  3217. return false;
  3218. #undef DO_
  3219. }
  3220. void TestMap::SerializeWithCachedSizes(
  3221. ::google::protobuf::io::CodedOutputStream* output) const {
  3222. // @@protoc_insertion_point(serialize_start:proto3.TestMap)
  3223. ::google::protobuf::uint32 cached_has_bits = 0;
  3224. (void) cached_has_bits;
  3225. // map<bool, int32> bool_map = 1;
  3226. if (!this->bool_map().empty()) {
  3227. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  3228. ConstPtr;
  3229. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  3230. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3231. if (output->IsSerializationDeterministic() &&
  3232. this->bool_map().size() > 1) {
  3233. ::std::unique_ptr<SortItem[]> items(
  3234. new SortItem[this->bool_map().size()]);
  3235. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  3236. size_type n = 0;
  3237. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  3238. it = this->bool_map().begin();
  3239. it != this->bool_map().end(); ++it, ++n) {
  3240. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3241. }
  3242. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3243. ::std::unique_ptr<TestMap_BoolMapEntry_DoNotUse> entry;
  3244. for (size_type i = 0; i < n; i++) {
  3245. entry.reset(bool_map_.NewEntryWrapper(
  3246. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3247. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3248. 1, *entry, output);
  3249. }
  3250. } else {
  3251. ::std::unique_ptr<TestMap_BoolMapEntry_DoNotUse> entry;
  3252. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  3253. it = this->bool_map().begin();
  3254. it != this->bool_map().end(); ++it) {
  3255. entry.reset(bool_map_.NewEntryWrapper(
  3256. it->first, it->second));
  3257. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3258. 1, *entry, output);
  3259. }
  3260. }
  3261. }
  3262. // map<int32, int32> int32_map = 2;
  3263. if (!this->int32_map().empty()) {
  3264. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_pointer
  3265. ConstPtr;
  3266. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
  3267. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3268. if (output->IsSerializationDeterministic() &&
  3269. this->int32_map().size() > 1) {
  3270. ::std::unique_ptr<SortItem[]> items(
  3271. new SortItem[this->int32_map().size()]);
  3272. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::size_type size_type;
  3273. size_type n = 0;
  3274. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  3275. it = this->int32_map().begin();
  3276. it != this->int32_map().end(); ++it, ++n) {
  3277. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3278. }
  3279. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3280. ::std::unique_ptr<TestMap_Int32MapEntry_DoNotUse> entry;
  3281. for (size_type i = 0; i < n; i++) {
  3282. entry.reset(int32_map_.NewEntryWrapper(
  3283. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3284. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3285. 2, *entry, output);
  3286. }
  3287. } else {
  3288. ::std::unique_ptr<TestMap_Int32MapEntry_DoNotUse> entry;
  3289. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  3290. it = this->int32_map().begin();
  3291. it != this->int32_map().end(); ++it) {
  3292. entry.reset(int32_map_.NewEntryWrapper(
  3293. it->first, it->second));
  3294. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3295. 2, *entry, output);
  3296. }
  3297. }
  3298. }
  3299. // map<int64, int32> int64_map = 3;
  3300. if (!this->int64_map().empty()) {
  3301. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_pointer
  3302. ConstPtr;
  3303. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int64, ConstPtr > SortItem;
  3304. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3305. if (output->IsSerializationDeterministic() &&
  3306. this->int64_map().size() > 1) {
  3307. ::std::unique_ptr<SortItem[]> items(
  3308. new SortItem[this->int64_map().size()]);
  3309. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::size_type size_type;
  3310. size_type n = 0;
  3311. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  3312. it = this->int64_map().begin();
  3313. it != this->int64_map().end(); ++it, ++n) {
  3314. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3315. }
  3316. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3317. ::std::unique_ptr<TestMap_Int64MapEntry_DoNotUse> entry;
  3318. for (size_type i = 0; i < n; i++) {
  3319. entry.reset(int64_map_.NewEntryWrapper(
  3320. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3321. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3322. 3, *entry, output);
  3323. }
  3324. } else {
  3325. ::std::unique_ptr<TestMap_Int64MapEntry_DoNotUse> entry;
  3326. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  3327. it = this->int64_map().begin();
  3328. it != this->int64_map().end(); ++it) {
  3329. entry.reset(int64_map_.NewEntryWrapper(
  3330. it->first, it->second));
  3331. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3332. 3, *entry, output);
  3333. }
  3334. }
  3335. }
  3336. // map<uint32, int32> uint32_map = 4;
  3337. if (!this->uint32_map().empty()) {
  3338. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_pointer
  3339. ConstPtr;
  3340. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint32, ConstPtr > SortItem;
  3341. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3342. if (output->IsSerializationDeterministic() &&
  3343. this->uint32_map().size() > 1) {
  3344. ::std::unique_ptr<SortItem[]> items(
  3345. new SortItem[this->uint32_map().size()]);
  3346. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::size_type size_type;
  3347. size_type n = 0;
  3348. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  3349. it = this->uint32_map().begin();
  3350. it != this->uint32_map().end(); ++it, ++n) {
  3351. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3352. }
  3353. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3354. ::std::unique_ptr<TestMap_Uint32MapEntry_DoNotUse> entry;
  3355. for (size_type i = 0; i < n; i++) {
  3356. entry.reset(uint32_map_.NewEntryWrapper(
  3357. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3358. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3359. 4, *entry, output);
  3360. }
  3361. } else {
  3362. ::std::unique_ptr<TestMap_Uint32MapEntry_DoNotUse> entry;
  3363. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  3364. it = this->uint32_map().begin();
  3365. it != this->uint32_map().end(); ++it) {
  3366. entry.reset(uint32_map_.NewEntryWrapper(
  3367. it->first, it->second));
  3368. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3369. 4, *entry, output);
  3370. }
  3371. }
  3372. }
  3373. // map<uint64, int32> uint64_map = 5;
  3374. if (!this->uint64_map().empty()) {
  3375. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_pointer
  3376. ConstPtr;
  3377. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint64, ConstPtr > SortItem;
  3378. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3379. if (output->IsSerializationDeterministic() &&
  3380. this->uint64_map().size() > 1) {
  3381. ::std::unique_ptr<SortItem[]> items(
  3382. new SortItem[this->uint64_map().size()]);
  3383. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::size_type size_type;
  3384. size_type n = 0;
  3385. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  3386. it = this->uint64_map().begin();
  3387. it != this->uint64_map().end(); ++it, ++n) {
  3388. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3389. }
  3390. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3391. ::std::unique_ptr<TestMap_Uint64MapEntry_DoNotUse> entry;
  3392. for (size_type i = 0; i < n; i++) {
  3393. entry.reset(uint64_map_.NewEntryWrapper(
  3394. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3395. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3396. 5, *entry, output);
  3397. }
  3398. } else {
  3399. ::std::unique_ptr<TestMap_Uint64MapEntry_DoNotUse> entry;
  3400. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  3401. it = this->uint64_map().begin();
  3402. it != this->uint64_map().end(); ++it) {
  3403. entry.reset(uint64_map_.NewEntryWrapper(
  3404. it->first, it->second));
  3405. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3406. 5, *entry, output);
  3407. }
  3408. }
  3409. }
  3410. // map<string, int32> string_map = 6;
  3411. if (!this->string_map().empty()) {
  3412. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_pointer
  3413. ConstPtr;
  3414. typedef ConstPtr SortItem;
  3415. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  3416. struct Utf8Check {
  3417. static void Check(ConstPtr p) {
  3418. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  3419. p->first.data(), static_cast<int>(p->first.length()),
  3420. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  3421. "proto3.TestMap.StringMapEntry.key");
  3422. }
  3423. };
  3424. if (output->IsSerializationDeterministic() &&
  3425. this->string_map().size() > 1) {
  3426. ::std::unique_ptr<SortItem[]> items(
  3427. new SortItem[this->string_map().size()]);
  3428. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::size_type size_type;
  3429. size_type n = 0;
  3430. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  3431. it = this->string_map().begin();
  3432. it != this->string_map().end(); ++it, ++n) {
  3433. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3434. }
  3435. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3436. ::std::unique_ptr<TestMap_StringMapEntry_DoNotUse> entry;
  3437. for (size_type i = 0; i < n; i++) {
  3438. entry.reset(string_map_.NewEntryWrapper(
  3439. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  3440. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3441. 6, *entry, output);
  3442. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  3443. }
  3444. } else {
  3445. ::std::unique_ptr<TestMap_StringMapEntry_DoNotUse> entry;
  3446. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  3447. it = this->string_map().begin();
  3448. it != this->string_map().end(); ++it) {
  3449. entry.reset(string_map_.NewEntryWrapper(
  3450. it->first, it->second));
  3451. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  3452. 6, *entry, output);
  3453. Utf8Check::Check(&*it);
  3454. }
  3455. }
  3456. }
  3457. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  3458. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  3459. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  3460. }
  3461. // @@protoc_insertion_point(serialize_end:proto3.TestMap)
  3462. }
  3463. ::google::protobuf::uint8* TestMap::InternalSerializeWithCachedSizesToArray(
  3464. bool deterministic, ::google::protobuf::uint8* target) const {
  3465. (void)deterministic; // Unused
  3466. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestMap)
  3467. ::google::protobuf::uint32 cached_has_bits = 0;
  3468. (void) cached_has_bits;
  3469. // map<bool, int32> bool_map = 1;
  3470. if (!this->bool_map().empty()) {
  3471. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  3472. ConstPtr;
  3473. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  3474. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3475. if (deterministic &&
  3476. this->bool_map().size() > 1) {
  3477. ::std::unique_ptr<SortItem[]> items(
  3478. new SortItem[this->bool_map().size()]);
  3479. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  3480. size_type n = 0;
  3481. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  3482. it = this->bool_map().begin();
  3483. it != this->bool_map().end(); ++it, ++n) {
  3484. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3485. }
  3486. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3487. ::std::unique_ptr<TestMap_BoolMapEntry_DoNotUse> entry;
  3488. for (size_type i = 0; i < n; i++) {
  3489. entry.reset(bool_map_.NewEntryWrapper(
  3490. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3491. target = ::google::protobuf::internal::WireFormatLite::
  3492. InternalWriteMessageNoVirtualToArray(
  3493. 1, *entry, deterministic, target);
  3494. ;
  3495. }
  3496. } else {
  3497. ::std::unique_ptr<TestMap_BoolMapEntry_DoNotUse> entry;
  3498. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  3499. it = this->bool_map().begin();
  3500. it != this->bool_map().end(); ++it) {
  3501. entry.reset(bool_map_.NewEntryWrapper(
  3502. it->first, it->second));
  3503. target = ::google::protobuf::internal::WireFormatLite::
  3504. InternalWriteMessageNoVirtualToArray(
  3505. 1, *entry, deterministic, target);
  3506. ;
  3507. }
  3508. }
  3509. }
  3510. // map<int32, int32> int32_map = 2;
  3511. if (!this->int32_map().empty()) {
  3512. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_pointer
  3513. ConstPtr;
  3514. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
  3515. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3516. if (deterministic &&
  3517. this->int32_map().size() > 1) {
  3518. ::std::unique_ptr<SortItem[]> items(
  3519. new SortItem[this->int32_map().size()]);
  3520. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::size_type size_type;
  3521. size_type n = 0;
  3522. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  3523. it = this->int32_map().begin();
  3524. it != this->int32_map().end(); ++it, ++n) {
  3525. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3526. }
  3527. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3528. ::std::unique_ptr<TestMap_Int32MapEntry_DoNotUse> entry;
  3529. for (size_type i = 0; i < n; i++) {
  3530. entry.reset(int32_map_.NewEntryWrapper(
  3531. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3532. target = ::google::protobuf::internal::WireFormatLite::
  3533. InternalWriteMessageNoVirtualToArray(
  3534. 2, *entry, deterministic, target);
  3535. ;
  3536. }
  3537. } else {
  3538. ::std::unique_ptr<TestMap_Int32MapEntry_DoNotUse> entry;
  3539. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  3540. it = this->int32_map().begin();
  3541. it != this->int32_map().end(); ++it) {
  3542. entry.reset(int32_map_.NewEntryWrapper(
  3543. it->first, it->second));
  3544. target = ::google::protobuf::internal::WireFormatLite::
  3545. InternalWriteMessageNoVirtualToArray(
  3546. 2, *entry, deterministic, target);
  3547. ;
  3548. }
  3549. }
  3550. }
  3551. // map<int64, int32> int64_map = 3;
  3552. if (!this->int64_map().empty()) {
  3553. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_pointer
  3554. ConstPtr;
  3555. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int64, ConstPtr > SortItem;
  3556. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3557. if (deterministic &&
  3558. this->int64_map().size() > 1) {
  3559. ::std::unique_ptr<SortItem[]> items(
  3560. new SortItem[this->int64_map().size()]);
  3561. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::size_type size_type;
  3562. size_type n = 0;
  3563. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  3564. it = this->int64_map().begin();
  3565. it != this->int64_map().end(); ++it, ++n) {
  3566. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3567. }
  3568. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3569. ::std::unique_ptr<TestMap_Int64MapEntry_DoNotUse> entry;
  3570. for (size_type i = 0; i < n; i++) {
  3571. entry.reset(int64_map_.NewEntryWrapper(
  3572. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3573. target = ::google::protobuf::internal::WireFormatLite::
  3574. InternalWriteMessageNoVirtualToArray(
  3575. 3, *entry, deterministic, target);
  3576. ;
  3577. }
  3578. } else {
  3579. ::std::unique_ptr<TestMap_Int64MapEntry_DoNotUse> entry;
  3580. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  3581. it = this->int64_map().begin();
  3582. it != this->int64_map().end(); ++it) {
  3583. entry.reset(int64_map_.NewEntryWrapper(
  3584. it->first, it->second));
  3585. target = ::google::protobuf::internal::WireFormatLite::
  3586. InternalWriteMessageNoVirtualToArray(
  3587. 3, *entry, deterministic, target);
  3588. ;
  3589. }
  3590. }
  3591. }
  3592. // map<uint32, int32> uint32_map = 4;
  3593. if (!this->uint32_map().empty()) {
  3594. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_pointer
  3595. ConstPtr;
  3596. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint32, ConstPtr > SortItem;
  3597. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3598. if (deterministic &&
  3599. this->uint32_map().size() > 1) {
  3600. ::std::unique_ptr<SortItem[]> items(
  3601. new SortItem[this->uint32_map().size()]);
  3602. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::size_type size_type;
  3603. size_type n = 0;
  3604. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  3605. it = this->uint32_map().begin();
  3606. it != this->uint32_map().end(); ++it, ++n) {
  3607. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3608. }
  3609. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3610. ::std::unique_ptr<TestMap_Uint32MapEntry_DoNotUse> entry;
  3611. for (size_type i = 0; i < n; i++) {
  3612. entry.reset(uint32_map_.NewEntryWrapper(
  3613. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3614. target = ::google::protobuf::internal::WireFormatLite::
  3615. InternalWriteMessageNoVirtualToArray(
  3616. 4, *entry, deterministic, target);
  3617. ;
  3618. }
  3619. } else {
  3620. ::std::unique_ptr<TestMap_Uint32MapEntry_DoNotUse> entry;
  3621. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  3622. it = this->uint32_map().begin();
  3623. it != this->uint32_map().end(); ++it) {
  3624. entry.reset(uint32_map_.NewEntryWrapper(
  3625. it->first, it->second));
  3626. target = ::google::protobuf::internal::WireFormatLite::
  3627. InternalWriteMessageNoVirtualToArray(
  3628. 4, *entry, deterministic, target);
  3629. ;
  3630. }
  3631. }
  3632. }
  3633. // map<uint64, int32> uint64_map = 5;
  3634. if (!this->uint64_map().empty()) {
  3635. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_pointer
  3636. ConstPtr;
  3637. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint64, ConstPtr > SortItem;
  3638. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  3639. if (deterministic &&
  3640. this->uint64_map().size() > 1) {
  3641. ::std::unique_ptr<SortItem[]> items(
  3642. new SortItem[this->uint64_map().size()]);
  3643. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::size_type size_type;
  3644. size_type n = 0;
  3645. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  3646. it = this->uint64_map().begin();
  3647. it != this->uint64_map().end(); ++it, ++n) {
  3648. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3649. }
  3650. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3651. ::std::unique_ptr<TestMap_Uint64MapEntry_DoNotUse> entry;
  3652. for (size_type i = 0; i < n; i++) {
  3653. entry.reset(uint64_map_.NewEntryWrapper(
  3654. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  3655. target = ::google::protobuf::internal::WireFormatLite::
  3656. InternalWriteMessageNoVirtualToArray(
  3657. 5, *entry, deterministic, target);
  3658. ;
  3659. }
  3660. } else {
  3661. ::std::unique_ptr<TestMap_Uint64MapEntry_DoNotUse> entry;
  3662. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  3663. it = this->uint64_map().begin();
  3664. it != this->uint64_map().end(); ++it) {
  3665. entry.reset(uint64_map_.NewEntryWrapper(
  3666. it->first, it->second));
  3667. target = ::google::protobuf::internal::WireFormatLite::
  3668. InternalWriteMessageNoVirtualToArray(
  3669. 5, *entry, deterministic, target);
  3670. ;
  3671. }
  3672. }
  3673. }
  3674. // map<string, int32> string_map = 6;
  3675. if (!this->string_map().empty()) {
  3676. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_pointer
  3677. ConstPtr;
  3678. typedef ConstPtr SortItem;
  3679. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  3680. struct Utf8Check {
  3681. static void Check(ConstPtr p) {
  3682. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  3683. p->first.data(), static_cast<int>(p->first.length()),
  3684. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  3685. "proto3.TestMap.StringMapEntry.key");
  3686. }
  3687. };
  3688. if (deterministic &&
  3689. this->string_map().size() > 1) {
  3690. ::std::unique_ptr<SortItem[]> items(
  3691. new SortItem[this->string_map().size()]);
  3692. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::size_type size_type;
  3693. size_type n = 0;
  3694. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  3695. it = this->string_map().begin();
  3696. it != this->string_map().end(); ++it, ++n) {
  3697. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  3698. }
  3699. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  3700. ::std::unique_ptr<TestMap_StringMapEntry_DoNotUse> entry;
  3701. for (size_type i = 0; i < n; i++) {
  3702. entry.reset(string_map_.NewEntryWrapper(
  3703. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  3704. target = ::google::protobuf::internal::WireFormatLite::
  3705. InternalWriteMessageNoVirtualToArray(
  3706. 6, *entry, deterministic, target);
  3707. ;
  3708. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  3709. }
  3710. } else {
  3711. ::std::unique_ptr<TestMap_StringMapEntry_DoNotUse> entry;
  3712. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  3713. it = this->string_map().begin();
  3714. it != this->string_map().end(); ++it) {
  3715. entry.reset(string_map_.NewEntryWrapper(
  3716. it->first, it->second));
  3717. target = ::google::protobuf::internal::WireFormatLite::
  3718. InternalWriteMessageNoVirtualToArray(
  3719. 6, *entry, deterministic, target);
  3720. ;
  3721. Utf8Check::Check(&*it);
  3722. }
  3723. }
  3724. }
  3725. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  3726. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  3727. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  3728. }
  3729. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestMap)
  3730. return target;
  3731. }
  3732. size_t TestMap::ByteSizeLong() const {
  3733. // @@protoc_insertion_point(message_byte_size_start:proto3.TestMap)
  3734. size_t total_size = 0;
  3735. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  3736. total_size +=
  3737. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  3738. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  3739. }
  3740. // map<bool, int32> bool_map = 1;
  3741. total_size += 1 *
  3742. ::google::protobuf::internal::FromIntSize(this->bool_map_size());
  3743. {
  3744. ::std::unique_ptr<TestMap_BoolMapEntry_DoNotUse> entry;
  3745. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  3746. it = this->bool_map().begin();
  3747. it != this->bool_map().end(); ++it) {
  3748. entry.reset(bool_map_.NewEntryWrapper(it->first, it->second));
  3749. total_size += ::google::protobuf::internal::WireFormatLite::
  3750. MessageSizeNoVirtual(*entry);
  3751. }
  3752. }
  3753. // map<int32, int32> int32_map = 2;
  3754. total_size += 1 *
  3755. ::google::protobuf::internal::FromIntSize(this->int32_map_size());
  3756. {
  3757. ::std::unique_ptr<TestMap_Int32MapEntry_DoNotUse> entry;
  3758. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  3759. it = this->int32_map().begin();
  3760. it != this->int32_map().end(); ++it) {
  3761. entry.reset(int32_map_.NewEntryWrapper(it->first, it->second));
  3762. total_size += ::google::protobuf::internal::WireFormatLite::
  3763. MessageSizeNoVirtual(*entry);
  3764. }
  3765. }
  3766. // map<int64, int32> int64_map = 3;
  3767. total_size += 1 *
  3768. ::google::protobuf::internal::FromIntSize(this->int64_map_size());
  3769. {
  3770. ::std::unique_ptr<TestMap_Int64MapEntry_DoNotUse> entry;
  3771. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  3772. it = this->int64_map().begin();
  3773. it != this->int64_map().end(); ++it) {
  3774. entry.reset(int64_map_.NewEntryWrapper(it->first, it->second));
  3775. total_size += ::google::protobuf::internal::WireFormatLite::
  3776. MessageSizeNoVirtual(*entry);
  3777. }
  3778. }
  3779. // map<uint32, int32> uint32_map = 4;
  3780. total_size += 1 *
  3781. ::google::protobuf::internal::FromIntSize(this->uint32_map_size());
  3782. {
  3783. ::std::unique_ptr<TestMap_Uint32MapEntry_DoNotUse> entry;
  3784. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  3785. it = this->uint32_map().begin();
  3786. it != this->uint32_map().end(); ++it) {
  3787. entry.reset(uint32_map_.NewEntryWrapper(it->first, it->second));
  3788. total_size += ::google::protobuf::internal::WireFormatLite::
  3789. MessageSizeNoVirtual(*entry);
  3790. }
  3791. }
  3792. // map<uint64, int32> uint64_map = 5;
  3793. total_size += 1 *
  3794. ::google::protobuf::internal::FromIntSize(this->uint64_map_size());
  3795. {
  3796. ::std::unique_ptr<TestMap_Uint64MapEntry_DoNotUse> entry;
  3797. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  3798. it = this->uint64_map().begin();
  3799. it != this->uint64_map().end(); ++it) {
  3800. entry.reset(uint64_map_.NewEntryWrapper(it->first, it->second));
  3801. total_size += ::google::protobuf::internal::WireFormatLite::
  3802. MessageSizeNoVirtual(*entry);
  3803. }
  3804. }
  3805. // map<string, int32> string_map = 6;
  3806. total_size += 1 *
  3807. ::google::protobuf::internal::FromIntSize(this->string_map_size());
  3808. {
  3809. ::std::unique_ptr<TestMap_StringMapEntry_DoNotUse> entry;
  3810. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  3811. it = this->string_map().begin();
  3812. it != this->string_map().end(); ++it) {
  3813. entry.reset(string_map_.NewEntryWrapper(it->first, it->second));
  3814. total_size += ::google::protobuf::internal::WireFormatLite::
  3815. MessageSizeNoVirtual(*entry);
  3816. }
  3817. }
  3818. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  3819. SetCachedSize(cached_size);
  3820. return total_size;
  3821. }
  3822. void TestMap::MergeFrom(const ::google::protobuf::Message& from) {
  3823. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestMap)
  3824. GOOGLE_DCHECK_NE(&from, this);
  3825. const TestMap* source =
  3826. ::google::protobuf::internal::DynamicCastToGenerated<const TestMap>(
  3827. &from);
  3828. if (source == NULL) {
  3829. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestMap)
  3830. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  3831. } else {
  3832. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestMap)
  3833. MergeFrom(*source);
  3834. }
  3835. }
  3836. void TestMap::MergeFrom(const TestMap& from) {
  3837. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestMap)
  3838. GOOGLE_DCHECK_NE(&from, this);
  3839. _internal_metadata_.MergeFrom(from._internal_metadata_);
  3840. ::google::protobuf::uint32 cached_has_bits = 0;
  3841. (void) cached_has_bits;
  3842. bool_map_.MergeFrom(from.bool_map_);
  3843. int32_map_.MergeFrom(from.int32_map_);
  3844. int64_map_.MergeFrom(from.int64_map_);
  3845. uint32_map_.MergeFrom(from.uint32_map_);
  3846. uint64_map_.MergeFrom(from.uint64_map_);
  3847. string_map_.MergeFrom(from.string_map_);
  3848. }
  3849. void TestMap::CopyFrom(const ::google::protobuf::Message& from) {
  3850. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestMap)
  3851. if (&from == this) return;
  3852. Clear();
  3853. MergeFrom(from);
  3854. }
  3855. void TestMap::CopyFrom(const TestMap& from) {
  3856. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestMap)
  3857. if (&from == this) return;
  3858. Clear();
  3859. MergeFrom(from);
  3860. }
  3861. bool TestMap::IsInitialized() const {
  3862. return true;
  3863. }
  3864. void TestMap::Swap(TestMap* other) {
  3865. if (other == this) return;
  3866. InternalSwap(other);
  3867. }
  3868. void TestMap::InternalSwap(TestMap* other) {
  3869. using std::swap;
  3870. bool_map_.Swap(&other->bool_map_);
  3871. int32_map_.Swap(&other->int32_map_);
  3872. int64_map_.Swap(&other->int64_map_);
  3873. uint32_map_.Swap(&other->uint32_map_);
  3874. uint64_map_.Swap(&other->uint64_map_);
  3875. string_map_.Swap(&other->string_map_);
  3876. _internal_metadata_.Swap(&other->_internal_metadata_);
  3877. }
  3878. ::google::protobuf::Metadata TestMap::GetMetadata() const {
  3879. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3880. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  3881. }
  3882. // ===================================================================
  3883. TestNestedMap_BoolMapEntry_DoNotUse::TestNestedMap_BoolMapEntry_DoNotUse() {}
  3884. TestNestedMap_BoolMapEntry_DoNotUse::TestNestedMap_BoolMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3885. void TestNestedMap_BoolMapEntry_DoNotUse::MergeFrom(const TestNestedMap_BoolMapEntry_DoNotUse& other) {
  3886. MergeFromInternal(other);
  3887. }
  3888. ::google::protobuf::Metadata TestNestedMap_BoolMapEntry_DoNotUse::GetMetadata() const {
  3889. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3890. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[10];
  3891. }
  3892. void TestNestedMap_BoolMapEntry_DoNotUse::MergeFrom(
  3893. const ::google::protobuf::Message& other) {
  3894. ::google::protobuf::Message::MergeFrom(other);
  3895. }
  3896. // ===================================================================
  3897. TestNestedMap_Int32MapEntry_DoNotUse::TestNestedMap_Int32MapEntry_DoNotUse() {}
  3898. TestNestedMap_Int32MapEntry_DoNotUse::TestNestedMap_Int32MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3899. void TestNestedMap_Int32MapEntry_DoNotUse::MergeFrom(const TestNestedMap_Int32MapEntry_DoNotUse& other) {
  3900. MergeFromInternal(other);
  3901. }
  3902. ::google::protobuf::Metadata TestNestedMap_Int32MapEntry_DoNotUse::GetMetadata() const {
  3903. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3904. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[11];
  3905. }
  3906. void TestNestedMap_Int32MapEntry_DoNotUse::MergeFrom(
  3907. const ::google::protobuf::Message& other) {
  3908. ::google::protobuf::Message::MergeFrom(other);
  3909. }
  3910. // ===================================================================
  3911. TestNestedMap_Int64MapEntry_DoNotUse::TestNestedMap_Int64MapEntry_DoNotUse() {}
  3912. TestNestedMap_Int64MapEntry_DoNotUse::TestNestedMap_Int64MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3913. void TestNestedMap_Int64MapEntry_DoNotUse::MergeFrom(const TestNestedMap_Int64MapEntry_DoNotUse& other) {
  3914. MergeFromInternal(other);
  3915. }
  3916. ::google::protobuf::Metadata TestNestedMap_Int64MapEntry_DoNotUse::GetMetadata() const {
  3917. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3918. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[12];
  3919. }
  3920. void TestNestedMap_Int64MapEntry_DoNotUse::MergeFrom(
  3921. const ::google::protobuf::Message& other) {
  3922. ::google::protobuf::Message::MergeFrom(other);
  3923. }
  3924. // ===================================================================
  3925. TestNestedMap_Uint32MapEntry_DoNotUse::TestNestedMap_Uint32MapEntry_DoNotUse() {}
  3926. TestNestedMap_Uint32MapEntry_DoNotUse::TestNestedMap_Uint32MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3927. void TestNestedMap_Uint32MapEntry_DoNotUse::MergeFrom(const TestNestedMap_Uint32MapEntry_DoNotUse& other) {
  3928. MergeFromInternal(other);
  3929. }
  3930. ::google::protobuf::Metadata TestNestedMap_Uint32MapEntry_DoNotUse::GetMetadata() const {
  3931. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3932. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[13];
  3933. }
  3934. void TestNestedMap_Uint32MapEntry_DoNotUse::MergeFrom(
  3935. const ::google::protobuf::Message& other) {
  3936. ::google::protobuf::Message::MergeFrom(other);
  3937. }
  3938. // ===================================================================
  3939. TestNestedMap_Uint64MapEntry_DoNotUse::TestNestedMap_Uint64MapEntry_DoNotUse() {}
  3940. TestNestedMap_Uint64MapEntry_DoNotUse::TestNestedMap_Uint64MapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3941. void TestNestedMap_Uint64MapEntry_DoNotUse::MergeFrom(const TestNestedMap_Uint64MapEntry_DoNotUse& other) {
  3942. MergeFromInternal(other);
  3943. }
  3944. ::google::protobuf::Metadata TestNestedMap_Uint64MapEntry_DoNotUse::GetMetadata() const {
  3945. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3946. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[14];
  3947. }
  3948. void TestNestedMap_Uint64MapEntry_DoNotUse::MergeFrom(
  3949. const ::google::protobuf::Message& other) {
  3950. ::google::protobuf::Message::MergeFrom(other);
  3951. }
  3952. // ===================================================================
  3953. TestNestedMap_StringMapEntry_DoNotUse::TestNestedMap_StringMapEntry_DoNotUse() {}
  3954. TestNestedMap_StringMapEntry_DoNotUse::TestNestedMap_StringMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3955. void TestNestedMap_StringMapEntry_DoNotUse::MergeFrom(const TestNestedMap_StringMapEntry_DoNotUse& other) {
  3956. MergeFromInternal(other);
  3957. }
  3958. ::google::protobuf::Metadata TestNestedMap_StringMapEntry_DoNotUse::GetMetadata() const {
  3959. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3960. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[15];
  3961. }
  3962. void TestNestedMap_StringMapEntry_DoNotUse::MergeFrom(
  3963. const ::google::protobuf::Message& other) {
  3964. ::google::protobuf::Message::MergeFrom(other);
  3965. }
  3966. // ===================================================================
  3967. TestNestedMap_MapMapEntry_DoNotUse::TestNestedMap_MapMapEntry_DoNotUse() {}
  3968. TestNestedMap_MapMapEntry_DoNotUse::TestNestedMap_MapMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  3969. void TestNestedMap_MapMapEntry_DoNotUse::MergeFrom(const TestNestedMap_MapMapEntry_DoNotUse& other) {
  3970. MergeFromInternal(other);
  3971. }
  3972. ::google::protobuf::Metadata TestNestedMap_MapMapEntry_DoNotUse::GetMetadata() const {
  3973. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  3974. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[16];
  3975. }
  3976. void TestNestedMap_MapMapEntry_DoNotUse::MergeFrom(
  3977. const ::google::protobuf::Message& other) {
  3978. ::google::protobuf::Message::MergeFrom(other);
  3979. }
  3980. // ===================================================================
  3981. void TestNestedMap::InitAsDefaultInstance() {
  3982. }
  3983. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  3984. const int TestNestedMap::kBoolMapFieldNumber;
  3985. const int TestNestedMap::kInt32MapFieldNumber;
  3986. const int TestNestedMap::kInt64MapFieldNumber;
  3987. const int TestNestedMap::kUint32MapFieldNumber;
  3988. const int TestNestedMap::kUint64MapFieldNumber;
  3989. const int TestNestedMap::kStringMapFieldNumber;
  3990. const int TestNestedMap::kMapMapFieldNumber;
  3991. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  3992. TestNestedMap::TestNestedMap()
  3993. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  3994. ::google::protobuf::internal::InitSCC(
  3995. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap.base);
  3996. SharedCtor();
  3997. // @@protoc_insertion_point(constructor:proto3.TestNestedMap)
  3998. }
  3999. TestNestedMap::TestNestedMap(const TestNestedMap& from)
  4000. : ::google::protobuf::Message(),
  4001. _internal_metadata_(NULL) {
  4002. _internal_metadata_.MergeFrom(from._internal_metadata_);
  4003. bool_map_.MergeFrom(from.bool_map_);
  4004. int32_map_.MergeFrom(from.int32_map_);
  4005. int64_map_.MergeFrom(from.int64_map_);
  4006. uint32_map_.MergeFrom(from.uint32_map_);
  4007. uint64_map_.MergeFrom(from.uint64_map_);
  4008. string_map_.MergeFrom(from.string_map_);
  4009. map_map_.MergeFrom(from.map_map_);
  4010. // @@protoc_insertion_point(copy_constructor:proto3.TestNestedMap)
  4011. }
  4012. void TestNestedMap::SharedCtor() {
  4013. }
  4014. TestNestedMap::~TestNestedMap() {
  4015. // @@protoc_insertion_point(destructor:proto3.TestNestedMap)
  4016. SharedDtor();
  4017. }
  4018. void TestNestedMap::SharedDtor() {
  4019. }
  4020. void TestNestedMap::SetCachedSize(int size) const {
  4021. _cached_size_.Set(size);
  4022. }
  4023. const ::google::protobuf::Descriptor* TestNestedMap::descriptor() {
  4024. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  4025. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  4026. }
  4027. const TestNestedMap& TestNestedMap::default_instance() {
  4028. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestNestedMap.base);
  4029. return *internal_default_instance();
  4030. }
  4031. void TestNestedMap::Clear() {
  4032. // @@protoc_insertion_point(message_clear_start:proto3.TestNestedMap)
  4033. ::google::protobuf::uint32 cached_has_bits = 0;
  4034. // Prevent compiler warnings about cached_has_bits being unused
  4035. (void) cached_has_bits;
  4036. bool_map_.Clear();
  4037. int32_map_.Clear();
  4038. int64_map_.Clear();
  4039. uint32_map_.Clear();
  4040. uint64_map_.Clear();
  4041. string_map_.Clear();
  4042. map_map_.Clear();
  4043. _internal_metadata_.Clear();
  4044. }
  4045. bool TestNestedMap::MergePartialFromCodedStream(
  4046. ::google::protobuf::io::CodedInputStream* input) {
  4047. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  4048. ::google::protobuf::uint32 tag;
  4049. // @@protoc_insertion_point(parse_start:proto3.TestNestedMap)
  4050. for (;;) {
  4051. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  4052. tag = p.first;
  4053. if (!p.second) goto handle_unusual;
  4054. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  4055. // map<bool, int32> bool_map = 1;
  4056. case 1: {
  4057. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4058. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  4059. TestNestedMap_BoolMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4060. TestNestedMap_BoolMapEntry_DoNotUse,
  4061. bool, ::google::protobuf::int32,
  4062. ::google::protobuf::internal::WireFormatLite::TYPE_BOOL,
  4063. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4064. 0 >,
  4065. ::google::protobuf::Map< bool, ::google::protobuf::int32 > > parser(&bool_map_);
  4066. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4067. input, &parser));
  4068. } else {
  4069. goto handle_unusual;
  4070. }
  4071. break;
  4072. }
  4073. // map<int32, int32> int32_map = 2;
  4074. case 2: {
  4075. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4076. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  4077. TestNestedMap_Int32MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4078. TestNestedMap_Int32MapEntry_DoNotUse,
  4079. ::google::protobuf::int32, ::google::protobuf::int32,
  4080. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4081. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4082. 0 >,
  4083. ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 > > parser(&int32_map_);
  4084. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4085. input, &parser));
  4086. } else {
  4087. goto handle_unusual;
  4088. }
  4089. break;
  4090. }
  4091. // map<int64, int32> int64_map = 3;
  4092. case 3: {
  4093. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4094. static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
  4095. TestNestedMap_Int64MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4096. TestNestedMap_Int64MapEntry_DoNotUse,
  4097. ::google::protobuf::int64, ::google::protobuf::int32,
  4098. ::google::protobuf::internal::WireFormatLite::TYPE_INT64,
  4099. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4100. 0 >,
  4101. ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 > > parser(&int64_map_);
  4102. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4103. input, &parser));
  4104. } else {
  4105. goto handle_unusual;
  4106. }
  4107. break;
  4108. }
  4109. // map<uint32, int32> uint32_map = 4;
  4110. case 4: {
  4111. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4112. static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
  4113. TestNestedMap_Uint32MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4114. TestNestedMap_Uint32MapEntry_DoNotUse,
  4115. ::google::protobuf::uint32, ::google::protobuf::int32,
  4116. ::google::protobuf::internal::WireFormatLite::TYPE_UINT32,
  4117. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4118. 0 >,
  4119. ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 > > parser(&uint32_map_);
  4120. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4121. input, &parser));
  4122. } else {
  4123. goto handle_unusual;
  4124. }
  4125. break;
  4126. }
  4127. // map<uint64, int32> uint64_map = 5;
  4128. case 5: {
  4129. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4130. static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
  4131. TestNestedMap_Uint64MapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4132. TestNestedMap_Uint64MapEntry_DoNotUse,
  4133. ::google::protobuf::uint64, ::google::protobuf::int32,
  4134. ::google::protobuf::internal::WireFormatLite::TYPE_UINT64,
  4135. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4136. 0 >,
  4137. ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 > > parser(&uint64_map_);
  4138. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4139. input, &parser));
  4140. } else {
  4141. goto handle_unusual;
  4142. }
  4143. break;
  4144. }
  4145. // map<string, int32> string_map = 6;
  4146. case 6: {
  4147. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4148. static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
  4149. TestNestedMap_StringMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4150. TestNestedMap_StringMapEntry_DoNotUse,
  4151. ::std::string, ::google::protobuf::int32,
  4152. ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
  4153. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  4154. 0 >,
  4155. ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 > > parser(&string_map_);
  4156. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4157. input, &parser));
  4158. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4159. parser.key().data(), static_cast<int>(parser.key().length()),
  4160. ::google::protobuf::internal::WireFormatLite::PARSE,
  4161. "proto3.TestNestedMap.StringMapEntry.key"));
  4162. } else {
  4163. goto handle_unusual;
  4164. }
  4165. break;
  4166. }
  4167. // map<string, .proto3.TestNestedMap> map_map = 7;
  4168. case 7: {
  4169. if (static_cast< ::google::protobuf::uint8>(tag) ==
  4170. static_cast< ::google::protobuf::uint8>(58u /* 58 & 0xFF */)) {
  4171. TestNestedMap_MapMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  4172. TestNestedMap_MapMapEntry_DoNotUse,
  4173. ::std::string, ::proto3::TestNestedMap,
  4174. ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
  4175. ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE,
  4176. 0 >,
  4177. ::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap > > parser(&map_map_);
  4178. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  4179. input, &parser));
  4180. DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4181. parser.key().data(), static_cast<int>(parser.key().length()),
  4182. ::google::protobuf::internal::WireFormatLite::PARSE,
  4183. "proto3.TestNestedMap.MapMapEntry.key"));
  4184. } else {
  4185. goto handle_unusual;
  4186. }
  4187. break;
  4188. }
  4189. default: {
  4190. handle_unusual:
  4191. if (tag == 0) {
  4192. goto success;
  4193. }
  4194. DO_(::google::protobuf::internal::WireFormat::SkipField(
  4195. input, tag, _internal_metadata_.mutable_unknown_fields()));
  4196. break;
  4197. }
  4198. }
  4199. }
  4200. success:
  4201. // @@protoc_insertion_point(parse_success:proto3.TestNestedMap)
  4202. return true;
  4203. failure:
  4204. // @@protoc_insertion_point(parse_failure:proto3.TestNestedMap)
  4205. return false;
  4206. #undef DO_
  4207. }
  4208. void TestNestedMap::SerializeWithCachedSizes(
  4209. ::google::protobuf::io::CodedOutputStream* output) const {
  4210. // @@protoc_insertion_point(serialize_start:proto3.TestNestedMap)
  4211. ::google::protobuf::uint32 cached_has_bits = 0;
  4212. (void) cached_has_bits;
  4213. // map<bool, int32> bool_map = 1;
  4214. if (!this->bool_map().empty()) {
  4215. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  4216. ConstPtr;
  4217. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  4218. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4219. if (output->IsSerializationDeterministic() &&
  4220. this->bool_map().size() > 1) {
  4221. ::std::unique_ptr<SortItem[]> items(
  4222. new SortItem[this->bool_map().size()]);
  4223. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  4224. size_type n = 0;
  4225. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  4226. it = this->bool_map().begin();
  4227. it != this->bool_map().end(); ++it, ++n) {
  4228. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4229. }
  4230. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4231. ::std::unique_ptr<TestNestedMap_BoolMapEntry_DoNotUse> entry;
  4232. for (size_type i = 0; i < n; i++) {
  4233. entry.reset(bool_map_.NewEntryWrapper(
  4234. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4235. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4236. 1, *entry, output);
  4237. }
  4238. } else {
  4239. ::std::unique_ptr<TestNestedMap_BoolMapEntry_DoNotUse> entry;
  4240. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  4241. it = this->bool_map().begin();
  4242. it != this->bool_map().end(); ++it) {
  4243. entry.reset(bool_map_.NewEntryWrapper(
  4244. it->first, it->second));
  4245. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4246. 1, *entry, output);
  4247. }
  4248. }
  4249. }
  4250. // map<int32, int32> int32_map = 2;
  4251. if (!this->int32_map().empty()) {
  4252. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_pointer
  4253. ConstPtr;
  4254. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
  4255. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4256. if (output->IsSerializationDeterministic() &&
  4257. this->int32_map().size() > 1) {
  4258. ::std::unique_ptr<SortItem[]> items(
  4259. new SortItem[this->int32_map().size()]);
  4260. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::size_type size_type;
  4261. size_type n = 0;
  4262. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  4263. it = this->int32_map().begin();
  4264. it != this->int32_map().end(); ++it, ++n) {
  4265. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4266. }
  4267. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4268. ::std::unique_ptr<TestNestedMap_Int32MapEntry_DoNotUse> entry;
  4269. for (size_type i = 0; i < n; i++) {
  4270. entry.reset(int32_map_.NewEntryWrapper(
  4271. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4272. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4273. 2, *entry, output);
  4274. }
  4275. } else {
  4276. ::std::unique_ptr<TestNestedMap_Int32MapEntry_DoNotUse> entry;
  4277. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  4278. it = this->int32_map().begin();
  4279. it != this->int32_map().end(); ++it) {
  4280. entry.reset(int32_map_.NewEntryWrapper(
  4281. it->first, it->second));
  4282. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4283. 2, *entry, output);
  4284. }
  4285. }
  4286. }
  4287. // map<int64, int32> int64_map = 3;
  4288. if (!this->int64_map().empty()) {
  4289. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_pointer
  4290. ConstPtr;
  4291. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int64, ConstPtr > SortItem;
  4292. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4293. if (output->IsSerializationDeterministic() &&
  4294. this->int64_map().size() > 1) {
  4295. ::std::unique_ptr<SortItem[]> items(
  4296. new SortItem[this->int64_map().size()]);
  4297. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::size_type size_type;
  4298. size_type n = 0;
  4299. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  4300. it = this->int64_map().begin();
  4301. it != this->int64_map().end(); ++it, ++n) {
  4302. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4303. }
  4304. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4305. ::std::unique_ptr<TestNestedMap_Int64MapEntry_DoNotUse> entry;
  4306. for (size_type i = 0; i < n; i++) {
  4307. entry.reset(int64_map_.NewEntryWrapper(
  4308. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4309. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4310. 3, *entry, output);
  4311. }
  4312. } else {
  4313. ::std::unique_ptr<TestNestedMap_Int64MapEntry_DoNotUse> entry;
  4314. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  4315. it = this->int64_map().begin();
  4316. it != this->int64_map().end(); ++it) {
  4317. entry.reset(int64_map_.NewEntryWrapper(
  4318. it->first, it->second));
  4319. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4320. 3, *entry, output);
  4321. }
  4322. }
  4323. }
  4324. // map<uint32, int32> uint32_map = 4;
  4325. if (!this->uint32_map().empty()) {
  4326. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_pointer
  4327. ConstPtr;
  4328. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint32, ConstPtr > SortItem;
  4329. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4330. if (output->IsSerializationDeterministic() &&
  4331. this->uint32_map().size() > 1) {
  4332. ::std::unique_ptr<SortItem[]> items(
  4333. new SortItem[this->uint32_map().size()]);
  4334. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::size_type size_type;
  4335. size_type n = 0;
  4336. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  4337. it = this->uint32_map().begin();
  4338. it != this->uint32_map().end(); ++it, ++n) {
  4339. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4340. }
  4341. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4342. ::std::unique_ptr<TestNestedMap_Uint32MapEntry_DoNotUse> entry;
  4343. for (size_type i = 0; i < n; i++) {
  4344. entry.reset(uint32_map_.NewEntryWrapper(
  4345. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4346. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4347. 4, *entry, output);
  4348. }
  4349. } else {
  4350. ::std::unique_ptr<TestNestedMap_Uint32MapEntry_DoNotUse> entry;
  4351. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  4352. it = this->uint32_map().begin();
  4353. it != this->uint32_map().end(); ++it) {
  4354. entry.reset(uint32_map_.NewEntryWrapper(
  4355. it->first, it->second));
  4356. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4357. 4, *entry, output);
  4358. }
  4359. }
  4360. }
  4361. // map<uint64, int32> uint64_map = 5;
  4362. if (!this->uint64_map().empty()) {
  4363. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_pointer
  4364. ConstPtr;
  4365. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint64, ConstPtr > SortItem;
  4366. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4367. if (output->IsSerializationDeterministic() &&
  4368. this->uint64_map().size() > 1) {
  4369. ::std::unique_ptr<SortItem[]> items(
  4370. new SortItem[this->uint64_map().size()]);
  4371. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::size_type size_type;
  4372. size_type n = 0;
  4373. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  4374. it = this->uint64_map().begin();
  4375. it != this->uint64_map().end(); ++it, ++n) {
  4376. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4377. }
  4378. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4379. ::std::unique_ptr<TestNestedMap_Uint64MapEntry_DoNotUse> entry;
  4380. for (size_type i = 0; i < n; i++) {
  4381. entry.reset(uint64_map_.NewEntryWrapper(
  4382. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4383. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4384. 5, *entry, output);
  4385. }
  4386. } else {
  4387. ::std::unique_ptr<TestNestedMap_Uint64MapEntry_DoNotUse> entry;
  4388. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  4389. it = this->uint64_map().begin();
  4390. it != this->uint64_map().end(); ++it) {
  4391. entry.reset(uint64_map_.NewEntryWrapper(
  4392. it->first, it->second));
  4393. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4394. 5, *entry, output);
  4395. }
  4396. }
  4397. }
  4398. // map<string, int32> string_map = 6;
  4399. if (!this->string_map().empty()) {
  4400. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_pointer
  4401. ConstPtr;
  4402. typedef ConstPtr SortItem;
  4403. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  4404. struct Utf8Check {
  4405. static void Check(ConstPtr p) {
  4406. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4407. p->first.data(), static_cast<int>(p->first.length()),
  4408. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  4409. "proto3.TestNestedMap.StringMapEntry.key");
  4410. }
  4411. };
  4412. if (output->IsSerializationDeterministic() &&
  4413. this->string_map().size() > 1) {
  4414. ::std::unique_ptr<SortItem[]> items(
  4415. new SortItem[this->string_map().size()]);
  4416. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::size_type size_type;
  4417. size_type n = 0;
  4418. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  4419. it = this->string_map().begin();
  4420. it != this->string_map().end(); ++it, ++n) {
  4421. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4422. }
  4423. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4424. ::std::unique_ptr<TestNestedMap_StringMapEntry_DoNotUse> entry;
  4425. for (size_type i = 0; i < n; i++) {
  4426. entry.reset(string_map_.NewEntryWrapper(
  4427. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  4428. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4429. 6, *entry, output);
  4430. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  4431. }
  4432. } else {
  4433. ::std::unique_ptr<TestNestedMap_StringMapEntry_DoNotUse> entry;
  4434. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  4435. it = this->string_map().begin();
  4436. it != this->string_map().end(); ++it) {
  4437. entry.reset(string_map_.NewEntryWrapper(
  4438. it->first, it->second));
  4439. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4440. 6, *entry, output);
  4441. Utf8Check::Check(&*it);
  4442. }
  4443. }
  4444. }
  4445. // map<string, .proto3.TestNestedMap> map_map = 7;
  4446. if (!this->map_map().empty()) {
  4447. typedef ::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_pointer
  4448. ConstPtr;
  4449. typedef ConstPtr SortItem;
  4450. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  4451. struct Utf8Check {
  4452. static void Check(ConstPtr p) {
  4453. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4454. p->first.data(), static_cast<int>(p->first.length()),
  4455. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  4456. "proto3.TestNestedMap.MapMapEntry.key");
  4457. }
  4458. };
  4459. if (output->IsSerializationDeterministic() &&
  4460. this->map_map().size() > 1) {
  4461. ::std::unique_ptr<SortItem[]> items(
  4462. new SortItem[this->map_map().size()]);
  4463. typedef ::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::size_type size_type;
  4464. size_type n = 0;
  4465. for (::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_iterator
  4466. it = this->map_map().begin();
  4467. it != this->map_map().end(); ++it, ++n) {
  4468. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4469. }
  4470. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4471. ::std::unique_ptr<TestNestedMap_MapMapEntry_DoNotUse> entry;
  4472. for (size_type i = 0; i < n; i++) {
  4473. entry.reset(map_map_.NewEntryWrapper(
  4474. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  4475. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4476. 7, *entry, output);
  4477. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  4478. }
  4479. } else {
  4480. ::std::unique_ptr<TestNestedMap_MapMapEntry_DoNotUse> entry;
  4481. for (::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_iterator
  4482. it = this->map_map().begin();
  4483. it != this->map_map().end(); ++it) {
  4484. entry.reset(map_map_.NewEntryWrapper(
  4485. it->first, it->second));
  4486. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  4487. 7, *entry, output);
  4488. Utf8Check::Check(&*it);
  4489. }
  4490. }
  4491. }
  4492. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  4493. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  4494. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  4495. }
  4496. // @@protoc_insertion_point(serialize_end:proto3.TestNestedMap)
  4497. }
  4498. ::google::protobuf::uint8* TestNestedMap::InternalSerializeWithCachedSizesToArray(
  4499. bool deterministic, ::google::protobuf::uint8* target) const {
  4500. (void)deterministic; // Unused
  4501. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestNestedMap)
  4502. ::google::protobuf::uint32 cached_has_bits = 0;
  4503. (void) cached_has_bits;
  4504. // map<bool, int32> bool_map = 1;
  4505. if (!this->bool_map().empty()) {
  4506. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  4507. ConstPtr;
  4508. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  4509. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4510. if (deterministic &&
  4511. this->bool_map().size() > 1) {
  4512. ::std::unique_ptr<SortItem[]> items(
  4513. new SortItem[this->bool_map().size()]);
  4514. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  4515. size_type n = 0;
  4516. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  4517. it = this->bool_map().begin();
  4518. it != this->bool_map().end(); ++it, ++n) {
  4519. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4520. }
  4521. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4522. ::std::unique_ptr<TestNestedMap_BoolMapEntry_DoNotUse> entry;
  4523. for (size_type i = 0; i < n; i++) {
  4524. entry.reset(bool_map_.NewEntryWrapper(
  4525. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4526. target = ::google::protobuf::internal::WireFormatLite::
  4527. InternalWriteMessageNoVirtualToArray(
  4528. 1, *entry, deterministic, target);
  4529. ;
  4530. }
  4531. } else {
  4532. ::std::unique_ptr<TestNestedMap_BoolMapEntry_DoNotUse> entry;
  4533. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  4534. it = this->bool_map().begin();
  4535. it != this->bool_map().end(); ++it) {
  4536. entry.reset(bool_map_.NewEntryWrapper(
  4537. it->first, it->second));
  4538. target = ::google::protobuf::internal::WireFormatLite::
  4539. InternalWriteMessageNoVirtualToArray(
  4540. 1, *entry, deterministic, target);
  4541. ;
  4542. }
  4543. }
  4544. }
  4545. // map<int32, int32> int32_map = 2;
  4546. if (!this->int32_map().empty()) {
  4547. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_pointer
  4548. ConstPtr;
  4549. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
  4550. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4551. if (deterministic &&
  4552. this->int32_map().size() > 1) {
  4553. ::std::unique_ptr<SortItem[]> items(
  4554. new SortItem[this->int32_map().size()]);
  4555. typedef ::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::size_type size_type;
  4556. size_type n = 0;
  4557. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  4558. it = this->int32_map().begin();
  4559. it != this->int32_map().end(); ++it, ++n) {
  4560. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4561. }
  4562. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4563. ::std::unique_ptr<TestNestedMap_Int32MapEntry_DoNotUse> entry;
  4564. for (size_type i = 0; i < n; i++) {
  4565. entry.reset(int32_map_.NewEntryWrapper(
  4566. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4567. target = ::google::protobuf::internal::WireFormatLite::
  4568. InternalWriteMessageNoVirtualToArray(
  4569. 2, *entry, deterministic, target);
  4570. ;
  4571. }
  4572. } else {
  4573. ::std::unique_ptr<TestNestedMap_Int32MapEntry_DoNotUse> entry;
  4574. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  4575. it = this->int32_map().begin();
  4576. it != this->int32_map().end(); ++it) {
  4577. entry.reset(int32_map_.NewEntryWrapper(
  4578. it->first, it->second));
  4579. target = ::google::protobuf::internal::WireFormatLite::
  4580. InternalWriteMessageNoVirtualToArray(
  4581. 2, *entry, deterministic, target);
  4582. ;
  4583. }
  4584. }
  4585. }
  4586. // map<int64, int32> int64_map = 3;
  4587. if (!this->int64_map().empty()) {
  4588. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_pointer
  4589. ConstPtr;
  4590. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int64, ConstPtr > SortItem;
  4591. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4592. if (deterministic &&
  4593. this->int64_map().size() > 1) {
  4594. ::std::unique_ptr<SortItem[]> items(
  4595. new SortItem[this->int64_map().size()]);
  4596. typedef ::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::size_type size_type;
  4597. size_type n = 0;
  4598. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  4599. it = this->int64_map().begin();
  4600. it != this->int64_map().end(); ++it, ++n) {
  4601. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4602. }
  4603. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4604. ::std::unique_ptr<TestNestedMap_Int64MapEntry_DoNotUse> entry;
  4605. for (size_type i = 0; i < n; i++) {
  4606. entry.reset(int64_map_.NewEntryWrapper(
  4607. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4608. target = ::google::protobuf::internal::WireFormatLite::
  4609. InternalWriteMessageNoVirtualToArray(
  4610. 3, *entry, deterministic, target);
  4611. ;
  4612. }
  4613. } else {
  4614. ::std::unique_ptr<TestNestedMap_Int64MapEntry_DoNotUse> entry;
  4615. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  4616. it = this->int64_map().begin();
  4617. it != this->int64_map().end(); ++it) {
  4618. entry.reset(int64_map_.NewEntryWrapper(
  4619. it->first, it->second));
  4620. target = ::google::protobuf::internal::WireFormatLite::
  4621. InternalWriteMessageNoVirtualToArray(
  4622. 3, *entry, deterministic, target);
  4623. ;
  4624. }
  4625. }
  4626. }
  4627. // map<uint32, int32> uint32_map = 4;
  4628. if (!this->uint32_map().empty()) {
  4629. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_pointer
  4630. ConstPtr;
  4631. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint32, ConstPtr > SortItem;
  4632. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4633. if (deterministic &&
  4634. this->uint32_map().size() > 1) {
  4635. ::std::unique_ptr<SortItem[]> items(
  4636. new SortItem[this->uint32_map().size()]);
  4637. typedef ::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::size_type size_type;
  4638. size_type n = 0;
  4639. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  4640. it = this->uint32_map().begin();
  4641. it != this->uint32_map().end(); ++it, ++n) {
  4642. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4643. }
  4644. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4645. ::std::unique_ptr<TestNestedMap_Uint32MapEntry_DoNotUse> entry;
  4646. for (size_type i = 0; i < n; i++) {
  4647. entry.reset(uint32_map_.NewEntryWrapper(
  4648. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4649. target = ::google::protobuf::internal::WireFormatLite::
  4650. InternalWriteMessageNoVirtualToArray(
  4651. 4, *entry, deterministic, target);
  4652. ;
  4653. }
  4654. } else {
  4655. ::std::unique_ptr<TestNestedMap_Uint32MapEntry_DoNotUse> entry;
  4656. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  4657. it = this->uint32_map().begin();
  4658. it != this->uint32_map().end(); ++it) {
  4659. entry.reset(uint32_map_.NewEntryWrapper(
  4660. it->first, it->second));
  4661. target = ::google::protobuf::internal::WireFormatLite::
  4662. InternalWriteMessageNoVirtualToArray(
  4663. 4, *entry, deterministic, target);
  4664. ;
  4665. }
  4666. }
  4667. }
  4668. // map<uint64, int32> uint64_map = 5;
  4669. if (!this->uint64_map().empty()) {
  4670. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_pointer
  4671. ConstPtr;
  4672. typedef ::google::protobuf::internal::SortItem< ::google::protobuf::uint64, ConstPtr > SortItem;
  4673. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  4674. if (deterministic &&
  4675. this->uint64_map().size() > 1) {
  4676. ::std::unique_ptr<SortItem[]> items(
  4677. new SortItem[this->uint64_map().size()]);
  4678. typedef ::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::size_type size_type;
  4679. size_type n = 0;
  4680. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  4681. it = this->uint64_map().begin();
  4682. it != this->uint64_map().end(); ++it, ++n) {
  4683. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4684. }
  4685. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4686. ::std::unique_ptr<TestNestedMap_Uint64MapEntry_DoNotUse> entry;
  4687. for (size_type i = 0; i < n; i++) {
  4688. entry.reset(uint64_map_.NewEntryWrapper(
  4689. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  4690. target = ::google::protobuf::internal::WireFormatLite::
  4691. InternalWriteMessageNoVirtualToArray(
  4692. 5, *entry, deterministic, target);
  4693. ;
  4694. }
  4695. } else {
  4696. ::std::unique_ptr<TestNestedMap_Uint64MapEntry_DoNotUse> entry;
  4697. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  4698. it = this->uint64_map().begin();
  4699. it != this->uint64_map().end(); ++it) {
  4700. entry.reset(uint64_map_.NewEntryWrapper(
  4701. it->first, it->second));
  4702. target = ::google::protobuf::internal::WireFormatLite::
  4703. InternalWriteMessageNoVirtualToArray(
  4704. 5, *entry, deterministic, target);
  4705. ;
  4706. }
  4707. }
  4708. }
  4709. // map<string, int32> string_map = 6;
  4710. if (!this->string_map().empty()) {
  4711. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_pointer
  4712. ConstPtr;
  4713. typedef ConstPtr SortItem;
  4714. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  4715. struct Utf8Check {
  4716. static void Check(ConstPtr p) {
  4717. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4718. p->first.data(), static_cast<int>(p->first.length()),
  4719. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  4720. "proto3.TestNestedMap.StringMapEntry.key");
  4721. }
  4722. };
  4723. if (deterministic &&
  4724. this->string_map().size() > 1) {
  4725. ::std::unique_ptr<SortItem[]> items(
  4726. new SortItem[this->string_map().size()]);
  4727. typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::size_type size_type;
  4728. size_type n = 0;
  4729. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  4730. it = this->string_map().begin();
  4731. it != this->string_map().end(); ++it, ++n) {
  4732. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4733. }
  4734. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4735. ::std::unique_ptr<TestNestedMap_StringMapEntry_DoNotUse> entry;
  4736. for (size_type i = 0; i < n; i++) {
  4737. entry.reset(string_map_.NewEntryWrapper(
  4738. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  4739. target = ::google::protobuf::internal::WireFormatLite::
  4740. InternalWriteMessageNoVirtualToArray(
  4741. 6, *entry, deterministic, target);
  4742. ;
  4743. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  4744. }
  4745. } else {
  4746. ::std::unique_ptr<TestNestedMap_StringMapEntry_DoNotUse> entry;
  4747. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  4748. it = this->string_map().begin();
  4749. it != this->string_map().end(); ++it) {
  4750. entry.reset(string_map_.NewEntryWrapper(
  4751. it->first, it->second));
  4752. target = ::google::protobuf::internal::WireFormatLite::
  4753. InternalWriteMessageNoVirtualToArray(
  4754. 6, *entry, deterministic, target);
  4755. ;
  4756. Utf8Check::Check(&*it);
  4757. }
  4758. }
  4759. }
  4760. // map<string, .proto3.TestNestedMap> map_map = 7;
  4761. if (!this->map_map().empty()) {
  4762. typedef ::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_pointer
  4763. ConstPtr;
  4764. typedef ConstPtr SortItem;
  4765. typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  4766. struct Utf8Check {
  4767. static void Check(ConstPtr p) {
  4768. ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  4769. p->first.data(), static_cast<int>(p->first.length()),
  4770. ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  4771. "proto3.TestNestedMap.MapMapEntry.key");
  4772. }
  4773. };
  4774. if (deterministic &&
  4775. this->map_map().size() > 1) {
  4776. ::std::unique_ptr<SortItem[]> items(
  4777. new SortItem[this->map_map().size()]);
  4778. typedef ::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::size_type size_type;
  4779. size_type n = 0;
  4780. for (::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_iterator
  4781. it = this->map_map().begin();
  4782. it != this->map_map().end(); ++it, ++n) {
  4783. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  4784. }
  4785. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  4786. ::std::unique_ptr<TestNestedMap_MapMapEntry_DoNotUse> entry;
  4787. for (size_type i = 0; i < n; i++) {
  4788. entry.reset(map_map_.NewEntryWrapper(
  4789. items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  4790. target = ::google::protobuf::internal::WireFormatLite::
  4791. InternalWriteMessageNoVirtualToArray(
  4792. 7, *entry, deterministic, target);
  4793. ;
  4794. Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  4795. }
  4796. } else {
  4797. ::std::unique_ptr<TestNestedMap_MapMapEntry_DoNotUse> entry;
  4798. for (::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_iterator
  4799. it = this->map_map().begin();
  4800. it != this->map_map().end(); ++it) {
  4801. entry.reset(map_map_.NewEntryWrapper(
  4802. it->first, it->second));
  4803. target = ::google::protobuf::internal::WireFormatLite::
  4804. InternalWriteMessageNoVirtualToArray(
  4805. 7, *entry, deterministic, target);
  4806. ;
  4807. Utf8Check::Check(&*it);
  4808. }
  4809. }
  4810. }
  4811. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  4812. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  4813. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  4814. }
  4815. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestNestedMap)
  4816. return target;
  4817. }
  4818. size_t TestNestedMap::ByteSizeLong() const {
  4819. // @@protoc_insertion_point(message_byte_size_start:proto3.TestNestedMap)
  4820. size_t total_size = 0;
  4821. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  4822. total_size +=
  4823. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  4824. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  4825. }
  4826. // map<bool, int32> bool_map = 1;
  4827. total_size += 1 *
  4828. ::google::protobuf::internal::FromIntSize(this->bool_map_size());
  4829. {
  4830. ::std::unique_ptr<TestNestedMap_BoolMapEntry_DoNotUse> entry;
  4831. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  4832. it = this->bool_map().begin();
  4833. it != this->bool_map().end(); ++it) {
  4834. entry.reset(bool_map_.NewEntryWrapper(it->first, it->second));
  4835. total_size += ::google::protobuf::internal::WireFormatLite::
  4836. MessageSizeNoVirtual(*entry);
  4837. }
  4838. }
  4839. // map<int32, int32> int32_map = 2;
  4840. total_size += 1 *
  4841. ::google::protobuf::internal::FromIntSize(this->int32_map_size());
  4842. {
  4843. ::std::unique_ptr<TestNestedMap_Int32MapEntry_DoNotUse> entry;
  4844. for (::google::protobuf::Map< ::google::protobuf::int32, ::google::protobuf::int32 >::const_iterator
  4845. it = this->int32_map().begin();
  4846. it != this->int32_map().end(); ++it) {
  4847. entry.reset(int32_map_.NewEntryWrapper(it->first, it->second));
  4848. total_size += ::google::protobuf::internal::WireFormatLite::
  4849. MessageSizeNoVirtual(*entry);
  4850. }
  4851. }
  4852. // map<int64, int32> int64_map = 3;
  4853. total_size += 1 *
  4854. ::google::protobuf::internal::FromIntSize(this->int64_map_size());
  4855. {
  4856. ::std::unique_ptr<TestNestedMap_Int64MapEntry_DoNotUse> entry;
  4857. for (::google::protobuf::Map< ::google::protobuf::int64, ::google::protobuf::int32 >::const_iterator
  4858. it = this->int64_map().begin();
  4859. it != this->int64_map().end(); ++it) {
  4860. entry.reset(int64_map_.NewEntryWrapper(it->first, it->second));
  4861. total_size += ::google::protobuf::internal::WireFormatLite::
  4862. MessageSizeNoVirtual(*entry);
  4863. }
  4864. }
  4865. // map<uint32, int32> uint32_map = 4;
  4866. total_size += 1 *
  4867. ::google::protobuf::internal::FromIntSize(this->uint32_map_size());
  4868. {
  4869. ::std::unique_ptr<TestNestedMap_Uint32MapEntry_DoNotUse> entry;
  4870. for (::google::protobuf::Map< ::google::protobuf::uint32, ::google::protobuf::int32 >::const_iterator
  4871. it = this->uint32_map().begin();
  4872. it != this->uint32_map().end(); ++it) {
  4873. entry.reset(uint32_map_.NewEntryWrapper(it->first, it->second));
  4874. total_size += ::google::protobuf::internal::WireFormatLite::
  4875. MessageSizeNoVirtual(*entry);
  4876. }
  4877. }
  4878. // map<uint64, int32> uint64_map = 5;
  4879. total_size += 1 *
  4880. ::google::protobuf::internal::FromIntSize(this->uint64_map_size());
  4881. {
  4882. ::std::unique_ptr<TestNestedMap_Uint64MapEntry_DoNotUse> entry;
  4883. for (::google::protobuf::Map< ::google::protobuf::uint64, ::google::protobuf::int32 >::const_iterator
  4884. it = this->uint64_map().begin();
  4885. it != this->uint64_map().end(); ++it) {
  4886. entry.reset(uint64_map_.NewEntryWrapper(it->first, it->second));
  4887. total_size += ::google::protobuf::internal::WireFormatLite::
  4888. MessageSizeNoVirtual(*entry);
  4889. }
  4890. }
  4891. // map<string, int32> string_map = 6;
  4892. total_size += 1 *
  4893. ::google::protobuf::internal::FromIntSize(this->string_map_size());
  4894. {
  4895. ::std::unique_ptr<TestNestedMap_StringMapEntry_DoNotUse> entry;
  4896. for (::google::protobuf::Map< ::std::string, ::google::protobuf::int32 >::const_iterator
  4897. it = this->string_map().begin();
  4898. it != this->string_map().end(); ++it) {
  4899. entry.reset(string_map_.NewEntryWrapper(it->first, it->second));
  4900. total_size += ::google::protobuf::internal::WireFormatLite::
  4901. MessageSizeNoVirtual(*entry);
  4902. }
  4903. }
  4904. // map<string, .proto3.TestNestedMap> map_map = 7;
  4905. total_size += 1 *
  4906. ::google::protobuf::internal::FromIntSize(this->map_map_size());
  4907. {
  4908. ::std::unique_ptr<TestNestedMap_MapMapEntry_DoNotUse> entry;
  4909. for (::google::protobuf::Map< ::std::string, ::proto3::TestNestedMap >::const_iterator
  4910. it = this->map_map().begin();
  4911. it != this->map_map().end(); ++it) {
  4912. entry.reset(map_map_.NewEntryWrapper(it->first, it->second));
  4913. total_size += ::google::protobuf::internal::WireFormatLite::
  4914. MessageSizeNoVirtual(*entry);
  4915. }
  4916. }
  4917. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  4918. SetCachedSize(cached_size);
  4919. return total_size;
  4920. }
  4921. void TestNestedMap::MergeFrom(const ::google::protobuf::Message& from) {
  4922. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestNestedMap)
  4923. GOOGLE_DCHECK_NE(&from, this);
  4924. const TestNestedMap* source =
  4925. ::google::protobuf::internal::DynamicCastToGenerated<const TestNestedMap>(
  4926. &from);
  4927. if (source == NULL) {
  4928. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestNestedMap)
  4929. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  4930. } else {
  4931. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestNestedMap)
  4932. MergeFrom(*source);
  4933. }
  4934. }
  4935. void TestNestedMap::MergeFrom(const TestNestedMap& from) {
  4936. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestNestedMap)
  4937. GOOGLE_DCHECK_NE(&from, this);
  4938. _internal_metadata_.MergeFrom(from._internal_metadata_);
  4939. ::google::protobuf::uint32 cached_has_bits = 0;
  4940. (void) cached_has_bits;
  4941. bool_map_.MergeFrom(from.bool_map_);
  4942. int32_map_.MergeFrom(from.int32_map_);
  4943. int64_map_.MergeFrom(from.int64_map_);
  4944. uint32_map_.MergeFrom(from.uint32_map_);
  4945. uint64_map_.MergeFrom(from.uint64_map_);
  4946. string_map_.MergeFrom(from.string_map_);
  4947. map_map_.MergeFrom(from.map_map_);
  4948. }
  4949. void TestNestedMap::CopyFrom(const ::google::protobuf::Message& from) {
  4950. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestNestedMap)
  4951. if (&from == this) return;
  4952. Clear();
  4953. MergeFrom(from);
  4954. }
  4955. void TestNestedMap::CopyFrom(const TestNestedMap& from) {
  4956. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestNestedMap)
  4957. if (&from == this) return;
  4958. Clear();
  4959. MergeFrom(from);
  4960. }
  4961. bool TestNestedMap::IsInitialized() const {
  4962. return true;
  4963. }
  4964. void TestNestedMap::Swap(TestNestedMap* other) {
  4965. if (other == this) return;
  4966. InternalSwap(other);
  4967. }
  4968. void TestNestedMap::InternalSwap(TestNestedMap* other) {
  4969. using std::swap;
  4970. bool_map_.Swap(&other->bool_map_);
  4971. int32_map_.Swap(&other->int32_map_);
  4972. int64_map_.Swap(&other->int64_map_);
  4973. uint32_map_.Swap(&other->uint32_map_);
  4974. uint64_map_.Swap(&other->uint64_map_);
  4975. string_map_.Swap(&other->string_map_);
  4976. map_map_.Swap(&other->map_map_);
  4977. _internal_metadata_.Swap(&other->_internal_metadata_);
  4978. }
  4979. ::google::protobuf::Metadata TestNestedMap::GetMetadata() const {
  4980. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  4981. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  4982. }
  4983. // ===================================================================
  4984. void TestWrapper::InitAsDefaultInstance() {
  4985. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->bool_value_ = const_cast< ::google::protobuf::BoolValue*>(
  4986. ::google::protobuf::BoolValue::internal_default_instance());
  4987. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->int32_value_ = const_cast< ::google::protobuf::Int32Value*>(
  4988. ::google::protobuf::Int32Value::internal_default_instance());
  4989. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->int64_value_ = const_cast< ::google::protobuf::Int64Value*>(
  4990. ::google::protobuf::Int64Value::internal_default_instance());
  4991. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->uint32_value_ = const_cast< ::google::protobuf::UInt32Value*>(
  4992. ::google::protobuf::UInt32Value::internal_default_instance());
  4993. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->uint64_value_ = const_cast< ::google::protobuf::UInt64Value*>(
  4994. ::google::protobuf::UInt64Value::internal_default_instance());
  4995. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->float_value_ = const_cast< ::google::protobuf::FloatValue*>(
  4996. ::google::protobuf::FloatValue::internal_default_instance());
  4997. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->double_value_ = const_cast< ::google::protobuf::DoubleValue*>(
  4998. ::google::protobuf::DoubleValue::internal_default_instance());
  4999. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->string_value_ = const_cast< ::google::protobuf::StringValue*>(
  5000. ::google::protobuf::StringValue::internal_default_instance());
  5001. ::proto3::_TestWrapper_default_instance_._instance.get_mutable()->bytes_value_ = const_cast< ::google::protobuf::BytesValue*>(
  5002. ::google::protobuf::BytesValue::internal_default_instance());
  5003. }
  5004. void TestWrapper::clear_bool_value() {
  5005. if (GetArenaNoVirtual() == NULL && bool_value_ != NULL) {
  5006. delete bool_value_;
  5007. }
  5008. bool_value_ = NULL;
  5009. }
  5010. void TestWrapper::clear_int32_value() {
  5011. if (GetArenaNoVirtual() == NULL && int32_value_ != NULL) {
  5012. delete int32_value_;
  5013. }
  5014. int32_value_ = NULL;
  5015. }
  5016. void TestWrapper::clear_int64_value() {
  5017. if (GetArenaNoVirtual() == NULL && int64_value_ != NULL) {
  5018. delete int64_value_;
  5019. }
  5020. int64_value_ = NULL;
  5021. }
  5022. void TestWrapper::clear_uint32_value() {
  5023. if (GetArenaNoVirtual() == NULL && uint32_value_ != NULL) {
  5024. delete uint32_value_;
  5025. }
  5026. uint32_value_ = NULL;
  5027. }
  5028. void TestWrapper::clear_uint64_value() {
  5029. if (GetArenaNoVirtual() == NULL && uint64_value_ != NULL) {
  5030. delete uint64_value_;
  5031. }
  5032. uint64_value_ = NULL;
  5033. }
  5034. void TestWrapper::clear_float_value() {
  5035. if (GetArenaNoVirtual() == NULL && float_value_ != NULL) {
  5036. delete float_value_;
  5037. }
  5038. float_value_ = NULL;
  5039. }
  5040. void TestWrapper::clear_double_value() {
  5041. if (GetArenaNoVirtual() == NULL && double_value_ != NULL) {
  5042. delete double_value_;
  5043. }
  5044. double_value_ = NULL;
  5045. }
  5046. void TestWrapper::clear_string_value() {
  5047. if (GetArenaNoVirtual() == NULL && string_value_ != NULL) {
  5048. delete string_value_;
  5049. }
  5050. string_value_ = NULL;
  5051. }
  5052. void TestWrapper::clear_bytes_value() {
  5053. if (GetArenaNoVirtual() == NULL && bytes_value_ != NULL) {
  5054. delete bytes_value_;
  5055. }
  5056. bytes_value_ = NULL;
  5057. }
  5058. void TestWrapper::clear_repeated_bool_value() {
  5059. repeated_bool_value_.Clear();
  5060. }
  5061. void TestWrapper::clear_repeated_int32_value() {
  5062. repeated_int32_value_.Clear();
  5063. }
  5064. void TestWrapper::clear_repeated_int64_value() {
  5065. repeated_int64_value_.Clear();
  5066. }
  5067. void TestWrapper::clear_repeated_uint32_value() {
  5068. repeated_uint32_value_.Clear();
  5069. }
  5070. void TestWrapper::clear_repeated_uint64_value() {
  5071. repeated_uint64_value_.Clear();
  5072. }
  5073. void TestWrapper::clear_repeated_float_value() {
  5074. repeated_float_value_.Clear();
  5075. }
  5076. void TestWrapper::clear_repeated_double_value() {
  5077. repeated_double_value_.Clear();
  5078. }
  5079. void TestWrapper::clear_repeated_string_value() {
  5080. repeated_string_value_.Clear();
  5081. }
  5082. void TestWrapper::clear_repeated_bytes_value() {
  5083. repeated_bytes_value_.Clear();
  5084. }
  5085. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  5086. const int TestWrapper::kBoolValueFieldNumber;
  5087. const int TestWrapper::kInt32ValueFieldNumber;
  5088. const int TestWrapper::kInt64ValueFieldNumber;
  5089. const int TestWrapper::kUint32ValueFieldNumber;
  5090. const int TestWrapper::kUint64ValueFieldNumber;
  5091. const int TestWrapper::kFloatValueFieldNumber;
  5092. const int TestWrapper::kDoubleValueFieldNumber;
  5093. const int TestWrapper::kStringValueFieldNumber;
  5094. const int TestWrapper::kBytesValueFieldNumber;
  5095. const int TestWrapper::kRepeatedBoolValueFieldNumber;
  5096. const int TestWrapper::kRepeatedInt32ValueFieldNumber;
  5097. const int TestWrapper::kRepeatedInt64ValueFieldNumber;
  5098. const int TestWrapper::kRepeatedUint32ValueFieldNumber;
  5099. const int TestWrapper::kRepeatedUint64ValueFieldNumber;
  5100. const int TestWrapper::kRepeatedFloatValueFieldNumber;
  5101. const int TestWrapper::kRepeatedDoubleValueFieldNumber;
  5102. const int TestWrapper::kRepeatedStringValueFieldNumber;
  5103. const int TestWrapper::kRepeatedBytesValueFieldNumber;
  5104. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  5105. TestWrapper::TestWrapper()
  5106. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  5107. ::google::protobuf::internal::InitSCC(
  5108. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestWrapper.base);
  5109. SharedCtor();
  5110. // @@protoc_insertion_point(constructor:proto3.TestWrapper)
  5111. }
  5112. TestWrapper::TestWrapper(const TestWrapper& from)
  5113. : ::google::protobuf::Message(),
  5114. _internal_metadata_(NULL),
  5115. repeated_bool_value_(from.repeated_bool_value_),
  5116. repeated_int32_value_(from.repeated_int32_value_),
  5117. repeated_int64_value_(from.repeated_int64_value_),
  5118. repeated_uint32_value_(from.repeated_uint32_value_),
  5119. repeated_uint64_value_(from.repeated_uint64_value_),
  5120. repeated_float_value_(from.repeated_float_value_),
  5121. repeated_double_value_(from.repeated_double_value_),
  5122. repeated_string_value_(from.repeated_string_value_),
  5123. repeated_bytes_value_(from.repeated_bytes_value_) {
  5124. _internal_metadata_.MergeFrom(from._internal_metadata_);
  5125. if (from.has_bool_value()) {
  5126. bool_value_ = new ::google::protobuf::BoolValue(*from.bool_value_);
  5127. } else {
  5128. bool_value_ = NULL;
  5129. }
  5130. if (from.has_int32_value()) {
  5131. int32_value_ = new ::google::protobuf::Int32Value(*from.int32_value_);
  5132. } else {
  5133. int32_value_ = NULL;
  5134. }
  5135. if (from.has_int64_value()) {
  5136. int64_value_ = new ::google::protobuf::Int64Value(*from.int64_value_);
  5137. } else {
  5138. int64_value_ = NULL;
  5139. }
  5140. if (from.has_uint32_value()) {
  5141. uint32_value_ = new ::google::protobuf::UInt32Value(*from.uint32_value_);
  5142. } else {
  5143. uint32_value_ = NULL;
  5144. }
  5145. if (from.has_uint64_value()) {
  5146. uint64_value_ = new ::google::protobuf::UInt64Value(*from.uint64_value_);
  5147. } else {
  5148. uint64_value_ = NULL;
  5149. }
  5150. if (from.has_float_value()) {
  5151. float_value_ = new ::google::protobuf::FloatValue(*from.float_value_);
  5152. } else {
  5153. float_value_ = NULL;
  5154. }
  5155. if (from.has_double_value()) {
  5156. double_value_ = new ::google::protobuf::DoubleValue(*from.double_value_);
  5157. } else {
  5158. double_value_ = NULL;
  5159. }
  5160. if (from.has_string_value()) {
  5161. string_value_ = new ::google::protobuf::StringValue(*from.string_value_);
  5162. } else {
  5163. string_value_ = NULL;
  5164. }
  5165. if (from.has_bytes_value()) {
  5166. bytes_value_ = new ::google::protobuf::BytesValue(*from.bytes_value_);
  5167. } else {
  5168. bytes_value_ = NULL;
  5169. }
  5170. // @@protoc_insertion_point(copy_constructor:proto3.TestWrapper)
  5171. }
  5172. void TestWrapper::SharedCtor() {
  5173. ::memset(&bool_value_, 0, static_cast<size_t>(
  5174. reinterpret_cast<char*>(&bytes_value_) -
  5175. reinterpret_cast<char*>(&bool_value_)) + sizeof(bytes_value_));
  5176. }
  5177. TestWrapper::~TestWrapper() {
  5178. // @@protoc_insertion_point(destructor:proto3.TestWrapper)
  5179. SharedDtor();
  5180. }
  5181. void TestWrapper::SharedDtor() {
  5182. if (this != internal_default_instance()) delete bool_value_;
  5183. if (this != internal_default_instance()) delete int32_value_;
  5184. if (this != internal_default_instance()) delete int64_value_;
  5185. if (this != internal_default_instance()) delete uint32_value_;
  5186. if (this != internal_default_instance()) delete uint64_value_;
  5187. if (this != internal_default_instance()) delete float_value_;
  5188. if (this != internal_default_instance()) delete double_value_;
  5189. if (this != internal_default_instance()) delete string_value_;
  5190. if (this != internal_default_instance()) delete bytes_value_;
  5191. }
  5192. void TestWrapper::SetCachedSize(int size) const {
  5193. _cached_size_.Set(size);
  5194. }
  5195. const ::google::protobuf::Descriptor* TestWrapper::descriptor() {
  5196. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  5197. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  5198. }
  5199. const TestWrapper& TestWrapper::default_instance() {
  5200. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestWrapper.base);
  5201. return *internal_default_instance();
  5202. }
  5203. void TestWrapper::Clear() {
  5204. // @@protoc_insertion_point(message_clear_start:proto3.TestWrapper)
  5205. ::google::protobuf::uint32 cached_has_bits = 0;
  5206. // Prevent compiler warnings about cached_has_bits being unused
  5207. (void) cached_has_bits;
  5208. repeated_bool_value_.Clear();
  5209. repeated_int32_value_.Clear();
  5210. repeated_int64_value_.Clear();
  5211. repeated_uint32_value_.Clear();
  5212. repeated_uint64_value_.Clear();
  5213. repeated_float_value_.Clear();
  5214. repeated_double_value_.Clear();
  5215. repeated_string_value_.Clear();
  5216. repeated_bytes_value_.Clear();
  5217. if (GetArenaNoVirtual() == NULL && bool_value_ != NULL) {
  5218. delete bool_value_;
  5219. }
  5220. bool_value_ = NULL;
  5221. if (GetArenaNoVirtual() == NULL && int32_value_ != NULL) {
  5222. delete int32_value_;
  5223. }
  5224. int32_value_ = NULL;
  5225. if (GetArenaNoVirtual() == NULL && int64_value_ != NULL) {
  5226. delete int64_value_;
  5227. }
  5228. int64_value_ = NULL;
  5229. if (GetArenaNoVirtual() == NULL && uint32_value_ != NULL) {
  5230. delete uint32_value_;
  5231. }
  5232. uint32_value_ = NULL;
  5233. if (GetArenaNoVirtual() == NULL && uint64_value_ != NULL) {
  5234. delete uint64_value_;
  5235. }
  5236. uint64_value_ = NULL;
  5237. if (GetArenaNoVirtual() == NULL && float_value_ != NULL) {
  5238. delete float_value_;
  5239. }
  5240. float_value_ = NULL;
  5241. if (GetArenaNoVirtual() == NULL && double_value_ != NULL) {
  5242. delete double_value_;
  5243. }
  5244. double_value_ = NULL;
  5245. if (GetArenaNoVirtual() == NULL && string_value_ != NULL) {
  5246. delete string_value_;
  5247. }
  5248. string_value_ = NULL;
  5249. if (GetArenaNoVirtual() == NULL && bytes_value_ != NULL) {
  5250. delete bytes_value_;
  5251. }
  5252. bytes_value_ = NULL;
  5253. _internal_metadata_.Clear();
  5254. }
  5255. bool TestWrapper::MergePartialFromCodedStream(
  5256. ::google::protobuf::io::CodedInputStream* input) {
  5257. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  5258. ::google::protobuf::uint32 tag;
  5259. // @@protoc_insertion_point(parse_start:proto3.TestWrapper)
  5260. for (;;) {
  5261. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(16383u);
  5262. tag = p.first;
  5263. if (!p.second) goto handle_unusual;
  5264. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  5265. // .google.protobuf.BoolValue bool_value = 1;
  5266. case 1: {
  5267. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5268. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  5269. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5270. input, mutable_bool_value()));
  5271. } else {
  5272. goto handle_unusual;
  5273. }
  5274. break;
  5275. }
  5276. // .google.protobuf.Int32Value int32_value = 2;
  5277. case 2: {
  5278. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5279. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  5280. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5281. input, mutable_int32_value()));
  5282. } else {
  5283. goto handle_unusual;
  5284. }
  5285. break;
  5286. }
  5287. // .google.protobuf.Int64Value int64_value = 3;
  5288. case 3: {
  5289. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5290. static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
  5291. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5292. input, mutable_int64_value()));
  5293. } else {
  5294. goto handle_unusual;
  5295. }
  5296. break;
  5297. }
  5298. // .google.protobuf.UInt32Value uint32_value = 4;
  5299. case 4: {
  5300. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5301. static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
  5302. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5303. input, mutable_uint32_value()));
  5304. } else {
  5305. goto handle_unusual;
  5306. }
  5307. break;
  5308. }
  5309. // .google.protobuf.UInt64Value uint64_value = 5;
  5310. case 5: {
  5311. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5312. static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
  5313. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5314. input, mutable_uint64_value()));
  5315. } else {
  5316. goto handle_unusual;
  5317. }
  5318. break;
  5319. }
  5320. // .google.protobuf.FloatValue float_value = 6;
  5321. case 6: {
  5322. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5323. static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
  5324. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5325. input, mutable_float_value()));
  5326. } else {
  5327. goto handle_unusual;
  5328. }
  5329. break;
  5330. }
  5331. // .google.protobuf.DoubleValue double_value = 7;
  5332. case 7: {
  5333. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5334. static_cast< ::google::protobuf::uint8>(58u /* 58 & 0xFF */)) {
  5335. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5336. input, mutable_double_value()));
  5337. } else {
  5338. goto handle_unusual;
  5339. }
  5340. break;
  5341. }
  5342. // .google.protobuf.StringValue string_value = 8;
  5343. case 8: {
  5344. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5345. static_cast< ::google::protobuf::uint8>(66u /* 66 & 0xFF */)) {
  5346. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5347. input, mutable_string_value()));
  5348. } else {
  5349. goto handle_unusual;
  5350. }
  5351. break;
  5352. }
  5353. // .google.protobuf.BytesValue bytes_value = 9;
  5354. case 9: {
  5355. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5356. static_cast< ::google::protobuf::uint8>(74u /* 74 & 0xFF */)) {
  5357. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5358. input, mutable_bytes_value()));
  5359. } else {
  5360. goto handle_unusual;
  5361. }
  5362. break;
  5363. }
  5364. // repeated .google.protobuf.BoolValue repeated_bool_value = 11;
  5365. case 11: {
  5366. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5367. static_cast< ::google::protobuf::uint8>(90u /* 90 & 0xFF */)) {
  5368. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5369. input, add_repeated_bool_value()));
  5370. } else {
  5371. goto handle_unusual;
  5372. }
  5373. break;
  5374. }
  5375. // repeated .google.protobuf.Int32Value repeated_int32_value = 12;
  5376. case 12: {
  5377. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5378. static_cast< ::google::protobuf::uint8>(98u /* 98 & 0xFF */)) {
  5379. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5380. input, add_repeated_int32_value()));
  5381. } else {
  5382. goto handle_unusual;
  5383. }
  5384. break;
  5385. }
  5386. // repeated .google.protobuf.Int64Value repeated_int64_value = 13;
  5387. case 13: {
  5388. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5389. static_cast< ::google::protobuf::uint8>(106u /* 106 & 0xFF */)) {
  5390. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5391. input, add_repeated_int64_value()));
  5392. } else {
  5393. goto handle_unusual;
  5394. }
  5395. break;
  5396. }
  5397. // repeated .google.protobuf.UInt32Value repeated_uint32_value = 14;
  5398. case 14: {
  5399. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5400. static_cast< ::google::protobuf::uint8>(114u /* 114 & 0xFF */)) {
  5401. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5402. input, add_repeated_uint32_value()));
  5403. } else {
  5404. goto handle_unusual;
  5405. }
  5406. break;
  5407. }
  5408. // repeated .google.protobuf.UInt64Value repeated_uint64_value = 15;
  5409. case 15: {
  5410. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5411. static_cast< ::google::protobuf::uint8>(122u /* 122 & 0xFF */)) {
  5412. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5413. input, add_repeated_uint64_value()));
  5414. } else {
  5415. goto handle_unusual;
  5416. }
  5417. break;
  5418. }
  5419. // repeated .google.protobuf.FloatValue repeated_float_value = 16;
  5420. case 16: {
  5421. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5422. static_cast< ::google::protobuf::uint8>(130u /* 130 & 0xFF */)) {
  5423. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5424. input, add_repeated_float_value()));
  5425. } else {
  5426. goto handle_unusual;
  5427. }
  5428. break;
  5429. }
  5430. // repeated .google.protobuf.DoubleValue repeated_double_value = 17;
  5431. case 17: {
  5432. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5433. static_cast< ::google::protobuf::uint8>(138u /* 138 & 0xFF */)) {
  5434. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5435. input, add_repeated_double_value()));
  5436. } else {
  5437. goto handle_unusual;
  5438. }
  5439. break;
  5440. }
  5441. // repeated .google.protobuf.StringValue repeated_string_value = 18;
  5442. case 18: {
  5443. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5444. static_cast< ::google::protobuf::uint8>(146u /* 146 & 0xFF */)) {
  5445. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5446. input, add_repeated_string_value()));
  5447. } else {
  5448. goto handle_unusual;
  5449. }
  5450. break;
  5451. }
  5452. // repeated .google.protobuf.BytesValue repeated_bytes_value = 19;
  5453. case 19: {
  5454. if (static_cast< ::google::protobuf::uint8>(tag) ==
  5455. static_cast< ::google::protobuf::uint8>(154u /* 154 & 0xFF */)) {
  5456. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  5457. input, add_repeated_bytes_value()));
  5458. } else {
  5459. goto handle_unusual;
  5460. }
  5461. break;
  5462. }
  5463. default: {
  5464. handle_unusual:
  5465. if (tag == 0) {
  5466. goto success;
  5467. }
  5468. DO_(::google::protobuf::internal::WireFormat::SkipField(
  5469. input, tag, _internal_metadata_.mutable_unknown_fields()));
  5470. break;
  5471. }
  5472. }
  5473. }
  5474. success:
  5475. // @@protoc_insertion_point(parse_success:proto3.TestWrapper)
  5476. return true;
  5477. failure:
  5478. // @@protoc_insertion_point(parse_failure:proto3.TestWrapper)
  5479. return false;
  5480. #undef DO_
  5481. }
  5482. void TestWrapper::SerializeWithCachedSizes(
  5483. ::google::protobuf::io::CodedOutputStream* output) const {
  5484. // @@protoc_insertion_point(serialize_start:proto3.TestWrapper)
  5485. ::google::protobuf::uint32 cached_has_bits = 0;
  5486. (void) cached_has_bits;
  5487. // .google.protobuf.BoolValue bool_value = 1;
  5488. if (this->has_bool_value()) {
  5489. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5490. 1, this->_internal_bool_value(), output);
  5491. }
  5492. // .google.protobuf.Int32Value int32_value = 2;
  5493. if (this->has_int32_value()) {
  5494. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5495. 2, this->_internal_int32_value(), output);
  5496. }
  5497. // .google.protobuf.Int64Value int64_value = 3;
  5498. if (this->has_int64_value()) {
  5499. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5500. 3, this->_internal_int64_value(), output);
  5501. }
  5502. // .google.protobuf.UInt32Value uint32_value = 4;
  5503. if (this->has_uint32_value()) {
  5504. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5505. 4, this->_internal_uint32_value(), output);
  5506. }
  5507. // .google.protobuf.UInt64Value uint64_value = 5;
  5508. if (this->has_uint64_value()) {
  5509. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5510. 5, this->_internal_uint64_value(), output);
  5511. }
  5512. // .google.protobuf.FloatValue float_value = 6;
  5513. if (this->has_float_value()) {
  5514. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5515. 6, this->_internal_float_value(), output);
  5516. }
  5517. // .google.protobuf.DoubleValue double_value = 7;
  5518. if (this->has_double_value()) {
  5519. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5520. 7, this->_internal_double_value(), output);
  5521. }
  5522. // .google.protobuf.StringValue string_value = 8;
  5523. if (this->has_string_value()) {
  5524. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5525. 8, this->_internal_string_value(), output);
  5526. }
  5527. // .google.protobuf.BytesValue bytes_value = 9;
  5528. if (this->has_bytes_value()) {
  5529. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5530. 9, this->_internal_bytes_value(), output);
  5531. }
  5532. // repeated .google.protobuf.BoolValue repeated_bool_value = 11;
  5533. for (unsigned int i = 0,
  5534. n = static_cast<unsigned int>(this->repeated_bool_value_size()); i < n; i++) {
  5535. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5536. 11,
  5537. this->repeated_bool_value(static_cast<int>(i)),
  5538. output);
  5539. }
  5540. // repeated .google.protobuf.Int32Value repeated_int32_value = 12;
  5541. for (unsigned int i = 0,
  5542. n = static_cast<unsigned int>(this->repeated_int32_value_size()); i < n; i++) {
  5543. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5544. 12,
  5545. this->repeated_int32_value(static_cast<int>(i)),
  5546. output);
  5547. }
  5548. // repeated .google.protobuf.Int64Value repeated_int64_value = 13;
  5549. for (unsigned int i = 0,
  5550. n = static_cast<unsigned int>(this->repeated_int64_value_size()); i < n; i++) {
  5551. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5552. 13,
  5553. this->repeated_int64_value(static_cast<int>(i)),
  5554. output);
  5555. }
  5556. // repeated .google.protobuf.UInt32Value repeated_uint32_value = 14;
  5557. for (unsigned int i = 0,
  5558. n = static_cast<unsigned int>(this->repeated_uint32_value_size()); i < n; i++) {
  5559. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5560. 14,
  5561. this->repeated_uint32_value(static_cast<int>(i)),
  5562. output);
  5563. }
  5564. // repeated .google.protobuf.UInt64Value repeated_uint64_value = 15;
  5565. for (unsigned int i = 0,
  5566. n = static_cast<unsigned int>(this->repeated_uint64_value_size()); i < n; i++) {
  5567. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5568. 15,
  5569. this->repeated_uint64_value(static_cast<int>(i)),
  5570. output);
  5571. }
  5572. // repeated .google.protobuf.FloatValue repeated_float_value = 16;
  5573. for (unsigned int i = 0,
  5574. n = static_cast<unsigned int>(this->repeated_float_value_size()); i < n; i++) {
  5575. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5576. 16,
  5577. this->repeated_float_value(static_cast<int>(i)),
  5578. output);
  5579. }
  5580. // repeated .google.protobuf.DoubleValue repeated_double_value = 17;
  5581. for (unsigned int i = 0,
  5582. n = static_cast<unsigned int>(this->repeated_double_value_size()); i < n; i++) {
  5583. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5584. 17,
  5585. this->repeated_double_value(static_cast<int>(i)),
  5586. output);
  5587. }
  5588. // repeated .google.protobuf.StringValue repeated_string_value = 18;
  5589. for (unsigned int i = 0,
  5590. n = static_cast<unsigned int>(this->repeated_string_value_size()); i < n; i++) {
  5591. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5592. 18,
  5593. this->repeated_string_value(static_cast<int>(i)),
  5594. output);
  5595. }
  5596. // repeated .google.protobuf.BytesValue repeated_bytes_value = 19;
  5597. for (unsigned int i = 0,
  5598. n = static_cast<unsigned int>(this->repeated_bytes_value_size()); i < n; i++) {
  5599. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  5600. 19,
  5601. this->repeated_bytes_value(static_cast<int>(i)),
  5602. output);
  5603. }
  5604. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  5605. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  5606. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  5607. }
  5608. // @@protoc_insertion_point(serialize_end:proto3.TestWrapper)
  5609. }
  5610. ::google::protobuf::uint8* TestWrapper::InternalSerializeWithCachedSizesToArray(
  5611. bool deterministic, ::google::protobuf::uint8* target) const {
  5612. (void)deterministic; // Unused
  5613. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestWrapper)
  5614. ::google::protobuf::uint32 cached_has_bits = 0;
  5615. (void) cached_has_bits;
  5616. // .google.protobuf.BoolValue bool_value = 1;
  5617. if (this->has_bool_value()) {
  5618. target = ::google::protobuf::internal::WireFormatLite::
  5619. InternalWriteMessageToArray(
  5620. 1, this->_internal_bool_value(), deterministic, target);
  5621. }
  5622. // .google.protobuf.Int32Value int32_value = 2;
  5623. if (this->has_int32_value()) {
  5624. target = ::google::protobuf::internal::WireFormatLite::
  5625. InternalWriteMessageToArray(
  5626. 2, this->_internal_int32_value(), deterministic, target);
  5627. }
  5628. // .google.protobuf.Int64Value int64_value = 3;
  5629. if (this->has_int64_value()) {
  5630. target = ::google::protobuf::internal::WireFormatLite::
  5631. InternalWriteMessageToArray(
  5632. 3, this->_internal_int64_value(), deterministic, target);
  5633. }
  5634. // .google.protobuf.UInt32Value uint32_value = 4;
  5635. if (this->has_uint32_value()) {
  5636. target = ::google::protobuf::internal::WireFormatLite::
  5637. InternalWriteMessageToArray(
  5638. 4, this->_internal_uint32_value(), deterministic, target);
  5639. }
  5640. // .google.protobuf.UInt64Value uint64_value = 5;
  5641. if (this->has_uint64_value()) {
  5642. target = ::google::protobuf::internal::WireFormatLite::
  5643. InternalWriteMessageToArray(
  5644. 5, this->_internal_uint64_value(), deterministic, target);
  5645. }
  5646. // .google.protobuf.FloatValue float_value = 6;
  5647. if (this->has_float_value()) {
  5648. target = ::google::protobuf::internal::WireFormatLite::
  5649. InternalWriteMessageToArray(
  5650. 6, this->_internal_float_value(), deterministic, target);
  5651. }
  5652. // .google.protobuf.DoubleValue double_value = 7;
  5653. if (this->has_double_value()) {
  5654. target = ::google::protobuf::internal::WireFormatLite::
  5655. InternalWriteMessageToArray(
  5656. 7, this->_internal_double_value(), deterministic, target);
  5657. }
  5658. // .google.protobuf.StringValue string_value = 8;
  5659. if (this->has_string_value()) {
  5660. target = ::google::protobuf::internal::WireFormatLite::
  5661. InternalWriteMessageToArray(
  5662. 8, this->_internal_string_value(), deterministic, target);
  5663. }
  5664. // .google.protobuf.BytesValue bytes_value = 9;
  5665. if (this->has_bytes_value()) {
  5666. target = ::google::protobuf::internal::WireFormatLite::
  5667. InternalWriteMessageToArray(
  5668. 9, this->_internal_bytes_value(), deterministic, target);
  5669. }
  5670. // repeated .google.protobuf.BoolValue repeated_bool_value = 11;
  5671. for (unsigned int i = 0,
  5672. n = static_cast<unsigned int>(this->repeated_bool_value_size()); i < n; i++) {
  5673. target = ::google::protobuf::internal::WireFormatLite::
  5674. InternalWriteMessageToArray(
  5675. 11, this->repeated_bool_value(static_cast<int>(i)), deterministic, target);
  5676. }
  5677. // repeated .google.protobuf.Int32Value repeated_int32_value = 12;
  5678. for (unsigned int i = 0,
  5679. n = static_cast<unsigned int>(this->repeated_int32_value_size()); i < n; i++) {
  5680. target = ::google::protobuf::internal::WireFormatLite::
  5681. InternalWriteMessageToArray(
  5682. 12, this->repeated_int32_value(static_cast<int>(i)), deterministic, target);
  5683. }
  5684. // repeated .google.protobuf.Int64Value repeated_int64_value = 13;
  5685. for (unsigned int i = 0,
  5686. n = static_cast<unsigned int>(this->repeated_int64_value_size()); i < n; i++) {
  5687. target = ::google::protobuf::internal::WireFormatLite::
  5688. InternalWriteMessageToArray(
  5689. 13, this->repeated_int64_value(static_cast<int>(i)), deterministic, target);
  5690. }
  5691. // repeated .google.protobuf.UInt32Value repeated_uint32_value = 14;
  5692. for (unsigned int i = 0,
  5693. n = static_cast<unsigned int>(this->repeated_uint32_value_size()); i < n; i++) {
  5694. target = ::google::protobuf::internal::WireFormatLite::
  5695. InternalWriteMessageToArray(
  5696. 14, this->repeated_uint32_value(static_cast<int>(i)), deterministic, target);
  5697. }
  5698. // repeated .google.protobuf.UInt64Value repeated_uint64_value = 15;
  5699. for (unsigned int i = 0,
  5700. n = static_cast<unsigned int>(this->repeated_uint64_value_size()); i < n; i++) {
  5701. target = ::google::protobuf::internal::WireFormatLite::
  5702. InternalWriteMessageToArray(
  5703. 15, this->repeated_uint64_value(static_cast<int>(i)), deterministic, target);
  5704. }
  5705. // repeated .google.protobuf.FloatValue repeated_float_value = 16;
  5706. for (unsigned int i = 0,
  5707. n = static_cast<unsigned int>(this->repeated_float_value_size()); i < n; i++) {
  5708. target = ::google::protobuf::internal::WireFormatLite::
  5709. InternalWriteMessageToArray(
  5710. 16, this->repeated_float_value(static_cast<int>(i)), deterministic, target);
  5711. }
  5712. // repeated .google.protobuf.DoubleValue repeated_double_value = 17;
  5713. for (unsigned int i = 0,
  5714. n = static_cast<unsigned int>(this->repeated_double_value_size()); i < n; i++) {
  5715. target = ::google::protobuf::internal::WireFormatLite::
  5716. InternalWriteMessageToArray(
  5717. 17, this->repeated_double_value(static_cast<int>(i)), deterministic, target);
  5718. }
  5719. // repeated .google.protobuf.StringValue repeated_string_value = 18;
  5720. for (unsigned int i = 0,
  5721. n = static_cast<unsigned int>(this->repeated_string_value_size()); i < n; i++) {
  5722. target = ::google::protobuf::internal::WireFormatLite::
  5723. InternalWriteMessageToArray(
  5724. 18, this->repeated_string_value(static_cast<int>(i)), deterministic, target);
  5725. }
  5726. // repeated .google.protobuf.BytesValue repeated_bytes_value = 19;
  5727. for (unsigned int i = 0,
  5728. n = static_cast<unsigned int>(this->repeated_bytes_value_size()); i < n; i++) {
  5729. target = ::google::protobuf::internal::WireFormatLite::
  5730. InternalWriteMessageToArray(
  5731. 19, this->repeated_bytes_value(static_cast<int>(i)), deterministic, target);
  5732. }
  5733. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  5734. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  5735. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  5736. }
  5737. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestWrapper)
  5738. return target;
  5739. }
  5740. size_t TestWrapper::ByteSizeLong() const {
  5741. // @@protoc_insertion_point(message_byte_size_start:proto3.TestWrapper)
  5742. size_t total_size = 0;
  5743. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  5744. total_size +=
  5745. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  5746. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  5747. }
  5748. // repeated .google.protobuf.BoolValue repeated_bool_value = 11;
  5749. {
  5750. unsigned int count = static_cast<unsigned int>(this->repeated_bool_value_size());
  5751. total_size += 1UL * count;
  5752. for (unsigned int i = 0; i < count; i++) {
  5753. total_size +=
  5754. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5755. this->repeated_bool_value(static_cast<int>(i)));
  5756. }
  5757. }
  5758. // repeated .google.protobuf.Int32Value repeated_int32_value = 12;
  5759. {
  5760. unsigned int count = static_cast<unsigned int>(this->repeated_int32_value_size());
  5761. total_size += 1UL * count;
  5762. for (unsigned int i = 0; i < count; i++) {
  5763. total_size +=
  5764. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5765. this->repeated_int32_value(static_cast<int>(i)));
  5766. }
  5767. }
  5768. // repeated .google.protobuf.Int64Value repeated_int64_value = 13;
  5769. {
  5770. unsigned int count = static_cast<unsigned int>(this->repeated_int64_value_size());
  5771. total_size += 1UL * count;
  5772. for (unsigned int i = 0; i < count; i++) {
  5773. total_size +=
  5774. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5775. this->repeated_int64_value(static_cast<int>(i)));
  5776. }
  5777. }
  5778. // repeated .google.protobuf.UInt32Value repeated_uint32_value = 14;
  5779. {
  5780. unsigned int count = static_cast<unsigned int>(this->repeated_uint32_value_size());
  5781. total_size += 1UL * count;
  5782. for (unsigned int i = 0; i < count; i++) {
  5783. total_size +=
  5784. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5785. this->repeated_uint32_value(static_cast<int>(i)));
  5786. }
  5787. }
  5788. // repeated .google.protobuf.UInt64Value repeated_uint64_value = 15;
  5789. {
  5790. unsigned int count = static_cast<unsigned int>(this->repeated_uint64_value_size());
  5791. total_size += 1UL * count;
  5792. for (unsigned int i = 0; i < count; i++) {
  5793. total_size +=
  5794. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5795. this->repeated_uint64_value(static_cast<int>(i)));
  5796. }
  5797. }
  5798. // repeated .google.protobuf.FloatValue repeated_float_value = 16;
  5799. {
  5800. unsigned int count = static_cast<unsigned int>(this->repeated_float_value_size());
  5801. total_size += 2UL * count;
  5802. for (unsigned int i = 0; i < count; i++) {
  5803. total_size +=
  5804. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5805. this->repeated_float_value(static_cast<int>(i)));
  5806. }
  5807. }
  5808. // repeated .google.protobuf.DoubleValue repeated_double_value = 17;
  5809. {
  5810. unsigned int count = static_cast<unsigned int>(this->repeated_double_value_size());
  5811. total_size += 2UL * count;
  5812. for (unsigned int i = 0; i < count; i++) {
  5813. total_size +=
  5814. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5815. this->repeated_double_value(static_cast<int>(i)));
  5816. }
  5817. }
  5818. // repeated .google.protobuf.StringValue repeated_string_value = 18;
  5819. {
  5820. unsigned int count = static_cast<unsigned int>(this->repeated_string_value_size());
  5821. total_size += 2UL * count;
  5822. for (unsigned int i = 0; i < count; i++) {
  5823. total_size +=
  5824. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5825. this->repeated_string_value(static_cast<int>(i)));
  5826. }
  5827. }
  5828. // repeated .google.protobuf.BytesValue repeated_bytes_value = 19;
  5829. {
  5830. unsigned int count = static_cast<unsigned int>(this->repeated_bytes_value_size());
  5831. total_size += 2UL * count;
  5832. for (unsigned int i = 0; i < count; i++) {
  5833. total_size +=
  5834. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5835. this->repeated_bytes_value(static_cast<int>(i)));
  5836. }
  5837. }
  5838. // .google.protobuf.BoolValue bool_value = 1;
  5839. if (this->has_bool_value()) {
  5840. total_size += 1 +
  5841. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5842. *bool_value_);
  5843. }
  5844. // .google.protobuf.Int32Value int32_value = 2;
  5845. if (this->has_int32_value()) {
  5846. total_size += 1 +
  5847. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5848. *int32_value_);
  5849. }
  5850. // .google.protobuf.Int64Value int64_value = 3;
  5851. if (this->has_int64_value()) {
  5852. total_size += 1 +
  5853. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5854. *int64_value_);
  5855. }
  5856. // .google.protobuf.UInt32Value uint32_value = 4;
  5857. if (this->has_uint32_value()) {
  5858. total_size += 1 +
  5859. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5860. *uint32_value_);
  5861. }
  5862. // .google.protobuf.UInt64Value uint64_value = 5;
  5863. if (this->has_uint64_value()) {
  5864. total_size += 1 +
  5865. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5866. *uint64_value_);
  5867. }
  5868. // .google.protobuf.FloatValue float_value = 6;
  5869. if (this->has_float_value()) {
  5870. total_size += 1 +
  5871. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5872. *float_value_);
  5873. }
  5874. // .google.protobuf.DoubleValue double_value = 7;
  5875. if (this->has_double_value()) {
  5876. total_size += 1 +
  5877. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5878. *double_value_);
  5879. }
  5880. // .google.protobuf.StringValue string_value = 8;
  5881. if (this->has_string_value()) {
  5882. total_size += 1 +
  5883. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5884. *string_value_);
  5885. }
  5886. // .google.protobuf.BytesValue bytes_value = 9;
  5887. if (this->has_bytes_value()) {
  5888. total_size += 1 +
  5889. ::google::protobuf::internal::WireFormatLite::MessageSize(
  5890. *bytes_value_);
  5891. }
  5892. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  5893. SetCachedSize(cached_size);
  5894. return total_size;
  5895. }
  5896. void TestWrapper::MergeFrom(const ::google::protobuf::Message& from) {
  5897. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestWrapper)
  5898. GOOGLE_DCHECK_NE(&from, this);
  5899. const TestWrapper* source =
  5900. ::google::protobuf::internal::DynamicCastToGenerated<const TestWrapper>(
  5901. &from);
  5902. if (source == NULL) {
  5903. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestWrapper)
  5904. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  5905. } else {
  5906. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestWrapper)
  5907. MergeFrom(*source);
  5908. }
  5909. }
  5910. void TestWrapper::MergeFrom(const TestWrapper& from) {
  5911. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestWrapper)
  5912. GOOGLE_DCHECK_NE(&from, this);
  5913. _internal_metadata_.MergeFrom(from._internal_metadata_);
  5914. ::google::protobuf::uint32 cached_has_bits = 0;
  5915. (void) cached_has_bits;
  5916. repeated_bool_value_.MergeFrom(from.repeated_bool_value_);
  5917. repeated_int32_value_.MergeFrom(from.repeated_int32_value_);
  5918. repeated_int64_value_.MergeFrom(from.repeated_int64_value_);
  5919. repeated_uint32_value_.MergeFrom(from.repeated_uint32_value_);
  5920. repeated_uint64_value_.MergeFrom(from.repeated_uint64_value_);
  5921. repeated_float_value_.MergeFrom(from.repeated_float_value_);
  5922. repeated_double_value_.MergeFrom(from.repeated_double_value_);
  5923. repeated_string_value_.MergeFrom(from.repeated_string_value_);
  5924. repeated_bytes_value_.MergeFrom(from.repeated_bytes_value_);
  5925. if (from.has_bool_value()) {
  5926. mutable_bool_value()->::google::protobuf::BoolValue::MergeFrom(from.bool_value());
  5927. }
  5928. if (from.has_int32_value()) {
  5929. mutable_int32_value()->::google::protobuf::Int32Value::MergeFrom(from.int32_value());
  5930. }
  5931. if (from.has_int64_value()) {
  5932. mutable_int64_value()->::google::protobuf::Int64Value::MergeFrom(from.int64_value());
  5933. }
  5934. if (from.has_uint32_value()) {
  5935. mutable_uint32_value()->::google::protobuf::UInt32Value::MergeFrom(from.uint32_value());
  5936. }
  5937. if (from.has_uint64_value()) {
  5938. mutable_uint64_value()->::google::protobuf::UInt64Value::MergeFrom(from.uint64_value());
  5939. }
  5940. if (from.has_float_value()) {
  5941. mutable_float_value()->::google::protobuf::FloatValue::MergeFrom(from.float_value());
  5942. }
  5943. if (from.has_double_value()) {
  5944. mutable_double_value()->::google::protobuf::DoubleValue::MergeFrom(from.double_value());
  5945. }
  5946. if (from.has_string_value()) {
  5947. mutable_string_value()->::google::protobuf::StringValue::MergeFrom(from.string_value());
  5948. }
  5949. if (from.has_bytes_value()) {
  5950. mutable_bytes_value()->::google::protobuf::BytesValue::MergeFrom(from.bytes_value());
  5951. }
  5952. }
  5953. void TestWrapper::CopyFrom(const ::google::protobuf::Message& from) {
  5954. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestWrapper)
  5955. if (&from == this) return;
  5956. Clear();
  5957. MergeFrom(from);
  5958. }
  5959. void TestWrapper::CopyFrom(const TestWrapper& from) {
  5960. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestWrapper)
  5961. if (&from == this) return;
  5962. Clear();
  5963. MergeFrom(from);
  5964. }
  5965. bool TestWrapper::IsInitialized() const {
  5966. return true;
  5967. }
  5968. void TestWrapper::Swap(TestWrapper* other) {
  5969. if (other == this) return;
  5970. InternalSwap(other);
  5971. }
  5972. void TestWrapper::InternalSwap(TestWrapper* other) {
  5973. using std::swap;
  5974. CastToBase(&repeated_bool_value_)->InternalSwap(CastToBase(&other->repeated_bool_value_));
  5975. CastToBase(&repeated_int32_value_)->InternalSwap(CastToBase(&other->repeated_int32_value_));
  5976. CastToBase(&repeated_int64_value_)->InternalSwap(CastToBase(&other->repeated_int64_value_));
  5977. CastToBase(&repeated_uint32_value_)->InternalSwap(CastToBase(&other->repeated_uint32_value_));
  5978. CastToBase(&repeated_uint64_value_)->InternalSwap(CastToBase(&other->repeated_uint64_value_));
  5979. CastToBase(&repeated_float_value_)->InternalSwap(CastToBase(&other->repeated_float_value_));
  5980. CastToBase(&repeated_double_value_)->InternalSwap(CastToBase(&other->repeated_double_value_));
  5981. CastToBase(&repeated_string_value_)->InternalSwap(CastToBase(&other->repeated_string_value_));
  5982. CastToBase(&repeated_bytes_value_)->InternalSwap(CastToBase(&other->repeated_bytes_value_));
  5983. swap(bool_value_, other->bool_value_);
  5984. swap(int32_value_, other->int32_value_);
  5985. swap(int64_value_, other->int64_value_);
  5986. swap(uint32_value_, other->uint32_value_);
  5987. swap(uint64_value_, other->uint64_value_);
  5988. swap(float_value_, other->float_value_);
  5989. swap(double_value_, other->double_value_);
  5990. swap(string_value_, other->string_value_);
  5991. swap(bytes_value_, other->bytes_value_);
  5992. _internal_metadata_.Swap(&other->_internal_metadata_);
  5993. }
  5994. ::google::protobuf::Metadata TestWrapper::GetMetadata() const {
  5995. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  5996. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  5997. }
  5998. // ===================================================================
  5999. void TestTimestamp::InitAsDefaultInstance() {
  6000. ::proto3::_TestTimestamp_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::Timestamp*>(
  6001. ::google::protobuf::Timestamp::internal_default_instance());
  6002. }
  6003. void TestTimestamp::clear_value() {
  6004. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6005. delete value_;
  6006. }
  6007. value_ = NULL;
  6008. }
  6009. void TestTimestamp::clear_repeated_value() {
  6010. repeated_value_.Clear();
  6011. }
  6012. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  6013. const int TestTimestamp::kValueFieldNumber;
  6014. const int TestTimestamp::kRepeatedValueFieldNumber;
  6015. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  6016. TestTimestamp::TestTimestamp()
  6017. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  6018. ::google::protobuf::internal::InitSCC(
  6019. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestTimestamp.base);
  6020. SharedCtor();
  6021. // @@protoc_insertion_point(constructor:proto3.TestTimestamp)
  6022. }
  6023. TestTimestamp::TestTimestamp(const TestTimestamp& from)
  6024. : ::google::protobuf::Message(),
  6025. _internal_metadata_(NULL),
  6026. repeated_value_(from.repeated_value_) {
  6027. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6028. if (from.has_value()) {
  6029. value_ = new ::google::protobuf::Timestamp(*from.value_);
  6030. } else {
  6031. value_ = NULL;
  6032. }
  6033. // @@protoc_insertion_point(copy_constructor:proto3.TestTimestamp)
  6034. }
  6035. void TestTimestamp::SharedCtor() {
  6036. value_ = NULL;
  6037. }
  6038. TestTimestamp::~TestTimestamp() {
  6039. // @@protoc_insertion_point(destructor:proto3.TestTimestamp)
  6040. SharedDtor();
  6041. }
  6042. void TestTimestamp::SharedDtor() {
  6043. if (this != internal_default_instance()) delete value_;
  6044. }
  6045. void TestTimestamp::SetCachedSize(int size) const {
  6046. _cached_size_.Set(size);
  6047. }
  6048. const ::google::protobuf::Descriptor* TestTimestamp::descriptor() {
  6049. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6050. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  6051. }
  6052. const TestTimestamp& TestTimestamp::default_instance() {
  6053. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestTimestamp.base);
  6054. return *internal_default_instance();
  6055. }
  6056. void TestTimestamp::Clear() {
  6057. // @@protoc_insertion_point(message_clear_start:proto3.TestTimestamp)
  6058. ::google::protobuf::uint32 cached_has_bits = 0;
  6059. // Prevent compiler warnings about cached_has_bits being unused
  6060. (void) cached_has_bits;
  6061. repeated_value_.Clear();
  6062. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6063. delete value_;
  6064. }
  6065. value_ = NULL;
  6066. _internal_metadata_.Clear();
  6067. }
  6068. bool TestTimestamp::MergePartialFromCodedStream(
  6069. ::google::protobuf::io::CodedInputStream* input) {
  6070. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  6071. ::google::protobuf::uint32 tag;
  6072. // @@protoc_insertion_point(parse_start:proto3.TestTimestamp)
  6073. for (;;) {
  6074. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  6075. tag = p.first;
  6076. if (!p.second) goto handle_unusual;
  6077. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  6078. // .google.protobuf.Timestamp value = 1;
  6079. case 1: {
  6080. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6081. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  6082. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6083. input, mutable_value()));
  6084. } else {
  6085. goto handle_unusual;
  6086. }
  6087. break;
  6088. }
  6089. // repeated .google.protobuf.Timestamp repeated_value = 2;
  6090. case 2: {
  6091. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6092. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  6093. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6094. input, add_repeated_value()));
  6095. } else {
  6096. goto handle_unusual;
  6097. }
  6098. break;
  6099. }
  6100. default: {
  6101. handle_unusual:
  6102. if (tag == 0) {
  6103. goto success;
  6104. }
  6105. DO_(::google::protobuf::internal::WireFormat::SkipField(
  6106. input, tag, _internal_metadata_.mutable_unknown_fields()));
  6107. break;
  6108. }
  6109. }
  6110. }
  6111. success:
  6112. // @@protoc_insertion_point(parse_success:proto3.TestTimestamp)
  6113. return true;
  6114. failure:
  6115. // @@protoc_insertion_point(parse_failure:proto3.TestTimestamp)
  6116. return false;
  6117. #undef DO_
  6118. }
  6119. void TestTimestamp::SerializeWithCachedSizes(
  6120. ::google::protobuf::io::CodedOutputStream* output) const {
  6121. // @@protoc_insertion_point(serialize_start:proto3.TestTimestamp)
  6122. ::google::protobuf::uint32 cached_has_bits = 0;
  6123. (void) cached_has_bits;
  6124. // .google.protobuf.Timestamp value = 1;
  6125. if (this->has_value()) {
  6126. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6127. 1, this->_internal_value(), output);
  6128. }
  6129. // repeated .google.protobuf.Timestamp repeated_value = 2;
  6130. for (unsigned int i = 0,
  6131. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6132. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6133. 2,
  6134. this->repeated_value(static_cast<int>(i)),
  6135. output);
  6136. }
  6137. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6138. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  6139. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  6140. }
  6141. // @@protoc_insertion_point(serialize_end:proto3.TestTimestamp)
  6142. }
  6143. ::google::protobuf::uint8* TestTimestamp::InternalSerializeWithCachedSizesToArray(
  6144. bool deterministic, ::google::protobuf::uint8* target) const {
  6145. (void)deterministic; // Unused
  6146. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestTimestamp)
  6147. ::google::protobuf::uint32 cached_has_bits = 0;
  6148. (void) cached_has_bits;
  6149. // .google.protobuf.Timestamp value = 1;
  6150. if (this->has_value()) {
  6151. target = ::google::protobuf::internal::WireFormatLite::
  6152. InternalWriteMessageToArray(
  6153. 1, this->_internal_value(), deterministic, target);
  6154. }
  6155. // repeated .google.protobuf.Timestamp repeated_value = 2;
  6156. for (unsigned int i = 0,
  6157. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6158. target = ::google::protobuf::internal::WireFormatLite::
  6159. InternalWriteMessageToArray(
  6160. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  6161. }
  6162. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6163. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  6164. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  6165. }
  6166. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestTimestamp)
  6167. return target;
  6168. }
  6169. size_t TestTimestamp::ByteSizeLong() const {
  6170. // @@protoc_insertion_point(message_byte_size_start:proto3.TestTimestamp)
  6171. size_t total_size = 0;
  6172. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6173. total_size +=
  6174. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  6175. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  6176. }
  6177. // repeated .google.protobuf.Timestamp repeated_value = 2;
  6178. {
  6179. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  6180. total_size += 1UL * count;
  6181. for (unsigned int i = 0; i < count; i++) {
  6182. total_size +=
  6183. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6184. this->repeated_value(static_cast<int>(i)));
  6185. }
  6186. }
  6187. // .google.protobuf.Timestamp value = 1;
  6188. if (this->has_value()) {
  6189. total_size += 1 +
  6190. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6191. *value_);
  6192. }
  6193. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  6194. SetCachedSize(cached_size);
  6195. return total_size;
  6196. }
  6197. void TestTimestamp::MergeFrom(const ::google::protobuf::Message& from) {
  6198. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestTimestamp)
  6199. GOOGLE_DCHECK_NE(&from, this);
  6200. const TestTimestamp* source =
  6201. ::google::protobuf::internal::DynamicCastToGenerated<const TestTimestamp>(
  6202. &from);
  6203. if (source == NULL) {
  6204. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestTimestamp)
  6205. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  6206. } else {
  6207. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestTimestamp)
  6208. MergeFrom(*source);
  6209. }
  6210. }
  6211. void TestTimestamp::MergeFrom(const TestTimestamp& from) {
  6212. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestTimestamp)
  6213. GOOGLE_DCHECK_NE(&from, this);
  6214. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6215. ::google::protobuf::uint32 cached_has_bits = 0;
  6216. (void) cached_has_bits;
  6217. repeated_value_.MergeFrom(from.repeated_value_);
  6218. if (from.has_value()) {
  6219. mutable_value()->::google::protobuf::Timestamp::MergeFrom(from.value());
  6220. }
  6221. }
  6222. void TestTimestamp::CopyFrom(const ::google::protobuf::Message& from) {
  6223. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestTimestamp)
  6224. if (&from == this) return;
  6225. Clear();
  6226. MergeFrom(from);
  6227. }
  6228. void TestTimestamp::CopyFrom(const TestTimestamp& from) {
  6229. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestTimestamp)
  6230. if (&from == this) return;
  6231. Clear();
  6232. MergeFrom(from);
  6233. }
  6234. bool TestTimestamp::IsInitialized() const {
  6235. return true;
  6236. }
  6237. void TestTimestamp::Swap(TestTimestamp* other) {
  6238. if (other == this) return;
  6239. InternalSwap(other);
  6240. }
  6241. void TestTimestamp::InternalSwap(TestTimestamp* other) {
  6242. using std::swap;
  6243. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  6244. swap(value_, other->value_);
  6245. _internal_metadata_.Swap(&other->_internal_metadata_);
  6246. }
  6247. ::google::protobuf::Metadata TestTimestamp::GetMetadata() const {
  6248. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6249. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  6250. }
  6251. // ===================================================================
  6252. void TestDuration::InitAsDefaultInstance() {
  6253. ::proto3::_TestDuration_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::Duration*>(
  6254. ::google::protobuf::Duration::internal_default_instance());
  6255. }
  6256. void TestDuration::clear_value() {
  6257. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6258. delete value_;
  6259. }
  6260. value_ = NULL;
  6261. }
  6262. void TestDuration::clear_repeated_value() {
  6263. repeated_value_.Clear();
  6264. }
  6265. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  6266. const int TestDuration::kValueFieldNumber;
  6267. const int TestDuration::kRepeatedValueFieldNumber;
  6268. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  6269. TestDuration::TestDuration()
  6270. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  6271. ::google::protobuf::internal::InitSCC(
  6272. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestDuration.base);
  6273. SharedCtor();
  6274. // @@protoc_insertion_point(constructor:proto3.TestDuration)
  6275. }
  6276. TestDuration::TestDuration(const TestDuration& from)
  6277. : ::google::protobuf::Message(),
  6278. _internal_metadata_(NULL),
  6279. repeated_value_(from.repeated_value_) {
  6280. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6281. if (from.has_value()) {
  6282. value_ = new ::google::protobuf::Duration(*from.value_);
  6283. } else {
  6284. value_ = NULL;
  6285. }
  6286. // @@protoc_insertion_point(copy_constructor:proto3.TestDuration)
  6287. }
  6288. void TestDuration::SharedCtor() {
  6289. value_ = NULL;
  6290. }
  6291. TestDuration::~TestDuration() {
  6292. // @@protoc_insertion_point(destructor:proto3.TestDuration)
  6293. SharedDtor();
  6294. }
  6295. void TestDuration::SharedDtor() {
  6296. if (this != internal_default_instance()) delete value_;
  6297. }
  6298. void TestDuration::SetCachedSize(int size) const {
  6299. _cached_size_.Set(size);
  6300. }
  6301. const ::google::protobuf::Descriptor* TestDuration::descriptor() {
  6302. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6303. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  6304. }
  6305. const TestDuration& TestDuration::default_instance() {
  6306. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestDuration.base);
  6307. return *internal_default_instance();
  6308. }
  6309. void TestDuration::Clear() {
  6310. // @@protoc_insertion_point(message_clear_start:proto3.TestDuration)
  6311. ::google::protobuf::uint32 cached_has_bits = 0;
  6312. // Prevent compiler warnings about cached_has_bits being unused
  6313. (void) cached_has_bits;
  6314. repeated_value_.Clear();
  6315. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6316. delete value_;
  6317. }
  6318. value_ = NULL;
  6319. _internal_metadata_.Clear();
  6320. }
  6321. bool TestDuration::MergePartialFromCodedStream(
  6322. ::google::protobuf::io::CodedInputStream* input) {
  6323. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  6324. ::google::protobuf::uint32 tag;
  6325. // @@protoc_insertion_point(parse_start:proto3.TestDuration)
  6326. for (;;) {
  6327. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  6328. tag = p.first;
  6329. if (!p.second) goto handle_unusual;
  6330. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  6331. // .google.protobuf.Duration value = 1;
  6332. case 1: {
  6333. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6334. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  6335. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6336. input, mutable_value()));
  6337. } else {
  6338. goto handle_unusual;
  6339. }
  6340. break;
  6341. }
  6342. // repeated .google.protobuf.Duration repeated_value = 2;
  6343. case 2: {
  6344. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6345. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  6346. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6347. input, add_repeated_value()));
  6348. } else {
  6349. goto handle_unusual;
  6350. }
  6351. break;
  6352. }
  6353. default: {
  6354. handle_unusual:
  6355. if (tag == 0) {
  6356. goto success;
  6357. }
  6358. DO_(::google::protobuf::internal::WireFormat::SkipField(
  6359. input, tag, _internal_metadata_.mutable_unknown_fields()));
  6360. break;
  6361. }
  6362. }
  6363. }
  6364. success:
  6365. // @@protoc_insertion_point(parse_success:proto3.TestDuration)
  6366. return true;
  6367. failure:
  6368. // @@protoc_insertion_point(parse_failure:proto3.TestDuration)
  6369. return false;
  6370. #undef DO_
  6371. }
  6372. void TestDuration::SerializeWithCachedSizes(
  6373. ::google::protobuf::io::CodedOutputStream* output) const {
  6374. // @@protoc_insertion_point(serialize_start:proto3.TestDuration)
  6375. ::google::protobuf::uint32 cached_has_bits = 0;
  6376. (void) cached_has_bits;
  6377. // .google.protobuf.Duration value = 1;
  6378. if (this->has_value()) {
  6379. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6380. 1, this->_internal_value(), output);
  6381. }
  6382. // repeated .google.protobuf.Duration repeated_value = 2;
  6383. for (unsigned int i = 0,
  6384. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6385. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6386. 2,
  6387. this->repeated_value(static_cast<int>(i)),
  6388. output);
  6389. }
  6390. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6391. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  6392. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  6393. }
  6394. // @@protoc_insertion_point(serialize_end:proto3.TestDuration)
  6395. }
  6396. ::google::protobuf::uint8* TestDuration::InternalSerializeWithCachedSizesToArray(
  6397. bool deterministic, ::google::protobuf::uint8* target) const {
  6398. (void)deterministic; // Unused
  6399. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestDuration)
  6400. ::google::protobuf::uint32 cached_has_bits = 0;
  6401. (void) cached_has_bits;
  6402. // .google.protobuf.Duration value = 1;
  6403. if (this->has_value()) {
  6404. target = ::google::protobuf::internal::WireFormatLite::
  6405. InternalWriteMessageToArray(
  6406. 1, this->_internal_value(), deterministic, target);
  6407. }
  6408. // repeated .google.protobuf.Duration repeated_value = 2;
  6409. for (unsigned int i = 0,
  6410. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6411. target = ::google::protobuf::internal::WireFormatLite::
  6412. InternalWriteMessageToArray(
  6413. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  6414. }
  6415. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6416. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  6417. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  6418. }
  6419. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestDuration)
  6420. return target;
  6421. }
  6422. size_t TestDuration::ByteSizeLong() const {
  6423. // @@protoc_insertion_point(message_byte_size_start:proto3.TestDuration)
  6424. size_t total_size = 0;
  6425. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6426. total_size +=
  6427. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  6428. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  6429. }
  6430. // repeated .google.protobuf.Duration repeated_value = 2;
  6431. {
  6432. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  6433. total_size += 1UL * count;
  6434. for (unsigned int i = 0; i < count; i++) {
  6435. total_size +=
  6436. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6437. this->repeated_value(static_cast<int>(i)));
  6438. }
  6439. }
  6440. // .google.protobuf.Duration value = 1;
  6441. if (this->has_value()) {
  6442. total_size += 1 +
  6443. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6444. *value_);
  6445. }
  6446. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  6447. SetCachedSize(cached_size);
  6448. return total_size;
  6449. }
  6450. void TestDuration::MergeFrom(const ::google::protobuf::Message& from) {
  6451. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestDuration)
  6452. GOOGLE_DCHECK_NE(&from, this);
  6453. const TestDuration* source =
  6454. ::google::protobuf::internal::DynamicCastToGenerated<const TestDuration>(
  6455. &from);
  6456. if (source == NULL) {
  6457. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestDuration)
  6458. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  6459. } else {
  6460. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestDuration)
  6461. MergeFrom(*source);
  6462. }
  6463. }
  6464. void TestDuration::MergeFrom(const TestDuration& from) {
  6465. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestDuration)
  6466. GOOGLE_DCHECK_NE(&from, this);
  6467. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6468. ::google::protobuf::uint32 cached_has_bits = 0;
  6469. (void) cached_has_bits;
  6470. repeated_value_.MergeFrom(from.repeated_value_);
  6471. if (from.has_value()) {
  6472. mutable_value()->::google::protobuf::Duration::MergeFrom(from.value());
  6473. }
  6474. }
  6475. void TestDuration::CopyFrom(const ::google::protobuf::Message& from) {
  6476. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestDuration)
  6477. if (&from == this) return;
  6478. Clear();
  6479. MergeFrom(from);
  6480. }
  6481. void TestDuration::CopyFrom(const TestDuration& from) {
  6482. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestDuration)
  6483. if (&from == this) return;
  6484. Clear();
  6485. MergeFrom(from);
  6486. }
  6487. bool TestDuration::IsInitialized() const {
  6488. return true;
  6489. }
  6490. void TestDuration::Swap(TestDuration* other) {
  6491. if (other == this) return;
  6492. InternalSwap(other);
  6493. }
  6494. void TestDuration::InternalSwap(TestDuration* other) {
  6495. using std::swap;
  6496. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  6497. swap(value_, other->value_);
  6498. _internal_metadata_.Swap(&other->_internal_metadata_);
  6499. }
  6500. ::google::protobuf::Metadata TestDuration::GetMetadata() const {
  6501. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6502. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  6503. }
  6504. // ===================================================================
  6505. void TestFieldMask::InitAsDefaultInstance() {
  6506. ::proto3::_TestFieldMask_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::FieldMask*>(
  6507. ::google::protobuf::FieldMask::internal_default_instance());
  6508. }
  6509. void TestFieldMask::clear_value() {
  6510. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6511. delete value_;
  6512. }
  6513. value_ = NULL;
  6514. }
  6515. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  6516. const int TestFieldMask::kValueFieldNumber;
  6517. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  6518. TestFieldMask::TestFieldMask()
  6519. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  6520. ::google::protobuf::internal::InitSCC(
  6521. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestFieldMask.base);
  6522. SharedCtor();
  6523. // @@protoc_insertion_point(constructor:proto3.TestFieldMask)
  6524. }
  6525. TestFieldMask::TestFieldMask(const TestFieldMask& from)
  6526. : ::google::protobuf::Message(),
  6527. _internal_metadata_(NULL) {
  6528. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6529. if (from.has_value()) {
  6530. value_ = new ::google::protobuf::FieldMask(*from.value_);
  6531. } else {
  6532. value_ = NULL;
  6533. }
  6534. // @@protoc_insertion_point(copy_constructor:proto3.TestFieldMask)
  6535. }
  6536. void TestFieldMask::SharedCtor() {
  6537. value_ = NULL;
  6538. }
  6539. TestFieldMask::~TestFieldMask() {
  6540. // @@protoc_insertion_point(destructor:proto3.TestFieldMask)
  6541. SharedDtor();
  6542. }
  6543. void TestFieldMask::SharedDtor() {
  6544. if (this != internal_default_instance()) delete value_;
  6545. }
  6546. void TestFieldMask::SetCachedSize(int size) const {
  6547. _cached_size_.Set(size);
  6548. }
  6549. const ::google::protobuf::Descriptor* TestFieldMask::descriptor() {
  6550. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6551. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  6552. }
  6553. const TestFieldMask& TestFieldMask::default_instance() {
  6554. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestFieldMask.base);
  6555. return *internal_default_instance();
  6556. }
  6557. void TestFieldMask::Clear() {
  6558. // @@protoc_insertion_point(message_clear_start:proto3.TestFieldMask)
  6559. ::google::protobuf::uint32 cached_has_bits = 0;
  6560. // Prevent compiler warnings about cached_has_bits being unused
  6561. (void) cached_has_bits;
  6562. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6563. delete value_;
  6564. }
  6565. value_ = NULL;
  6566. _internal_metadata_.Clear();
  6567. }
  6568. bool TestFieldMask::MergePartialFromCodedStream(
  6569. ::google::protobuf::io::CodedInputStream* input) {
  6570. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  6571. ::google::protobuf::uint32 tag;
  6572. // @@protoc_insertion_point(parse_start:proto3.TestFieldMask)
  6573. for (;;) {
  6574. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  6575. tag = p.first;
  6576. if (!p.second) goto handle_unusual;
  6577. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  6578. // .google.protobuf.FieldMask value = 1;
  6579. case 1: {
  6580. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6581. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  6582. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6583. input, mutable_value()));
  6584. } else {
  6585. goto handle_unusual;
  6586. }
  6587. break;
  6588. }
  6589. default: {
  6590. handle_unusual:
  6591. if (tag == 0) {
  6592. goto success;
  6593. }
  6594. DO_(::google::protobuf::internal::WireFormat::SkipField(
  6595. input, tag, _internal_metadata_.mutable_unknown_fields()));
  6596. break;
  6597. }
  6598. }
  6599. }
  6600. success:
  6601. // @@protoc_insertion_point(parse_success:proto3.TestFieldMask)
  6602. return true;
  6603. failure:
  6604. // @@protoc_insertion_point(parse_failure:proto3.TestFieldMask)
  6605. return false;
  6606. #undef DO_
  6607. }
  6608. void TestFieldMask::SerializeWithCachedSizes(
  6609. ::google::protobuf::io::CodedOutputStream* output) const {
  6610. // @@protoc_insertion_point(serialize_start:proto3.TestFieldMask)
  6611. ::google::protobuf::uint32 cached_has_bits = 0;
  6612. (void) cached_has_bits;
  6613. // .google.protobuf.FieldMask value = 1;
  6614. if (this->has_value()) {
  6615. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6616. 1, this->_internal_value(), output);
  6617. }
  6618. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6619. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  6620. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  6621. }
  6622. // @@protoc_insertion_point(serialize_end:proto3.TestFieldMask)
  6623. }
  6624. ::google::protobuf::uint8* TestFieldMask::InternalSerializeWithCachedSizesToArray(
  6625. bool deterministic, ::google::protobuf::uint8* target) const {
  6626. (void)deterministic; // Unused
  6627. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestFieldMask)
  6628. ::google::protobuf::uint32 cached_has_bits = 0;
  6629. (void) cached_has_bits;
  6630. // .google.protobuf.FieldMask value = 1;
  6631. if (this->has_value()) {
  6632. target = ::google::protobuf::internal::WireFormatLite::
  6633. InternalWriteMessageToArray(
  6634. 1, this->_internal_value(), deterministic, target);
  6635. }
  6636. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6637. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  6638. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  6639. }
  6640. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestFieldMask)
  6641. return target;
  6642. }
  6643. size_t TestFieldMask::ByteSizeLong() const {
  6644. // @@protoc_insertion_point(message_byte_size_start:proto3.TestFieldMask)
  6645. size_t total_size = 0;
  6646. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6647. total_size +=
  6648. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  6649. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  6650. }
  6651. // .google.protobuf.FieldMask value = 1;
  6652. if (this->has_value()) {
  6653. total_size += 1 +
  6654. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6655. *value_);
  6656. }
  6657. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  6658. SetCachedSize(cached_size);
  6659. return total_size;
  6660. }
  6661. void TestFieldMask::MergeFrom(const ::google::protobuf::Message& from) {
  6662. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestFieldMask)
  6663. GOOGLE_DCHECK_NE(&from, this);
  6664. const TestFieldMask* source =
  6665. ::google::protobuf::internal::DynamicCastToGenerated<const TestFieldMask>(
  6666. &from);
  6667. if (source == NULL) {
  6668. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestFieldMask)
  6669. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  6670. } else {
  6671. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestFieldMask)
  6672. MergeFrom(*source);
  6673. }
  6674. }
  6675. void TestFieldMask::MergeFrom(const TestFieldMask& from) {
  6676. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestFieldMask)
  6677. GOOGLE_DCHECK_NE(&from, this);
  6678. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6679. ::google::protobuf::uint32 cached_has_bits = 0;
  6680. (void) cached_has_bits;
  6681. if (from.has_value()) {
  6682. mutable_value()->::google::protobuf::FieldMask::MergeFrom(from.value());
  6683. }
  6684. }
  6685. void TestFieldMask::CopyFrom(const ::google::protobuf::Message& from) {
  6686. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestFieldMask)
  6687. if (&from == this) return;
  6688. Clear();
  6689. MergeFrom(from);
  6690. }
  6691. void TestFieldMask::CopyFrom(const TestFieldMask& from) {
  6692. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestFieldMask)
  6693. if (&from == this) return;
  6694. Clear();
  6695. MergeFrom(from);
  6696. }
  6697. bool TestFieldMask::IsInitialized() const {
  6698. return true;
  6699. }
  6700. void TestFieldMask::Swap(TestFieldMask* other) {
  6701. if (other == this) return;
  6702. InternalSwap(other);
  6703. }
  6704. void TestFieldMask::InternalSwap(TestFieldMask* other) {
  6705. using std::swap;
  6706. swap(value_, other->value_);
  6707. _internal_metadata_.Swap(&other->_internal_metadata_);
  6708. }
  6709. ::google::protobuf::Metadata TestFieldMask::GetMetadata() const {
  6710. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6711. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  6712. }
  6713. // ===================================================================
  6714. void TestStruct::InitAsDefaultInstance() {
  6715. ::proto3::_TestStruct_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::Struct*>(
  6716. ::google::protobuf::Struct::internal_default_instance());
  6717. }
  6718. void TestStruct::clear_value() {
  6719. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6720. delete value_;
  6721. }
  6722. value_ = NULL;
  6723. }
  6724. void TestStruct::clear_repeated_value() {
  6725. repeated_value_.Clear();
  6726. }
  6727. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  6728. const int TestStruct::kValueFieldNumber;
  6729. const int TestStruct::kRepeatedValueFieldNumber;
  6730. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  6731. TestStruct::TestStruct()
  6732. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  6733. ::google::protobuf::internal::InitSCC(
  6734. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestStruct.base);
  6735. SharedCtor();
  6736. // @@protoc_insertion_point(constructor:proto3.TestStruct)
  6737. }
  6738. TestStruct::TestStruct(const TestStruct& from)
  6739. : ::google::protobuf::Message(),
  6740. _internal_metadata_(NULL),
  6741. repeated_value_(from.repeated_value_) {
  6742. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6743. if (from.has_value()) {
  6744. value_ = new ::google::protobuf::Struct(*from.value_);
  6745. } else {
  6746. value_ = NULL;
  6747. }
  6748. // @@protoc_insertion_point(copy_constructor:proto3.TestStruct)
  6749. }
  6750. void TestStruct::SharedCtor() {
  6751. value_ = NULL;
  6752. }
  6753. TestStruct::~TestStruct() {
  6754. // @@protoc_insertion_point(destructor:proto3.TestStruct)
  6755. SharedDtor();
  6756. }
  6757. void TestStruct::SharedDtor() {
  6758. if (this != internal_default_instance()) delete value_;
  6759. }
  6760. void TestStruct::SetCachedSize(int size) const {
  6761. _cached_size_.Set(size);
  6762. }
  6763. const ::google::protobuf::Descriptor* TestStruct::descriptor() {
  6764. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6765. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  6766. }
  6767. const TestStruct& TestStruct::default_instance() {
  6768. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestStruct.base);
  6769. return *internal_default_instance();
  6770. }
  6771. void TestStruct::Clear() {
  6772. // @@protoc_insertion_point(message_clear_start:proto3.TestStruct)
  6773. ::google::protobuf::uint32 cached_has_bits = 0;
  6774. // Prevent compiler warnings about cached_has_bits being unused
  6775. (void) cached_has_bits;
  6776. repeated_value_.Clear();
  6777. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6778. delete value_;
  6779. }
  6780. value_ = NULL;
  6781. _internal_metadata_.Clear();
  6782. }
  6783. bool TestStruct::MergePartialFromCodedStream(
  6784. ::google::protobuf::io::CodedInputStream* input) {
  6785. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  6786. ::google::protobuf::uint32 tag;
  6787. // @@protoc_insertion_point(parse_start:proto3.TestStruct)
  6788. for (;;) {
  6789. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  6790. tag = p.first;
  6791. if (!p.second) goto handle_unusual;
  6792. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  6793. // .google.protobuf.Struct value = 1;
  6794. case 1: {
  6795. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6796. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  6797. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6798. input, mutable_value()));
  6799. } else {
  6800. goto handle_unusual;
  6801. }
  6802. break;
  6803. }
  6804. // repeated .google.protobuf.Struct repeated_value = 2;
  6805. case 2: {
  6806. if (static_cast< ::google::protobuf::uint8>(tag) ==
  6807. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  6808. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  6809. input, add_repeated_value()));
  6810. } else {
  6811. goto handle_unusual;
  6812. }
  6813. break;
  6814. }
  6815. default: {
  6816. handle_unusual:
  6817. if (tag == 0) {
  6818. goto success;
  6819. }
  6820. DO_(::google::protobuf::internal::WireFormat::SkipField(
  6821. input, tag, _internal_metadata_.mutable_unknown_fields()));
  6822. break;
  6823. }
  6824. }
  6825. }
  6826. success:
  6827. // @@protoc_insertion_point(parse_success:proto3.TestStruct)
  6828. return true;
  6829. failure:
  6830. // @@protoc_insertion_point(parse_failure:proto3.TestStruct)
  6831. return false;
  6832. #undef DO_
  6833. }
  6834. void TestStruct::SerializeWithCachedSizes(
  6835. ::google::protobuf::io::CodedOutputStream* output) const {
  6836. // @@protoc_insertion_point(serialize_start:proto3.TestStruct)
  6837. ::google::protobuf::uint32 cached_has_bits = 0;
  6838. (void) cached_has_bits;
  6839. // .google.protobuf.Struct value = 1;
  6840. if (this->has_value()) {
  6841. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6842. 1, this->_internal_value(), output);
  6843. }
  6844. // repeated .google.protobuf.Struct repeated_value = 2;
  6845. for (unsigned int i = 0,
  6846. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6847. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  6848. 2,
  6849. this->repeated_value(static_cast<int>(i)),
  6850. output);
  6851. }
  6852. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6853. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  6854. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  6855. }
  6856. // @@protoc_insertion_point(serialize_end:proto3.TestStruct)
  6857. }
  6858. ::google::protobuf::uint8* TestStruct::InternalSerializeWithCachedSizesToArray(
  6859. bool deterministic, ::google::protobuf::uint8* target) const {
  6860. (void)deterministic; // Unused
  6861. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestStruct)
  6862. ::google::protobuf::uint32 cached_has_bits = 0;
  6863. (void) cached_has_bits;
  6864. // .google.protobuf.Struct value = 1;
  6865. if (this->has_value()) {
  6866. target = ::google::protobuf::internal::WireFormatLite::
  6867. InternalWriteMessageToArray(
  6868. 1, this->_internal_value(), deterministic, target);
  6869. }
  6870. // repeated .google.protobuf.Struct repeated_value = 2;
  6871. for (unsigned int i = 0,
  6872. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  6873. target = ::google::protobuf::internal::WireFormatLite::
  6874. InternalWriteMessageToArray(
  6875. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  6876. }
  6877. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6878. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  6879. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  6880. }
  6881. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestStruct)
  6882. return target;
  6883. }
  6884. size_t TestStruct::ByteSizeLong() const {
  6885. // @@protoc_insertion_point(message_byte_size_start:proto3.TestStruct)
  6886. size_t total_size = 0;
  6887. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  6888. total_size +=
  6889. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  6890. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  6891. }
  6892. // repeated .google.protobuf.Struct repeated_value = 2;
  6893. {
  6894. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  6895. total_size += 1UL * count;
  6896. for (unsigned int i = 0; i < count; i++) {
  6897. total_size +=
  6898. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6899. this->repeated_value(static_cast<int>(i)));
  6900. }
  6901. }
  6902. // .google.protobuf.Struct value = 1;
  6903. if (this->has_value()) {
  6904. total_size += 1 +
  6905. ::google::protobuf::internal::WireFormatLite::MessageSize(
  6906. *value_);
  6907. }
  6908. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  6909. SetCachedSize(cached_size);
  6910. return total_size;
  6911. }
  6912. void TestStruct::MergeFrom(const ::google::protobuf::Message& from) {
  6913. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestStruct)
  6914. GOOGLE_DCHECK_NE(&from, this);
  6915. const TestStruct* source =
  6916. ::google::protobuf::internal::DynamicCastToGenerated<const TestStruct>(
  6917. &from);
  6918. if (source == NULL) {
  6919. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestStruct)
  6920. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  6921. } else {
  6922. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestStruct)
  6923. MergeFrom(*source);
  6924. }
  6925. }
  6926. void TestStruct::MergeFrom(const TestStruct& from) {
  6927. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestStruct)
  6928. GOOGLE_DCHECK_NE(&from, this);
  6929. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6930. ::google::protobuf::uint32 cached_has_bits = 0;
  6931. (void) cached_has_bits;
  6932. repeated_value_.MergeFrom(from.repeated_value_);
  6933. if (from.has_value()) {
  6934. mutable_value()->::google::protobuf::Struct::MergeFrom(from.value());
  6935. }
  6936. }
  6937. void TestStruct::CopyFrom(const ::google::protobuf::Message& from) {
  6938. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestStruct)
  6939. if (&from == this) return;
  6940. Clear();
  6941. MergeFrom(from);
  6942. }
  6943. void TestStruct::CopyFrom(const TestStruct& from) {
  6944. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestStruct)
  6945. if (&from == this) return;
  6946. Clear();
  6947. MergeFrom(from);
  6948. }
  6949. bool TestStruct::IsInitialized() const {
  6950. return true;
  6951. }
  6952. void TestStruct::Swap(TestStruct* other) {
  6953. if (other == this) return;
  6954. InternalSwap(other);
  6955. }
  6956. void TestStruct::InternalSwap(TestStruct* other) {
  6957. using std::swap;
  6958. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  6959. swap(value_, other->value_);
  6960. _internal_metadata_.Swap(&other->_internal_metadata_);
  6961. }
  6962. ::google::protobuf::Metadata TestStruct::GetMetadata() const {
  6963. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  6964. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  6965. }
  6966. // ===================================================================
  6967. void TestAny::InitAsDefaultInstance() {
  6968. ::proto3::_TestAny_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::Any*>(
  6969. ::google::protobuf::Any::internal_default_instance());
  6970. }
  6971. void TestAny::clear_value() {
  6972. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  6973. delete value_;
  6974. }
  6975. value_ = NULL;
  6976. }
  6977. void TestAny::clear_repeated_value() {
  6978. repeated_value_.Clear();
  6979. }
  6980. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  6981. const int TestAny::kValueFieldNumber;
  6982. const int TestAny::kRepeatedValueFieldNumber;
  6983. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  6984. TestAny::TestAny()
  6985. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  6986. ::google::protobuf::internal::InitSCC(
  6987. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestAny.base);
  6988. SharedCtor();
  6989. // @@protoc_insertion_point(constructor:proto3.TestAny)
  6990. }
  6991. TestAny::TestAny(const TestAny& from)
  6992. : ::google::protobuf::Message(),
  6993. _internal_metadata_(NULL),
  6994. repeated_value_(from.repeated_value_) {
  6995. _internal_metadata_.MergeFrom(from._internal_metadata_);
  6996. if (from.has_value()) {
  6997. value_ = new ::google::protobuf::Any(*from.value_);
  6998. } else {
  6999. value_ = NULL;
  7000. }
  7001. // @@protoc_insertion_point(copy_constructor:proto3.TestAny)
  7002. }
  7003. void TestAny::SharedCtor() {
  7004. value_ = NULL;
  7005. }
  7006. TestAny::~TestAny() {
  7007. // @@protoc_insertion_point(destructor:proto3.TestAny)
  7008. SharedDtor();
  7009. }
  7010. void TestAny::SharedDtor() {
  7011. if (this != internal_default_instance()) delete value_;
  7012. }
  7013. void TestAny::SetCachedSize(int size) const {
  7014. _cached_size_.Set(size);
  7015. }
  7016. const ::google::protobuf::Descriptor* TestAny::descriptor() {
  7017. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7018. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  7019. }
  7020. const TestAny& TestAny::default_instance() {
  7021. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestAny.base);
  7022. return *internal_default_instance();
  7023. }
  7024. void TestAny::Clear() {
  7025. // @@protoc_insertion_point(message_clear_start:proto3.TestAny)
  7026. ::google::protobuf::uint32 cached_has_bits = 0;
  7027. // Prevent compiler warnings about cached_has_bits being unused
  7028. (void) cached_has_bits;
  7029. repeated_value_.Clear();
  7030. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  7031. delete value_;
  7032. }
  7033. value_ = NULL;
  7034. _internal_metadata_.Clear();
  7035. }
  7036. bool TestAny::MergePartialFromCodedStream(
  7037. ::google::protobuf::io::CodedInputStream* input) {
  7038. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  7039. ::google::protobuf::uint32 tag;
  7040. // @@protoc_insertion_point(parse_start:proto3.TestAny)
  7041. for (;;) {
  7042. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  7043. tag = p.first;
  7044. if (!p.second) goto handle_unusual;
  7045. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  7046. // .google.protobuf.Any value = 1;
  7047. case 1: {
  7048. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7049. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  7050. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7051. input, mutable_value()));
  7052. } else {
  7053. goto handle_unusual;
  7054. }
  7055. break;
  7056. }
  7057. // repeated .google.protobuf.Any repeated_value = 2;
  7058. case 2: {
  7059. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7060. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  7061. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7062. input, add_repeated_value()));
  7063. } else {
  7064. goto handle_unusual;
  7065. }
  7066. break;
  7067. }
  7068. default: {
  7069. handle_unusual:
  7070. if (tag == 0) {
  7071. goto success;
  7072. }
  7073. DO_(::google::protobuf::internal::WireFormat::SkipField(
  7074. input, tag, _internal_metadata_.mutable_unknown_fields()));
  7075. break;
  7076. }
  7077. }
  7078. }
  7079. success:
  7080. // @@protoc_insertion_point(parse_success:proto3.TestAny)
  7081. return true;
  7082. failure:
  7083. // @@protoc_insertion_point(parse_failure:proto3.TestAny)
  7084. return false;
  7085. #undef DO_
  7086. }
  7087. void TestAny::SerializeWithCachedSizes(
  7088. ::google::protobuf::io::CodedOutputStream* output) const {
  7089. // @@protoc_insertion_point(serialize_start:proto3.TestAny)
  7090. ::google::protobuf::uint32 cached_has_bits = 0;
  7091. (void) cached_has_bits;
  7092. // .google.protobuf.Any value = 1;
  7093. if (this->has_value()) {
  7094. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7095. 1, this->_internal_value(), output);
  7096. }
  7097. // repeated .google.protobuf.Any repeated_value = 2;
  7098. for (unsigned int i = 0,
  7099. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7100. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7101. 2,
  7102. this->repeated_value(static_cast<int>(i)),
  7103. output);
  7104. }
  7105. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7106. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  7107. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  7108. }
  7109. // @@protoc_insertion_point(serialize_end:proto3.TestAny)
  7110. }
  7111. ::google::protobuf::uint8* TestAny::InternalSerializeWithCachedSizesToArray(
  7112. bool deterministic, ::google::protobuf::uint8* target) const {
  7113. (void)deterministic; // Unused
  7114. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestAny)
  7115. ::google::protobuf::uint32 cached_has_bits = 0;
  7116. (void) cached_has_bits;
  7117. // .google.protobuf.Any value = 1;
  7118. if (this->has_value()) {
  7119. target = ::google::protobuf::internal::WireFormatLite::
  7120. InternalWriteMessageToArray(
  7121. 1, this->_internal_value(), deterministic, target);
  7122. }
  7123. // repeated .google.protobuf.Any repeated_value = 2;
  7124. for (unsigned int i = 0,
  7125. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7126. target = ::google::protobuf::internal::WireFormatLite::
  7127. InternalWriteMessageToArray(
  7128. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  7129. }
  7130. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7131. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  7132. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  7133. }
  7134. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestAny)
  7135. return target;
  7136. }
  7137. size_t TestAny::ByteSizeLong() const {
  7138. // @@protoc_insertion_point(message_byte_size_start:proto3.TestAny)
  7139. size_t total_size = 0;
  7140. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7141. total_size +=
  7142. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  7143. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  7144. }
  7145. // repeated .google.protobuf.Any repeated_value = 2;
  7146. {
  7147. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  7148. total_size += 1UL * count;
  7149. for (unsigned int i = 0; i < count; i++) {
  7150. total_size +=
  7151. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7152. this->repeated_value(static_cast<int>(i)));
  7153. }
  7154. }
  7155. // .google.protobuf.Any value = 1;
  7156. if (this->has_value()) {
  7157. total_size += 1 +
  7158. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7159. *value_);
  7160. }
  7161. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  7162. SetCachedSize(cached_size);
  7163. return total_size;
  7164. }
  7165. void TestAny::MergeFrom(const ::google::protobuf::Message& from) {
  7166. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestAny)
  7167. GOOGLE_DCHECK_NE(&from, this);
  7168. const TestAny* source =
  7169. ::google::protobuf::internal::DynamicCastToGenerated<const TestAny>(
  7170. &from);
  7171. if (source == NULL) {
  7172. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestAny)
  7173. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  7174. } else {
  7175. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestAny)
  7176. MergeFrom(*source);
  7177. }
  7178. }
  7179. void TestAny::MergeFrom(const TestAny& from) {
  7180. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestAny)
  7181. GOOGLE_DCHECK_NE(&from, this);
  7182. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7183. ::google::protobuf::uint32 cached_has_bits = 0;
  7184. (void) cached_has_bits;
  7185. repeated_value_.MergeFrom(from.repeated_value_);
  7186. if (from.has_value()) {
  7187. mutable_value()->::google::protobuf::Any::MergeFrom(from.value());
  7188. }
  7189. }
  7190. void TestAny::CopyFrom(const ::google::protobuf::Message& from) {
  7191. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestAny)
  7192. if (&from == this) return;
  7193. Clear();
  7194. MergeFrom(from);
  7195. }
  7196. void TestAny::CopyFrom(const TestAny& from) {
  7197. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestAny)
  7198. if (&from == this) return;
  7199. Clear();
  7200. MergeFrom(from);
  7201. }
  7202. bool TestAny::IsInitialized() const {
  7203. return true;
  7204. }
  7205. void TestAny::Swap(TestAny* other) {
  7206. if (other == this) return;
  7207. InternalSwap(other);
  7208. }
  7209. void TestAny::InternalSwap(TestAny* other) {
  7210. using std::swap;
  7211. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  7212. swap(value_, other->value_);
  7213. _internal_metadata_.Swap(&other->_internal_metadata_);
  7214. }
  7215. ::google::protobuf::Metadata TestAny::GetMetadata() const {
  7216. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7217. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  7218. }
  7219. // ===================================================================
  7220. void TestValue::InitAsDefaultInstance() {
  7221. ::proto3::_TestValue_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::Value*>(
  7222. ::google::protobuf::Value::internal_default_instance());
  7223. }
  7224. void TestValue::clear_value() {
  7225. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  7226. delete value_;
  7227. }
  7228. value_ = NULL;
  7229. }
  7230. void TestValue::clear_repeated_value() {
  7231. repeated_value_.Clear();
  7232. }
  7233. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  7234. const int TestValue::kValueFieldNumber;
  7235. const int TestValue::kRepeatedValueFieldNumber;
  7236. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  7237. TestValue::TestValue()
  7238. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  7239. ::google::protobuf::internal::InitSCC(
  7240. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestValue.base);
  7241. SharedCtor();
  7242. // @@protoc_insertion_point(constructor:proto3.TestValue)
  7243. }
  7244. TestValue::TestValue(const TestValue& from)
  7245. : ::google::protobuf::Message(),
  7246. _internal_metadata_(NULL),
  7247. repeated_value_(from.repeated_value_) {
  7248. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7249. if (from.has_value()) {
  7250. value_ = new ::google::protobuf::Value(*from.value_);
  7251. } else {
  7252. value_ = NULL;
  7253. }
  7254. // @@protoc_insertion_point(copy_constructor:proto3.TestValue)
  7255. }
  7256. void TestValue::SharedCtor() {
  7257. value_ = NULL;
  7258. }
  7259. TestValue::~TestValue() {
  7260. // @@protoc_insertion_point(destructor:proto3.TestValue)
  7261. SharedDtor();
  7262. }
  7263. void TestValue::SharedDtor() {
  7264. if (this != internal_default_instance()) delete value_;
  7265. }
  7266. void TestValue::SetCachedSize(int size) const {
  7267. _cached_size_.Set(size);
  7268. }
  7269. const ::google::protobuf::Descriptor* TestValue::descriptor() {
  7270. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7271. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  7272. }
  7273. const TestValue& TestValue::default_instance() {
  7274. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestValue.base);
  7275. return *internal_default_instance();
  7276. }
  7277. void TestValue::Clear() {
  7278. // @@protoc_insertion_point(message_clear_start:proto3.TestValue)
  7279. ::google::protobuf::uint32 cached_has_bits = 0;
  7280. // Prevent compiler warnings about cached_has_bits being unused
  7281. (void) cached_has_bits;
  7282. repeated_value_.Clear();
  7283. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  7284. delete value_;
  7285. }
  7286. value_ = NULL;
  7287. _internal_metadata_.Clear();
  7288. }
  7289. bool TestValue::MergePartialFromCodedStream(
  7290. ::google::protobuf::io::CodedInputStream* input) {
  7291. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  7292. ::google::protobuf::uint32 tag;
  7293. // @@protoc_insertion_point(parse_start:proto3.TestValue)
  7294. for (;;) {
  7295. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  7296. tag = p.first;
  7297. if (!p.second) goto handle_unusual;
  7298. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  7299. // .google.protobuf.Value value = 1;
  7300. case 1: {
  7301. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7302. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  7303. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7304. input, mutable_value()));
  7305. } else {
  7306. goto handle_unusual;
  7307. }
  7308. break;
  7309. }
  7310. // repeated .google.protobuf.Value repeated_value = 2;
  7311. case 2: {
  7312. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7313. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  7314. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7315. input, add_repeated_value()));
  7316. } else {
  7317. goto handle_unusual;
  7318. }
  7319. break;
  7320. }
  7321. default: {
  7322. handle_unusual:
  7323. if (tag == 0) {
  7324. goto success;
  7325. }
  7326. DO_(::google::protobuf::internal::WireFormat::SkipField(
  7327. input, tag, _internal_metadata_.mutable_unknown_fields()));
  7328. break;
  7329. }
  7330. }
  7331. }
  7332. success:
  7333. // @@protoc_insertion_point(parse_success:proto3.TestValue)
  7334. return true;
  7335. failure:
  7336. // @@protoc_insertion_point(parse_failure:proto3.TestValue)
  7337. return false;
  7338. #undef DO_
  7339. }
  7340. void TestValue::SerializeWithCachedSizes(
  7341. ::google::protobuf::io::CodedOutputStream* output) const {
  7342. // @@protoc_insertion_point(serialize_start:proto3.TestValue)
  7343. ::google::protobuf::uint32 cached_has_bits = 0;
  7344. (void) cached_has_bits;
  7345. // .google.protobuf.Value value = 1;
  7346. if (this->has_value()) {
  7347. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7348. 1, this->_internal_value(), output);
  7349. }
  7350. // repeated .google.protobuf.Value repeated_value = 2;
  7351. for (unsigned int i = 0,
  7352. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7353. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7354. 2,
  7355. this->repeated_value(static_cast<int>(i)),
  7356. output);
  7357. }
  7358. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7359. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  7360. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  7361. }
  7362. // @@protoc_insertion_point(serialize_end:proto3.TestValue)
  7363. }
  7364. ::google::protobuf::uint8* TestValue::InternalSerializeWithCachedSizesToArray(
  7365. bool deterministic, ::google::protobuf::uint8* target) const {
  7366. (void)deterministic; // Unused
  7367. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestValue)
  7368. ::google::protobuf::uint32 cached_has_bits = 0;
  7369. (void) cached_has_bits;
  7370. // .google.protobuf.Value value = 1;
  7371. if (this->has_value()) {
  7372. target = ::google::protobuf::internal::WireFormatLite::
  7373. InternalWriteMessageToArray(
  7374. 1, this->_internal_value(), deterministic, target);
  7375. }
  7376. // repeated .google.protobuf.Value repeated_value = 2;
  7377. for (unsigned int i = 0,
  7378. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7379. target = ::google::protobuf::internal::WireFormatLite::
  7380. InternalWriteMessageToArray(
  7381. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  7382. }
  7383. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7384. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  7385. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  7386. }
  7387. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestValue)
  7388. return target;
  7389. }
  7390. size_t TestValue::ByteSizeLong() const {
  7391. // @@protoc_insertion_point(message_byte_size_start:proto3.TestValue)
  7392. size_t total_size = 0;
  7393. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7394. total_size +=
  7395. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  7396. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  7397. }
  7398. // repeated .google.protobuf.Value repeated_value = 2;
  7399. {
  7400. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  7401. total_size += 1UL * count;
  7402. for (unsigned int i = 0; i < count; i++) {
  7403. total_size +=
  7404. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7405. this->repeated_value(static_cast<int>(i)));
  7406. }
  7407. }
  7408. // .google.protobuf.Value value = 1;
  7409. if (this->has_value()) {
  7410. total_size += 1 +
  7411. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7412. *value_);
  7413. }
  7414. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  7415. SetCachedSize(cached_size);
  7416. return total_size;
  7417. }
  7418. void TestValue::MergeFrom(const ::google::protobuf::Message& from) {
  7419. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestValue)
  7420. GOOGLE_DCHECK_NE(&from, this);
  7421. const TestValue* source =
  7422. ::google::protobuf::internal::DynamicCastToGenerated<const TestValue>(
  7423. &from);
  7424. if (source == NULL) {
  7425. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestValue)
  7426. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  7427. } else {
  7428. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestValue)
  7429. MergeFrom(*source);
  7430. }
  7431. }
  7432. void TestValue::MergeFrom(const TestValue& from) {
  7433. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestValue)
  7434. GOOGLE_DCHECK_NE(&from, this);
  7435. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7436. ::google::protobuf::uint32 cached_has_bits = 0;
  7437. (void) cached_has_bits;
  7438. repeated_value_.MergeFrom(from.repeated_value_);
  7439. if (from.has_value()) {
  7440. mutable_value()->::google::protobuf::Value::MergeFrom(from.value());
  7441. }
  7442. }
  7443. void TestValue::CopyFrom(const ::google::protobuf::Message& from) {
  7444. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestValue)
  7445. if (&from == this) return;
  7446. Clear();
  7447. MergeFrom(from);
  7448. }
  7449. void TestValue::CopyFrom(const TestValue& from) {
  7450. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestValue)
  7451. if (&from == this) return;
  7452. Clear();
  7453. MergeFrom(from);
  7454. }
  7455. bool TestValue::IsInitialized() const {
  7456. return true;
  7457. }
  7458. void TestValue::Swap(TestValue* other) {
  7459. if (other == this) return;
  7460. InternalSwap(other);
  7461. }
  7462. void TestValue::InternalSwap(TestValue* other) {
  7463. using std::swap;
  7464. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  7465. swap(value_, other->value_);
  7466. _internal_metadata_.Swap(&other->_internal_metadata_);
  7467. }
  7468. ::google::protobuf::Metadata TestValue::GetMetadata() const {
  7469. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7470. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  7471. }
  7472. // ===================================================================
  7473. void TestListValue::InitAsDefaultInstance() {
  7474. ::proto3::_TestListValue_default_instance_._instance.get_mutable()->value_ = const_cast< ::google::protobuf::ListValue*>(
  7475. ::google::protobuf::ListValue::internal_default_instance());
  7476. }
  7477. void TestListValue::clear_value() {
  7478. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  7479. delete value_;
  7480. }
  7481. value_ = NULL;
  7482. }
  7483. void TestListValue::clear_repeated_value() {
  7484. repeated_value_.Clear();
  7485. }
  7486. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  7487. const int TestListValue::kValueFieldNumber;
  7488. const int TestListValue::kRepeatedValueFieldNumber;
  7489. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  7490. TestListValue::TestListValue()
  7491. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  7492. ::google::protobuf::internal::InitSCC(
  7493. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestListValue.base);
  7494. SharedCtor();
  7495. // @@protoc_insertion_point(constructor:proto3.TestListValue)
  7496. }
  7497. TestListValue::TestListValue(const TestListValue& from)
  7498. : ::google::protobuf::Message(),
  7499. _internal_metadata_(NULL),
  7500. repeated_value_(from.repeated_value_) {
  7501. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7502. if (from.has_value()) {
  7503. value_ = new ::google::protobuf::ListValue(*from.value_);
  7504. } else {
  7505. value_ = NULL;
  7506. }
  7507. // @@protoc_insertion_point(copy_constructor:proto3.TestListValue)
  7508. }
  7509. void TestListValue::SharedCtor() {
  7510. value_ = NULL;
  7511. }
  7512. TestListValue::~TestListValue() {
  7513. // @@protoc_insertion_point(destructor:proto3.TestListValue)
  7514. SharedDtor();
  7515. }
  7516. void TestListValue::SharedDtor() {
  7517. if (this != internal_default_instance()) delete value_;
  7518. }
  7519. void TestListValue::SetCachedSize(int size) const {
  7520. _cached_size_.Set(size);
  7521. }
  7522. const ::google::protobuf::Descriptor* TestListValue::descriptor() {
  7523. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7524. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  7525. }
  7526. const TestListValue& TestListValue::default_instance() {
  7527. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestListValue.base);
  7528. return *internal_default_instance();
  7529. }
  7530. void TestListValue::Clear() {
  7531. // @@protoc_insertion_point(message_clear_start:proto3.TestListValue)
  7532. ::google::protobuf::uint32 cached_has_bits = 0;
  7533. // Prevent compiler warnings about cached_has_bits being unused
  7534. (void) cached_has_bits;
  7535. repeated_value_.Clear();
  7536. if (GetArenaNoVirtual() == NULL && value_ != NULL) {
  7537. delete value_;
  7538. }
  7539. value_ = NULL;
  7540. _internal_metadata_.Clear();
  7541. }
  7542. bool TestListValue::MergePartialFromCodedStream(
  7543. ::google::protobuf::io::CodedInputStream* input) {
  7544. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  7545. ::google::protobuf::uint32 tag;
  7546. // @@protoc_insertion_point(parse_start:proto3.TestListValue)
  7547. for (;;) {
  7548. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  7549. tag = p.first;
  7550. if (!p.second) goto handle_unusual;
  7551. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  7552. // .google.protobuf.ListValue value = 1;
  7553. case 1: {
  7554. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7555. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  7556. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7557. input, mutable_value()));
  7558. } else {
  7559. goto handle_unusual;
  7560. }
  7561. break;
  7562. }
  7563. // repeated .google.protobuf.ListValue repeated_value = 2;
  7564. case 2: {
  7565. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7566. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  7567. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  7568. input, add_repeated_value()));
  7569. } else {
  7570. goto handle_unusual;
  7571. }
  7572. break;
  7573. }
  7574. default: {
  7575. handle_unusual:
  7576. if (tag == 0) {
  7577. goto success;
  7578. }
  7579. DO_(::google::protobuf::internal::WireFormat::SkipField(
  7580. input, tag, _internal_metadata_.mutable_unknown_fields()));
  7581. break;
  7582. }
  7583. }
  7584. }
  7585. success:
  7586. // @@protoc_insertion_point(parse_success:proto3.TestListValue)
  7587. return true;
  7588. failure:
  7589. // @@protoc_insertion_point(parse_failure:proto3.TestListValue)
  7590. return false;
  7591. #undef DO_
  7592. }
  7593. void TestListValue::SerializeWithCachedSizes(
  7594. ::google::protobuf::io::CodedOutputStream* output) const {
  7595. // @@protoc_insertion_point(serialize_start:proto3.TestListValue)
  7596. ::google::protobuf::uint32 cached_has_bits = 0;
  7597. (void) cached_has_bits;
  7598. // .google.protobuf.ListValue value = 1;
  7599. if (this->has_value()) {
  7600. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7601. 1, this->_internal_value(), output);
  7602. }
  7603. // repeated .google.protobuf.ListValue repeated_value = 2;
  7604. for (unsigned int i = 0,
  7605. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7606. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7607. 2,
  7608. this->repeated_value(static_cast<int>(i)),
  7609. output);
  7610. }
  7611. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7612. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  7613. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  7614. }
  7615. // @@protoc_insertion_point(serialize_end:proto3.TestListValue)
  7616. }
  7617. ::google::protobuf::uint8* TestListValue::InternalSerializeWithCachedSizesToArray(
  7618. bool deterministic, ::google::protobuf::uint8* target) const {
  7619. (void)deterministic; // Unused
  7620. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestListValue)
  7621. ::google::protobuf::uint32 cached_has_bits = 0;
  7622. (void) cached_has_bits;
  7623. // .google.protobuf.ListValue value = 1;
  7624. if (this->has_value()) {
  7625. target = ::google::protobuf::internal::WireFormatLite::
  7626. InternalWriteMessageToArray(
  7627. 1, this->_internal_value(), deterministic, target);
  7628. }
  7629. // repeated .google.protobuf.ListValue repeated_value = 2;
  7630. for (unsigned int i = 0,
  7631. n = static_cast<unsigned int>(this->repeated_value_size()); i < n; i++) {
  7632. target = ::google::protobuf::internal::WireFormatLite::
  7633. InternalWriteMessageToArray(
  7634. 2, this->repeated_value(static_cast<int>(i)), deterministic, target);
  7635. }
  7636. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7637. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  7638. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  7639. }
  7640. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestListValue)
  7641. return target;
  7642. }
  7643. size_t TestListValue::ByteSizeLong() const {
  7644. // @@protoc_insertion_point(message_byte_size_start:proto3.TestListValue)
  7645. size_t total_size = 0;
  7646. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7647. total_size +=
  7648. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  7649. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  7650. }
  7651. // repeated .google.protobuf.ListValue repeated_value = 2;
  7652. {
  7653. unsigned int count = static_cast<unsigned int>(this->repeated_value_size());
  7654. total_size += 1UL * count;
  7655. for (unsigned int i = 0; i < count; i++) {
  7656. total_size +=
  7657. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7658. this->repeated_value(static_cast<int>(i)));
  7659. }
  7660. }
  7661. // .google.protobuf.ListValue value = 1;
  7662. if (this->has_value()) {
  7663. total_size += 1 +
  7664. ::google::protobuf::internal::WireFormatLite::MessageSize(
  7665. *value_);
  7666. }
  7667. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  7668. SetCachedSize(cached_size);
  7669. return total_size;
  7670. }
  7671. void TestListValue::MergeFrom(const ::google::protobuf::Message& from) {
  7672. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestListValue)
  7673. GOOGLE_DCHECK_NE(&from, this);
  7674. const TestListValue* source =
  7675. ::google::protobuf::internal::DynamicCastToGenerated<const TestListValue>(
  7676. &from);
  7677. if (source == NULL) {
  7678. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestListValue)
  7679. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  7680. } else {
  7681. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestListValue)
  7682. MergeFrom(*source);
  7683. }
  7684. }
  7685. void TestListValue::MergeFrom(const TestListValue& from) {
  7686. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestListValue)
  7687. GOOGLE_DCHECK_NE(&from, this);
  7688. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7689. ::google::protobuf::uint32 cached_has_bits = 0;
  7690. (void) cached_has_bits;
  7691. repeated_value_.MergeFrom(from.repeated_value_);
  7692. if (from.has_value()) {
  7693. mutable_value()->::google::protobuf::ListValue::MergeFrom(from.value());
  7694. }
  7695. }
  7696. void TestListValue::CopyFrom(const ::google::protobuf::Message& from) {
  7697. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestListValue)
  7698. if (&from == this) return;
  7699. Clear();
  7700. MergeFrom(from);
  7701. }
  7702. void TestListValue::CopyFrom(const TestListValue& from) {
  7703. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestListValue)
  7704. if (&from == this) return;
  7705. Clear();
  7706. MergeFrom(from);
  7707. }
  7708. bool TestListValue::IsInitialized() const {
  7709. return true;
  7710. }
  7711. void TestListValue::Swap(TestListValue* other) {
  7712. if (other == this) return;
  7713. InternalSwap(other);
  7714. }
  7715. void TestListValue::InternalSwap(TestListValue* other) {
  7716. using std::swap;
  7717. CastToBase(&repeated_value_)->InternalSwap(CastToBase(&other->repeated_value_));
  7718. swap(value_, other->value_);
  7719. _internal_metadata_.Swap(&other->_internal_metadata_);
  7720. }
  7721. ::google::protobuf::Metadata TestListValue::GetMetadata() const {
  7722. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7723. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  7724. }
  7725. // ===================================================================
  7726. TestBoolValue_BoolMapEntry_DoNotUse::TestBoolValue_BoolMapEntry_DoNotUse() {}
  7727. TestBoolValue_BoolMapEntry_DoNotUse::TestBoolValue_BoolMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  7728. void TestBoolValue_BoolMapEntry_DoNotUse::MergeFrom(const TestBoolValue_BoolMapEntry_DoNotUse& other) {
  7729. MergeFromInternal(other);
  7730. }
  7731. ::google::protobuf::Metadata TestBoolValue_BoolMapEntry_DoNotUse::GetMetadata() const {
  7732. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7733. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[26];
  7734. }
  7735. void TestBoolValue_BoolMapEntry_DoNotUse::MergeFrom(
  7736. const ::google::protobuf::Message& other) {
  7737. ::google::protobuf::Message::MergeFrom(other);
  7738. }
  7739. // ===================================================================
  7740. void TestBoolValue::InitAsDefaultInstance() {
  7741. }
  7742. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  7743. const int TestBoolValue::kBoolValueFieldNumber;
  7744. const int TestBoolValue::kBoolMapFieldNumber;
  7745. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  7746. TestBoolValue::TestBoolValue()
  7747. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  7748. ::google::protobuf::internal::InitSCC(
  7749. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestBoolValue.base);
  7750. SharedCtor();
  7751. // @@protoc_insertion_point(constructor:proto3.TestBoolValue)
  7752. }
  7753. TestBoolValue::TestBoolValue(const TestBoolValue& from)
  7754. : ::google::protobuf::Message(),
  7755. _internal_metadata_(NULL) {
  7756. _internal_metadata_.MergeFrom(from._internal_metadata_);
  7757. bool_map_.MergeFrom(from.bool_map_);
  7758. bool_value_ = from.bool_value_;
  7759. // @@protoc_insertion_point(copy_constructor:proto3.TestBoolValue)
  7760. }
  7761. void TestBoolValue::SharedCtor() {
  7762. bool_value_ = false;
  7763. }
  7764. TestBoolValue::~TestBoolValue() {
  7765. // @@protoc_insertion_point(destructor:proto3.TestBoolValue)
  7766. SharedDtor();
  7767. }
  7768. void TestBoolValue::SharedDtor() {
  7769. }
  7770. void TestBoolValue::SetCachedSize(int size) const {
  7771. _cached_size_.Set(size);
  7772. }
  7773. const ::google::protobuf::Descriptor* TestBoolValue::descriptor() {
  7774. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  7775. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  7776. }
  7777. const TestBoolValue& TestBoolValue::default_instance() {
  7778. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestBoolValue.base);
  7779. return *internal_default_instance();
  7780. }
  7781. void TestBoolValue::Clear() {
  7782. // @@protoc_insertion_point(message_clear_start:proto3.TestBoolValue)
  7783. ::google::protobuf::uint32 cached_has_bits = 0;
  7784. // Prevent compiler warnings about cached_has_bits being unused
  7785. (void) cached_has_bits;
  7786. bool_map_.Clear();
  7787. bool_value_ = false;
  7788. _internal_metadata_.Clear();
  7789. }
  7790. bool TestBoolValue::MergePartialFromCodedStream(
  7791. ::google::protobuf::io::CodedInputStream* input) {
  7792. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  7793. ::google::protobuf::uint32 tag;
  7794. // @@protoc_insertion_point(parse_start:proto3.TestBoolValue)
  7795. for (;;) {
  7796. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  7797. tag = p.first;
  7798. if (!p.second) goto handle_unusual;
  7799. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  7800. // bool bool_value = 1;
  7801. case 1: {
  7802. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7803. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  7804. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  7805. bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
  7806. input, &bool_value_)));
  7807. } else {
  7808. goto handle_unusual;
  7809. }
  7810. break;
  7811. }
  7812. // map<bool, int32> bool_map = 2;
  7813. case 2: {
  7814. if (static_cast< ::google::protobuf::uint8>(tag) ==
  7815. static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  7816. TestBoolValue_BoolMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
  7817. TestBoolValue_BoolMapEntry_DoNotUse,
  7818. bool, ::google::protobuf::int32,
  7819. ::google::protobuf::internal::WireFormatLite::TYPE_BOOL,
  7820. ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
  7821. 0 >,
  7822. ::google::protobuf::Map< bool, ::google::protobuf::int32 > > parser(&bool_map_);
  7823. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  7824. input, &parser));
  7825. } else {
  7826. goto handle_unusual;
  7827. }
  7828. break;
  7829. }
  7830. default: {
  7831. handle_unusual:
  7832. if (tag == 0) {
  7833. goto success;
  7834. }
  7835. DO_(::google::protobuf::internal::WireFormat::SkipField(
  7836. input, tag, _internal_metadata_.mutable_unknown_fields()));
  7837. break;
  7838. }
  7839. }
  7840. }
  7841. success:
  7842. // @@protoc_insertion_point(parse_success:proto3.TestBoolValue)
  7843. return true;
  7844. failure:
  7845. // @@protoc_insertion_point(parse_failure:proto3.TestBoolValue)
  7846. return false;
  7847. #undef DO_
  7848. }
  7849. void TestBoolValue::SerializeWithCachedSizes(
  7850. ::google::protobuf::io::CodedOutputStream* output) const {
  7851. // @@protoc_insertion_point(serialize_start:proto3.TestBoolValue)
  7852. ::google::protobuf::uint32 cached_has_bits = 0;
  7853. (void) cached_has_bits;
  7854. // bool bool_value = 1;
  7855. if (this->bool_value() != 0) {
  7856. ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->bool_value(), output);
  7857. }
  7858. // map<bool, int32> bool_map = 2;
  7859. if (!this->bool_map().empty()) {
  7860. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  7861. ConstPtr;
  7862. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  7863. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  7864. if (output->IsSerializationDeterministic() &&
  7865. this->bool_map().size() > 1) {
  7866. ::std::unique_ptr<SortItem[]> items(
  7867. new SortItem[this->bool_map().size()]);
  7868. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  7869. size_type n = 0;
  7870. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  7871. it = this->bool_map().begin();
  7872. it != this->bool_map().end(); ++it, ++n) {
  7873. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  7874. }
  7875. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  7876. ::std::unique_ptr<TestBoolValue_BoolMapEntry_DoNotUse> entry;
  7877. for (size_type i = 0; i < n; i++) {
  7878. entry.reset(bool_map_.NewEntryWrapper(
  7879. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  7880. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7881. 2, *entry, output);
  7882. }
  7883. } else {
  7884. ::std::unique_ptr<TestBoolValue_BoolMapEntry_DoNotUse> entry;
  7885. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  7886. it = this->bool_map().begin();
  7887. it != this->bool_map().end(); ++it) {
  7888. entry.reset(bool_map_.NewEntryWrapper(
  7889. it->first, it->second));
  7890. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  7891. 2, *entry, output);
  7892. }
  7893. }
  7894. }
  7895. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7896. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  7897. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  7898. }
  7899. // @@protoc_insertion_point(serialize_end:proto3.TestBoolValue)
  7900. }
  7901. ::google::protobuf::uint8* TestBoolValue::InternalSerializeWithCachedSizesToArray(
  7902. bool deterministic, ::google::protobuf::uint8* target) const {
  7903. (void)deterministic; // Unused
  7904. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestBoolValue)
  7905. ::google::protobuf::uint32 cached_has_bits = 0;
  7906. (void) cached_has_bits;
  7907. // bool bool_value = 1;
  7908. if (this->bool_value() != 0) {
  7909. target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->bool_value(), target);
  7910. }
  7911. // map<bool, int32> bool_map = 2;
  7912. if (!this->bool_map().empty()) {
  7913. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_pointer
  7914. ConstPtr;
  7915. typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem;
  7916. typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
  7917. if (deterministic &&
  7918. this->bool_map().size() > 1) {
  7919. ::std::unique_ptr<SortItem[]> items(
  7920. new SortItem[this->bool_map().size()]);
  7921. typedef ::google::protobuf::Map< bool, ::google::protobuf::int32 >::size_type size_type;
  7922. size_type n = 0;
  7923. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  7924. it = this->bool_map().begin();
  7925. it != this->bool_map().end(); ++it, ++n) {
  7926. items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  7927. }
  7928. ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  7929. ::std::unique_ptr<TestBoolValue_BoolMapEntry_DoNotUse> entry;
  7930. for (size_type i = 0; i < n; i++) {
  7931. entry.reset(bool_map_.NewEntryWrapper(
  7932. items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
  7933. target = ::google::protobuf::internal::WireFormatLite::
  7934. InternalWriteMessageNoVirtualToArray(
  7935. 2, *entry, deterministic, target);
  7936. ;
  7937. }
  7938. } else {
  7939. ::std::unique_ptr<TestBoolValue_BoolMapEntry_DoNotUse> entry;
  7940. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  7941. it = this->bool_map().begin();
  7942. it != this->bool_map().end(); ++it) {
  7943. entry.reset(bool_map_.NewEntryWrapper(
  7944. it->first, it->second));
  7945. target = ::google::protobuf::internal::WireFormatLite::
  7946. InternalWriteMessageNoVirtualToArray(
  7947. 2, *entry, deterministic, target);
  7948. ;
  7949. }
  7950. }
  7951. }
  7952. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7953. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  7954. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  7955. }
  7956. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestBoolValue)
  7957. return target;
  7958. }
  7959. size_t TestBoolValue::ByteSizeLong() const {
  7960. // @@protoc_insertion_point(message_byte_size_start:proto3.TestBoolValue)
  7961. size_t total_size = 0;
  7962. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  7963. total_size +=
  7964. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  7965. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  7966. }
  7967. // map<bool, int32> bool_map = 2;
  7968. total_size += 1 *
  7969. ::google::protobuf::internal::FromIntSize(this->bool_map_size());
  7970. {
  7971. ::std::unique_ptr<TestBoolValue_BoolMapEntry_DoNotUse> entry;
  7972. for (::google::protobuf::Map< bool, ::google::protobuf::int32 >::const_iterator
  7973. it = this->bool_map().begin();
  7974. it != this->bool_map().end(); ++it) {
  7975. entry.reset(bool_map_.NewEntryWrapper(it->first, it->second));
  7976. total_size += ::google::protobuf::internal::WireFormatLite::
  7977. MessageSizeNoVirtual(*entry);
  7978. }
  7979. }
  7980. // bool bool_value = 1;
  7981. if (this->bool_value() != 0) {
  7982. total_size += 1 + 1;
  7983. }
  7984. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  7985. SetCachedSize(cached_size);
  7986. return total_size;
  7987. }
  7988. void TestBoolValue::MergeFrom(const ::google::protobuf::Message& from) {
  7989. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestBoolValue)
  7990. GOOGLE_DCHECK_NE(&from, this);
  7991. const TestBoolValue* source =
  7992. ::google::protobuf::internal::DynamicCastToGenerated<const TestBoolValue>(
  7993. &from);
  7994. if (source == NULL) {
  7995. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestBoolValue)
  7996. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  7997. } else {
  7998. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestBoolValue)
  7999. MergeFrom(*source);
  8000. }
  8001. }
  8002. void TestBoolValue::MergeFrom(const TestBoolValue& from) {
  8003. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestBoolValue)
  8004. GOOGLE_DCHECK_NE(&from, this);
  8005. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8006. ::google::protobuf::uint32 cached_has_bits = 0;
  8007. (void) cached_has_bits;
  8008. bool_map_.MergeFrom(from.bool_map_);
  8009. if (from.bool_value() != 0) {
  8010. set_bool_value(from.bool_value());
  8011. }
  8012. }
  8013. void TestBoolValue::CopyFrom(const ::google::protobuf::Message& from) {
  8014. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestBoolValue)
  8015. if (&from == this) return;
  8016. Clear();
  8017. MergeFrom(from);
  8018. }
  8019. void TestBoolValue::CopyFrom(const TestBoolValue& from) {
  8020. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestBoolValue)
  8021. if (&from == this) return;
  8022. Clear();
  8023. MergeFrom(from);
  8024. }
  8025. bool TestBoolValue::IsInitialized() const {
  8026. return true;
  8027. }
  8028. void TestBoolValue::Swap(TestBoolValue* other) {
  8029. if (other == this) return;
  8030. InternalSwap(other);
  8031. }
  8032. void TestBoolValue::InternalSwap(TestBoolValue* other) {
  8033. using std::swap;
  8034. bool_map_.Swap(&other->bool_map_);
  8035. swap(bool_value_, other->bool_value_);
  8036. _internal_metadata_.Swap(&other->_internal_metadata_);
  8037. }
  8038. ::google::protobuf::Metadata TestBoolValue::GetMetadata() const {
  8039. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8040. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  8041. }
  8042. // ===================================================================
  8043. void TestCustomJsonName::InitAsDefaultInstance() {
  8044. }
  8045. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  8046. const int TestCustomJsonName::kValueFieldNumber;
  8047. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  8048. TestCustomJsonName::TestCustomJsonName()
  8049. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  8050. ::google::protobuf::internal::InitSCC(
  8051. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestCustomJsonName.base);
  8052. SharedCtor();
  8053. // @@protoc_insertion_point(constructor:proto3.TestCustomJsonName)
  8054. }
  8055. TestCustomJsonName::TestCustomJsonName(const TestCustomJsonName& from)
  8056. : ::google::protobuf::Message(),
  8057. _internal_metadata_(NULL) {
  8058. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8059. value_ = from.value_;
  8060. // @@protoc_insertion_point(copy_constructor:proto3.TestCustomJsonName)
  8061. }
  8062. void TestCustomJsonName::SharedCtor() {
  8063. value_ = 0;
  8064. }
  8065. TestCustomJsonName::~TestCustomJsonName() {
  8066. // @@protoc_insertion_point(destructor:proto3.TestCustomJsonName)
  8067. SharedDtor();
  8068. }
  8069. void TestCustomJsonName::SharedDtor() {
  8070. }
  8071. void TestCustomJsonName::SetCachedSize(int size) const {
  8072. _cached_size_.Set(size);
  8073. }
  8074. const ::google::protobuf::Descriptor* TestCustomJsonName::descriptor() {
  8075. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8076. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  8077. }
  8078. const TestCustomJsonName& TestCustomJsonName::default_instance() {
  8079. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestCustomJsonName.base);
  8080. return *internal_default_instance();
  8081. }
  8082. void TestCustomJsonName::Clear() {
  8083. // @@protoc_insertion_point(message_clear_start:proto3.TestCustomJsonName)
  8084. ::google::protobuf::uint32 cached_has_bits = 0;
  8085. // Prevent compiler warnings about cached_has_bits being unused
  8086. (void) cached_has_bits;
  8087. value_ = 0;
  8088. _internal_metadata_.Clear();
  8089. }
  8090. bool TestCustomJsonName::MergePartialFromCodedStream(
  8091. ::google::protobuf::io::CodedInputStream* input) {
  8092. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  8093. ::google::protobuf::uint32 tag;
  8094. // @@protoc_insertion_point(parse_start:proto3.TestCustomJsonName)
  8095. for (;;) {
  8096. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  8097. tag = p.first;
  8098. if (!p.second) goto handle_unusual;
  8099. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  8100. // int32 value = 1[json_name = "@value"];
  8101. case 1: {
  8102. if (static_cast< ::google::protobuf::uint8>(tag) ==
  8103. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  8104. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  8105. ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
  8106. input, &value_)));
  8107. } else {
  8108. goto handle_unusual;
  8109. }
  8110. break;
  8111. }
  8112. default: {
  8113. handle_unusual:
  8114. if (tag == 0) {
  8115. goto success;
  8116. }
  8117. DO_(::google::protobuf::internal::WireFormat::SkipField(
  8118. input, tag, _internal_metadata_.mutable_unknown_fields()));
  8119. break;
  8120. }
  8121. }
  8122. }
  8123. success:
  8124. // @@protoc_insertion_point(parse_success:proto3.TestCustomJsonName)
  8125. return true;
  8126. failure:
  8127. // @@protoc_insertion_point(parse_failure:proto3.TestCustomJsonName)
  8128. return false;
  8129. #undef DO_
  8130. }
  8131. void TestCustomJsonName::SerializeWithCachedSizes(
  8132. ::google::protobuf::io::CodedOutputStream* output) const {
  8133. // @@protoc_insertion_point(serialize_start:proto3.TestCustomJsonName)
  8134. ::google::protobuf::uint32 cached_has_bits = 0;
  8135. (void) cached_has_bits;
  8136. // int32 value = 1[json_name = "@value"];
  8137. if (this->value() != 0) {
  8138. ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->value(), output);
  8139. }
  8140. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8141. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  8142. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  8143. }
  8144. // @@protoc_insertion_point(serialize_end:proto3.TestCustomJsonName)
  8145. }
  8146. ::google::protobuf::uint8* TestCustomJsonName::InternalSerializeWithCachedSizesToArray(
  8147. bool deterministic, ::google::protobuf::uint8* target) const {
  8148. (void)deterministic; // Unused
  8149. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestCustomJsonName)
  8150. ::google::protobuf::uint32 cached_has_bits = 0;
  8151. (void) cached_has_bits;
  8152. // int32 value = 1[json_name = "@value"];
  8153. if (this->value() != 0) {
  8154. target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->value(), target);
  8155. }
  8156. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8157. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  8158. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  8159. }
  8160. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestCustomJsonName)
  8161. return target;
  8162. }
  8163. size_t TestCustomJsonName::ByteSizeLong() const {
  8164. // @@protoc_insertion_point(message_byte_size_start:proto3.TestCustomJsonName)
  8165. size_t total_size = 0;
  8166. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8167. total_size +=
  8168. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  8169. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  8170. }
  8171. // int32 value = 1[json_name = "@value"];
  8172. if (this->value() != 0) {
  8173. total_size += 1 +
  8174. ::google::protobuf::internal::WireFormatLite::Int32Size(
  8175. this->value());
  8176. }
  8177. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  8178. SetCachedSize(cached_size);
  8179. return total_size;
  8180. }
  8181. void TestCustomJsonName::MergeFrom(const ::google::protobuf::Message& from) {
  8182. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestCustomJsonName)
  8183. GOOGLE_DCHECK_NE(&from, this);
  8184. const TestCustomJsonName* source =
  8185. ::google::protobuf::internal::DynamicCastToGenerated<const TestCustomJsonName>(
  8186. &from);
  8187. if (source == NULL) {
  8188. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestCustomJsonName)
  8189. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  8190. } else {
  8191. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestCustomJsonName)
  8192. MergeFrom(*source);
  8193. }
  8194. }
  8195. void TestCustomJsonName::MergeFrom(const TestCustomJsonName& from) {
  8196. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestCustomJsonName)
  8197. GOOGLE_DCHECK_NE(&from, this);
  8198. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8199. ::google::protobuf::uint32 cached_has_bits = 0;
  8200. (void) cached_has_bits;
  8201. if (from.value() != 0) {
  8202. set_value(from.value());
  8203. }
  8204. }
  8205. void TestCustomJsonName::CopyFrom(const ::google::protobuf::Message& from) {
  8206. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestCustomJsonName)
  8207. if (&from == this) return;
  8208. Clear();
  8209. MergeFrom(from);
  8210. }
  8211. void TestCustomJsonName::CopyFrom(const TestCustomJsonName& from) {
  8212. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestCustomJsonName)
  8213. if (&from == this) return;
  8214. Clear();
  8215. MergeFrom(from);
  8216. }
  8217. bool TestCustomJsonName::IsInitialized() const {
  8218. return true;
  8219. }
  8220. void TestCustomJsonName::Swap(TestCustomJsonName* other) {
  8221. if (other == this) return;
  8222. InternalSwap(other);
  8223. }
  8224. void TestCustomJsonName::InternalSwap(TestCustomJsonName* other) {
  8225. using std::swap;
  8226. swap(value_, other->value_);
  8227. _internal_metadata_.Swap(&other->_internal_metadata_);
  8228. }
  8229. ::google::protobuf::Metadata TestCustomJsonName::GetMetadata() const {
  8230. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8231. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  8232. }
  8233. // ===================================================================
  8234. void TestExtensions::InitAsDefaultInstance() {
  8235. ::proto3::_TestExtensions_default_instance_._instance.get_mutable()->extensions_ = const_cast< ::protobuf_unittest::TestAllExtensions*>(
  8236. ::protobuf_unittest::TestAllExtensions::internal_default_instance());
  8237. }
  8238. void TestExtensions::clear_extensions() {
  8239. if (GetArenaNoVirtual() == NULL && extensions_ != NULL) {
  8240. delete extensions_;
  8241. }
  8242. extensions_ = NULL;
  8243. }
  8244. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  8245. const int TestExtensions::kExtensionsFieldNumber;
  8246. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  8247. TestExtensions::TestExtensions()
  8248. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  8249. ::google::protobuf::internal::InitSCC(
  8250. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestExtensions.base);
  8251. SharedCtor();
  8252. // @@protoc_insertion_point(constructor:proto3.TestExtensions)
  8253. }
  8254. TestExtensions::TestExtensions(const TestExtensions& from)
  8255. : ::google::protobuf::Message(),
  8256. _internal_metadata_(NULL) {
  8257. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8258. if (from.has_extensions()) {
  8259. extensions_ = new ::protobuf_unittest::TestAllExtensions(*from.extensions_);
  8260. } else {
  8261. extensions_ = NULL;
  8262. }
  8263. // @@protoc_insertion_point(copy_constructor:proto3.TestExtensions)
  8264. }
  8265. void TestExtensions::SharedCtor() {
  8266. extensions_ = NULL;
  8267. }
  8268. TestExtensions::~TestExtensions() {
  8269. // @@protoc_insertion_point(destructor:proto3.TestExtensions)
  8270. SharedDtor();
  8271. }
  8272. void TestExtensions::SharedDtor() {
  8273. if (this != internal_default_instance()) delete extensions_;
  8274. }
  8275. void TestExtensions::SetCachedSize(int size) const {
  8276. _cached_size_.Set(size);
  8277. }
  8278. const ::google::protobuf::Descriptor* TestExtensions::descriptor() {
  8279. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8280. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  8281. }
  8282. const TestExtensions& TestExtensions::default_instance() {
  8283. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestExtensions.base);
  8284. return *internal_default_instance();
  8285. }
  8286. void TestExtensions::Clear() {
  8287. // @@protoc_insertion_point(message_clear_start:proto3.TestExtensions)
  8288. ::google::protobuf::uint32 cached_has_bits = 0;
  8289. // Prevent compiler warnings about cached_has_bits being unused
  8290. (void) cached_has_bits;
  8291. if (GetArenaNoVirtual() == NULL && extensions_ != NULL) {
  8292. delete extensions_;
  8293. }
  8294. extensions_ = NULL;
  8295. _internal_metadata_.Clear();
  8296. }
  8297. bool TestExtensions::MergePartialFromCodedStream(
  8298. ::google::protobuf::io::CodedInputStream* input) {
  8299. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  8300. ::google::protobuf::uint32 tag;
  8301. // @@protoc_insertion_point(parse_start:proto3.TestExtensions)
  8302. for (;;) {
  8303. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  8304. tag = p.first;
  8305. if (!p.second) goto handle_unusual;
  8306. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  8307. // .protobuf_unittest.TestAllExtensions extensions = 1;
  8308. case 1: {
  8309. if (static_cast< ::google::protobuf::uint8>(tag) ==
  8310. static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  8311. DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  8312. input, mutable_extensions()));
  8313. } else {
  8314. goto handle_unusual;
  8315. }
  8316. break;
  8317. }
  8318. default: {
  8319. handle_unusual:
  8320. if (tag == 0) {
  8321. goto success;
  8322. }
  8323. DO_(::google::protobuf::internal::WireFormat::SkipField(
  8324. input, tag, _internal_metadata_.mutable_unknown_fields()));
  8325. break;
  8326. }
  8327. }
  8328. }
  8329. success:
  8330. // @@protoc_insertion_point(parse_success:proto3.TestExtensions)
  8331. return true;
  8332. failure:
  8333. // @@protoc_insertion_point(parse_failure:proto3.TestExtensions)
  8334. return false;
  8335. #undef DO_
  8336. }
  8337. void TestExtensions::SerializeWithCachedSizes(
  8338. ::google::protobuf::io::CodedOutputStream* output) const {
  8339. // @@protoc_insertion_point(serialize_start:proto3.TestExtensions)
  8340. ::google::protobuf::uint32 cached_has_bits = 0;
  8341. (void) cached_has_bits;
  8342. // .protobuf_unittest.TestAllExtensions extensions = 1;
  8343. if (this->has_extensions()) {
  8344. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  8345. 1, this->_internal_extensions(), output);
  8346. }
  8347. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8348. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  8349. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  8350. }
  8351. // @@protoc_insertion_point(serialize_end:proto3.TestExtensions)
  8352. }
  8353. ::google::protobuf::uint8* TestExtensions::InternalSerializeWithCachedSizesToArray(
  8354. bool deterministic, ::google::protobuf::uint8* target) const {
  8355. (void)deterministic; // Unused
  8356. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestExtensions)
  8357. ::google::protobuf::uint32 cached_has_bits = 0;
  8358. (void) cached_has_bits;
  8359. // .protobuf_unittest.TestAllExtensions extensions = 1;
  8360. if (this->has_extensions()) {
  8361. target = ::google::protobuf::internal::WireFormatLite::
  8362. InternalWriteMessageToArray(
  8363. 1, this->_internal_extensions(), deterministic, target);
  8364. }
  8365. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8366. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  8367. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  8368. }
  8369. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestExtensions)
  8370. return target;
  8371. }
  8372. size_t TestExtensions::ByteSizeLong() const {
  8373. // @@protoc_insertion_point(message_byte_size_start:proto3.TestExtensions)
  8374. size_t total_size = 0;
  8375. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8376. total_size +=
  8377. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  8378. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  8379. }
  8380. // .protobuf_unittest.TestAllExtensions extensions = 1;
  8381. if (this->has_extensions()) {
  8382. total_size += 1 +
  8383. ::google::protobuf::internal::WireFormatLite::MessageSize(
  8384. *extensions_);
  8385. }
  8386. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  8387. SetCachedSize(cached_size);
  8388. return total_size;
  8389. }
  8390. void TestExtensions::MergeFrom(const ::google::protobuf::Message& from) {
  8391. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestExtensions)
  8392. GOOGLE_DCHECK_NE(&from, this);
  8393. const TestExtensions* source =
  8394. ::google::protobuf::internal::DynamicCastToGenerated<const TestExtensions>(
  8395. &from);
  8396. if (source == NULL) {
  8397. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestExtensions)
  8398. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  8399. } else {
  8400. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestExtensions)
  8401. MergeFrom(*source);
  8402. }
  8403. }
  8404. void TestExtensions::MergeFrom(const TestExtensions& from) {
  8405. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestExtensions)
  8406. GOOGLE_DCHECK_NE(&from, this);
  8407. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8408. ::google::protobuf::uint32 cached_has_bits = 0;
  8409. (void) cached_has_bits;
  8410. if (from.has_extensions()) {
  8411. mutable_extensions()->::protobuf_unittest::TestAllExtensions::MergeFrom(from.extensions());
  8412. }
  8413. }
  8414. void TestExtensions::CopyFrom(const ::google::protobuf::Message& from) {
  8415. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestExtensions)
  8416. if (&from == this) return;
  8417. Clear();
  8418. MergeFrom(from);
  8419. }
  8420. void TestExtensions::CopyFrom(const TestExtensions& from) {
  8421. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestExtensions)
  8422. if (&from == this) return;
  8423. Clear();
  8424. MergeFrom(from);
  8425. }
  8426. bool TestExtensions::IsInitialized() const {
  8427. if (has_extensions()) {
  8428. if (!this->extensions_->IsInitialized()) return false;
  8429. }
  8430. return true;
  8431. }
  8432. void TestExtensions::Swap(TestExtensions* other) {
  8433. if (other == this) return;
  8434. InternalSwap(other);
  8435. }
  8436. void TestExtensions::InternalSwap(TestExtensions* other) {
  8437. using std::swap;
  8438. swap(extensions_, other->extensions_);
  8439. _internal_metadata_.Swap(&other->_internal_metadata_);
  8440. }
  8441. ::google::protobuf::Metadata TestExtensions::GetMetadata() const {
  8442. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8443. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  8444. }
  8445. // ===================================================================
  8446. void TestEnumValue::InitAsDefaultInstance() {
  8447. }
  8448. #if !defined(_MSC_VER) || _MSC_VER >= 1900
  8449. const int TestEnumValue::kEnumValue1FieldNumber;
  8450. const int TestEnumValue::kEnumValue2FieldNumber;
  8451. const int TestEnumValue::kEnumValue3FieldNumber;
  8452. #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
  8453. TestEnumValue::TestEnumValue()
  8454. : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  8455. ::google::protobuf::internal::InitSCC(
  8456. &protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestEnumValue.base);
  8457. SharedCtor();
  8458. // @@protoc_insertion_point(constructor:proto3.TestEnumValue)
  8459. }
  8460. TestEnumValue::TestEnumValue(const TestEnumValue& from)
  8461. : ::google::protobuf::Message(),
  8462. _internal_metadata_(NULL) {
  8463. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8464. ::memcpy(&enum_value1_, &from.enum_value1_,
  8465. static_cast<size_t>(reinterpret_cast<char*>(&enum_value3_) -
  8466. reinterpret_cast<char*>(&enum_value1_)) + sizeof(enum_value3_));
  8467. // @@protoc_insertion_point(copy_constructor:proto3.TestEnumValue)
  8468. }
  8469. void TestEnumValue::SharedCtor() {
  8470. ::memset(&enum_value1_, 0, static_cast<size_t>(
  8471. reinterpret_cast<char*>(&enum_value3_) -
  8472. reinterpret_cast<char*>(&enum_value1_)) + sizeof(enum_value3_));
  8473. }
  8474. TestEnumValue::~TestEnumValue() {
  8475. // @@protoc_insertion_point(destructor:proto3.TestEnumValue)
  8476. SharedDtor();
  8477. }
  8478. void TestEnumValue::SharedDtor() {
  8479. }
  8480. void TestEnumValue::SetCachedSize(int size) const {
  8481. _cached_size_.Set(size);
  8482. }
  8483. const ::google::protobuf::Descriptor* TestEnumValue::descriptor() {
  8484. ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8485. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
  8486. }
  8487. const TestEnumValue& TestEnumValue::default_instance() {
  8488. ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::scc_info_TestEnumValue.base);
  8489. return *internal_default_instance();
  8490. }
  8491. void TestEnumValue::Clear() {
  8492. // @@protoc_insertion_point(message_clear_start:proto3.TestEnumValue)
  8493. ::google::protobuf::uint32 cached_has_bits = 0;
  8494. // Prevent compiler warnings about cached_has_bits being unused
  8495. (void) cached_has_bits;
  8496. ::memset(&enum_value1_, 0, static_cast<size_t>(
  8497. reinterpret_cast<char*>(&enum_value3_) -
  8498. reinterpret_cast<char*>(&enum_value1_)) + sizeof(enum_value3_));
  8499. _internal_metadata_.Clear();
  8500. }
  8501. bool TestEnumValue::MergePartialFromCodedStream(
  8502. ::google::protobuf::io::CodedInputStream* input) {
  8503. #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  8504. ::google::protobuf::uint32 tag;
  8505. // @@protoc_insertion_point(parse_start:proto3.TestEnumValue)
  8506. for (;;) {
  8507. ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  8508. tag = p.first;
  8509. if (!p.second) goto handle_unusual;
  8510. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  8511. // .proto3.EnumType enum_value1 = 1;
  8512. case 1: {
  8513. if (static_cast< ::google::protobuf::uint8>(tag) ==
  8514. static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
  8515. int value;
  8516. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  8517. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  8518. input, &value)));
  8519. set_enum_value1(static_cast< ::proto3::EnumType >(value));
  8520. } else {
  8521. goto handle_unusual;
  8522. }
  8523. break;
  8524. }
  8525. // .proto3.EnumType enum_value2 = 2;
  8526. case 2: {
  8527. if (static_cast< ::google::protobuf::uint8>(tag) ==
  8528. static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
  8529. int value;
  8530. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  8531. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  8532. input, &value)));
  8533. set_enum_value2(static_cast< ::proto3::EnumType >(value));
  8534. } else {
  8535. goto handle_unusual;
  8536. }
  8537. break;
  8538. }
  8539. // .proto3.EnumType enum_value3 = 3;
  8540. case 3: {
  8541. if (static_cast< ::google::protobuf::uint8>(tag) ==
  8542. static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) {
  8543. int value;
  8544. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  8545. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  8546. input, &value)));
  8547. set_enum_value3(static_cast< ::proto3::EnumType >(value));
  8548. } else {
  8549. goto handle_unusual;
  8550. }
  8551. break;
  8552. }
  8553. default: {
  8554. handle_unusual:
  8555. if (tag == 0) {
  8556. goto success;
  8557. }
  8558. DO_(::google::protobuf::internal::WireFormat::SkipField(
  8559. input, tag, _internal_metadata_.mutable_unknown_fields()));
  8560. break;
  8561. }
  8562. }
  8563. }
  8564. success:
  8565. // @@protoc_insertion_point(parse_success:proto3.TestEnumValue)
  8566. return true;
  8567. failure:
  8568. // @@protoc_insertion_point(parse_failure:proto3.TestEnumValue)
  8569. return false;
  8570. #undef DO_
  8571. }
  8572. void TestEnumValue::SerializeWithCachedSizes(
  8573. ::google::protobuf::io::CodedOutputStream* output) const {
  8574. // @@protoc_insertion_point(serialize_start:proto3.TestEnumValue)
  8575. ::google::protobuf::uint32 cached_has_bits = 0;
  8576. (void) cached_has_bits;
  8577. // .proto3.EnumType enum_value1 = 1;
  8578. if (this->enum_value1() != 0) {
  8579. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  8580. 1, this->enum_value1(), output);
  8581. }
  8582. // .proto3.EnumType enum_value2 = 2;
  8583. if (this->enum_value2() != 0) {
  8584. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  8585. 2, this->enum_value2(), output);
  8586. }
  8587. // .proto3.EnumType enum_value3 = 3;
  8588. if (this->enum_value3() != 0) {
  8589. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  8590. 3, this->enum_value3(), output);
  8591. }
  8592. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8593. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  8594. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
  8595. }
  8596. // @@protoc_insertion_point(serialize_end:proto3.TestEnumValue)
  8597. }
  8598. ::google::protobuf::uint8* TestEnumValue::InternalSerializeWithCachedSizesToArray(
  8599. bool deterministic, ::google::protobuf::uint8* target) const {
  8600. (void)deterministic; // Unused
  8601. // @@protoc_insertion_point(serialize_to_array_start:proto3.TestEnumValue)
  8602. ::google::protobuf::uint32 cached_has_bits = 0;
  8603. (void) cached_has_bits;
  8604. // .proto3.EnumType enum_value1 = 1;
  8605. if (this->enum_value1() != 0) {
  8606. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  8607. 1, this->enum_value1(), target);
  8608. }
  8609. // .proto3.EnumType enum_value2 = 2;
  8610. if (this->enum_value2() != 0) {
  8611. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  8612. 2, this->enum_value2(), target);
  8613. }
  8614. // .proto3.EnumType enum_value3 = 3;
  8615. if (this->enum_value3() != 0) {
  8616. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  8617. 3, this->enum_value3(), target);
  8618. }
  8619. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8620. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  8621. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
  8622. }
  8623. // @@protoc_insertion_point(serialize_to_array_end:proto3.TestEnumValue)
  8624. return target;
  8625. }
  8626. size_t TestEnumValue::ByteSizeLong() const {
  8627. // @@protoc_insertion_point(message_byte_size_start:proto3.TestEnumValue)
  8628. size_t total_size = 0;
  8629. if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
  8630. total_size +=
  8631. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  8632. (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
  8633. }
  8634. // .proto3.EnumType enum_value1 = 1;
  8635. if (this->enum_value1() != 0) {
  8636. total_size += 1 +
  8637. ::google::protobuf::internal::WireFormatLite::EnumSize(this->enum_value1());
  8638. }
  8639. // .proto3.EnumType enum_value2 = 2;
  8640. if (this->enum_value2() != 0) {
  8641. total_size += 1 +
  8642. ::google::protobuf::internal::WireFormatLite::EnumSize(this->enum_value2());
  8643. }
  8644. // .proto3.EnumType enum_value3 = 3;
  8645. if (this->enum_value3() != 0) {
  8646. total_size += 1 +
  8647. ::google::protobuf::internal::WireFormatLite::EnumSize(this->enum_value3());
  8648. }
  8649. int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  8650. SetCachedSize(cached_size);
  8651. return total_size;
  8652. }
  8653. void TestEnumValue::MergeFrom(const ::google::protobuf::Message& from) {
  8654. // @@protoc_insertion_point(generalized_merge_from_start:proto3.TestEnumValue)
  8655. GOOGLE_DCHECK_NE(&from, this);
  8656. const TestEnumValue* source =
  8657. ::google::protobuf::internal::DynamicCastToGenerated<const TestEnumValue>(
  8658. &from);
  8659. if (source == NULL) {
  8660. // @@protoc_insertion_point(generalized_merge_from_cast_fail:proto3.TestEnumValue)
  8661. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  8662. } else {
  8663. // @@protoc_insertion_point(generalized_merge_from_cast_success:proto3.TestEnumValue)
  8664. MergeFrom(*source);
  8665. }
  8666. }
  8667. void TestEnumValue::MergeFrom(const TestEnumValue& from) {
  8668. // @@protoc_insertion_point(class_specific_merge_from_start:proto3.TestEnumValue)
  8669. GOOGLE_DCHECK_NE(&from, this);
  8670. _internal_metadata_.MergeFrom(from._internal_metadata_);
  8671. ::google::protobuf::uint32 cached_has_bits = 0;
  8672. (void) cached_has_bits;
  8673. if (from.enum_value1() != 0) {
  8674. set_enum_value1(from.enum_value1());
  8675. }
  8676. if (from.enum_value2() != 0) {
  8677. set_enum_value2(from.enum_value2());
  8678. }
  8679. if (from.enum_value3() != 0) {
  8680. set_enum_value3(from.enum_value3());
  8681. }
  8682. }
  8683. void TestEnumValue::CopyFrom(const ::google::protobuf::Message& from) {
  8684. // @@protoc_insertion_point(generalized_copy_from_start:proto3.TestEnumValue)
  8685. if (&from == this) return;
  8686. Clear();
  8687. MergeFrom(from);
  8688. }
  8689. void TestEnumValue::CopyFrom(const TestEnumValue& from) {
  8690. // @@protoc_insertion_point(class_specific_copy_from_start:proto3.TestEnumValue)
  8691. if (&from == this) return;
  8692. Clear();
  8693. MergeFrom(from);
  8694. }
  8695. bool TestEnumValue::IsInitialized() const {
  8696. return true;
  8697. }
  8698. void TestEnumValue::Swap(TestEnumValue* other) {
  8699. if (other == this) return;
  8700. InternalSwap(other);
  8701. }
  8702. void TestEnumValue::InternalSwap(TestEnumValue* other) {
  8703. using std::swap;
  8704. swap(enum_value1_, other->enum_value1_);
  8705. swap(enum_value2_, other->enum_value2_);
  8706. swap(enum_value3_, other->enum_value3_);
  8707. _internal_metadata_.Swap(&other->_internal_metadata_);
  8708. }
  8709. ::google::protobuf::Metadata TestEnumValue::GetMetadata() const {
  8710. protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::protobuf_AssignDescriptorsOnce();
  8711. return ::protobuf_google_2fprotobuf_2futil_2fjson_5fformat_5fproto3_2eproto::file_level_metadata[kIndexInFileMessages];
  8712. }
  8713. // @@protoc_insertion_point(namespace_scope)
  8714. } // namespace proto3
  8715. namespace google {
  8716. namespace protobuf {
  8717. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::MessageType* Arena::CreateMaybeMessage< ::proto3::MessageType >(Arena* arena) {
  8718. return Arena::CreateInternal< ::proto3::MessageType >(arena);
  8719. }
  8720. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMessage* Arena::CreateMaybeMessage< ::proto3::TestMessage >(Arena* arena) {
  8721. return Arena::CreateInternal< ::proto3::TestMessage >(arena);
  8722. }
  8723. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestOneof* Arena::CreateMaybeMessage< ::proto3::TestOneof >(Arena* arena) {
  8724. return Arena::CreateInternal< ::proto3::TestOneof >(arena);
  8725. }
  8726. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_BoolMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_BoolMapEntry_DoNotUse >(Arena* arena) {
  8727. return Arena::CreateInternal< ::proto3::TestMap_BoolMapEntry_DoNotUse >(arena);
  8728. }
  8729. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_Int32MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_Int32MapEntry_DoNotUse >(Arena* arena) {
  8730. return Arena::CreateInternal< ::proto3::TestMap_Int32MapEntry_DoNotUse >(arena);
  8731. }
  8732. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_Int64MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_Int64MapEntry_DoNotUse >(Arena* arena) {
  8733. return Arena::CreateInternal< ::proto3::TestMap_Int64MapEntry_DoNotUse >(arena);
  8734. }
  8735. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_Uint32MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_Uint32MapEntry_DoNotUse >(Arena* arena) {
  8736. return Arena::CreateInternal< ::proto3::TestMap_Uint32MapEntry_DoNotUse >(arena);
  8737. }
  8738. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_Uint64MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_Uint64MapEntry_DoNotUse >(Arena* arena) {
  8739. return Arena::CreateInternal< ::proto3::TestMap_Uint64MapEntry_DoNotUse >(arena);
  8740. }
  8741. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap_StringMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestMap_StringMapEntry_DoNotUse >(Arena* arena) {
  8742. return Arena::CreateInternal< ::proto3::TestMap_StringMapEntry_DoNotUse >(arena);
  8743. }
  8744. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestMap* Arena::CreateMaybeMessage< ::proto3::TestMap >(Arena* arena) {
  8745. return Arena::CreateInternal< ::proto3::TestMap >(arena);
  8746. }
  8747. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_BoolMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_BoolMapEntry_DoNotUse >(Arena* arena) {
  8748. return Arena::CreateInternal< ::proto3::TestNestedMap_BoolMapEntry_DoNotUse >(arena);
  8749. }
  8750. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_Int32MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_Int32MapEntry_DoNotUse >(Arena* arena) {
  8751. return Arena::CreateInternal< ::proto3::TestNestedMap_Int32MapEntry_DoNotUse >(arena);
  8752. }
  8753. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_Int64MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_Int64MapEntry_DoNotUse >(Arena* arena) {
  8754. return Arena::CreateInternal< ::proto3::TestNestedMap_Int64MapEntry_DoNotUse >(arena);
  8755. }
  8756. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_Uint32MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_Uint32MapEntry_DoNotUse >(Arena* arena) {
  8757. return Arena::CreateInternal< ::proto3::TestNestedMap_Uint32MapEntry_DoNotUse >(arena);
  8758. }
  8759. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_Uint64MapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_Uint64MapEntry_DoNotUse >(Arena* arena) {
  8760. return Arena::CreateInternal< ::proto3::TestNestedMap_Uint64MapEntry_DoNotUse >(arena);
  8761. }
  8762. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_StringMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_StringMapEntry_DoNotUse >(Arena* arena) {
  8763. return Arena::CreateInternal< ::proto3::TestNestedMap_StringMapEntry_DoNotUse >(arena);
  8764. }
  8765. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap_MapMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestNestedMap_MapMapEntry_DoNotUse >(Arena* arena) {
  8766. return Arena::CreateInternal< ::proto3::TestNestedMap_MapMapEntry_DoNotUse >(arena);
  8767. }
  8768. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestNestedMap* Arena::CreateMaybeMessage< ::proto3::TestNestedMap >(Arena* arena) {
  8769. return Arena::CreateInternal< ::proto3::TestNestedMap >(arena);
  8770. }
  8771. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestWrapper* Arena::CreateMaybeMessage< ::proto3::TestWrapper >(Arena* arena) {
  8772. return Arena::CreateInternal< ::proto3::TestWrapper >(arena);
  8773. }
  8774. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestTimestamp* Arena::CreateMaybeMessage< ::proto3::TestTimestamp >(Arena* arena) {
  8775. return Arena::CreateInternal< ::proto3::TestTimestamp >(arena);
  8776. }
  8777. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestDuration* Arena::CreateMaybeMessage< ::proto3::TestDuration >(Arena* arena) {
  8778. return Arena::CreateInternal< ::proto3::TestDuration >(arena);
  8779. }
  8780. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestFieldMask* Arena::CreateMaybeMessage< ::proto3::TestFieldMask >(Arena* arena) {
  8781. return Arena::CreateInternal< ::proto3::TestFieldMask >(arena);
  8782. }
  8783. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestStruct* Arena::CreateMaybeMessage< ::proto3::TestStruct >(Arena* arena) {
  8784. return Arena::CreateInternal< ::proto3::TestStruct >(arena);
  8785. }
  8786. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestAny* Arena::CreateMaybeMessage< ::proto3::TestAny >(Arena* arena) {
  8787. return Arena::CreateInternal< ::proto3::TestAny >(arena);
  8788. }
  8789. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestValue* Arena::CreateMaybeMessage< ::proto3::TestValue >(Arena* arena) {
  8790. return Arena::CreateInternal< ::proto3::TestValue >(arena);
  8791. }
  8792. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestListValue* Arena::CreateMaybeMessage< ::proto3::TestListValue >(Arena* arena) {
  8793. return Arena::CreateInternal< ::proto3::TestListValue >(arena);
  8794. }
  8795. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestBoolValue_BoolMapEntry_DoNotUse* Arena::CreateMaybeMessage< ::proto3::TestBoolValue_BoolMapEntry_DoNotUse >(Arena* arena) {
  8796. return Arena::CreateInternal< ::proto3::TestBoolValue_BoolMapEntry_DoNotUse >(arena);
  8797. }
  8798. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestBoolValue* Arena::CreateMaybeMessage< ::proto3::TestBoolValue >(Arena* arena) {
  8799. return Arena::CreateInternal< ::proto3::TestBoolValue >(arena);
  8800. }
  8801. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestCustomJsonName* Arena::CreateMaybeMessage< ::proto3::TestCustomJsonName >(Arena* arena) {
  8802. return Arena::CreateInternal< ::proto3::TestCustomJsonName >(arena);
  8803. }
  8804. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestExtensions* Arena::CreateMaybeMessage< ::proto3::TestExtensions >(Arena* arena) {
  8805. return Arena::CreateInternal< ::proto3::TestExtensions >(arena);
  8806. }
  8807. template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::proto3::TestEnumValue* Arena::CreateMaybeMessage< ::proto3::TestEnumValue >(Arena* arena) {
  8808. return Arena::CreateInternal< ::proto3::TestEnumValue >(arena);
  8809. }
  8810. } // namespace protobuf
  8811. } // namespace google
  8812. // @@protoc_insertion_point(global_scope)