1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728 |
- // Generated by the protocol buffer compiler. DO NOT EDIT!
- // source: addressbook.proto
- #include "addressbook.pb.h"
- #include <algorithm>
- #include <google/protobuf/stubs/common.h>
- #include <google/protobuf/stubs/port.h>
- #include <google/protobuf/io/coded_stream.h>
- #include <google/protobuf/wire_format_lite_inl.h>
- #include <google/protobuf/descriptor.h>
- #include <google/protobuf/generated_message_reflection.h>
- #include <google/protobuf/reflection_ops.h>
- #include <google/protobuf/wire_format.h>
- // This is a temporary google only hack
- #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- #include "third_party/protobuf/version.h"
- #endif
- // @@protoc_insertion_point(includes)
- namespace protobuf_addressbook_2eproto {
- extern PROTOBUF_INTERNAL_EXPORT_protobuf_addressbook_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Address;
- extern PROTOBUF_INTERNAL_EXPORT_protobuf_addressbook_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_PhoneNumber;
- extern PROTOBUF_INTERNAL_EXPORT_protobuf_addressbook_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Contact_PhonesEntry_DoNotUse;
- extern PROTOBUF_INTERNAL_EXPORT_protobuf_addressbook_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Job;
- extern PROTOBUF_INTERNAL_EXPORT_protobuf_addressbook_2eproto ::google::protobuf::internal::SCCInfo<3> scc_info_Contact;
- } // namespace protobuf_addressbook_2eproto
- namespace qtprotobuf {
- namespace examples {
- class PhoneNumberDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<PhoneNumber>
- _instance;
- } _PhoneNumber_default_instance_;
- class AddressDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<Address>
- _instance;
- } _Address_default_instance_;
- class JobDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<Job>
- _instance;
- } _Job_default_instance_;
- class Contact_PhonesEntry_DoNotUseDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<Contact_PhonesEntry_DoNotUse>
- _instance;
- } _Contact_PhonesEntry_DoNotUse_default_instance_;
- class ContactDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<Contact>
- _instance;
- } _Contact_default_instance_;
- class ContactsDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<Contacts>
- _instance;
- } _Contacts_default_instance_;
- class SimpleResultDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<SimpleResult>
- _instance;
- } _SimpleResult_default_instance_;
- class ListFrameDefaultTypeInternal {
- public:
- ::google::protobuf::internal::ExplicitlyConstructed<ListFrame>
- _instance;
- } _ListFrame_default_instance_;
- } // namespace examples
- } // namespace qtprotobuf
- namespace protobuf_addressbook_2eproto {
- static void InitDefaultsPhoneNumber() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_PhoneNumber_default_instance_;
- new (ptr) ::qtprotobuf::examples::PhoneNumber();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::PhoneNumber::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<0> scc_info_PhoneNumber =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsPhoneNumber}, {}};
- static void InitDefaultsAddress() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_Address_default_instance_;
- new (ptr) ::qtprotobuf::examples::Address();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::Address::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<0> scc_info_Address =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsAddress}, {}};
- static void InitDefaultsJob() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_Job_default_instance_;
- new (ptr) ::qtprotobuf::examples::Job();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::Job::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<1> scc_info_Job =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsJob}, {
- &protobuf_addressbook_2eproto::scc_info_Address.base,}};
- static void InitDefaultsContact_PhonesEntry_DoNotUse() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_Contact_PhonesEntry_DoNotUse_default_instance_;
- new (ptr) ::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse();
- }
- ::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<1> scc_info_Contact_PhonesEntry_DoNotUse =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsContact_PhonesEntry_DoNotUse}, {
- &protobuf_addressbook_2eproto::scc_info_PhoneNumber.base,}};
- static void InitDefaultsContact() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_Contact_default_instance_;
- new (ptr) ::qtprotobuf::examples::Contact();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::Contact::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<3> scc_info_Contact =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 3, InitDefaultsContact}, {
- &protobuf_addressbook_2eproto::scc_info_Contact_PhonesEntry_DoNotUse.base,
- &protobuf_addressbook_2eproto::scc_info_Address.base,
- &protobuf_addressbook_2eproto::scc_info_Job.base,}};
- static void InitDefaultsContacts() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_Contacts_default_instance_;
- new (ptr) ::qtprotobuf::examples::Contacts();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::Contacts::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<1> scc_info_Contacts =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsContacts}, {
- &protobuf_addressbook_2eproto::scc_info_Contact.base,}};
- static void InitDefaultsSimpleResult() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_SimpleResult_default_instance_;
- new (ptr) ::qtprotobuf::examples::SimpleResult();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::SimpleResult::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<0> scc_info_SimpleResult =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsSimpleResult}, {}};
- static void InitDefaultsListFrame() {
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- {
- void* ptr = &::qtprotobuf::examples::_ListFrame_default_instance_;
- new (ptr) ::qtprotobuf::examples::ListFrame();
- ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
- }
- ::qtprotobuf::examples::ListFrame::InitAsDefaultInstance();
- }
- ::google::protobuf::internal::SCCInfo<0> scc_info_ListFrame =
- {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsListFrame}, {}};
- void InitDefaults() {
- ::google::protobuf::internal::InitSCC(&scc_info_PhoneNumber.base);
- ::google::protobuf::internal::InitSCC(&scc_info_Address.base);
- ::google::protobuf::internal::InitSCC(&scc_info_Job.base);
- ::google::protobuf::internal::InitSCC(&scc_info_Contact_PhonesEntry_DoNotUse.base);
- ::google::protobuf::internal::InitSCC(&scc_info_Contact.base);
- ::google::protobuf::internal::InitSCC(&scc_info_Contacts.base);
- ::google::protobuf::internal::InitSCC(&scc_info_SimpleResult.base);
- ::google::protobuf::internal::InitSCC(&scc_info_ListFrame.base);
- }
- ::google::protobuf::Metadata file_level_metadata[8];
- const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1];
- const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::PhoneNumber, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::PhoneNumber, countrycode_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::PhoneNumber, number_),
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, zipcode_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, streetaddress1_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, streetaddress2_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, state_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Address, country_),
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Job, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Job, title_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Job, officeaddress_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse, _has_bits_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse, key_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse, value_),
- 0,
- 1,
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, firstname_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, lastname_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, middlename_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, phones_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, address_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contact, job_),
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contacts, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::Contacts, list_),
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::SimpleResult, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::SimpleResult, ok_),
- ~0u, // no _has_bits_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::ListFrame, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::ListFrame, start_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::qtprotobuf::examples::ListFrame, end_),
- };
- static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
- { 0, -1, sizeof(::qtprotobuf::examples::PhoneNumber)},
- { 7, -1, sizeof(::qtprotobuf::examples::Address)},
- { 17, -1, sizeof(::qtprotobuf::examples::Job)},
- { 24, 31, sizeof(::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse)},
- { 33, -1, sizeof(::qtprotobuf::examples::Contact)},
- { 44, -1, sizeof(::qtprotobuf::examples::Contacts)},
- { 50, -1, sizeof(::qtprotobuf::examples::SimpleResult)},
- { 56, -1, sizeof(::qtprotobuf::examples::ListFrame)},
- };
- static ::google::protobuf::Message const * const file_default_instances[] = {
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_PhoneNumber_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_Address_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_Job_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_Contact_PhonesEntry_DoNotUse_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_Contact_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_Contacts_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_SimpleResult_default_instance_),
- reinterpret_cast<const ::google::protobuf::Message*>(&::qtprotobuf::examples::_ListFrame_default_instance_),
- };
- void protobuf_AssignDescriptors() {
- AddDescriptors();
- AssignDescriptors(
- "addressbook.proto", schemas, file_default_instances, TableStruct::offsets,
- file_level_metadata, file_level_enum_descriptors, NULL);
- }
- void protobuf_AssignDescriptorsOnce() {
- static ::google::protobuf::internal::once_flag once;
- ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
- }
- void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
- void protobuf_RegisterTypes(const ::std::string&) {
- protobuf_AssignDescriptorsOnce();
- ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 8);
- }
- void AddDescriptorsImpl() {
- InitDefaults();
- static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
- "\n\021addressbook.proto\022\023qtprotobuf.examples"
- "\"2\n\013PhoneNumber\022\023\n\013countryCode\030\001 \001(\r\022\016\n\006"
- "number\030\002 \001(\004\"j\n\007Address\022\017\n\007zipCode\030\001 \001(\004"
- "\022\026\n\016streetAddress1\030\002 \001(\t\022\026\n\016streetAddres"
- "s2\030\003 \001(\t\022\r\n\005state\030\004 \001(\t\022\017\n\007country\030\005 \001(\r"
- "\"I\n\003Job\022\r\n\005title\030\001 \001(\t\0223\n\rofficeAddress\030"
- "\002 \001(\0132\034.qtprotobuf.examples.Address\"\333\002\n\007"
- "Contact\022\021\n\tfirstName\030\001 \001(\t\022\020\n\010lastName\030\002"
- " \001(\t\022\022\n\nmiddleName\030\003 \001(\t\0228\n\006phones\030\004 \003(\013"
- "2(.qtprotobuf.examples.Contact.PhonesEnt"
- "ry\022-\n\007address\030\005 \001(\0132\034.qtprotobuf.example"
- "s.Address\022%\n\003job\030\006 \001(\0132\030.qtprotobuf.exam"
- "ples.Job\032O\n\013PhonesEntry\022\013\n\003key\030\001 \001(\005\022/\n\005"
- "value\030\002 \001(\0132 .qtprotobuf.examples.PhoneN"
- "umber:\0028\001\"6\n\tPhoneType\022\010\n\004Home\020\000\022\010\n\004Work"
- "\020\001\022\n\n\006Mobile\020\002\022\t\n\005Other\020\003\"6\n\010Contacts\022*\n"
- "\004list\030\001 \003(\0132\034.qtprotobuf.examples.Contac"
- "t\"\032\n\014SimpleResult\022\n\n\002ok\030\001 \001(\010\"\'\n\tListFra"
- "me\022\r\n\005start\030\001 \001(\021\022\013\n\003end\030\002 \001(\0212\232\003\n\013Addre"
- "ssBook\022K\n\naddContact\022\034.qtprotobuf.exampl"
- "es.Contact\032\035.qtprotobuf.examples.Contact"
- "s\"\000\022N\n\rremoveContact\022\034.qtprotobuf.exampl"
- "es.Contact\032\035.qtprotobuf.examples.Contact"
- "s\"\000\022N\n\013getContacts\022\036.qtprotobuf.examples"
- ".ListFrame\032\035.qtprotobuf.examples.Contact"
- "s\"\000\022M\n\010makeCall\022\034.qtprotobuf.examples.Co"
- "ntact\032!.qtprotobuf.examples.SimpleResult"
- "\"\000\022O\n\nnavigateTo\022\034.qtprotobuf.examples.A"
- "ddress\032!.qtprotobuf.examples.SimpleResul"
- "t\"\000b\006proto3"
- };
- ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
- descriptor, 1171);
- ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
- "addressbook.proto", &protobuf_RegisterTypes);
- }
- void AddDescriptors() {
- static ::google::protobuf::internal::once_flag once;
- ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
- }
- // Force AddDescriptors() to be called at dynamic initialization time.
- struct StaticDescriptorInitializer {
- StaticDescriptorInitializer() {
- AddDescriptors();
- }
- } static_descriptor_initializer;
- } // namespace protobuf_addressbook_2eproto
- namespace qtprotobuf {
- namespace examples {
- const ::google::protobuf::EnumDescriptor* Contact_PhoneType_descriptor() {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return protobuf_addressbook_2eproto::file_level_enum_descriptors[0];
- }
- bool Contact_PhoneType_IsValid(int value) {
- switch (value) {
- case 0:
- case 1:
- case 2:
- case 3:
- return true;
- default:
- return false;
- }
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const Contact_PhoneType Contact::Home;
- const Contact_PhoneType Contact::Work;
- const Contact_PhoneType Contact::Mobile;
- const Contact_PhoneType Contact::Other;
- const Contact_PhoneType Contact::PhoneType_MIN;
- const Contact_PhoneType Contact::PhoneType_MAX;
- const int Contact::PhoneType_ARRAYSIZE;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- // ===================================================================
- void PhoneNumber::InitAsDefaultInstance() {
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int PhoneNumber::kCountryCodeFieldNumber;
- const int PhoneNumber::kNumberFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- PhoneNumber::PhoneNumber()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_PhoneNumber.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.PhoneNumber)
- }
- PhoneNumber::PhoneNumber(const PhoneNumber& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::memcpy(&number_, &from.number_,
- static_cast<size_t>(reinterpret_cast<char*>(&countrycode_) -
- reinterpret_cast<char*>(&number_)) + sizeof(countrycode_));
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.PhoneNumber)
- }
- void PhoneNumber::SharedCtor() {
- ::memset(&number_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&countrycode_) -
- reinterpret_cast<char*>(&number_)) + sizeof(countrycode_));
- }
- PhoneNumber::~PhoneNumber() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.PhoneNumber)
- SharedDtor();
- }
- void PhoneNumber::SharedDtor() {
- }
- void PhoneNumber::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* PhoneNumber::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const PhoneNumber& PhoneNumber::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_PhoneNumber.base);
- return *internal_default_instance();
- }
- void PhoneNumber::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.PhoneNumber)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- ::memset(&number_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&countrycode_) -
- reinterpret_cast<char*>(&number_)) + sizeof(countrycode_));
- _internal_metadata_.Clear();
- }
- bool PhoneNumber::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.PhoneNumber)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // uint32 countryCode = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
- input, &countrycode_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // uint64 number = 2;
- case 2: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
- input, &number_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.PhoneNumber)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.PhoneNumber)
- return false;
- #undef DO_
- }
- void PhoneNumber::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.PhoneNumber)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // uint32 countryCode = 1;
- if (this->countrycode() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->countrycode(), output);
- }
- // uint64 number = 2;
- if (this->number() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->number(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.PhoneNumber)
- }
- ::google::protobuf::uint8* PhoneNumber::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.PhoneNumber)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // uint32 countryCode = 1;
- if (this->countrycode() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->countrycode(), target);
- }
- // uint64 number = 2;
- if (this->number() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(2, this->number(), target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.PhoneNumber)
- return target;
- }
- size_t PhoneNumber::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.PhoneNumber)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // uint64 number = 2;
- if (this->number() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::UInt64Size(
- this->number());
- }
- // uint32 countryCode = 1;
- if (this->countrycode() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::UInt32Size(
- this->countrycode());
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void PhoneNumber::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.PhoneNumber)
- GOOGLE_DCHECK_NE(&from, this);
- const PhoneNumber* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const PhoneNumber>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.PhoneNumber)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.PhoneNumber)
- MergeFrom(*source);
- }
- }
- void PhoneNumber::MergeFrom(const PhoneNumber& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.PhoneNumber)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- if (from.number() != 0) {
- set_number(from.number());
- }
- if (from.countrycode() != 0) {
- set_countrycode(from.countrycode());
- }
- }
- void PhoneNumber::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.PhoneNumber)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void PhoneNumber::CopyFrom(const PhoneNumber& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.PhoneNumber)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool PhoneNumber::IsInitialized() const {
- return true;
- }
- void PhoneNumber::Swap(PhoneNumber* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void PhoneNumber::InternalSwap(PhoneNumber* other) {
- using std::swap;
- swap(number_, other->number_);
- swap(countrycode_, other->countrycode_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata PhoneNumber::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- void Address::InitAsDefaultInstance() {
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int Address::kZipCodeFieldNumber;
- const int Address::kStreetAddress1FieldNumber;
- const int Address::kStreetAddress2FieldNumber;
- const int Address::kStateFieldNumber;
- const int Address::kCountryFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- Address::Address()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_Address.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.Address)
- }
- Address::Address(const Address& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- streetaddress1_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.streetaddress1().size() > 0) {
- streetaddress1_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.streetaddress1_);
- }
- streetaddress2_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.streetaddress2().size() > 0) {
- streetaddress2_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.streetaddress2_);
- }
- state_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.state().size() > 0) {
- state_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.state_);
- }
- ::memcpy(&zipcode_, &from.zipcode_,
- static_cast<size_t>(reinterpret_cast<char*>(&country_) -
- reinterpret_cast<char*>(&zipcode_)) + sizeof(country_));
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.Address)
- }
- void Address::SharedCtor() {
- streetaddress1_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- streetaddress2_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- state_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- ::memset(&zipcode_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&country_) -
- reinterpret_cast<char*>(&zipcode_)) + sizeof(country_));
- }
- Address::~Address() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.Address)
- SharedDtor();
- }
- void Address::SharedDtor() {
- streetaddress1_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- streetaddress2_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- state_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- }
- void Address::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* Address::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const Address& Address::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_Address.base);
- return *internal_default_instance();
- }
- void Address::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.Address)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- streetaddress1_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- streetaddress2_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- state_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- ::memset(&zipcode_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&country_) -
- reinterpret_cast<char*>(&zipcode_)) + sizeof(country_));
- _internal_metadata_.Clear();
- }
- bool Address::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.Address)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // uint64 zipCode = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
- input, &zipcode_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // string streetAddress1 = 2;
- case 2: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_streetaddress1()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress1().data(), static_cast<int>(this->streetaddress1().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Address.streetAddress1"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // string streetAddress2 = 3;
- case 3: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_streetaddress2()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress2().data(), static_cast<int>(this->streetaddress2().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Address.streetAddress2"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // string state = 4;
- case 4: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_state()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->state().data(), static_cast<int>(this->state().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Address.state"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // uint32 country = 5;
- case 5: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
- input, &country_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.Address)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.Address)
- return false;
- #undef DO_
- }
- void Address::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.Address)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // uint64 zipCode = 1;
- if (this->zipcode() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->zipcode(), output);
- }
- // string streetAddress1 = 2;
- if (this->streetaddress1().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress1().data(), static_cast<int>(this->streetaddress1().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.streetAddress1");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 2, this->streetaddress1(), output);
- }
- // string streetAddress2 = 3;
- if (this->streetaddress2().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress2().data(), static_cast<int>(this->streetaddress2().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.streetAddress2");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 3, this->streetaddress2(), output);
- }
- // string state = 4;
- if (this->state().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->state().data(), static_cast<int>(this->state().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.state");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 4, this->state(), output);
- }
- // uint32 country = 5;
- if (this->country() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->country(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.Address)
- }
- ::google::protobuf::uint8* Address::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.Address)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // uint64 zipCode = 1;
- if (this->zipcode() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->zipcode(), target);
- }
- // string streetAddress1 = 2;
- if (this->streetaddress1().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress1().data(), static_cast<int>(this->streetaddress1().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.streetAddress1");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 2, this->streetaddress1(), target);
- }
- // string streetAddress2 = 3;
- if (this->streetaddress2().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->streetaddress2().data(), static_cast<int>(this->streetaddress2().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.streetAddress2");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 3, this->streetaddress2(), target);
- }
- // string state = 4;
- if (this->state().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->state().data(), static_cast<int>(this->state().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Address.state");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 4, this->state(), target);
- }
- // uint32 country = 5;
- if (this->country() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->country(), target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.Address)
- return target;
- }
- size_t Address::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.Address)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // string streetAddress1 = 2;
- if (this->streetaddress1().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->streetaddress1());
- }
- // string streetAddress2 = 3;
- if (this->streetaddress2().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->streetaddress2());
- }
- // string state = 4;
- if (this->state().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->state());
- }
- // uint64 zipCode = 1;
- if (this->zipcode() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::UInt64Size(
- this->zipcode());
- }
- // uint32 country = 5;
- if (this->country() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::UInt32Size(
- this->country());
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void Address::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.Address)
- GOOGLE_DCHECK_NE(&from, this);
- const Address* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const Address>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.Address)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.Address)
- MergeFrom(*source);
- }
- }
- void Address::MergeFrom(const Address& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.Address)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- if (from.streetaddress1().size() > 0) {
- streetaddress1_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.streetaddress1_);
- }
- if (from.streetaddress2().size() > 0) {
- streetaddress2_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.streetaddress2_);
- }
- if (from.state().size() > 0) {
- state_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.state_);
- }
- if (from.zipcode() != 0) {
- set_zipcode(from.zipcode());
- }
- if (from.country() != 0) {
- set_country(from.country());
- }
- }
- void Address::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.Address)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void Address::CopyFrom(const Address& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.Address)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool Address::IsInitialized() const {
- return true;
- }
- void Address::Swap(Address* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void Address::InternalSwap(Address* other) {
- using std::swap;
- streetaddress1_.Swap(&other->streetaddress1_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- streetaddress2_.Swap(&other->streetaddress2_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- state_.Swap(&other->state_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- swap(zipcode_, other->zipcode_);
- swap(country_, other->country_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata Address::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- void Job::InitAsDefaultInstance() {
- ::qtprotobuf::examples::_Job_default_instance_._instance.get_mutable()->officeaddress_ = const_cast< ::qtprotobuf::examples::Address*>(
- ::qtprotobuf::examples::Address::internal_default_instance());
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int Job::kTitleFieldNumber;
- const int Job::kOfficeAddressFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- Job::Job()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_Job.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.Job)
- }
- Job::Job(const Job& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.title().size() > 0) {
- title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
- }
- if (from.has_officeaddress()) {
- officeaddress_ = new ::qtprotobuf::examples::Address(*from.officeaddress_);
- } else {
- officeaddress_ = NULL;
- }
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.Job)
- }
- void Job::SharedCtor() {
- title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- officeaddress_ = NULL;
- }
- Job::~Job() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.Job)
- SharedDtor();
- }
- void Job::SharedDtor() {
- title_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (this != internal_default_instance()) delete officeaddress_;
- }
- void Job::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* Job::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const Job& Job::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_Job.base);
- return *internal_default_instance();
- }
- void Job::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.Job)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- title_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (GetArenaNoVirtual() == NULL && officeaddress_ != NULL) {
- delete officeaddress_;
- }
- officeaddress_ = NULL;
- _internal_metadata_.Clear();
- }
- bool Job::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.Job)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // string title = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_title()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->title().data(), static_cast<int>(this->title().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Job.title"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // .qtprotobuf.examples.Address officeAddress = 2;
- case 2: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
- input, mutable_officeaddress()));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.Job)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.Job)
- return false;
- #undef DO_
- }
- void Job::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.Job)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // string title = 1;
- if (this->title().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->title().data(), static_cast<int>(this->title().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Job.title");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 1, this->title(), output);
- }
- // .qtprotobuf.examples.Address officeAddress = 2;
- if (this->has_officeaddress()) {
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 2, this->_internal_officeaddress(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.Job)
- }
- ::google::protobuf::uint8* Job::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.Job)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // string title = 1;
- if (this->title().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->title().data(), static_cast<int>(this->title().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Job.title");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 1, this->title(), target);
- }
- // .qtprotobuf.examples.Address officeAddress = 2;
- if (this->has_officeaddress()) {
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageToArray(
- 2, this->_internal_officeaddress(), deterministic, target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.Job)
- return target;
- }
- size_t Job::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.Job)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // string title = 1;
- if (this->title().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->title());
- }
- // .qtprotobuf.examples.Address officeAddress = 2;
- if (this->has_officeaddress()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::MessageSize(
- *officeaddress_);
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void Job::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.Job)
- GOOGLE_DCHECK_NE(&from, this);
- const Job* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const Job>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.Job)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.Job)
- MergeFrom(*source);
- }
- }
- void Job::MergeFrom(const Job& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.Job)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- if (from.title().size() > 0) {
- title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
- }
- if (from.has_officeaddress()) {
- mutable_officeaddress()->::qtprotobuf::examples::Address::MergeFrom(from.officeaddress());
- }
- }
- void Job::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.Job)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void Job::CopyFrom(const Job& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.Job)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool Job::IsInitialized() const {
- return true;
- }
- void Job::Swap(Job* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void Job::InternalSwap(Job* other) {
- using std::swap;
- title_.Swap(&other->title_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- swap(officeaddress_, other->officeaddress_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata Job::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- Contact_PhonesEntry_DoNotUse::Contact_PhonesEntry_DoNotUse() {}
- Contact_PhonesEntry_DoNotUse::Contact_PhonesEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
- void Contact_PhonesEntry_DoNotUse::MergeFrom(const Contact_PhonesEntry_DoNotUse& other) {
- MergeFromInternal(other);
- }
- ::google::protobuf::Metadata Contact_PhonesEntry_DoNotUse::GetMetadata() const {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[3];
- }
- void Contact_PhonesEntry_DoNotUse::MergeFrom(
- const ::google::protobuf::Message& other) {
- ::google::protobuf::Message::MergeFrom(other);
- }
- // ===================================================================
- void Contact::InitAsDefaultInstance() {
- ::qtprotobuf::examples::_Contact_default_instance_._instance.get_mutable()->address_ = const_cast< ::qtprotobuf::examples::Address*>(
- ::qtprotobuf::examples::Address::internal_default_instance());
- ::qtprotobuf::examples::_Contact_default_instance_._instance.get_mutable()->job_ = const_cast< ::qtprotobuf::examples::Job*>(
- ::qtprotobuf::examples::Job::internal_default_instance());
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int Contact::kFirstNameFieldNumber;
- const int Contact::kLastNameFieldNumber;
- const int Contact::kMiddleNameFieldNumber;
- const int Contact::kPhonesFieldNumber;
- const int Contact::kAddressFieldNumber;
- const int Contact::kJobFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- Contact::Contact()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_Contact.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.Contact)
- }
- Contact::Contact(const Contact& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- phones_.MergeFrom(from.phones_);
- firstname_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.firstname().size() > 0) {
- firstname_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.firstname_);
- }
- lastname_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.lastname().size() > 0) {
- lastname_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.lastname_);
- }
- middlename_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (from.middlename().size() > 0) {
- middlename_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.middlename_);
- }
- if (from.has_address()) {
- address_ = new ::qtprotobuf::examples::Address(*from.address_);
- } else {
- address_ = NULL;
- }
- if (from.has_job()) {
- job_ = new ::qtprotobuf::examples::Job(*from.job_);
- } else {
- job_ = NULL;
- }
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.Contact)
- }
- void Contact::SharedCtor() {
- firstname_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- lastname_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- middlename_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- ::memset(&address_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&job_) -
- reinterpret_cast<char*>(&address_)) + sizeof(job_));
- }
- Contact::~Contact() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.Contact)
- SharedDtor();
- }
- void Contact::SharedDtor() {
- firstname_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- lastname_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- middlename_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (this != internal_default_instance()) delete address_;
- if (this != internal_default_instance()) delete job_;
- }
- void Contact::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* Contact::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const Contact& Contact::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_Contact.base);
- return *internal_default_instance();
- }
- void Contact::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.Contact)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- phones_.Clear();
- firstname_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- lastname_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- middlename_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- if (GetArenaNoVirtual() == NULL && address_ != NULL) {
- delete address_;
- }
- address_ = NULL;
- if (GetArenaNoVirtual() == NULL && job_ != NULL) {
- delete job_;
- }
- job_ = NULL;
- _internal_metadata_.Clear();
- }
- bool Contact::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.Contact)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // string firstName = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_firstname()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->firstname().data(), static_cast<int>(this->firstname().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Contact.firstName"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // string lastName = 2;
- case 2: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_lastname()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->lastname().data(), static_cast<int>(this->lastname().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Contact.lastName"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // string middleName = 3;
- case 3: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_middlename()));
- DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->middlename().data(), static_cast<int>(this->middlename().length()),
- ::google::protobuf::internal::WireFormatLite::PARSE,
- "qtprotobuf.examples.Contact.middleName"));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // map<int32, .qtprotobuf.examples.PhoneNumber> phones = 4;
- case 4: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
- Contact_PhonesEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField<
- Contact_PhonesEntry_DoNotUse,
- ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber,
- ::google::protobuf::internal::WireFormatLite::TYPE_INT32,
- ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE,
- 0 >,
- ::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber > > parser(&phones_);
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
- input, &parser));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // .qtprotobuf.examples.Address address = 5;
- case 5: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
- input, mutable_address()));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // .qtprotobuf.examples.Job job = 6;
- case 6: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
- input, mutable_job()));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.Contact)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.Contact)
- return false;
- #undef DO_
- }
- void Contact::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.Contact)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // string firstName = 1;
- if (this->firstname().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->firstname().data(), static_cast<int>(this->firstname().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.firstName");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 1, this->firstname(), output);
- }
- // string lastName = 2;
- if (this->lastname().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->lastname().data(), static_cast<int>(this->lastname().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.lastName");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 2, this->lastname(), output);
- }
- // string middleName = 3;
- if (this->middlename().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->middlename().data(), static_cast<int>(this->middlename().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.middleName");
- ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
- 3, this->middlename(), output);
- }
- // map<int32, .qtprotobuf.examples.PhoneNumber> phones = 4;
- if (!this->phones().empty()) {
- typedef ::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_pointer
- ConstPtr;
- typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
- typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
- if (output->IsSerializationDeterministic() &&
- this->phones().size() > 1) {
- ::std::unique_ptr<SortItem[]> items(
- new SortItem[this->phones().size()]);
- typedef ::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::size_type size_type;
- size_type n = 0;
- for (::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_iterator
- it = this->phones().begin();
- it != this->phones().end(); ++it, ++n) {
- items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
- }
- ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
- ::std::unique_ptr<Contact_PhonesEntry_DoNotUse> entry;
- for (size_type i = 0; i < n; i++) {
- entry.reset(phones_.NewEntryWrapper(
- items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 4, *entry, output);
- }
- } else {
- ::std::unique_ptr<Contact_PhonesEntry_DoNotUse> entry;
- for (::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_iterator
- it = this->phones().begin();
- it != this->phones().end(); ++it) {
- entry.reset(phones_.NewEntryWrapper(
- it->first, it->second));
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 4, *entry, output);
- }
- }
- }
- // .qtprotobuf.examples.Address address = 5;
- if (this->has_address()) {
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 5, this->_internal_address(), output);
- }
- // .qtprotobuf.examples.Job job = 6;
- if (this->has_job()) {
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 6, this->_internal_job(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.Contact)
- }
- ::google::protobuf::uint8* Contact::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.Contact)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // string firstName = 1;
- if (this->firstname().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->firstname().data(), static_cast<int>(this->firstname().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.firstName");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 1, this->firstname(), target);
- }
- // string lastName = 2;
- if (this->lastname().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->lastname().data(), static_cast<int>(this->lastname().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.lastName");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 2, this->lastname(), target);
- }
- // string middleName = 3;
- if (this->middlename().size() > 0) {
- ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
- this->middlename().data(), static_cast<int>(this->middlename().length()),
- ::google::protobuf::internal::WireFormatLite::SERIALIZE,
- "qtprotobuf.examples.Contact.middleName");
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 3, this->middlename(), target);
- }
- // map<int32, .qtprotobuf.examples.PhoneNumber> phones = 4;
- if (!this->phones().empty()) {
- typedef ::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_pointer
- ConstPtr;
- typedef ::google::protobuf::internal::SortItem< ::google::protobuf::int32, ConstPtr > SortItem;
- typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less;
- if (deterministic &&
- this->phones().size() > 1) {
- ::std::unique_ptr<SortItem[]> items(
- new SortItem[this->phones().size()]);
- typedef ::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::size_type size_type;
- size_type n = 0;
- for (::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_iterator
- it = this->phones().begin();
- it != this->phones().end(); ++it, ++n) {
- items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
- }
- ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
- ::std::unique_ptr<Contact_PhonesEntry_DoNotUse> entry;
- for (size_type i = 0; i < n; i++) {
- entry.reset(phones_.NewEntryWrapper(
- items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second));
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageNoVirtualToArray(
- 4, *entry, deterministic, target);
- ;
- }
- } else {
- ::std::unique_ptr<Contact_PhonesEntry_DoNotUse> entry;
- for (::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_iterator
- it = this->phones().begin();
- it != this->phones().end(); ++it) {
- entry.reset(phones_.NewEntryWrapper(
- it->first, it->second));
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageNoVirtualToArray(
- 4, *entry, deterministic, target);
- ;
- }
- }
- }
- // .qtprotobuf.examples.Address address = 5;
- if (this->has_address()) {
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageToArray(
- 5, this->_internal_address(), deterministic, target);
- }
- // .qtprotobuf.examples.Job job = 6;
- if (this->has_job()) {
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageToArray(
- 6, this->_internal_job(), deterministic, target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.Contact)
- return target;
- }
- size_t Contact::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.Contact)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // map<int32, .qtprotobuf.examples.PhoneNumber> phones = 4;
- total_size += 1 *
- ::google::protobuf::internal::FromIntSize(this->phones_size());
- {
- ::std::unique_ptr<Contact_PhonesEntry_DoNotUse> entry;
- for (::google::protobuf::Map< ::google::protobuf::int32, ::qtprotobuf::examples::PhoneNumber >::const_iterator
- it = this->phones().begin();
- it != this->phones().end(); ++it) {
- entry.reset(phones_.NewEntryWrapper(it->first, it->second));
- total_size += ::google::protobuf::internal::WireFormatLite::
- MessageSizeNoVirtual(*entry);
- }
- }
- // string firstName = 1;
- if (this->firstname().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->firstname());
- }
- // string lastName = 2;
- if (this->lastname().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->lastname());
- }
- // string middleName = 3;
- if (this->middlename().size() > 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->middlename());
- }
- // .qtprotobuf.examples.Address address = 5;
- if (this->has_address()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::MessageSize(
- *address_);
- }
- // .qtprotobuf.examples.Job job = 6;
- if (this->has_job()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::MessageSize(
- *job_);
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void Contact::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.Contact)
- GOOGLE_DCHECK_NE(&from, this);
- const Contact* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const Contact>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.Contact)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.Contact)
- MergeFrom(*source);
- }
- }
- void Contact::MergeFrom(const Contact& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.Contact)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- phones_.MergeFrom(from.phones_);
- if (from.firstname().size() > 0) {
- firstname_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.firstname_);
- }
- if (from.lastname().size() > 0) {
- lastname_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.lastname_);
- }
- if (from.middlename().size() > 0) {
- middlename_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.middlename_);
- }
- if (from.has_address()) {
- mutable_address()->::qtprotobuf::examples::Address::MergeFrom(from.address());
- }
- if (from.has_job()) {
- mutable_job()->::qtprotobuf::examples::Job::MergeFrom(from.job());
- }
- }
- void Contact::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.Contact)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void Contact::CopyFrom(const Contact& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.Contact)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool Contact::IsInitialized() const {
- return true;
- }
- void Contact::Swap(Contact* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void Contact::InternalSwap(Contact* other) {
- using std::swap;
- phones_.Swap(&other->phones_);
- firstname_.Swap(&other->firstname_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- lastname_.Swap(&other->lastname_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- middlename_.Swap(&other->middlename_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
- GetArenaNoVirtual());
- swap(address_, other->address_);
- swap(job_, other->job_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata Contact::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- void Contacts::InitAsDefaultInstance() {
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int Contacts::kListFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- Contacts::Contacts()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_Contacts.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.Contacts)
- }
- Contacts::Contacts(const Contacts& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL),
- list_(from.list_) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.Contacts)
- }
- void Contacts::SharedCtor() {
- }
- Contacts::~Contacts() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.Contacts)
- SharedDtor();
- }
- void Contacts::SharedDtor() {
- }
- void Contacts::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* Contacts::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const Contacts& Contacts::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_Contacts.base);
- return *internal_default_instance();
- }
- void Contacts::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.Contacts)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- list_.Clear();
- _internal_metadata_.Clear();
- }
- bool Contacts::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.Contacts)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // repeated .qtprotobuf.examples.Contact list = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
- input, add_list()));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.Contacts)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.Contacts)
- return false;
- #undef DO_
- }
- void Contacts::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.Contacts)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // repeated .qtprotobuf.examples.Contact list = 1;
- for (unsigned int i = 0,
- n = static_cast<unsigned int>(this->list_size()); i < n; i++) {
- ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 1,
- this->list(static_cast<int>(i)),
- output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.Contacts)
- }
- ::google::protobuf::uint8* Contacts::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.Contacts)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // repeated .qtprotobuf.examples.Contact list = 1;
- for (unsigned int i = 0,
- n = static_cast<unsigned int>(this->list_size()); i < n; i++) {
- target = ::google::protobuf::internal::WireFormatLite::
- InternalWriteMessageToArray(
- 1, this->list(static_cast<int>(i)), deterministic, target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.Contacts)
- return target;
- }
- size_t Contacts::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.Contacts)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // repeated .qtprotobuf.examples.Contact list = 1;
- {
- unsigned int count = static_cast<unsigned int>(this->list_size());
- total_size += 1UL * count;
- for (unsigned int i = 0; i < count; i++) {
- total_size +=
- ::google::protobuf::internal::WireFormatLite::MessageSize(
- this->list(static_cast<int>(i)));
- }
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void Contacts::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.Contacts)
- GOOGLE_DCHECK_NE(&from, this);
- const Contacts* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const Contacts>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.Contacts)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.Contacts)
- MergeFrom(*source);
- }
- }
- void Contacts::MergeFrom(const Contacts& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.Contacts)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- list_.MergeFrom(from.list_);
- }
- void Contacts::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.Contacts)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void Contacts::CopyFrom(const Contacts& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.Contacts)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool Contacts::IsInitialized() const {
- return true;
- }
- void Contacts::Swap(Contacts* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void Contacts::InternalSwap(Contacts* other) {
- using std::swap;
- CastToBase(&list_)->InternalSwap(CastToBase(&other->list_));
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata Contacts::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- void SimpleResult::InitAsDefaultInstance() {
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int SimpleResult::kOkFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- SimpleResult::SimpleResult()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_SimpleResult.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.SimpleResult)
- }
- SimpleResult::SimpleResult(const SimpleResult& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ok_ = from.ok_;
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.SimpleResult)
- }
- void SimpleResult::SharedCtor() {
- ok_ = false;
- }
- SimpleResult::~SimpleResult() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.SimpleResult)
- SharedDtor();
- }
- void SimpleResult::SharedDtor() {
- }
- void SimpleResult::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* SimpleResult::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const SimpleResult& SimpleResult::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_SimpleResult.base);
- return *internal_default_instance();
- }
- void SimpleResult::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.SimpleResult)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- ok_ = false;
- _internal_metadata_.Clear();
- }
- bool SimpleResult::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.SimpleResult)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // bool ok = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
- input, &ok_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.SimpleResult)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.SimpleResult)
- return false;
- #undef DO_
- }
- void SimpleResult::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.SimpleResult)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // bool ok = 1;
- if (this->ok() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->ok(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.SimpleResult)
- }
- ::google::protobuf::uint8* SimpleResult::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.SimpleResult)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // bool ok = 1;
- if (this->ok() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->ok(), target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.SimpleResult)
- return target;
- }
- size_t SimpleResult::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.SimpleResult)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // bool ok = 1;
- if (this->ok() != 0) {
- total_size += 1 + 1;
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void SimpleResult::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.SimpleResult)
- GOOGLE_DCHECK_NE(&from, this);
- const SimpleResult* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const SimpleResult>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.SimpleResult)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.SimpleResult)
- MergeFrom(*source);
- }
- }
- void SimpleResult::MergeFrom(const SimpleResult& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.SimpleResult)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- if (from.ok() != 0) {
- set_ok(from.ok());
- }
- }
- void SimpleResult::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.SimpleResult)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void SimpleResult::CopyFrom(const SimpleResult& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.SimpleResult)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool SimpleResult::IsInitialized() const {
- return true;
- }
- void SimpleResult::Swap(SimpleResult* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void SimpleResult::InternalSwap(SimpleResult* other) {
- using std::swap;
- swap(ok_, other->ok_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata SimpleResult::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // ===================================================================
- void ListFrame::InitAsDefaultInstance() {
- }
- #if !defined(_MSC_VER) || _MSC_VER >= 1900
- const int ListFrame::kStartFieldNumber;
- const int ListFrame::kEndFieldNumber;
- #endif // !defined(_MSC_VER) || _MSC_VER >= 1900
- ListFrame::ListFrame()
- : ::google::protobuf::Message(), _internal_metadata_(NULL) {
- ::google::protobuf::internal::InitSCC(
- &protobuf_addressbook_2eproto::scc_info_ListFrame.base);
- SharedCtor();
- // @@protoc_insertion_point(constructor:qtprotobuf.examples.ListFrame)
- }
- ListFrame::ListFrame(const ListFrame& from)
- : ::google::protobuf::Message(),
- _internal_metadata_(NULL) {
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::memcpy(&start_, &from.start_,
- static_cast<size_t>(reinterpret_cast<char*>(&end_) -
- reinterpret_cast<char*>(&start_)) + sizeof(end_));
- // @@protoc_insertion_point(copy_constructor:qtprotobuf.examples.ListFrame)
- }
- void ListFrame::SharedCtor() {
- ::memset(&start_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&end_) -
- reinterpret_cast<char*>(&start_)) + sizeof(end_));
- }
- ListFrame::~ListFrame() {
- // @@protoc_insertion_point(destructor:qtprotobuf.examples.ListFrame)
- SharedDtor();
- }
- void ListFrame::SharedDtor() {
- }
- void ListFrame::SetCachedSize(int size) const {
- _cached_size_.Set(size);
- }
- const ::google::protobuf::Descriptor* ListFrame::descriptor() {
- ::protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
- }
- const ListFrame& ListFrame::default_instance() {
- ::google::protobuf::internal::InitSCC(&protobuf_addressbook_2eproto::scc_info_ListFrame.base);
- return *internal_default_instance();
- }
- void ListFrame::Clear() {
- // @@protoc_insertion_point(message_clear_start:qtprotobuf.examples.ListFrame)
- ::google::protobuf::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
- ::memset(&start_, 0, static_cast<size_t>(
- reinterpret_cast<char*>(&end_) -
- reinterpret_cast<char*>(&start_)) + sizeof(end_));
- _internal_metadata_.Clear();
- }
- bool ListFrame::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
- ::google::protobuf::uint32 tag;
- // @@protoc_insertion_point(parse_start:qtprotobuf.examples.ListFrame)
- for (;;) {
- ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
- tag = p.first;
- if (!p.second) goto handle_unusual;
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // sint32 start = 1;
- case 1: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_SINT32>(
- input, &start_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- // sint32 end = 2;
- case 2: {
- if (static_cast< ::google::protobuf::uint8>(tag) ==
- static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_SINT32>(
- input, &end_)));
- } else {
- goto handle_unusual;
- }
- break;
- }
- default: {
- handle_unusual:
- if (tag == 0) {
- goto success;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, _internal_metadata_.mutable_unknown_fields()));
- break;
- }
- }
- }
- success:
- // @@protoc_insertion_point(parse_success:qtprotobuf.examples.ListFrame)
- return true;
- failure:
- // @@protoc_insertion_point(parse_failure:qtprotobuf.examples.ListFrame)
- return false;
- #undef DO_
- }
- void ListFrame::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // @@protoc_insertion_point(serialize_start:qtprotobuf.examples.ListFrame)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // sint32 start = 1;
- if (this->start() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteSInt32(1, this->start(), output);
- }
- // sint32 end = 2;
- if (this->end() != 0) {
- ::google::protobuf::internal::WireFormatLite::WriteSInt32(2, this->end(), output);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
- }
- // @@protoc_insertion_point(serialize_end:qtprotobuf.examples.ListFrame)
- }
- ::google::protobuf::uint8* ListFrame::InternalSerializeWithCachedSizesToArray(
- bool deterministic, ::google::protobuf::uint8* target) const {
- (void)deterministic; // Unused
- // @@protoc_insertion_point(serialize_to_array_start:qtprotobuf.examples.ListFrame)
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- // sint32 start = 1;
- if (this->start() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteSInt32ToArray(1, this->start(), target);
- }
- // sint32 end = 2;
- if (this->end() != 0) {
- target = ::google::protobuf::internal::WireFormatLite::WriteSInt32ToArray(2, this->end(), target);
- }
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
- }
- // @@protoc_insertion_point(serialize_to_array_end:qtprotobuf.examples.ListFrame)
- return target;
- }
- size_t ListFrame::ByteSizeLong() const {
- // @@protoc_insertion_point(message_byte_size_start:qtprotobuf.examples.ListFrame)
- size_t total_size = 0;
- if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
- }
- // sint32 start = 1;
- if (this->start() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::SInt32Size(
- this->start());
- }
- // sint32 end = 2;
- if (this->end() != 0) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::SInt32Size(
- this->end());
- }
- int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- SetCachedSize(cached_size);
- return total_size;
- }
- void ListFrame::MergeFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_merge_from_start:qtprotobuf.examples.ListFrame)
- GOOGLE_DCHECK_NE(&from, this);
- const ListFrame* source =
- ::google::protobuf::internal::DynamicCastToGenerated<const ListFrame>(
- &from);
- if (source == NULL) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:qtprotobuf.examples.ListFrame)
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:qtprotobuf.examples.ListFrame)
- MergeFrom(*source);
- }
- }
- void ListFrame::MergeFrom(const ListFrame& from) {
- // @@protoc_insertion_point(class_specific_merge_from_start:qtprotobuf.examples.ListFrame)
- GOOGLE_DCHECK_NE(&from, this);
- _internal_metadata_.MergeFrom(from._internal_metadata_);
- ::google::protobuf::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
- if (from.start() != 0) {
- set_start(from.start());
- }
- if (from.end() != 0) {
- set_end(from.end());
- }
- }
- void ListFrame::CopyFrom(const ::google::protobuf::Message& from) {
- // @@protoc_insertion_point(generalized_copy_from_start:qtprotobuf.examples.ListFrame)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void ListFrame::CopyFrom(const ListFrame& from) {
- // @@protoc_insertion_point(class_specific_copy_from_start:qtprotobuf.examples.ListFrame)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool ListFrame::IsInitialized() const {
- return true;
- }
- void ListFrame::Swap(ListFrame* other) {
- if (other == this) return;
- InternalSwap(other);
- }
- void ListFrame::InternalSwap(ListFrame* other) {
- using std::swap;
- swap(start_, other->start_);
- swap(end_, other->end_);
- _internal_metadata_.Swap(&other->_internal_metadata_);
- }
- ::google::protobuf::Metadata ListFrame::GetMetadata() const {
- protobuf_addressbook_2eproto::protobuf_AssignDescriptorsOnce();
- return ::protobuf_addressbook_2eproto::file_level_metadata[kIndexInFileMessages];
- }
- // @@protoc_insertion_point(namespace_scope)
- } // namespace examples
- } // namespace qtprotobuf
- namespace google {
- namespace protobuf {
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::PhoneNumber* Arena::CreateMaybeMessage< ::qtprotobuf::examples::PhoneNumber >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::PhoneNumber >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::Address* Arena::CreateMaybeMessage< ::qtprotobuf::examples::Address >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::Address >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::Job* Arena::CreateMaybeMessage< ::qtprotobuf::examples::Job >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::Job >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse* Arena::CreateMaybeMessage< ::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::Contact_PhonesEntry_DoNotUse >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::Contact* Arena::CreateMaybeMessage< ::qtprotobuf::examples::Contact >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::Contact >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::Contacts* Arena::CreateMaybeMessage< ::qtprotobuf::examples::Contacts >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::Contacts >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::SimpleResult* Arena::CreateMaybeMessage< ::qtprotobuf::examples::SimpleResult >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::SimpleResult >(arena);
- }
- template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::qtprotobuf::examples::ListFrame* Arena::CreateMaybeMessage< ::qtprotobuf::examples::ListFrame >(Arena* arena) {
- return Arena::CreateInternal< ::qtprotobuf::examples::ListFrame >(arena);
- }
- } // namespace protobuf
- } // namespace google
- // @@protoc_insertion_point(global_scope)
|