mutation.pb.h 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502
  1. /*
  2. * Copyright 2018 Google
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. // Generated by the protocol buffer compiler. DO NOT EDIT!
  17. // source: firestore/local/mutation.proto
  18. #ifndef PROTOBUF_firestore_2flocal_2fmutation_2eproto__INCLUDED
  19. #define PROTOBUF_firestore_2flocal_2fmutation_2eproto__INCLUDED
  20. #include <string>
  21. #include <google/protobuf/stubs/common.h>
  22. #if GOOGLE_PROTOBUF_VERSION < 3005000
  23. #error This file was generated by a newer version of protoc which is
  24. #error incompatible with your Protocol Buffer headers. Please update
  25. #error your headers.
  26. #endif
  27. #if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
  28. #error This file was generated by an older version of protoc which is
  29. #error incompatible with your Protocol Buffer headers. Please
  30. #error regenerate this file with a newer version of protoc.
  31. #endif
  32. #include <google/protobuf/io/coded_stream.h>
  33. #include <google/protobuf/arena.h>
  34. #include <google/protobuf/arenastring.h>
  35. #include <google/protobuf/generated_message_table_driven.h>
  36. #include <google/protobuf/generated_message_util.h>
  37. #include <google/protobuf/metadata.h>
  38. #include <google/protobuf/message.h>
  39. #include <google/protobuf/repeated_field.h> // IWYU pragma: export
  40. #include <google/protobuf/extension_set.h> // IWYU pragma: export
  41. #include <google/protobuf/unknown_field_set.h>
  42. #include "google/firestore/v1beta1/write.pb.h"
  43. #include <google/protobuf/timestamp.pb.h>
  44. // @@protoc_insertion_point(includes)
  45. namespace protobuf_firestore_2flocal_2fmutation_2eproto {
  46. // Internal implementation detail -- do not use these members.
  47. struct TableStruct {
  48. static const ::google::protobuf::internal::ParseTableField entries[];
  49. static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
  50. static const ::google::protobuf::internal::ParseTable schema[2];
  51. static const ::google::protobuf::internal::FieldMetadata field_metadata[];
  52. static const ::google::protobuf::internal::SerializationTable serialization_table[];
  53. static const ::google::protobuf::uint32 offsets[];
  54. };
  55. void AddDescriptors();
  56. void InitDefaultsMutationQueueImpl();
  57. void InitDefaultsMutationQueue();
  58. void InitDefaultsWriteBatchImpl();
  59. void InitDefaultsWriteBatch();
  60. inline void InitDefaults() {
  61. InitDefaultsMutationQueue();
  62. InitDefaultsWriteBatch();
  63. }
  64. } // namespace protobuf_firestore_2flocal_2fmutation_2eproto
  65. namespace firestore {
  66. namespace client {
  67. class MutationQueue;
  68. class MutationQueueDefaultTypeInternal;
  69. extern MutationQueueDefaultTypeInternal _MutationQueue_default_instance_;
  70. class WriteBatch;
  71. class WriteBatchDefaultTypeInternal;
  72. extern WriteBatchDefaultTypeInternal _WriteBatch_default_instance_;
  73. } // namespace client
  74. } // namespace firestore
  75. namespace firestore {
  76. namespace client {
  77. // ===================================================================
  78. class MutationQueue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:firestore.client.MutationQueue) */ {
  79. public:
  80. MutationQueue();
  81. virtual ~MutationQueue();
  82. MutationQueue(const MutationQueue& from);
  83. inline MutationQueue& operator=(const MutationQueue& from) {
  84. CopyFrom(from);
  85. return *this;
  86. }
  87. #if LANG_CXX11
  88. MutationQueue(MutationQueue&& from) noexcept
  89. : MutationQueue() {
  90. *this = ::std::move(from);
  91. }
  92. inline MutationQueue& operator=(MutationQueue&& from) noexcept {
  93. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  94. if (this != &from) InternalSwap(&from);
  95. } else {
  96. CopyFrom(from);
  97. }
  98. return *this;
  99. }
  100. #endif
  101. static const ::google::protobuf::Descriptor* descriptor();
  102. static const MutationQueue& default_instance();
  103. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  104. static inline const MutationQueue* internal_default_instance() {
  105. return reinterpret_cast<const MutationQueue*>(
  106. &_MutationQueue_default_instance_);
  107. }
  108. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  109. 0;
  110. void Swap(MutationQueue* other);
  111. friend void swap(MutationQueue& a, MutationQueue& b) {
  112. a.Swap(&b);
  113. }
  114. // implements Message ----------------------------------------------
  115. inline MutationQueue* New() const PROTOBUF_FINAL { return New(NULL); }
  116. MutationQueue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  117. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  118. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  119. void CopyFrom(const MutationQueue& from);
  120. void MergeFrom(const MutationQueue& from);
  121. void Clear() PROTOBUF_FINAL;
  122. bool IsInitialized() const PROTOBUF_FINAL;
  123. size_t ByteSizeLong() const PROTOBUF_FINAL;
  124. bool MergePartialFromCodedStream(
  125. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  126. void SerializeWithCachedSizes(
  127. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  128. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  129. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  130. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  131. private:
  132. void SharedCtor();
  133. void SharedDtor();
  134. void SetCachedSize(int size) const PROTOBUF_FINAL;
  135. void InternalSwap(MutationQueue* other);
  136. private:
  137. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  138. return NULL;
  139. }
  140. inline void* MaybeArenaPtr() const {
  141. return NULL;
  142. }
  143. public:
  144. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  145. // nested types ----------------------------------------------------
  146. // accessors -------------------------------------------------------
  147. // bytes last_stream_token = 2;
  148. void clear_last_stream_token();
  149. static const int kLastStreamTokenFieldNumber = 2;
  150. const ::std::string& last_stream_token() const;
  151. void set_last_stream_token(const ::std::string& value);
  152. #if LANG_CXX11
  153. void set_last_stream_token(::std::string&& value);
  154. #endif
  155. void set_last_stream_token(const char* value);
  156. void set_last_stream_token(const void* value, size_t size);
  157. ::std::string* mutable_last_stream_token();
  158. ::std::string* release_last_stream_token();
  159. void set_allocated_last_stream_token(::std::string* last_stream_token);
  160. // int32 last_acknowledged_batch_id = 1;
  161. void clear_last_acknowledged_batch_id();
  162. static const int kLastAcknowledgedBatchIdFieldNumber = 1;
  163. ::google::protobuf::int32 last_acknowledged_batch_id() const;
  164. void set_last_acknowledged_batch_id(::google::protobuf::int32 value);
  165. // @@protoc_insertion_point(class_scope:firestore.client.MutationQueue)
  166. private:
  167. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  168. ::google::protobuf::internal::ArenaStringPtr last_stream_token_;
  169. ::google::protobuf::int32 last_acknowledged_batch_id_;
  170. mutable int _cached_size_;
  171. friend struct ::protobuf_firestore_2flocal_2fmutation_2eproto::TableStruct;
  172. friend void ::protobuf_firestore_2flocal_2fmutation_2eproto::InitDefaultsMutationQueueImpl();
  173. };
  174. // -------------------------------------------------------------------
  175. class WriteBatch : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:firestore.client.WriteBatch) */ {
  176. public:
  177. WriteBatch();
  178. virtual ~WriteBatch();
  179. WriteBatch(const WriteBatch& from);
  180. inline WriteBatch& operator=(const WriteBatch& from) {
  181. CopyFrom(from);
  182. return *this;
  183. }
  184. #if LANG_CXX11
  185. WriteBatch(WriteBatch&& from) noexcept
  186. : WriteBatch() {
  187. *this = ::std::move(from);
  188. }
  189. inline WriteBatch& operator=(WriteBatch&& from) noexcept {
  190. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  191. if (this != &from) InternalSwap(&from);
  192. } else {
  193. CopyFrom(from);
  194. }
  195. return *this;
  196. }
  197. #endif
  198. static const ::google::protobuf::Descriptor* descriptor();
  199. static const WriteBatch& default_instance();
  200. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  201. static inline const WriteBatch* internal_default_instance() {
  202. return reinterpret_cast<const WriteBatch*>(
  203. &_WriteBatch_default_instance_);
  204. }
  205. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  206. 1;
  207. void Swap(WriteBatch* other);
  208. friend void swap(WriteBatch& a, WriteBatch& b) {
  209. a.Swap(&b);
  210. }
  211. // implements Message ----------------------------------------------
  212. inline WriteBatch* New() const PROTOBUF_FINAL { return New(NULL); }
  213. WriteBatch* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  214. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  215. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  216. void CopyFrom(const WriteBatch& from);
  217. void MergeFrom(const WriteBatch& from);
  218. void Clear() PROTOBUF_FINAL;
  219. bool IsInitialized() const PROTOBUF_FINAL;
  220. size_t ByteSizeLong() const PROTOBUF_FINAL;
  221. bool MergePartialFromCodedStream(
  222. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  223. void SerializeWithCachedSizes(
  224. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  225. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  226. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  227. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  228. private:
  229. void SharedCtor();
  230. void SharedDtor();
  231. void SetCachedSize(int size) const PROTOBUF_FINAL;
  232. void InternalSwap(WriteBatch* other);
  233. private:
  234. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  235. return NULL;
  236. }
  237. inline void* MaybeArenaPtr() const {
  238. return NULL;
  239. }
  240. public:
  241. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  242. // nested types ----------------------------------------------------
  243. // accessors -------------------------------------------------------
  244. // repeated .google.firestore.v1beta1.Write writes = 2;
  245. int writes_size() const;
  246. void clear_writes();
  247. static const int kWritesFieldNumber = 2;
  248. const ::google::firestore::v1beta1::Write& writes(int index) const;
  249. ::google::firestore::v1beta1::Write* mutable_writes(int index);
  250. ::google::firestore::v1beta1::Write* add_writes();
  251. ::google::protobuf::RepeatedPtrField< ::google::firestore::v1beta1::Write >*
  252. mutable_writes();
  253. const ::google::protobuf::RepeatedPtrField< ::google::firestore::v1beta1::Write >&
  254. writes() const;
  255. // .google.protobuf.Timestamp local_write_time = 3;
  256. bool has_local_write_time() const;
  257. void clear_local_write_time();
  258. static const int kLocalWriteTimeFieldNumber = 3;
  259. const ::google::protobuf::Timestamp& local_write_time() const;
  260. ::google::protobuf::Timestamp* release_local_write_time();
  261. ::google::protobuf::Timestamp* mutable_local_write_time();
  262. void set_allocated_local_write_time(::google::protobuf::Timestamp* local_write_time);
  263. // int32 batch_id = 1;
  264. void clear_batch_id();
  265. static const int kBatchIdFieldNumber = 1;
  266. ::google::protobuf::int32 batch_id() const;
  267. void set_batch_id(::google::protobuf::int32 value);
  268. // @@protoc_insertion_point(class_scope:firestore.client.WriteBatch)
  269. private:
  270. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  271. ::google::protobuf::RepeatedPtrField< ::google::firestore::v1beta1::Write > writes_;
  272. ::google::protobuf::Timestamp* local_write_time_;
  273. ::google::protobuf::int32 batch_id_;
  274. mutable int _cached_size_;
  275. friend struct ::protobuf_firestore_2flocal_2fmutation_2eproto::TableStruct;
  276. friend void ::protobuf_firestore_2flocal_2fmutation_2eproto::InitDefaultsWriteBatchImpl();
  277. };
  278. // ===================================================================
  279. // ===================================================================
  280. #ifdef __GNUC__
  281. #pragma GCC diagnostic push
  282. #pragma GCC diagnostic ignored "-Wstrict-aliasing"
  283. #endif // __GNUC__
  284. // MutationQueue
  285. // int32 last_acknowledged_batch_id = 1;
  286. inline void MutationQueue::clear_last_acknowledged_batch_id() {
  287. last_acknowledged_batch_id_ = 0;
  288. }
  289. inline ::google::protobuf::int32 MutationQueue::last_acknowledged_batch_id() const {
  290. // @@protoc_insertion_point(field_get:firestore.client.MutationQueue.last_acknowledged_batch_id)
  291. return last_acknowledged_batch_id_;
  292. }
  293. inline void MutationQueue::set_last_acknowledged_batch_id(::google::protobuf::int32 value) {
  294. last_acknowledged_batch_id_ = value;
  295. // @@protoc_insertion_point(field_set:firestore.client.MutationQueue.last_acknowledged_batch_id)
  296. }
  297. // bytes last_stream_token = 2;
  298. inline void MutationQueue::clear_last_stream_token() {
  299. last_stream_token_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  300. }
  301. inline const ::std::string& MutationQueue::last_stream_token() const {
  302. // @@protoc_insertion_point(field_get:firestore.client.MutationQueue.last_stream_token)
  303. return last_stream_token_.GetNoArena();
  304. }
  305. inline void MutationQueue::set_last_stream_token(const ::std::string& value) {
  306. last_stream_token_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  307. // @@protoc_insertion_point(field_set:firestore.client.MutationQueue.last_stream_token)
  308. }
  309. #if LANG_CXX11
  310. inline void MutationQueue::set_last_stream_token(::std::string&& value) {
  311. last_stream_token_.SetNoArena(
  312. &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  313. // @@protoc_insertion_point(field_set_rvalue:firestore.client.MutationQueue.last_stream_token)
  314. }
  315. #endif
  316. inline void MutationQueue::set_last_stream_token(const char* value) {
  317. GOOGLE_DCHECK(value != NULL);
  318. last_stream_token_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  319. // @@protoc_insertion_point(field_set_char:firestore.client.MutationQueue.last_stream_token)
  320. }
  321. inline void MutationQueue::set_last_stream_token(const void* value, size_t size) {
  322. last_stream_token_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  323. ::std::string(reinterpret_cast<const char*>(value), size));
  324. // @@protoc_insertion_point(field_set_pointer:firestore.client.MutationQueue.last_stream_token)
  325. }
  326. inline ::std::string* MutationQueue::mutable_last_stream_token() {
  327. // @@protoc_insertion_point(field_mutable:firestore.client.MutationQueue.last_stream_token)
  328. return last_stream_token_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  329. }
  330. inline ::std::string* MutationQueue::release_last_stream_token() {
  331. // @@protoc_insertion_point(field_release:firestore.client.MutationQueue.last_stream_token)
  332. return last_stream_token_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  333. }
  334. inline void MutationQueue::set_allocated_last_stream_token(::std::string* last_stream_token) {
  335. if (last_stream_token != NULL) {
  336. } else {
  337. }
  338. last_stream_token_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), last_stream_token);
  339. // @@protoc_insertion_point(field_set_allocated:firestore.client.MutationQueue.last_stream_token)
  340. }
  341. // -------------------------------------------------------------------
  342. // WriteBatch
  343. // int32 batch_id = 1;
  344. inline void WriteBatch::clear_batch_id() {
  345. batch_id_ = 0;
  346. }
  347. inline ::google::protobuf::int32 WriteBatch::batch_id() const {
  348. // @@protoc_insertion_point(field_get:firestore.client.WriteBatch.batch_id)
  349. return batch_id_;
  350. }
  351. inline void WriteBatch::set_batch_id(::google::protobuf::int32 value) {
  352. batch_id_ = value;
  353. // @@protoc_insertion_point(field_set:firestore.client.WriteBatch.batch_id)
  354. }
  355. // repeated .google.firestore.v1beta1.Write writes = 2;
  356. inline int WriteBatch::writes_size() const {
  357. return writes_.size();
  358. }
  359. inline const ::google::firestore::v1beta1::Write& WriteBatch::writes(int index) const {
  360. // @@protoc_insertion_point(field_get:firestore.client.WriteBatch.writes)
  361. return writes_.Get(index);
  362. }
  363. inline ::google::firestore::v1beta1::Write* WriteBatch::mutable_writes(int index) {
  364. // @@protoc_insertion_point(field_mutable:firestore.client.WriteBatch.writes)
  365. return writes_.Mutable(index);
  366. }
  367. inline ::google::firestore::v1beta1::Write* WriteBatch::add_writes() {
  368. // @@protoc_insertion_point(field_add:firestore.client.WriteBatch.writes)
  369. return writes_.Add();
  370. }
  371. inline ::google::protobuf::RepeatedPtrField< ::google::firestore::v1beta1::Write >*
  372. WriteBatch::mutable_writes() {
  373. // @@protoc_insertion_point(field_mutable_list:firestore.client.WriteBatch.writes)
  374. return &writes_;
  375. }
  376. inline const ::google::protobuf::RepeatedPtrField< ::google::firestore::v1beta1::Write >&
  377. WriteBatch::writes() const {
  378. // @@protoc_insertion_point(field_list:firestore.client.WriteBatch.writes)
  379. return writes_;
  380. }
  381. // .google.protobuf.Timestamp local_write_time = 3;
  382. inline bool WriteBatch::has_local_write_time() const {
  383. return this != internal_default_instance() && local_write_time_ != NULL;
  384. }
  385. inline const ::google::protobuf::Timestamp& WriteBatch::local_write_time() const {
  386. const ::google::protobuf::Timestamp* p = local_write_time_;
  387. // @@protoc_insertion_point(field_get:firestore.client.WriteBatch.local_write_time)
  388. return p != NULL ? *p : *reinterpret_cast<const ::google::protobuf::Timestamp*>(
  389. &::google::protobuf::_Timestamp_default_instance_);
  390. }
  391. inline ::google::protobuf::Timestamp* WriteBatch::release_local_write_time() {
  392. // @@protoc_insertion_point(field_release:firestore.client.WriteBatch.local_write_time)
  393. ::google::protobuf::Timestamp* temp = local_write_time_;
  394. local_write_time_ = NULL;
  395. return temp;
  396. }
  397. inline ::google::protobuf::Timestamp* WriteBatch::mutable_local_write_time() {
  398. if (local_write_time_ == NULL) {
  399. local_write_time_ = new ::google::protobuf::Timestamp;
  400. }
  401. // @@protoc_insertion_point(field_mutable:firestore.client.WriteBatch.local_write_time)
  402. return local_write_time_;
  403. }
  404. inline void WriteBatch::set_allocated_local_write_time(::google::protobuf::Timestamp* local_write_time) {
  405. ::google::protobuf::Arena* message_arena = GetArenaNoVirtual();
  406. if (message_arena == NULL) {
  407. delete reinterpret_cast< ::google::protobuf::MessageLite*>(local_write_time_);
  408. }
  409. if (local_write_time) {
  410. ::google::protobuf::Arena* submessage_arena =
  411. reinterpret_cast< ::google::protobuf::MessageLite*>(local_write_time)->GetArena();
  412. if (message_arena != submessage_arena) {
  413. local_write_time = ::google::protobuf::internal::GetOwnedMessage(
  414. message_arena, local_write_time, submessage_arena);
  415. }
  416. } else {
  417. }
  418. local_write_time_ = local_write_time;
  419. // @@protoc_insertion_point(field_set_allocated:firestore.client.WriteBatch.local_write_time)
  420. }
  421. #ifdef __GNUC__
  422. #pragma GCC diagnostic pop
  423. #endif // __GNUC__
  424. // -------------------------------------------------------------------
  425. // @@protoc_insertion_point(namespace_scope)
  426. } // namespace client
  427. } // namespace firestore
  428. // @@protoc_insertion_point(global_scope)
  429. #endif // PROTOBUF_firestore_2flocal_2fmutation_2eproto__INCLUDED