search_store.pb.cc 67 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118
  1. // Generated by the protocol buffer compiler. DO NOT EDIT!
  2. #define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
  3. #include "search_store.pb.h"
  4. #include <algorithm>
  5. #include <google/protobuf/stubs/once.h>
  6. #include <google/protobuf/io/coded_stream.h>
  7. #include <google/protobuf/wire_format_lite_inl.h>
  8. #include <google/protobuf/descriptor.h>
  9. #include <google/protobuf/reflection_ops.h>
  10. #include <google/protobuf/wire_format.h>
  11. // @@protoc_insertion_point(includes)
  12. namespace lsmsearch {
  13. namespace {
  14. const ::google::protobuf::Descriptor* StoreIndexField_descriptor_ = NULL;
  15. const ::google::protobuf::internal::GeneratedMessageReflection*
  16. StoreIndexField_reflection_ = NULL;
  17. const ::google::protobuf::Descriptor* StoreDocument_descriptor_ = NULL;
  18. const ::google::protobuf::internal::GeneratedMessageReflection*
  19. StoreDocument_reflection_ = NULL;
  20. const ::google::protobuf::Descriptor* StoreDocValue_descriptor_ = NULL;
  21. const ::google::protobuf::internal::GeneratedMessageReflection*
  22. StoreDocValue_reflection_ = NULL;
  23. const ::google::protobuf::Descriptor* StoreMeta_descriptor_ = NULL;
  24. const ::google::protobuf::internal::GeneratedMessageReflection*
  25. StoreMeta_reflection_ = NULL;
  26. const ::google::protobuf::Descriptor* MockData_descriptor_ = NULL;
  27. const ::google::protobuf::internal::GeneratedMessageReflection*
  28. MockData_reflection_ = NULL;
  29. const ::google::protobuf::EnumDescriptor* MockData_Type_descriptor_ = NULL;
  30. const ::google::protobuf::Descriptor* MockDataList_descriptor_ = NULL;
  31. const ::google::protobuf::internal::GeneratedMessageReflection*
  32. MockDataList_reflection_ = NULL;
  33. } // namespace
  34. void protobuf_AssignDesc_search_5fstore_2eproto() {
  35. protobuf_AddDesc_search_5fstore_2eproto();
  36. const ::google::protobuf::FileDescriptor* file =
  37. ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
  38. "search_store.proto");
  39. GOOGLE_CHECK(file != NULL);
  40. StoreIndexField_descriptor_ = file->message_type(0);
  41. static const int StoreIndexField_offsets_[7] = {
  42. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, field_id_),
  43. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, field_flag_),
  44. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, field_type_),
  45. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, numeric_value_),
  46. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, string_value_),
  47. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, terms_),
  48. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, suffix_len_),
  49. };
  50. StoreIndexField_reflection_ =
  51. new ::google::protobuf::internal::GeneratedMessageReflection(
  52. StoreIndexField_descriptor_,
  53. StoreIndexField::default_instance_,
  54. StoreIndexField_offsets_,
  55. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, _has_bits_[0]),
  56. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreIndexField, _unknown_fields_),
  57. -1,
  58. ::google::protobuf::DescriptorPool::generated_pool(),
  59. ::google::protobuf::MessageFactory::generated_factory(),
  60. sizeof(StoreIndexField));
  61. StoreDocument_descriptor_ = file->message_type(1);
  62. static const int StoreDocument_offsets_[2] = {
  63. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocument, document_id_),
  64. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocument, fields_),
  65. };
  66. StoreDocument_reflection_ =
  67. new ::google::protobuf::internal::GeneratedMessageReflection(
  68. StoreDocument_descriptor_,
  69. StoreDocument::default_instance_,
  70. StoreDocument_offsets_,
  71. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocument, _has_bits_[0]),
  72. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocument, _unknown_fields_),
  73. -1,
  74. ::google::protobuf::DescriptorPool::generated_pool(),
  75. ::google::protobuf::MessageFactory::generated_factory(),
  76. sizeof(StoreDocument));
  77. StoreDocValue_descriptor_ = file->message_type(2);
  78. static const int StoreDocValue_offsets_[1] = {
  79. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocValue, fields_),
  80. };
  81. StoreDocValue_reflection_ =
  82. new ::google::protobuf::internal::GeneratedMessageReflection(
  83. StoreDocValue_descriptor_,
  84. StoreDocValue::default_instance_,
  85. StoreDocValue_offsets_,
  86. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocValue, _has_bits_[0]),
  87. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreDocValue, _unknown_fields_),
  88. -1,
  89. ::google::protobuf::DescriptorPool::generated_pool(),
  90. ::google::protobuf::MessageFactory::generated_factory(),
  91. sizeof(StoreDocValue));
  92. StoreMeta_descriptor_ = file->message_type(3);
  93. static const int StoreMeta_offsets_[4] = {
  94. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, total_documents_),
  95. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, delete_documents_),
  96. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, increase_seq_),
  97. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, terms_count_),
  98. };
  99. StoreMeta_reflection_ =
  100. new ::google::protobuf::internal::GeneratedMessageReflection(
  101. StoreMeta_descriptor_,
  102. StoreMeta::default_instance_,
  103. StoreMeta_offsets_,
  104. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, _has_bits_[0]),
  105. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(StoreMeta, _unknown_fields_),
  106. -1,
  107. ::google::protobuf::DescriptorPool::generated_pool(),
  108. ::google::protobuf::MessageFactory::generated_factory(),
  109. sizeof(StoreMeta));
  110. MockData_descriptor_ = file->message_type(4);
  111. static const int MockData_offsets_[5] = {
  112. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, column_type_),
  113. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, key_),
  114. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, value_),
  115. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, type_),
  116. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, end_key_),
  117. };
  118. MockData_reflection_ =
  119. new ::google::protobuf::internal::GeneratedMessageReflection(
  120. MockData_descriptor_,
  121. MockData::default_instance_,
  122. MockData_offsets_,
  123. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, _has_bits_[0]),
  124. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockData, _unknown_fields_),
  125. -1,
  126. ::google::protobuf::DescriptorPool::generated_pool(),
  127. ::google::protobuf::MessageFactory::generated_factory(),
  128. sizeof(MockData));
  129. MockData_Type_descriptor_ = MockData_descriptor_->enum_type(0);
  130. MockDataList_descriptor_ = file->message_type(5);
  131. static const int MockDataList_offsets_[1] = {
  132. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockDataList, mock_data_list_),
  133. };
  134. MockDataList_reflection_ =
  135. new ::google::protobuf::internal::GeneratedMessageReflection(
  136. MockDataList_descriptor_,
  137. MockDataList::default_instance_,
  138. MockDataList_offsets_,
  139. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockDataList, _has_bits_[0]),
  140. GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MockDataList, _unknown_fields_),
  141. -1,
  142. ::google::protobuf::DescriptorPool::generated_pool(),
  143. ::google::protobuf::MessageFactory::generated_factory(),
  144. sizeof(MockDataList));
  145. }
  146. namespace {
  147. GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
  148. inline void protobuf_AssignDescriptorsOnce() {
  149. ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
  150. &protobuf_AssignDesc_search_5fstore_2eproto);
  151. }
  152. void protobuf_RegisterTypes(const ::std::string&) {
  153. protobuf_AssignDescriptorsOnce();
  154. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  155. StoreIndexField_descriptor_, &StoreIndexField::default_instance());
  156. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  157. StoreDocument_descriptor_, &StoreDocument::default_instance());
  158. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  159. StoreDocValue_descriptor_, &StoreDocValue::default_instance());
  160. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  161. StoreMeta_descriptor_, &StoreMeta::default_instance());
  162. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  163. MockData_descriptor_, &MockData::default_instance());
  164. ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
  165. MockDataList_descriptor_, &MockDataList::default_instance());
  166. }
  167. } // namespace
  168. void protobuf_ShutdownFile_search_5fstore_2eproto() {
  169. delete StoreIndexField::default_instance_;
  170. delete StoreIndexField_reflection_;
  171. delete StoreDocument::default_instance_;
  172. delete StoreDocument_reflection_;
  173. delete StoreDocValue::default_instance_;
  174. delete StoreDocValue_reflection_;
  175. delete StoreMeta::default_instance_;
  176. delete StoreMeta_reflection_;
  177. delete MockData::default_instance_;
  178. delete MockData_reflection_;
  179. delete MockDataList::default_instance_;
  180. delete MockDataList_reflection_;
  181. }
  182. void protobuf_AddDesc_search_5fstore_2eproto() {
  183. static bool already_here = false;
  184. if (already_here) return;
  185. already_here = true;
  186. GOOGLE_PROTOBUF_VERIFY_VERSION;
  187. ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
  188. "\n\022search_store.proto\022\tlsmsearch\"\233\001\n\017Stor"
  189. "eIndexField\022\020\n\010field_id\030\001 \002(\r\022\022\n\nfield_f"
  190. "lag\030\002 \002(\r\022\022\n\nfield_type\030\003 \002(\r\022\025\n\rnumeric"
  191. "_value\030\004 \001(\004\022\024\n\014string_value\030\005 \001(\014\022\r\n\005te"
  192. "rms\030\006 \003(\014\022\022\n\nsuffix_len\030\n \001(\r\"P\n\rStoreDo"
  193. "cument\022\023\n\013document_id\030\001 \002(\004\022*\n\006fields\030\002 "
  194. "\003(\0132\032.lsmsearch.StoreIndexField\";\n\rStore"
  195. "DocValue\022*\n\006fields\030\001 \003(\0132\032.lsmsearch.Sto"
  196. "reIndexField\"i\n\tStoreMeta\022\027\n\017total_docum"
  197. "ents\030\001 \001(\004\022\030\n\020delete_documents\030\002 \001(\004\022\024\n\014"
  198. "increase_seq\030\003 \001(\004\022\023\n\013terms_count\030\004 \001(\004\""
  199. "\302\001\n\010MockData\022\023\n\013column_type\030\001 \002(\r\022\013\n\003key"
  200. "\030\002 \002(\014\022\r\n\005value\030\003 \002(\014\022&\n\004type\030\004 \002(\0162\030.ls"
  201. "msearch.MockData.Type\022\017\n\007end_key\030\005 \001(\014\"L"
  202. "\n\004Type\022\014\n\010kUnknown\020\000\022\013\n\007kUpdate\020\001\022\n\n\006kMe"
  203. "rge\020\002\022\013\n\007kDelete\020\003\022\020\n\014kDeleteRange\020\004\";\n\014"
  204. "MockDataList\022+\n\016mock_data_list\030\001 \003(\0132\023.l"
  205. "smsearch.MockData", 697);
  206. ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
  207. "search_store.proto", &protobuf_RegisterTypes);
  208. StoreIndexField::default_instance_ = new StoreIndexField();
  209. StoreDocument::default_instance_ = new StoreDocument();
  210. StoreDocValue::default_instance_ = new StoreDocValue();
  211. StoreMeta::default_instance_ = new StoreMeta();
  212. MockData::default_instance_ = new MockData();
  213. MockDataList::default_instance_ = new MockDataList();
  214. StoreIndexField::default_instance_->InitAsDefaultInstance();
  215. StoreDocument::default_instance_->InitAsDefaultInstance();
  216. StoreDocValue::default_instance_->InitAsDefaultInstance();
  217. StoreMeta::default_instance_->InitAsDefaultInstance();
  218. MockData::default_instance_->InitAsDefaultInstance();
  219. MockDataList::default_instance_->InitAsDefaultInstance();
  220. ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_search_5fstore_2eproto);
  221. }
  222. // Force AddDescriptors() to be called at static initialization time.
  223. struct StaticDescriptorInitializer_search_5fstore_2eproto {
  224. StaticDescriptorInitializer_search_5fstore_2eproto() {
  225. protobuf_AddDesc_search_5fstore_2eproto();
  226. }
  227. } static_descriptor_initializer_search_5fstore_2eproto_;
  228. // ===================================================================
  229. #ifndef _MSC_VER
  230. const int StoreIndexField::kFieldIdFieldNumber;
  231. const int StoreIndexField::kFieldFlagFieldNumber;
  232. const int StoreIndexField::kFieldTypeFieldNumber;
  233. const int StoreIndexField::kNumericValueFieldNumber;
  234. const int StoreIndexField::kStringValueFieldNumber;
  235. const int StoreIndexField::kTermsFieldNumber;
  236. const int StoreIndexField::kSuffixLenFieldNumber;
  237. #endif // !_MSC_VER
  238. StoreIndexField::StoreIndexField()
  239. : ::google::protobuf::Message() {
  240. SharedCtor();
  241. }
  242. void StoreIndexField::InitAsDefaultInstance() {
  243. }
  244. StoreIndexField::StoreIndexField(const StoreIndexField& from)
  245. : ::google::protobuf::Message() {
  246. SharedCtor();
  247. MergeFrom(from);
  248. }
  249. void StoreIndexField::SharedCtor() {
  250. _cached_size_ = 0;
  251. field_id_ = 0u;
  252. field_flag_ = 0u;
  253. field_type_ = 0u;
  254. numeric_value_ = GOOGLE_ULONGLONG(0);
  255. string_value_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  256. suffix_len_ = 0u;
  257. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  258. }
  259. StoreIndexField::~StoreIndexField() {
  260. SharedDtor();
  261. }
  262. void StoreIndexField::SharedDtor() {
  263. if (string_value_ != &::google::protobuf::internal::kEmptyString) {
  264. delete string_value_;
  265. }
  266. if (this != default_instance_) {
  267. }
  268. }
  269. void StoreIndexField::SetCachedSize(int size) const {
  270. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  271. _cached_size_ = size;
  272. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  273. }
  274. const ::google::protobuf::Descriptor* StoreIndexField::descriptor() {
  275. protobuf_AssignDescriptorsOnce();
  276. return StoreIndexField_descriptor_;
  277. }
  278. const StoreIndexField& StoreIndexField::default_instance() {
  279. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  280. }
  281. StoreIndexField* StoreIndexField::default_instance_ = NULL;
  282. StoreIndexField* StoreIndexField::New() const {
  283. return new StoreIndexField;
  284. }
  285. void StoreIndexField::Clear() {
  286. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  287. field_id_ = 0u;
  288. field_flag_ = 0u;
  289. field_type_ = 0u;
  290. numeric_value_ = GOOGLE_ULONGLONG(0);
  291. if (has_string_value()) {
  292. if (string_value_ != &::google::protobuf::internal::kEmptyString) {
  293. string_value_->clear();
  294. }
  295. }
  296. suffix_len_ = 0u;
  297. }
  298. terms_.Clear();
  299. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  300. mutable_unknown_fields()->Clear();
  301. }
  302. bool StoreIndexField::MergePartialFromCodedStream(
  303. ::google::protobuf::io::CodedInputStream* input) {
  304. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  305. ::google::protobuf::uint32 tag;
  306. while ((tag = input->ReadTag()) != 0) {
  307. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  308. // required uint32 field_id = 1;
  309. case 1: {
  310. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  311. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  312. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  313. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  314. input, &field_id_)));
  315. set_has_field_id();
  316. } else {
  317. goto handle_uninterpreted;
  318. }
  319. if (input->ExpectTag(16)) goto parse_field_flag;
  320. break;
  321. }
  322. // required uint32 field_flag = 2;
  323. case 2: {
  324. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  325. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  326. parse_field_flag:
  327. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  328. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  329. input, &field_flag_)));
  330. set_has_field_flag();
  331. } else {
  332. goto handle_uninterpreted;
  333. }
  334. if (input->ExpectTag(24)) goto parse_field_type;
  335. break;
  336. }
  337. // required uint32 field_type = 3;
  338. case 3: {
  339. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  340. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  341. parse_field_type:
  342. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  343. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  344. input, &field_type_)));
  345. set_has_field_type();
  346. } else {
  347. goto handle_uninterpreted;
  348. }
  349. if (input->ExpectTag(32)) goto parse_numeric_value;
  350. break;
  351. }
  352. // optional uint64 numeric_value = 4;
  353. case 4: {
  354. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  355. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  356. parse_numeric_value:
  357. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  358. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  359. input, &numeric_value_)));
  360. set_has_numeric_value();
  361. } else {
  362. goto handle_uninterpreted;
  363. }
  364. if (input->ExpectTag(42)) goto parse_string_value;
  365. break;
  366. }
  367. // optional bytes string_value = 5;
  368. case 5: {
  369. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  370. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  371. parse_string_value:
  372. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  373. input, this->mutable_string_value()));
  374. } else {
  375. goto handle_uninterpreted;
  376. }
  377. if (input->ExpectTag(50)) goto parse_terms;
  378. break;
  379. }
  380. // repeated bytes terms = 6;
  381. case 6: {
  382. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  383. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  384. parse_terms:
  385. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  386. input, this->add_terms()));
  387. } else {
  388. goto handle_uninterpreted;
  389. }
  390. if (input->ExpectTag(50)) goto parse_terms;
  391. if (input->ExpectTag(80)) goto parse_suffix_len;
  392. break;
  393. }
  394. // optional uint32 suffix_len = 10;
  395. case 10: {
  396. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  397. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  398. parse_suffix_len:
  399. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  400. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  401. input, &suffix_len_)));
  402. set_has_suffix_len();
  403. } else {
  404. goto handle_uninterpreted;
  405. }
  406. if (input->ExpectAtEnd()) return true;
  407. break;
  408. }
  409. default: {
  410. handle_uninterpreted:
  411. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  412. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  413. return true;
  414. }
  415. DO_(::google::protobuf::internal::WireFormat::SkipField(
  416. input, tag, mutable_unknown_fields()));
  417. break;
  418. }
  419. }
  420. }
  421. return true;
  422. #undef DO_
  423. }
  424. void StoreIndexField::SerializeWithCachedSizes(
  425. ::google::protobuf::io::CodedOutputStream* output) const {
  426. // required uint32 field_id = 1;
  427. if (has_field_id()) {
  428. ::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->field_id(), output);
  429. }
  430. // required uint32 field_flag = 2;
  431. if (has_field_flag()) {
  432. ::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->field_flag(), output);
  433. }
  434. // required uint32 field_type = 3;
  435. if (has_field_type()) {
  436. ::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->field_type(), output);
  437. }
  438. // optional uint64 numeric_value = 4;
  439. if (has_numeric_value()) {
  440. ::google::protobuf::internal::WireFormatLite::WriteUInt64(4, this->numeric_value(), output);
  441. }
  442. // optional bytes string_value = 5;
  443. if (has_string_value()) {
  444. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  445. 5, this->string_value(), output);
  446. }
  447. // repeated bytes terms = 6;
  448. for (int i = 0; i < this->terms_size(); i++) {
  449. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  450. 6, this->terms(i), output);
  451. }
  452. // optional uint32 suffix_len = 10;
  453. if (has_suffix_len()) {
  454. ::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->suffix_len(), output);
  455. }
  456. if (!unknown_fields().empty()) {
  457. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  458. unknown_fields(), output);
  459. }
  460. }
  461. ::google::protobuf::uint8* StoreIndexField::SerializeWithCachedSizesToArray(
  462. ::google::protobuf::uint8* target) const {
  463. // required uint32 field_id = 1;
  464. if (has_field_id()) {
  465. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->field_id(), target);
  466. }
  467. // required uint32 field_flag = 2;
  468. if (has_field_flag()) {
  469. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->field_flag(), target);
  470. }
  471. // required uint32 field_type = 3;
  472. if (has_field_type()) {
  473. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->field_type(), target);
  474. }
  475. // optional uint64 numeric_value = 4;
  476. if (has_numeric_value()) {
  477. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(4, this->numeric_value(), target);
  478. }
  479. // optional bytes string_value = 5;
  480. if (has_string_value()) {
  481. target =
  482. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  483. 5, this->string_value(), target);
  484. }
  485. // repeated bytes terms = 6;
  486. for (int i = 0; i < this->terms_size(); i++) {
  487. target = ::google::protobuf::internal::WireFormatLite::
  488. WriteBytesToArray(6, this->terms(i), target);
  489. }
  490. // optional uint32 suffix_len = 10;
  491. if (has_suffix_len()) {
  492. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->suffix_len(), target);
  493. }
  494. if (!unknown_fields().empty()) {
  495. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  496. unknown_fields(), target);
  497. }
  498. return target;
  499. }
  500. int StoreIndexField::ByteSize() const {
  501. int total_size = 0;
  502. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  503. // required uint32 field_id = 1;
  504. if (has_field_id()) {
  505. total_size += 1 +
  506. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  507. this->field_id());
  508. }
  509. // required uint32 field_flag = 2;
  510. if (has_field_flag()) {
  511. total_size += 1 +
  512. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  513. this->field_flag());
  514. }
  515. // required uint32 field_type = 3;
  516. if (has_field_type()) {
  517. total_size += 1 +
  518. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  519. this->field_type());
  520. }
  521. // optional uint64 numeric_value = 4;
  522. if (has_numeric_value()) {
  523. total_size += 1 +
  524. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  525. this->numeric_value());
  526. }
  527. // optional bytes string_value = 5;
  528. if (has_string_value()) {
  529. total_size += 1 +
  530. ::google::protobuf::internal::WireFormatLite::BytesSize(
  531. this->string_value());
  532. }
  533. // optional uint32 suffix_len = 10;
  534. if (has_suffix_len()) {
  535. total_size += 1 +
  536. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  537. this->suffix_len());
  538. }
  539. }
  540. // repeated bytes terms = 6;
  541. total_size += 1 * this->terms_size();
  542. for (int i = 0; i < this->terms_size(); i++) {
  543. total_size += ::google::protobuf::internal::WireFormatLite::BytesSize(
  544. this->terms(i));
  545. }
  546. if (!unknown_fields().empty()) {
  547. total_size +=
  548. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  549. unknown_fields());
  550. }
  551. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  552. _cached_size_ = total_size;
  553. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  554. return total_size;
  555. }
  556. void StoreIndexField::MergeFrom(const ::google::protobuf::Message& from) {
  557. GOOGLE_CHECK_NE(&from, this);
  558. const StoreIndexField* source =
  559. ::google::protobuf::internal::dynamic_cast_if_available<const StoreIndexField*>(
  560. &from);
  561. if (source == NULL) {
  562. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  563. } else {
  564. MergeFrom(*source);
  565. }
  566. }
  567. void StoreIndexField::MergeFrom(const StoreIndexField& from) {
  568. GOOGLE_CHECK_NE(&from, this);
  569. terms_.MergeFrom(from.terms_);
  570. if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  571. if (from.has_field_id()) {
  572. set_field_id(from.field_id());
  573. }
  574. if (from.has_field_flag()) {
  575. set_field_flag(from.field_flag());
  576. }
  577. if (from.has_field_type()) {
  578. set_field_type(from.field_type());
  579. }
  580. if (from.has_numeric_value()) {
  581. set_numeric_value(from.numeric_value());
  582. }
  583. if (from.has_string_value()) {
  584. set_string_value(from.string_value());
  585. }
  586. if (from.has_suffix_len()) {
  587. set_suffix_len(from.suffix_len());
  588. }
  589. }
  590. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  591. }
  592. void StoreIndexField::CopyFrom(const ::google::protobuf::Message& from) {
  593. if (&from == this) return;
  594. Clear();
  595. MergeFrom(from);
  596. }
  597. void StoreIndexField::CopyFrom(const StoreIndexField& from) {
  598. if (&from == this) return;
  599. Clear();
  600. MergeFrom(from);
  601. }
  602. bool StoreIndexField::IsInitialized() const {
  603. if ((_has_bits_[0] & 0x00000007) != 0x00000007) return false;
  604. return true;
  605. }
  606. void StoreIndexField::Swap(StoreIndexField* other) {
  607. if (other != this) {
  608. std::swap(field_id_, other->field_id_);
  609. std::swap(field_flag_, other->field_flag_);
  610. std::swap(field_type_, other->field_type_);
  611. std::swap(numeric_value_, other->numeric_value_);
  612. std::swap(string_value_, other->string_value_);
  613. terms_.Swap(&other->terms_);
  614. std::swap(suffix_len_, other->suffix_len_);
  615. std::swap(_has_bits_[0], other->_has_bits_[0]);
  616. _unknown_fields_.Swap(&other->_unknown_fields_);
  617. std::swap(_cached_size_, other->_cached_size_);
  618. }
  619. }
  620. ::google::protobuf::Metadata StoreIndexField::GetMetadata() const {
  621. protobuf_AssignDescriptorsOnce();
  622. ::google::protobuf::Metadata metadata;
  623. metadata.descriptor = StoreIndexField_descriptor_;
  624. metadata.reflection = StoreIndexField_reflection_;
  625. return metadata;
  626. }
  627. // ===================================================================
  628. #ifndef _MSC_VER
  629. const int StoreDocument::kDocumentIdFieldNumber;
  630. const int StoreDocument::kFieldsFieldNumber;
  631. #endif // !_MSC_VER
  632. StoreDocument::StoreDocument()
  633. : ::google::protobuf::Message() {
  634. SharedCtor();
  635. }
  636. void StoreDocument::InitAsDefaultInstance() {
  637. }
  638. StoreDocument::StoreDocument(const StoreDocument& from)
  639. : ::google::protobuf::Message() {
  640. SharedCtor();
  641. MergeFrom(from);
  642. }
  643. void StoreDocument::SharedCtor() {
  644. _cached_size_ = 0;
  645. document_id_ = GOOGLE_ULONGLONG(0);
  646. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  647. }
  648. StoreDocument::~StoreDocument() {
  649. SharedDtor();
  650. }
  651. void StoreDocument::SharedDtor() {
  652. if (this != default_instance_) {
  653. }
  654. }
  655. void StoreDocument::SetCachedSize(int size) const {
  656. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  657. _cached_size_ = size;
  658. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  659. }
  660. const ::google::protobuf::Descriptor* StoreDocument::descriptor() {
  661. protobuf_AssignDescriptorsOnce();
  662. return StoreDocument_descriptor_;
  663. }
  664. const StoreDocument& StoreDocument::default_instance() {
  665. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  666. }
  667. StoreDocument* StoreDocument::default_instance_ = NULL;
  668. StoreDocument* StoreDocument::New() const {
  669. return new StoreDocument;
  670. }
  671. void StoreDocument::Clear() {
  672. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  673. document_id_ = GOOGLE_ULONGLONG(0);
  674. }
  675. fields_.Clear();
  676. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  677. mutable_unknown_fields()->Clear();
  678. }
  679. bool StoreDocument::MergePartialFromCodedStream(
  680. ::google::protobuf::io::CodedInputStream* input) {
  681. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  682. ::google::protobuf::uint32 tag;
  683. while ((tag = input->ReadTag()) != 0) {
  684. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  685. // required uint64 document_id = 1;
  686. case 1: {
  687. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  688. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  689. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  690. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  691. input, &document_id_)));
  692. set_has_document_id();
  693. } else {
  694. goto handle_uninterpreted;
  695. }
  696. if (input->ExpectTag(18)) goto parse_fields;
  697. break;
  698. }
  699. // repeated .lsmsearch.StoreIndexField fields = 2;
  700. case 2: {
  701. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  702. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  703. parse_fields:
  704. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  705. input, add_fields()));
  706. } else {
  707. goto handle_uninterpreted;
  708. }
  709. if (input->ExpectTag(18)) goto parse_fields;
  710. if (input->ExpectAtEnd()) return true;
  711. break;
  712. }
  713. default: {
  714. handle_uninterpreted:
  715. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  716. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  717. return true;
  718. }
  719. DO_(::google::protobuf::internal::WireFormat::SkipField(
  720. input, tag, mutable_unknown_fields()));
  721. break;
  722. }
  723. }
  724. }
  725. return true;
  726. #undef DO_
  727. }
  728. void StoreDocument::SerializeWithCachedSizes(
  729. ::google::protobuf::io::CodedOutputStream* output) const {
  730. // required uint64 document_id = 1;
  731. if (has_document_id()) {
  732. ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->document_id(), output);
  733. }
  734. // repeated .lsmsearch.StoreIndexField fields = 2;
  735. for (int i = 0; i < this->fields_size(); i++) {
  736. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  737. 2, this->fields(i), output);
  738. }
  739. if (!unknown_fields().empty()) {
  740. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  741. unknown_fields(), output);
  742. }
  743. }
  744. ::google::protobuf::uint8* StoreDocument::SerializeWithCachedSizesToArray(
  745. ::google::protobuf::uint8* target) const {
  746. // required uint64 document_id = 1;
  747. if (has_document_id()) {
  748. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->document_id(), target);
  749. }
  750. // repeated .lsmsearch.StoreIndexField fields = 2;
  751. for (int i = 0; i < this->fields_size(); i++) {
  752. target = ::google::protobuf::internal::WireFormatLite::
  753. WriteMessageNoVirtualToArray(
  754. 2, this->fields(i), target);
  755. }
  756. if (!unknown_fields().empty()) {
  757. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  758. unknown_fields(), target);
  759. }
  760. return target;
  761. }
  762. int StoreDocument::ByteSize() const {
  763. int total_size = 0;
  764. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  765. // required uint64 document_id = 1;
  766. if (has_document_id()) {
  767. total_size += 1 +
  768. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  769. this->document_id());
  770. }
  771. }
  772. // repeated .lsmsearch.StoreIndexField fields = 2;
  773. total_size += 1 * this->fields_size();
  774. for (int i = 0; i < this->fields_size(); i++) {
  775. total_size +=
  776. ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
  777. this->fields(i));
  778. }
  779. if (!unknown_fields().empty()) {
  780. total_size +=
  781. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  782. unknown_fields());
  783. }
  784. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  785. _cached_size_ = total_size;
  786. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  787. return total_size;
  788. }
  789. void StoreDocument::MergeFrom(const ::google::protobuf::Message& from) {
  790. GOOGLE_CHECK_NE(&from, this);
  791. const StoreDocument* source =
  792. ::google::protobuf::internal::dynamic_cast_if_available<const StoreDocument*>(
  793. &from);
  794. if (source == NULL) {
  795. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  796. } else {
  797. MergeFrom(*source);
  798. }
  799. }
  800. void StoreDocument::MergeFrom(const StoreDocument& from) {
  801. GOOGLE_CHECK_NE(&from, this);
  802. fields_.MergeFrom(from.fields_);
  803. if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  804. if (from.has_document_id()) {
  805. set_document_id(from.document_id());
  806. }
  807. }
  808. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  809. }
  810. void StoreDocument::CopyFrom(const ::google::protobuf::Message& from) {
  811. if (&from == this) return;
  812. Clear();
  813. MergeFrom(from);
  814. }
  815. void StoreDocument::CopyFrom(const StoreDocument& from) {
  816. if (&from == this) return;
  817. Clear();
  818. MergeFrom(from);
  819. }
  820. bool StoreDocument::IsInitialized() const {
  821. if ((_has_bits_[0] & 0x00000001) != 0x00000001) return false;
  822. for (int i = 0; i < fields_size(); i++) {
  823. if (!this->fields(i).IsInitialized()) return false;
  824. }
  825. return true;
  826. }
  827. void StoreDocument::Swap(StoreDocument* other) {
  828. if (other != this) {
  829. std::swap(document_id_, other->document_id_);
  830. fields_.Swap(&other->fields_);
  831. std::swap(_has_bits_[0], other->_has_bits_[0]);
  832. _unknown_fields_.Swap(&other->_unknown_fields_);
  833. std::swap(_cached_size_, other->_cached_size_);
  834. }
  835. }
  836. ::google::protobuf::Metadata StoreDocument::GetMetadata() const {
  837. protobuf_AssignDescriptorsOnce();
  838. ::google::protobuf::Metadata metadata;
  839. metadata.descriptor = StoreDocument_descriptor_;
  840. metadata.reflection = StoreDocument_reflection_;
  841. return metadata;
  842. }
  843. // ===================================================================
  844. #ifndef _MSC_VER
  845. const int StoreDocValue::kFieldsFieldNumber;
  846. #endif // !_MSC_VER
  847. StoreDocValue::StoreDocValue()
  848. : ::google::protobuf::Message() {
  849. SharedCtor();
  850. }
  851. void StoreDocValue::InitAsDefaultInstance() {
  852. }
  853. StoreDocValue::StoreDocValue(const StoreDocValue& from)
  854. : ::google::protobuf::Message() {
  855. SharedCtor();
  856. MergeFrom(from);
  857. }
  858. void StoreDocValue::SharedCtor() {
  859. _cached_size_ = 0;
  860. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  861. }
  862. StoreDocValue::~StoreDocValue() {
  863. SharedDtor();
  864. }
  865. void StoreDocValue::SharedDtor() {
  866. if (this != default_instance_) {
  867. }
  868. }
  869. void StoreDocValue::SetCachedSize(int size) const {
  870. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  871. _cached_size_ = size;
  872. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  873. }
  874. const ::google::protobuf::Descriptor* StoreDocValue::descriptor() {
  875. protobuf_AssignDescriptorsOnce();
  876. return StoreDocValue_descriptor_;
  877. }
  878. const StoreDocValue& StoreDocValue::default_instance() {
  879. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  880. }
  881. StoreDocValue* StoreDocValue::default_instance_ = NULL;
  882. StoreDocValue* StoreDocValue::New() const {
  883. return new StoreDocValue;
  884. }
  885. void StoreDocValue::Clear() {
  886. fields_.Clear();
  887. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  888. mutable_unknown_fields()->Clear();
  889. }
  890. bool StoreDocValue::MergePartialFromCodedStream(
  891. ::google::protobuf::io::CodedInputStream* input) {
  892. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  893. ::google::protobuf::uint32 tag;
  894. while ((tag = input->ReadTag()) != 0) {
  895. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  896. // repeated .lsmsearch.StoreIndexField fields = 1;
  897. case 1: {
  898. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  899. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  900. parse_fields:
  901. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  902. input, add_fields()));
  903. } else {
  904. goto handle_uninterpreted;
  905. }
  906. if (input->ExpectTag(10)) goto parse_fields;
  907. if (input->ExpectAtEnd()) return true;
  908. break;
  909. }
  910. default: {
  911. handle_uninterpreted:
  912. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  913. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  914. return true;
  915. }
  916. DO_(::google::protobuf::internal::WireFormat::SkipField(
  917. input, tag, mutable_unknown_fields()));
  918. break;
  919. }
  920. }
  921. }
  922. return true;
  923. #undef DO_
  924. }
  925. void StoreDocValue::SerializeWithCachedSizes(
  926. ::google::protobuf::io::CodedOutputStream* output) const {
  927. // repeated .lsmsearch.StoreIndexField fields = 1;
  928. for (int i = 0; i < this->fields_size(); i++) {
  929. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  930. 1, this->fields(i), output);
  931. }
  932. if (!unknown_fields().empty()) {
  933. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  934. unknown_fields(), output);
  935. }
  936. }
  937. ::google::protobuf::uint8* StoreDocValue::SerializeWithCachedSizesToArray(
  938. ::google::protobuf::uint8* target) const {
  939. // repeated .lsmsearch.StoreIndexField fields = 1;
  940. for (int i = 0; i < this->fields_size(); i++) {
  941. target = ::google::protobuf::internal::WireFormatLite::
  942. WriteMessageNoVirtualToArray(
  943. 1, this->fields(i), target);
  944. }
  945. if (!unknown_fields().empty()) {
  946. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  947. unknown_fields(), target);
  948. }
  949. return target;
  950. }
  951. int StoreDocValue::ByteSize() const {
  952. int total_size = 0;
  953. // repeated .lsmsearch.StoreIndexField fields = 1;
  954. total_size += 1 * this->fields_size();
  955. for (int i = 0; i < this->fields_size(); i++) {
  956. total_size +=
  957. ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
  958. this->fields(i));
  959. }
  960. if (!unknown_fields().empty()) {
  961. total_size +=
  962. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  963. unknown_fields());
  964. }
  965. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  966. _cached_size_ = total_size;
  967. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  968. return total_size;
  969. }
  970. void StoreDocValue::MergeFrom(const ::google::protobuf::Message& from) {
  971. GOOGLE_CHECK_NE(&from, this);
  972. const StoreDocValue* source =
  973. ::google::protobuf::internal::dynamic_cast_if_available<const StoreDocValue*>(
  974. &from);
  975. if (source == NULL) {
  976. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  977. } else {
  978. MergeFrom(*source);
  979. }
  980. }
  981. void StoreDocValue::MergeFrom(const StoreDocValue& from) {
  982. GOOGLE_CHECK_NE(&from, this);
  983. fields_.MergeFrom(from.fields_);
  984. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  985. }
  986. void StoreDocValue::CopyFrom(const ::google::protobuf::Message& from) {
  987. if (&from == this) return;
  988. Clear();
  989. MergeFrom(from);
  990. }
  991. void StoreDocValue::CopyFrom(const StoreDocValue& from) {
  992. if (&from == this) return;
  993. Clear();
  994. MergeFrom(from);
  995. }
  996. bool StoreDocValue::IsInitialized() const {
  997. for (int i = 0; i < fields_size(); i++) {
  998. if (!this->fields(i).IsInitialized()) return false;
  999. }
  1000. return true;
  1001. }
  1002. void StoreDocValue::Swap(StoreDocValue* other) {
  1003. if (other != this) {
  1004. fields_.Swap(&other->fields_);
  1005. std::swap(_has_bits_[0], other->_has_bits_[0]);
  1006. _unknown_fields_.Swap(&other->_unknown_fields_);
  1007. std::swap(_cached_size_, other->_cached_size_);
  1008. }
  1009. }
  1010. ::google::protobuf::Metadata StoreDocValue::GetMetadata() const {
  1011. protobuf_AssignDescriptorsOnce();
  1012. ::google::protobuf::Metadata metadata;
  1013. metadata.descriptor = StoreDocValue_descriptor_;
  1014. metadata.reflection = StoreDocValue_reflection_;
  1015. return metadata;
  1016. }
  1017. // ===================================================================
  1018. #ifndef _MSC_VER
  1019. const int StoreMeta::kTotalDocumentsFieldNumber;
  1020. const int StoreMeta::kDeleteDocumentsFieldNumber;
  1021. const int StoreMeta::kIncreaseSeqFieldNumber;
  1022. const int StoreMeta::kTermsCountFieldNumber;
  1023. #endif // !_MSC_VER
  1024. StoreMeta::StoreMeta()
  1025. : ::google::protobuf::Message() {
  1026. SharedCtor();
  1027. }
  1028. void StoreMeta::InitAsDefaultInstance() {
  1029. }
  1030. StoreMeta::StoreMeta(const StoreMeta& from)
  1031. : ::google::protobuf::Message() {
  1032. SharedCtor();
  1033. MergeFrom(from);
  1034. }
  1035. void StoreMeta::SharedCtor() {
  1036. _cached_size_ = 0;
  1037. total_documents_ = GOOGLE_ULONGLONG(0);
  1038. delete_documents_ = GOOGLE_ULONGLONG(0);
  1039. increase_seq_ = GOOGLE_ULONGLONG(0);
  1040. terms_count_ = GOOGLE_ULONGLONG(0);
  1041. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1042. }
  1043. StoreMeta::~StoreMeta() {
  1044. SharedDtor();
  1045. }
  1046. void StoreMeta::SharedDtor() {
  1047. if (this != default_instance_) {
  1048. }
  1049. }
  1050. void StoreMeta::SetCachedSize(int size) const {
  1051. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1052. _cached_size_ = size;
  1053. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1054. }
  1055. const ::google::protobuf::Descriptor* StoreMeta::descriptor() {
  1056. protobuf_AssignDescriptorsOnce();
  1057. return StoreMeta_descriptor_;
  1058. }
  1059. const StoreMeta& StoreMeta::default_instance() {
  1060. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  1061. }
  1062. StoreMeta* StoreMeta::default_instance_ = NULL;
  1063. StoreMeta* StoreMeta::New() const {
  1064. return new StoreMeta;
  1065. }
  1066. void StoreMeta::Clear() {
  1067. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1068. total_documents_ = GOOGLE_ULONGLONG(0);
  1069. delete_documents_ = GOOGLE_ULONGLONG(0);
  1070. increase_seq_ = GOOGLE_ULONGLONG(0);
  1071. terms_count_ = GOOGLE_ULONGLONG(0);
  1072. }
  1073. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1074. mutable_unknown_fields()->Clear();
  1075. }
  1076. bool StoreMeta::MergePartialFromCodedStream(
  1077. ::google::protobuf::io::CodedInputStream* input) {
  1078. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  1079. ::google::protobuf::uint32 tag;
  1080. while ((tag = input->ReadTag()) != 0) {
  1081. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1082. // optional uint64 total_documents = 1;
  1083. case 1: {
  1084. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1085. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1086. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1087. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1088. input, &total_documents_)));
  1089. set_has_total_documents();
  1090. } else {
  1091. goto handle_uninterpreted;
  1092. }
  1093. if (input->ExpectTag(16)) goto parse_delete_documents;
  1094. break;
  1095. }
  1096. // optional uint64 delete_documents = 2;
  1097. case 2: {
  1098. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1099. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1100. parse_delete_documents:
  1101. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1102. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1103. input, &delete_documents_)));
  1104. set_has_delete_documents();
  1105. } else {
  1106. goto handle_uninterpreted;
  1107. }
  1108. if (input->ExpectTag(24)) goto parse_increase_seq;
  1109. break;
  1110. }
  1111. // optional uint64 increase_seq = 3;
  1112. case 3: {
  1113. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1114. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1115. parse_increase_seq:
  1116. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1117. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1118. input, &increase_seq_)));
  1119. set_has_increase_seq();
  1120. } else {
  1121. goto handle_uninterpreted;
  1122. }
  1123. if (input->ExpectTag(32)) goto parse_terms_count;
  1124. break;
  1125. }
  1126. // optional uint64 terms_count = 4;
  1127. case 4: {
  1128. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1129. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1130. parse_terms_count:
  1131. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1132. ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
  1133. input, &terms_count_)));
  1134. set_has_terms_count();
  1135. } else {
  1136. goto handle_uninterpreted;
  1137. }
  1138. if (input->ExpectAtEnd()) return true;
  1139. break;
  1140. }
  1141. default: {
  1142. handle_uninterpreted:
  1143. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1144. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  1145. return true;
  1146. }
  1147. DO_(::google::protobuf::internal::WireFormat::SkipField(
  1148. input, tag, mutable_unknown_fields()));
  1149. break;
  1150. }
  1151. }
  1152. }
  1153. return true;
  1154. #undef DO_
  1155. }
  1156. void StoreMeta::SerializeWithCachedSizes(
  1157. ::google::protobuf::io::CodedOutputStream* output) const {
  1158. // optional uint64 total_documents = 1;
  1159. if (has_total_documents()) {
  1160. ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->total_documents(), output);
  1161. }
  1162. // optional uint64 delete_documents = 2;
  1163. if (has_delete_documents()) {
  1164. ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->delete_documents(), output);
  1165. }
  1166. // optional uint64 increase_seq = 3;
  1167. if (has_increase_seq()) {
  1168. ::google::protobuf::internal::WireFormatLite::WriteUInt64(3, this->increase_seq(), output);
  1169. }
  1170. // optional uint64 terms_count = 4;
  1171. if (has_terms_count()) {
  1172. ::google::protobuf::internal::WireFormatLite::WriteUInt64(4, this->terms_count(), output);
  1173. }
  1174. if (!unknown_fields().empty()) {
  1175. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  1176. unknown_fields(), output);
  1177. }
  1178. }
  1179. ::google::protobuf::uint8* StoreMeta::SerializeWithCachedSizesToArray(
  1180. ::google::protobuf::uint8* target) const {
  1181. // optional uint64 total_documents = 1;
  1182. if (has_total_documents()) {
  1183. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->total_documents(), target);
  1184. }
  1185. // optional uint64 delete_documents = 2;
  1186. if (has_delete_documents()) {
  1187. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(2, this->delete_documents(), target);
  1188. }
  1189. // optional uint64 increase_seq = 3;
  1190. if (has_increase_seq()) {
  1191. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(3, this->increase_seq(), target);
  1192. }
  1193. // optional uint64 terms_count = 4;
  1194. if (has_terms_count()) {
  1195. target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(4, this->terms_count(), target);
  1196. }
  1197. if (!unknown_fields().empty()) {
  1198. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  1199. unknown_fields(), target);
  1200. }
  1201. return target;
  1202. }
  1203. int StoreMeta::ByteSize() const {
  1204. int total_size = 0;
  1205. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1206. // optional uint64 total_documents = 1;
  1207. if (has_total_documents()) {
  1208. total_size += 1 +
  1209. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1210. this->total_documents());
  1211. }
  1212. // optional uint64 delete_documents = 2;
  1213. if (has_delete_documents()) {
  1214. total_size += 1 +
  1215. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1216. this->delete_documents());
  1217. }
  1218. // optional uint64 increase_seq = 3;
  1219. if (has_increase_seq()) {
  1220. total_size += 1 +
  1221. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1222. this->increase_seq());
  1223. }
  1224. // optional uint64 terms_count = 4;
  1225. if (has_terms_count()) {
  1226. total_size += 1 +
  1227. ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1228. this->terms_count());
  1229. }
  1230. }
  1231. if (!unknown_fields().empty()) {
  1232. total_size +=
  1233. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  1234. unknown_fields());
  1235. }
  1236. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1237. _cached_size_ = total_size;
  1238. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1239. return total_size;
  1240. }
  1241. void StoreMeta::MergeFrom(const ::google::protobuf::Message& from) {
  1242. GOOGLE_CHECK_NE(&from, this);
  1243. const StoreMeta* source =
  1244. ::google::protobuf::internal::dynamic_cast_if_available<const StoreMeta*>(
  1245. &from);
  1246. if (source == NULL) {
  1247. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  1248. } else {
  1249. MergeFrom(*source);
  1250. }
  1251. }
  1252. void StoreMeta::MergeFrom(const StoreMeta& from) {
  1253. GOOGLE_CHECK_NE(&from, this);
  1254. if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1255. if (from.has_total_documents()) {
  1256. set_total_documents(from.total_documents());
  1257. }
  1258. if (from.has_delete_documents()) {
  1259. set_delete_documents(from.delete_documents());
  1260. }
  1261. if (from.has_increase_seq()) {
  1262. set_increase_seq(from.increase_seq());
  1263. }
  1264. if (from.has_terms_count()) {
  1265. set_terms_count(from.terms_count());
  1266. }
  1267. }
  1268. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  1269. }
  1270. void StoreMeta::CopyFrom(const ::google::protobuf::Message& from) {
  1271. if (&from == this) return;
  1272. Clear();
  1273. MergeFrom(from);
  1274. }
  1275. void StoreMeta::CopyFrom(const StoreMeta& from) {
  1276. if (&from == this) return;
  1277. Clear();
  1278. MergeFrom(from);
  1279. }
  1280. bool StoreMeta::IsInitialized() const {
  1281. return true;
  1282. }
  1283. void StoreMeta::Swap(StoreMeta* other) {
  1284. if (other != this) {
  1285. std::swap(total_documents_, other->total_documents_);
  1286. std::swap(delete_documents_, other->delete_documents_);
  1287. std::swap(increase_seq_, other->increase_seq_);
  1288. std::swap(terms_count_, other->terms_count_);
  1289. std::swap(_has_bits_[0], other->_has_bits_[0]);
  1290. _unknown_fields_.Swap(&other->_unknown_fields_);
  1291. std::swap(_cached_size_, other->_cached_size_);
  1292. }
  1293. }
  1294. ::google::protobuf::Metadata StoreMeta::GetMetadata() const {
  1295. protobuf_AssignDescriptorsOnce();
  1296. ::google::protobuf::Metadata metadata;
  1297. metadata.descriptor = StoreMeta_descriptor_;
  1298. metadata.reflection = StoreMeta_reflection_;
  1299. return metadata;
  1300. }
  1301. // ===================================================================
  1302. const ::google::protobuf::EnumDescriptor* MockData_Type_descriptor() {
  1303. protobuf_AssignDescriptorsOnce();
  1304. return MockData_Type_descriptor_;
  1305. }
  1306. bool MockData_Type_IsValid(int value) {
  1307. switch(value) {
  1308. case 0:
  1309. case 1:
  1310. case 2:
  1311. case 3:
  1312. case 4:
  1313. return true;
  1314. default:
  1315. return false;
  1316. }
  1317. }
  1318. #ifndef _MSC_VER
  1319. const MockData_Type MockData::kUnknown;
  1320. const MockData_Type MockData::kUpdate;
  1321. const MockData_Type MockData::kMerge;
  1322. const MockData_Type MockData::kDelete;
  1323. const MockData_Type MockData::kDeleteRange;
  1324. const MockData_Type MockData::Type_MIN;
  1325. const MockData_Type MockData::Type_MAX;
  1326. const int MockData::Type_ARRAYSIZE;
  1327. #endif // _MSC_VER
  1328. #ifndef _MSC_VER
  1329. const int MockData::kColumnTypeFieldNumber;
  1330. const int MockData::kKeyFieldNumber;
  1331. const int MockData::kValueFieldNumber;
  1332. const int MockData::kTypeFieldNumber;
  1333. const int MockData::kEndKeyFieldNumber;
  1334. #endif // !_MSC_VER
  1335. MockData::MockData()
  1336. : ::google::protobuf::Message() {
  1337. SharedCtor();
  1338. }
  1339. void MockData::InitAsDefaultInstance() {
  1340. }
  1341. MockData::MockData(const MockData& from)
  1342. : ::google::protobuf::Message() {
  1343. SharedCtor();
  1344. MergeFrom(from);
  1345. }
  1346. void MockData::SharedCtor() {
  1347. _cached_size_ = 0;
  1348. column_type_ = 0u;
  1349. key_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  1350. value_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  1351. type_ = 0;
  1352. end_key_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  1353. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1354. }
  1355. MockData::~MockData() {
  1356. SharedDtor();
  1357. }
  1358. void MockData::SharedDtor() {
  1359. if (key_ != &::google::protobuf::internal::kEmptyString) {
  1360. delete key_;
  1361. }
  1362. if (value_ != &::google::protobuf::internal::kEmptyString) {
  1363. delete value_;
  1364. }
  1365. if (end_key_ != &::google::protobuf::internal::kEmptyString) {
  1366. delete end_key_;
  1367. }
  1368. if (this != default_instance_) {
  1369. }
  1370. }
  1371. void MockData::SetCachedSize(int size) const {
  1372. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1373. _cached_size_ = size;
  1374. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1375. }
  1376. const ::google::protobuf::Descriptor* MockData::descriptor() {
  1377. protobuf_AssignDescriptorsOnce();
  1378. return MockData_descriptor_;
  1379. }
  1380. const MockData& MockData::default_instance() {
  1381. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  1382. }
  1383. MockData* MockData::default_instance_ = NULL;
  1384. MockData* MockData::New() const {
  1385. return new MockData;
  1386. }
  1387. void MockData::Clear() {
  1388. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1389. column_type_ = 0u;
  1390. if (has_key()) {
  1391. if (key_ != &::google::protobuf::internal::kEmptyString) {
  1392. key_->clear();
  1393. }
  1394. }
  1395. if (has_value()) {
  1396. if (value_ != &::google::protobuf::internal::kEmptyString) {
  1397. value_->clear();
  1398. }
  1399. }
  1400. type_ = 0;
  1401. if (has_end_key()) {
  1402. if (end_key_ != &::google::protobuf::internal::kEmptyString) {
  1403. end_key_->clear();
  1404. }
  1405. }
  1406. }
  1407. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1408. mutable_unknown_fields()->Clear();
  1409. }
  1410. bool MockData::MergePartialFromCodedStream(
  1411. ::google::protobuf::io::CodedInputStream* input) {
  1412. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  1413. ::google::protobuf::uint32 tag;
  1414. while ((tag = input->ReadTag()) != 0) {
  1415. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1416. // required uint32 column_type = 1;
  1417. case 1: {
  1418. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1419. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1420. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1421. ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
  1422. input, &column_type_)));
  1423. set_has_column_type();
  1424. } else {
  1425. goto handle_uninterpreted;
  1426. }
  1427. if (input->ExpectTag(18)) goto parse_key;
  1428. break;
  1429. }
  1430. // required bytes key = 2;
  1431. case 2: {
  1432. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1433. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  1434. parse_key:
  1435. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  1436. input, this->mutable_key()));
  1437. } else {
  1438. goto handle_uninterpreted;
  1439. }
  1440. if (input->ExpectTag(26)) goto parse_value;
  1441. break;
  1442. }
  1443. // required bytes value = 3;
  1444. case 3: {
  1445. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1446. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  1447. parse_value:
  1448. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  1449. input, this->mutable_value()));
  1450. } else {
  1451. goto handle_uninterpreted;
  1452. }
  1453. if (input->ExpectTag(32)) goto parse_type;
  1454. break;
  1455. }
  1456. // required .lsmsearch.MockData.Type type = 4;
  1457. case 4: {
  1458. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1459. ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
  1460. parse_type:
  1461. int value;
  1462. DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
  1463. int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
  1464. input, &value)));
  1465. if (::lsmsearch::MockData_Type_IsValid(value)) {
  1466. set_type(static_cast< ::lsmsearch::MockData_Type >(value));
  1467. } else {
  1468. mutable_unknown_fields()->AddVarint(4, value);
  1469. }
  1470. } else {
  1471. goto handle_uninterpreted;
  1472. }
  1473. if (input->ExpectTag(42)) goto parse_end_key;
  1474. break;
  1475. }
  1476. // optional bytes end_key = 5;
  1477. case 5: {
  1478. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1479. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  1480. parse_end_key:
  1481. DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
  1482. input, this->mutable_end_key()));
  1483. } else {
  1484. goto handle_uninterpreted;
  1485. }
  1486. if (input->ExpectAtEnd()) return true;
  1487. break;
  1488. }
  1489. default: {
  1490. handle_uninterpreted:
  1491. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1492. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  1493. return true;
  1494. }
  1495. DO_(::google::protobuf::internal::WireFormat::SkipField(
  1496. input, tag, mutable_unknown_fields()));
  1497. break;
  1498. }
  1499. }
  1500. }
  1501. return true;
  1502. #undef DO_
  1503. }
  1504. void MockData::SerializeWithCachedSizes(
  1505. ::google::protobuf::io::CodedOutputStream* output) const {
  1506. // required uint32 column_type = 1;
  1507. if (has_column_type()) {
  1508. ::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->column_type(), output);
  1509. }
  1510. // required bytes key = 2;
  1511. if (has_key()) {
  1512. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  1513. 2, this->key(), output);
  1514. }
  1515. // required bytes value = 3;
  1516. if (has_value()) {
  1517. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  1518. 3, this->value(), output);
  1519. }
  1520. // required .lsmsearch.MockData.Type type = 4;
  1521. if (has_type()) {
  1522. ::google::protobuf::internal::WireFormatLite::WriteEnum(
  1523. 4, this->type(), output);
  1524. }
  1525. // optional bytes end_key = 5;
  1526. if (has_end_key()) {
  1527. ::google::protobuf::internal::WireFormatLite::WriteBytes(
  1528. 5, this->end_key(), output);
  1529. }
  1530. if (!unknown_fields().empty()) {
  1531. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  1532. unknown_fields(), output);
  1533. }
  1534. }
  1535. ::google::protobuf::uint8* MockData::SerializeWithCachedSizesToArray(
  1536. ::google::protobuf::uint8* target) const {
  1537. // required uint32 column_type = 1;
  1538. if (has_column_type()) {
  1539. target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->column_type(), target);
  1540. }
  1541. // required bytes key = 2;
  1542. if (has_key()) {
  1543. target =
  1544. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  1545. 2, this->key(), target);
  1546. }
  1547. // required bytes value = 3;
  1548. if (has_value()) {
  1549. target =
  1550. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  1551. 3, this->value(), target);
  1552. }
  1553. // required .lsmsearch.MockData.Type type = 4;
  1554. if (has_type()) {
  1555. target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
  1556. 4, this->type(), target);
  1557. }
  1558. // optional bytes end_key = 5;
  1559. if (has_end_key()) {
  1560. target =
  1561. ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
  1562. 5, this->end_key(), target);
  1563. }
  1564. if (!unknown_fields().empty()) {
  1565. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  1566. unknown_fields(), target);
  1567. }
  1568. return target;
  1569. }
  1570. int MockData::ByteSize() const {
  1571. int total_size = 0;
  1572. if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1573. // required uint32 column_type = 1;
  1574. if (has_column_type()) {
  1575. total_size += 1 +
  1576. ::google::protobuf::internal::WireFormatLite::UInt32Size(
  1577. this->column_type());
  1578. }
  1579. // required bytes key = 2;
  1580. if (has_key()) {
  1581. total_size += 1 +
  1582. ::google::protobuf::internal::WireFormatLite::BytesSize(
  1583. this->key());
  1584. }
  1585. // required bytes value = 3;
  1586. if (has_value()) {
  1587. total_size += 1 +
  1588. ::google::protobuf::internal::WireFormatLite::BytesSize(
  1589. this->value());
  1590. }
  1591. // required .lsmsearch.MockData.Type type = 4;
  1592. if (has_type()) {
  1593. total_size += 1 +
  1594. ::google::protobuf::internal::WireFormatLite::EnumSize(this->type());
  1595. }
  1596. // optional bytes end_key = 5;
  1597. if (has_end_key()) {
  1598. total_size += 1 +
  1599. ::google::protobuf::internal::WireFormatLite::BytesSize(
  1600. this->end_key());
  1601. }
  1602. }
  1603. if (!unknown_fields().empty()) {
  1604. total_size +=
  1605. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  1606. unknown_fields());
  1607. }
  1608. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1609. _cached_size_ = total_size;
  1610. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1611. return total_size;
  1612. }
  1613. void MockData::MergeFrom(const ::google::protobuf::Message& from) {
  1614. GOOGLE_CHECK_NE(&from, this);
  1615. const MockData* source =
  1616. ::google::protobuf::internal::dynamic_cast_if_available<const MockData*>(
  1617. &from);
  1618. if (source == NULL) {
  1619. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  1620. } else {
  1621. MergeFrom(*source);
  1622. }
  1623. }
  1624. void MockData::MergeFrom(const MockData& from) {
  1625. GOOGLE_CHECK_NE(&from, this);
  1626. if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
  1627. if (from.has_column_type()) {
  1628. set_column_type(from.column_type());
  1629. }
  1630. if (from.has_key()) {
  1631. set_key(from.key());
  1632. }
  1633. if (from.has_value()) {
  1634. set_value(from.value());
  1635. }
  1636. if (from.has_type()) {
  1637. set_type(from.type());
  1638. }
  1639. if (from.has_end_key()) {
  1640. set_end_key(from.end_key());
  1641. }
  1642. }
  1643. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  1644. }
  1645. void MockData::CopyFrom(const ::google::protobuf::Message& from) {
  1646. if (&from == this) return;
  1647. Clear();
  1648. MergeFrom(from);
  1649. }
  1650. void MockData::CopyFrom(const MockData& from) {
  1651. if (&from == this) return;
  1652. Clear();
  1653. MergeFrom(from);
  1654. }
  1655. bool MockData::IsInitialized() const {
  1656. if ((_has_bits_[0] & 0x0000000f) != 0x0000000f) return false;
  1657. return true;
  1658. }
  1659. void MockData::Swap(MockData* other) {
  1660. if (other != this) {
  1661. std::swap(column_type_, other->column_type_);
  1662. std::swap(key_, other->key_);
  1663. std::swap(value_, other->value_);
  1664. std::swap(type_, other->type_);
  1665. std::swap(end_key_, other->end_key_);
  1666. std::swap(_has_bits_[0], other->_has_bits_[0]);
  1667. _unknown_fields_.Swap(&other->_unknown_fields_);
  1668. std::swap(_cached_size_, other->_cached_size_);
  1669. }
  1670. }
  1671. ::google::protobuf::Metadata MockData::GetMetadata() const {
  1672. protobuf_AssignDescriptorsOnce();
  1673. ::google::protobuf::Metadata metadata;
  1674. metadata.descriptor = MockData_descriptor_;
  1675. metadata.reflection = MockData_reflection_;
  1676. return metadata;
  1677. }
  1678. // ===================================================================
  1679. #ifndef _MSC_VER
  1680. const int MockDataList::kMockDataListFieldNumber;
  1681. #endif // !_MSC_VER
  1682. MockDataList::MockDataList()
  1683. : ::google::protobuf::Message() {
  1684. SharedCtor();
  1685. }
  1686. void MockDataList::InitAsDefaultInstance() {
  1687. }
  1688. MockDataList::MockDataList(const MockDataList& from)
  1689. : ::google::protobuf::Message() {
  1690. SharedCtor();
  1691. MergeFrom(from);
  1692. }
  1693. void MockDataList::SharedCtor() {
  1694. _cached_size_ = 0;
  1695. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1696. }
  1697. MockDataList::~MockDataList() {
  1698. SharedDtor();
  1699. }
  1700. void MockDataList::SharedDtor() {
  1701. if (this != default_instance_) {
  1702. }
  1703. }
  1704. void MockDataList::SetCachedSize(int size) const {
  1705. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1706. _cached_size_ = size;
  1707. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1708. }
  1709. const ::google::protobuf::Descriptor* MockDataList::descriptor() {
  1710. protobuf_AssignDescriptorsOnce();
  1711. return MockDataList_descriptor_;
  1712. }
  1713. const MockDataList& MockDataList::default_instance() {
  1714. if (default_instance_ == NULL) protobuf_AddDesc_search_5fstore_2eproto(); return *default_instance_;
  1715. }
  1716. MockDataList* MockDataList::default_instance_ = NULL;
  1717. MockDataList* MockDataList::New() const {
  1718. return new MockDataList;
  1719. }
  1720. void MockDataList::Clear() {
  1721. mock_data_list_.Clear();
  1722. ::memset(_has_bits_, 0, sizeof(_has_bits_));
  1723. mutable_unknown_fields()->Clear();
  1724. }
  1725. bool MockDataList::MergePartialFromCodedStream(
  1726. ::google::protobuf::io::CodedInputStream* input) {
  1727. #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
  1728. ::google::protobuf::uint32 tag;
  1729. while ((tag = input->ReadTag()) != 0) {
  1730. switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1731. // repeated .lsmsearch.MockData mock_data_list = 1;
  1732. case 1: {
  1733. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1734. ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
  1735. parse_mock_data_list:
  1736. DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  1737. input, add_mock_data_list()));
  1738. } else {
  1739. goto handle_uninterpreted;
  1740. }
  1741. if (input->ExpectTag(10)) goto parse_mock_data_list;
  1742. if (input->ExpectAtEnd()) return true;
  1743. break;
  1744. }
  1745. default: {
  1746. handle_uninterpreted:
  1747. if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
  1748. ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
  1749. return true;
  1750. }
  1751. DO_(::google::protobuf::internal::WireFormat::SkipField(
  1752. input, tag, mutable_unknown_fields()));
  1753. break;
  1754. }
  1755. }
  1756. }
  1757. return true;
  1758. #undef DO_
  1759. }
  1760. void MockDataList::SerializeWithCachedSizes(
  1761. ::google::protobuf::io::CodedOutputStream* output) const {
  1762. // repeated .lsmsearch.MockData mock_data_list = 1;
  1763. for (int i = 0; i < this->mock_data_list_size(); i++) {
  1764. ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
  1765. 1, this->mock_data_list(i), output);
  1766. }
  1767. if (!unknown_fields().empty()) {
  1768. ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
  1769. unknown_fields(), output);
  1770. }
  1771. }
  1772. ::google::protobuf::uint8* MockDataList::SerializeWithCachedSizesToArray(
  1773. ::google::protobuf::uint8* target) const {
  1774. // repeated .lsmsearch.MockData mock_data_list = 1;
  1775. for (int i = 0; i < this->mock_data_list_size(); i++) {
  1776. target = ::google::protobuf::internal::WireFormatLite::
  1777. WriteMessageNoVirtualToArray(
  1778. 1, this->mock_data_list(i), target);
  1779. }
  1780. if (!unknown_fields().empty()) {
  1781. target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
  1782. unknown_fields(), target);
  1783. }
  1784. return target;
  1785. }
  1786. int MockDataList::ByteSize() const {
  1787. int total_size = 0;
  1788. // repeated .lsmsearch.MockData mock_data_list = 1;
  1789. total_size += 1 * this->mock_data_list_size();
  1790. for (int i = 0; i < this->mock_data_list_size(); i++) {
  1791. total_size +=
  1792. ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
  1793. this->mock_data_list(i));
  1794. }
  1795. if (!unknown_fields().empty()) {
  1796. total_size +=
  1797. ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
  1798. unknown_fields());
  1799. }
  1800. GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  1801. _cached_size_ = total_size;
  1802. GOOGLE_SAFE_CONCURRENT_WRITES_END();
  1803. return total_size;
  1804. }
  1805. void MockDataList::MergeFrom(const ::google::protobuf::Message& from) {
  1806. GOOGLE_CHECK_NE(&from, this);
  1807. const MockDataList* source =
  1808. ::google::protobuf::internal::dynamic_cast_if_available<const MockDataList*>(
  1809. &from);
  1810. if (source == NULL) {
  1811. ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  1812. } else {
  1813. MergeFrom(*source);
  1814. }
  1815. }
  1816. void MockDataList::MergeFrom(const MockDataList& from) {
  1817. GOOGLE_CHECK_NE(&from, this);
  1818. mock_data_list_.MergeFrom(from.mock_data_list_);
  1819. mutable_unknown_fields()->MergeFrom(from.unknown_fields());
  1820. }
  1821. void MockDataList::CopyFrom(const ::google::protobuf::Message& from) {
  1822. if (&from == this) return;
  1823. Clear();
  1824. MergeFrom(from);
  1825. }
  1826. void MockDataList::CopyFrom(const MockDataList& from) {
  1827. if (&from == this) return;
  1828. Clear();
  1829. MergeFrom(from);
  1830. }
  1831. bool MockDataList::IsInitialized() const {
  1832. for (int i = 0; i < mock_data_list_size(); i++) {
  1833. if (!this->mock_data_list(i).IsInitialized()) return false;
  1834. }
  1835. return true;
  1836. }
  1837. void MockDataList::Swap(MockDataList* other) {
  1838. if (other != this) {
  1839. mock_data_list_.Swap(&other->mock_data_list_);
  1840. std::swap(_has_bits_[0], other->_has_bits_[0]);
  1841. _unknown_fields_.Swap(&other->_unknown_fields_);
  1842. std::swap(_cached_size_, other->_cached_size_);
  1843. }
  1844. }
  1845. ::google::protobuf::Metadata MockDataList::GetMetadata() const {
  1846. protobuf_AssignDescriptorsOnce();
  1847. ::google::protobuf::Metadata metadata;
  1848. metadata.descriptor = MockDataList_descriptor_;
  1849. metadata.reflection = MockDataList_reflection_;
  1850. return metadata;
  1851. }
  1852. // @@protoc_insertion_point(namespace_scope)
  1853. } // namespace lsmsearch
  1854. // @@protoc_insertion_point(global_scope)