common.pb.h 41 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082
  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: google/firestore/v1beta1/common.proto
  18. #ifndef PROTOBUF_google_2ffirestore_2fv1beta1_2fcommon_2eproto__INCLUDED
  19. #define PROTOBUF_google_2ffirestore_2fv1beta1_2fcommon_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/api/annotations.pb.h"
  43. #include <google/protobuf/timestamp.pb.h>
  44. // @@protoc_insertion_point(includes)
  45. namespace protobuf_google_2ffirestore_2fv1beta1_2fcommon_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[5];
  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 InitDefaultsDocumentMaskImpl();
  57. void InitDefaultsDocumentMask();
  58. void InitDefaultsPreconditionImpl();
  59. void InitDefaultsPrecondition();
  60. void InitDefaultsTransactionOptions_ReadWriteImpl();
  61. void InitDefaultsTransactionOptions_ReadWrite();
  62. void InitDefaultsTransactionOptions_ReadOnlyImpl();
  63. void InitDefaultsTransactionOptions_ReadOnly();
  64. void InitDefaultsTransactionOptionsImpl();
  65. void InitDefaultsTransactionOptions();
  66. inline void InitDefaults() {
  67. InitDefaultsDocumentMask();
  68. InitDefaultsPrecondition();
  69. InitDefaultsTransactionOptions_ReadWrite();
  70. InitDefaultsTransactionOptions_ReadOnly();
  71. InitDefaultsTransactionOptions();
  72. }
  73. } // namespace protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto
  74. namespace google {
  75. namespace firestore {
  76. namespace v1beta1 {
  77. class DocumentMask;
  78. class DocumentMaskDefaultTypeInternal;
  79. extern DocumentMaskDefaultTypeInternal _DocumentMask_default_instance_;
  80. class Precondition;
  81. class PreconditionDefaultTypeInternal;
  82. extern PreconditionDefaultTypeInternal _Precondition_default_instance_;
  83. class TransactionOptions;
  84. class TransactionOptionsDefaultTypeInternal;
  85. extern TransactionOptionsDefaultTypeInternal _TransactionOptions_default_instance_;
  86. class TransactionOptions_ReadOnly;
  87. class TransactionOptions_ReadOnlyDefaultTypeInternal;
  88. extern TransactionOptions_ReadOnlyDefaultTypeInternal _TransactionOptions_ReadOnly_default_instance_;
  89. class TransactionOptions_ReadWrite;
  90. class TransactionOptions_ReadWriteDefaultTypeInternal;
  91. extern TransactionOptions_ReadWriteDefaultTypeInternal _TransactionOptions_ReadWrite_default_instance_;
  92. } // namespace v1beta1
  93. } // namespace firestore
  94. } // namespace google
  95. namespace google {
  96. namespace firestore {
  97. namespace v1beta1 {
  98. // ===================================================================
  99. class DocumentMask : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.firestore.v1beta1.DocumentMask) */ {
  100. public:
  101. DocumentMask();
  102. virtual ~DocumentMask();
  103. DocumentMask(const DocumentMask& from);
  104. inline DocumentMask& operator=(const DocumentMask& from) {
  105. CopyFrom(from);
  106. return *this;
  107. }
  108. #if LANG_CXX11
  109. DocumentMask(DocumentMask&& from) noexcept
  110. : DocumentMask() {
  111. *this = ::std::move(from);
  112. }
  113. inline DocumentMask& operator=(DocumentMask&& from) noexcept {
  114. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  115. if (this != &from) InternalSwap(&from);
  116. } else {
  117. CopyFrom(from);
  118. }
  119. return *this;
  120. }
  121. #endif
  122. static const ::google::protobuf::Descriptor* descriptor();
  123. static const DocumentMask& default_instance();
  124. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  125. static inline const DocumentMask* internal_default_instance() {
  126. return reinterpret_cast<const DocumentMask*>(
  127. &_DocumentMask_default_instance_);
  128. }
  129. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  130. 0;
  131. void Swap(DocumentMask* other);
  132. friend void swap(DocumentMask& a, DocumentMask& b) {
  133. a.Swap(&b);
  134. }
  135. // implements Message ----------------------------------------------
  136. inline DocumentMask* New() const PROTOBUF_FINAL { return New(NULL); }
  137. DocumentMask* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  138. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  139. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  140. void CopyFrom(const DocumentMask& from);
  141. void MergeFrom(const DocumentMask& from);
  142. void Clear() PROTOBUF_FINAL;
  143. bool IsInitialized() const PROTOBUF_FINAL;
  144. size_t ByteSizeLong() const PROTOBUF_FINAL;
  145. bool MergePartialFromCodedStream(
  146. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  147. void SerializeWithCachedSizes(
  148. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  149. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  150. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  151. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  152. private:
  153. void SharedCtor();
  154. void SharedDtor();
  155. void SetCachedSize(int size) const PROTOBUF_FINAL;
  156. void InternalSwap(DocumentMask* other);
  157. private:
  158. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  159. return NULL;
  160. }
  161. inline void* MaybeArenaPtr() const {
  162. return NULL;
  163. }
  164. public:
  165. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  166. // nested types ----------------------------------------------------
  167. // accessors -------------------------------------------------------
  168. // repeated string field_paths = 1;
  169. int field_paths_size() const;
  170. void clear_field_paths();
  171. static const int kFieldPathsFieldNumber = 1;
  172. const ::std::string& field_paths(int index) const;
  173. ::std::string* mutable_field_paths(int index);
  174. void set_field_paths(int index, const ::std::string& value);
  175. #if LANG_CXX11
  176. void set_field_paths(int index, ::std::string&& value);
  177. #endif
  178. void set_field_paths(int index, const char* value);
  179. void set_field_paths(int index, const char* value, size_t size);
  180. ::std::string* add_field_paths();
  181. void add_field_paths(const ::std::string& value);
  182. #if LANG_CXX11
  183. void add_field_paths(::std::string&& value);
  184. #endif
  185. void add_field_paths(const char* value);
  186. void add_field_paths(const char* value, size_t size);
  187. const ::google::protobuf::RepeatedPtrField< ::std::string>& field_paths() const;
  188. ::google::protobuf::RepeatedPtrField< ::std::string>* mutable_field_paths();
  189. // @@protoc_insertion_point(class_scope:google.firestore.v1beta1.DocumentMask)
  190. private:
  191. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  192. ::google::protobuf::RepeatedPtrField< ::std::string> field_paths_;
  193. mutable int _cached_size_;
  194. friend struct ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::TableStruct;
  195. friend void ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::InitDefaultsDocumentMaskImpl();
  196. };
  197. // -------------------------------------------------------------------
  198. class Precondition : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.firestore.v1beta1.Precondition) */ {
  199. public:
  200. Precondition();
  201. virtual ~Precondition();
  202. Precondition(const Precondition& from);
  203. inline Precondition& operator=(const Precondition& from) {
  204. CopyFrom(from);
  205. return *this;
  206. }
  207. #if LANG_CXX11
  208. Precondition(Precondition&& from) noexcept
  209. : Precondition() {
  210. *this = ::std::move(from);
  211. }
  212. inline Precondition& operator=(Precondition&& from) noexcept {
  213. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  214. if (this != &from) InternalSwap(&from);
  215. } else {
  216. CopyFrom(from);
  217. }
  218. return *this;
  219. }
  220. #endif
  221. static const ::google::protobuf::Descriptor* descriptor();
  222. static const Precondition& default_instance();
  223. enum ConditionTypeCase {
  224. kExists = 1,
  225. kUpdateTime = 2,
  226. CONDITION_TYPE_NOT_SET = 0,
  227. };
  228. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  229. static inline const Precondition* internal_default_instance() {
  230. return reinterpret_cast<const Precondition*>(
  231. &_Precondition_default_instance_);
  232. }
  233. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  234. 1;
  235. void Swap(Precondition* other);
  236. friend void swap(Precondition& a, Precondition& b) {
  237. a.Swap(&b);
  238. }
  239. // implements Message ----------------------------------------------
  240. inline Precondition* New() const PROTOBUF_FINAL { return New(NULL); }
  241. Precondition* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  242. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  243. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  244. void CopyFrom(const Precondition& from);
  245. void MergeFrom(const Precondition& from);
  246. void Clear() PROTOBUF_FINAL;
  247. bool IsInitialized() const PROTOBUF_FINAL;
  248. size_t ByteSizeLong() const PROTOBUF_FINAL;
  249. bool MergePartialFromCodedStream(
  250. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  251. void SerializeWithCachedSizes(
  252. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  253. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  254. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  255. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  256. private:
  257. void SharedCtor();
  258. void SharedDtor();
  259. void SetCachedSize(int size) const PROTOBUF_FINAL;
  260. void InternalSwap(Precondition* other);
  261. private:
  262. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  263. return NULL;
  264. }
  265. inline void* MaybeArenaPtr() const {
  266. return NULL;
  267. }
  268. public:
  269. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  270. // nested types ----------------------------------------------------
  271. // accessors -------------------------------------------------------
  272. // bool exists = 1;
  273. private:
  274. bool has_exists() const;
  275. public:
  276. void clear_exists();
  277. static const int kExistsFieldNumber = 1;
  278. bool exists() const;
  279. void set_exists(bool value);
  280. // .google.protobuf.Timestamp update_time = 2;
  281. bool has_update_time() const;
  282. void clear_update_time();
  283. static const int kUpdateTimeFieldNumber = 2;
  284. const ::google::protobuf::Timestamp& update_time() const;
  285. ::google::protobuf::Timestamp* release_update_time();
  286. ::google::protobuf::Timestamp* mutable_update_time();
  287. void set_allocated_update_time(::google::protobuf::Timestamp* update_time);
  288. ConditionTypeCase condition_type_case() const;
  289. // @@protoc_insertion_point(class_scope:google.firestore.v1beta1.Precondition)
  290. private:
  291. void set_has_exists();
  292. void set_has_update_time();
  293. inline bool has_condition_type() const;
  294. void clear_condition_type();
  295. inline void clear_has_condition_type();
  296. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  297. union ConditionTypeUnion {
  298. ConditionTypeUnion() {}
  299. bool exists_;
  300. ::google::protobuf::Timestamp* update_time_;
  301. } condition_type_;
  302. mutable int _cached_size_;
  303. ::google::protobuf::uint32 _oneof_case_[1];
  304. friend struct ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::TableStruct;
  305. friend void ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::InitDefaultsPreconditionImpl();
  306. };
  307. // -------------------------------------------------------------------
  308. class TransactionOptions_ReadWrite : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.firestore.v1beta1.TransactionOptions.ReadWrite) */ {
  309. public:
  310. TransactionOptions_ReadWrite();
  311. virtual ~TransactionOptions_ReadWrite();
  312. TransactionOptions_ReadWrite(const TransactionOptions_ReadWrite& from);
  313. inline TransactionOptions_ReadWrite& operator=(const TransactionOptions_ReadWrite& from) {
  314. CopyFrom(from);
  315. return *this;
  316. }
  317. #if LANG_CXX11
  318. TransactionOptions_ReadWrite(TransactionOptions_ReadWrite&& from) noexcept
  319. : TransactionOptions_ReadWrite() {
  320. *this = ::std::move(from);
  321. }
  322. inline TransactionOptions_ReadWrite& operator=(TransactionOptions_ReadWrite&& from) noexcept {
  323. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  324. if (this != &from) InternalSwap(&from);
  325. } else {
  326. CopyFrom(from);
  327. }
  328. return *this;
  329. }
  330. #endif
  331. static const ::google::protobuf::Descriptor* descriptor();
  332. static const TransactionOptions_ReadWrite& default_instance();
  333. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  334. static inline const TransactionOptions_ReadWrite* internal_default_instance() {
  335. return reinterpret_cast<const TransactionOptions_ReadWrite*>(
  336. &_TransactionOptions_ReadWrite_default_instance_);
  337. }
  338. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  339. 2;
  340. void Swap(TransactionOptions_ReadWrite* other);
  341. friend void swap(TransactionOptions_ReadWrite& a, TransactionOptions_ReadWrite& b) {
  342. a.Swap(&b);
  343. }
  344. // implements Message ----------------------------------------------
  345. inline TransactionOptions_ReadWrite* New() const PROTOBUF_FINAL { return New(NULL); }
  346. TransactionOptions_ReadWrite* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  347. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  348. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  349. void CopyFrom(const TransactionOptions_ReadWrite& from);
  350. void MergeFrom(const TransactionOptions_ReadWrite& from);
  351. void Clear() PROTOBUF_FINAL;
  352. bool IsInitialized() const PROTOBUF_FINAL;
  353. size_t ByteSizeLong() const PROTOBUF_FINAL;
  354. bool MergePartialFromCodedStream(
  355. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  356. void SerializeWithCachedSizes(
  357. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  358. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  359. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  360. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  361. private:
  362. void SharedCtor();
  363. void SharedDtor();
  364. void SetCachedSize(int size) const PROTOBUF_FINAL;
  365. void InternalSwap(TransactionOptions_ReadWrite* other);
  366. private:
  367. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  368. return NULL;
  369. }
  370. inline void* MaybeArenaPtr() const {
  371. return NULL;
  372. }
  373. public:
  374. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  375. // nested types ----------------------------------------------------
  376. // accessors -------------------------------------------------------
  377. // bytes retry_transaction = 1;
  378. void clear_retry_transaction();
  379. static const int kRetryTransactionFieldNumber = 1;
  380. const ::std::string& retry_transaction() const;
  381. void set_retry_transaction(const ::std::string& value);
  382. #if LANG_CXX11
  383. void set_retry_transaction(::std::string&& value);
  384. #endif
  385. void set_retry_transaction(const char* value);
  386. void set_retry_transaction(const void* value, size_t size);
  387. ::std::string* mutable_retry_transaction();
  388. ::std::string* release_retry_transaction();
  389. void set_allocated_retry_transaction(::std::string* retry_transaction);
  390. // @@protoc_insertion_point(class_scope:google.firestore.v1beta1.TransactionOptions.ReadWrite)
  391. private:
  392. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  393. ::google::protobuf::internal::ArenaStringPtr retry_transaction_;
  394. mutable int _cached_size_;
  395. friend struct ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::TableStruct;
  396. friend void ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::InitDefaultsTransactionOptions_ReadWriteImpl();
  397. };
  398. // -------------------------------------------------------------------
  399. class TransactionOptions_ReadOnly : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.firestore.v1beta1.TransactionOptions.ReadOnly) */ {
  400. public:
  401. TransactionOptions_ReadOnly();
  402. virtual ~TransactionOptions_ReadOnly();
  403. TransactionOptions_ReadOnly(const TransactionOptions_ReadOnly& from);
  404. inline TransactionOptions_ReadOnly& operator=(const TransactionOptions_ReadOnly& from) {
  405. CopyFrom(from);
  406. return *this;
  407. }
  408. #if LANG_CXX11
  409. TransactionOptions_ReadOnly(TransactionOptions_ReadOnly&& from) noexcept
  410. : TransactionOptions_ReadOnly() {
  411. *this = ::std::move(from);
  412. }
  413. inline TransactionOptions_ReadOnly& operator=(TransactionOptions_ReadOnly&& from) noexcept {
  414. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  415. if (this != &from) InternalSwap(&from);
  416. } else {
  417. CopyFrom(from);
  418. }
  419. return *this;
  420. }
  421. #endif
  422. static const ::google::protobuf::Descriptor* descriptor();
  423. static const TransactionOptions_ReadOnly& default_instance();
  424. enum ConsistencySelectorCase {
  425. kReadTime = 2,
  426. CONSISTENCY_SELECTOR_NOT_SET = 0,
  427. };
  428. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  429. static inline const TransactionOptions_ReadOnly* internal_default_instance() {
  430. return reinterpret_cast<const TransactionOptions_ReadOnly*>(
  431. &_TransactionOptions_ReadOnly_default_instance_);
  432. }
  433. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  434. 3;
  435. void Swap(TransactionOptions_ReadOnly* other);
  436. friend void swap(TransactionOptions_ReadOnly& a, TransactionOptions_ReadOnly& b) {
  437. a.Swap(&b);
  438. }
  439. // implements Message ----------------------------------------------
  440. inline TransactionOptions_ReadOnly* New() const PROTOBUF_FINAL { return New(NULL); }
  441. TransactionOptions_ReadOnly* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  442. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  443. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  444. void CopyFrom(const TransactionOptions_ReadOnly& from);
  445. void MergeFrom(const TransactionOptions_ReadOnly& from);
  446. void Clear() PROTOBUF_FINAL;
  447. bool IsInitialized() const PROTOBUF_FINAL;
  448. size_t ByteSizeLong() const PROTOBUF_FINAL;
  449. bool MergePartialFromCodedStream(
  450. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  451. void SerializeWithCachedSizes(
  452. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  453. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  454. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  455. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  456. private:
  457. void SharedCtor();
  458. void SharedDtor();
  459. void SetCachedSize(int size) const PROTOBUF_FINAL;
  460. void InternalSwap(TransactionOptions_ReadOnly* other);
  461. private:
  462. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  463. return NULL;
  464. }
  465. inline void* MaybeArenaPtr() const {
  466. return NULL;
  467. }
  468. public:
  469. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  470. // nested types ----------------------------------------------------
  471. // accessors -------------------------------------------------------
  472. // .google.protobuf.Timestamp read_time = 2;
  473. bool has_read_time() const;
  474. void clear_read_time();
  475. static const int kReadTimeFieldNumber = 2;
  476. const ::google::protobuf::Timestamp& read_time() const;
  477. ::google::protobuf::Timestamp* release_read_time();
  478. ::google::protobuf::Timestamp* mutable_read_time();
  479. void set_allocated_read_time(::google::protobuf::Timestamp* read_time);
  480. ConsistencySelectorCase consistency_selector_case() const;
  481. // @@protoc_insertion_point(class_scope:google.firestore.v1beta1.TransactionOptions.ReadOnly)
  482. private:
  483. void set_has_read_time();
  484. inline bool has_consistency_selector() const;
  485. void clear_consistency_selector();
  486. inline void clear_has_consistency_selector();
  487. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  488. union ConsistencySelectorUnion {
  489. ConsistencySelectorUnion() {}
  490. ::google::protobuf::Timestamp* read_time_;
  491. } consistency_selector_;
  492. mutable int _cached_size_;
  493. ::google::protobuf::uint32 _oneof_case_[1];
  494. friend struct ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::TableStruct;
  495. friend void ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::InitDefaultsTransactionOptions_ReadOnlyImpl();
  496. };
  497. // -------------------------------------------------------------------
  498. class TransactionOptions : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.firestore.v1beta1.TransactionOptions) */ {
  499. public:
  500. TransactionOptions();
  501. virtual ~TransactionOptions();
  502. TransactionOptions(const TransactionOptions& from);
  503. inline TransactionOptions& operator=(const TransactionOptions& from) {
  504. CopyFrom(from);
  505. return *this;
  506. }
  507. #if LANG_CXX11
  508. TransactionOptions(TransactionOptions&& from) noexcept
  509. : TransactionOptions() {
  510. *this = ::std::move(from);
  511. }
  512. inline TransactionOptions& operator=(TransactionOptions&& from) noexcept {
  513. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  514. if (this != &from) InternalSwap(&from);
  515. } else {
  516. CopyFrom(from);
  517. }
  518. return *this;
  519. }
  520. #endif
  521. static const ::google::protobuf::Descriptor* descriptor();
  522. static const TransactionOptions& default_instance();
  523. enum ModeCase {
  524. kReadOnly = 2,
  525. kReadWrite = 3,
  526. MODE_NOT_SET = 0,
  527. };
  528. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  529. static inline const TransactionOptions* internal_default_instance() {
  530. return reinterpret_cast<const TransactionOptions*>(
  531. &_TransactionOptions_default_instance_);
  532. }
  533. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  534. 4;
  535. void Swap(TransactionOptions* other);
  536. friend void swap(TransactionOptions& a, TransactionOptions& b) {
  537. a.Swap(&b);
  538. }
  539. // implements Message ----------------------------------------------
  540. inline TransactionOptions* New() const PROTOBUF_FINAL { return New(NULL); }
  541. TransactionOptions* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  542. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  543. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  544. void CopyFrom(const TransactionOptions& from);
  545. void MergeFrom(const TransactionOptions& from);
  546. void Clear() PROTOBUF_FINAL;
  547. bool IsInitialized() const PROTOBUF_FINAL;
  548. size_t ByteSizeLong() const PROTOBUF_FINAL;
  549. bool MergePartialFromCodedStream(
  550. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  551. void SerializeWithCachedSizes(
  552. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  553. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  554. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  555. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  556. private:
  557. void SharedCtor();
  558. void SharedDtor();
  559. void SetCachedSize(int size) const PROTOBUF_FINAL;
  560. void InternalSwap(TransactionOptions* other);
  561. private:
  562. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  563. return NULL;
  564. }
  565. inline void* MaybeArenaPtr() const {
  566. return NULL;
  567. }
  568. public:
  569. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  570. // nested types ----------------------------------------------------
  571. typedef TransactionOptions_ReadWrite ReadWrite;
  572. typedef TransactionOptions_ReadOnly ReadOnly;
  573. // accessors -------------------------------------------------------
  574. // .google.firestore.v1beta1.TransactionOptions.ReadOnly read_only = 2;
  575. bool has_read_only() const;
  576. void clear_read_only();
  577. static const int kReadOnlyFieldNumber = 2;
  578. const ::google::firestore::v1beta1::TransactionOptions_ReadOnly& read_only() const;
  579. ::google::firestore::v1beta1::TransactionOptions_ReadOnly* release_read_only();
  580. ::google::firestore::v1beta1::TransactionOptions_ReadOnly* mutable_read_only();
  581. void set_allocated_read_only(::google::firestore::v1beta1::TransactionOptions_ReadOnly* read_only);
  582. // .google.firestore.v1beta1.TransactionOptions.ReadWrite read_write = 3;
  583. bool has_read_write() const;
  584. void clear_read_write();
  585. static const int kReadWriteFieldNumber = 3;
  586. const ::google::firestore::v1beta1::TransactionOptions_ReadWrite& read_write() const;
  587. ::google::firestore::v1beta1::TransactionOptions_ReadWrite* release_read_write();
  588. ::google::firestore::v1beta1::TransactionOptions_ReadWrite* mutable_read_write();
  589. void set_allocated_read_write(::google::firestore::v1beta1::TransactionOptions_ReadWrite* read_write);
  590. ModeCase mode_case() const;
  591. // @@protoc_insertion_point(class_scope:google.firestore.v1beta1.TransactionOptions)
  592. private:
  593. void set_has_read_only();
  594. void set_has_read_write();
  595. inline bool has_mode() const;
  596. void clear_mode();
  597. inline void clear_has_mode();
  598. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  599. union ModeUnion {
  600. ModeUnion() {}
  601. ::google::firestore::v1beta1::TransactionOptions_ReadOnly* read_only_;
  602. ::google::firestore::v1beta1::TransactionOptions_ReadWrite* read_write_;
  603. } mode_;
  604. mutable int _cached_size_;
  605. ::google::protobuf::uint32 _oneof_case_[1];
  606. friend struct ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::TableStruct;
  607. friend void ::protobuf_google_2ffirestore_2fv1beta1_2fcommon_2eproto::InitDefaultsTransactionOptionsImpl();
  608. };
  609. // ===================================================================
  610. // ===================================================================
  611. #ifdef __GNUC__
  612. #pragma GCC diagnostic push
  613. #pragma GCC diagnostic ignored "-Wstrict-aliasing"
  614. #endif // __GNUC__
  615. // DocumentMask
  616. // repeated string field_paths = 1;
  617. inline int DocumentMask::field_paths_size() const {
  618. return field_paths_.size();
  619. }
  620. inline void DocumentMask::clear_field_paths() {
  621. field_paths_.Clear();
  622. }
  623. inline const ::std::string& DocumentMask::field_paths(int index) const {
  624. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.DocumentMask.field_paths)
  625. return field_paths_.Get(index);
  626. }
  627. inline ::std::string* DocumentMask::mutable_field_paths(int index) {
  628. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.DocumentMask.field_paths)
  629. return field_paths_.Mutable(index);
  630. }
  631. inline void DocumentMask::set_field_paths(int index, const ::std::string& value) {
  632. // @@protoc_insertion_point(field_set:google.firestore.v1beta1.DocumentMask.field_paths)
  633. field_paths_.Mutable(index)->assign(value);
  634. }
  635. #if LANG_CXX11
  636. inline void DocumentMask::set_field_paths(int index, ::std::string&& value) {
  637. // @@protoc_insertion_point(field_set:google.firestore.v1beta1.DocumentMask.field_paths)
  638. field_paths_.Mutable(index)->assign(std::move(value));
  639. }
  640. #endif
  641. inline void DocumentMask::set_field_paths(int index, const char* value) {
  642. GOOGLE_DCHECK(value != NULL);
  643. field_paths_.Mutable(index)->assign(value);
  644. // @@protoc_insertion_point(field_set_char:google.firestore.v1beta1.DocumentMask.field_paths)
  645. }
  646. inline void DocumentMask::set_field_paths(int index, const char* value, size_t size) {
  647. field_paths_.Mutable(index)->assign(
  648. reinterpret_cast<const char*>(value), size);
  649. // @@protoc_insertion_point(field_set_pointer:google.firestore.v1beta1.DocumentMask.field_paths)
  650. }
  651. inline ::std::string* DocumentMask::add_field_paths() {
  652. // @@protoc_insertion_point(field_add_mutable:google.firestore.v1beta1.DocumentMask.field_paths)
  653. return field_paths_.Add();
  654. }
  655. inline void DocumentMask::add_field_paths(const ::std::string& value) {
  656. field_paths_.Add()->assign(value);
  657. // @@protoc_insertion_point(field_add:google.firestore.v1beta1.DocumentMask.field_paths)
  658. }
  659. #if LANG_CXX11
  660. inline void DocumentMask::add_field_paths(::std::string&& value) {
  661. field_paths_.Add(std::move(value));
  662. // @@protoc_insertion_point(field_add:google.firestore.v1beta1.DocumentMask.field_paths)
  663. }
  664. #endif
  665. inline void DocumentMask::add_field_paths(const char* value) {
  666. GOOGLE_DCHECK(value != NULL);
  667. field_paths_.Add()->assign(value);
  668. // @@protoc_insertion_point(field_add_char:google.firestore.v1beta1.DocumentMask.field_paths)
  669. }
  670. inline void DocumentMask::add_field_paths(const char* value, size_t size) {
  671. field_paths_.Add()->assign(reinterpret_cast<const char*>(value), size);
  672. // @@protoc_insertion_point(field_add_pointer:google.firestore.v1beta1.DocumentMask.field_paths)
  673. }
  674. inline const ::google::protobuf::RepeatedPtrField< ::std::string>&
  675. DocumentMask::field_paths() const {
  676. // @@protoc_insertion_point(field_list:google.firestore.v1beta1.DocumentMask.field_paths)
  677. return field_paths_;
  678. }
  679. inline ::google::protobuf::RepeatedPtrField< ::std::string>*
  680. DocumentMask::mutable_field_paths() {
  681. // @@protoc_insertion_point(field_mutable_list:google.firestore.v1beta1.DocumentMask.field_paths)
  682. return &field_paths_;
  683. }
  684. // -------------------------------------------------------------------
  685. // Precondition
  686. // bool exists = 1;
  687. inline bool Precondition::has_exists() const {
  688. return condition_type_case() == kExists;
  689. }
  690. inline void Precondition::set_has_exists() {
  691. _oneof_case_[0] = kExists;
  692. }
  693. inline void Precondition::clear_exists() {
  694. if (has_exists()) {
  695. condition_type_.exists_ = false;
  696. clear_has_condition_type();
  697. }
  698. }
  699. inline bool Precondition::exists() const {
  700. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.Precondition.exists)
  701. if (has_exists()) {
  702. return condition_type_.exists_;
  703. }
  704. return false;
  705. }
  706. inline void Precondition::set_exists(bool value) {
  707. if (!has_exists()) {
  708. clear_condition_type();
  709. set_has_exists();
  710. }
  711. condition_type_.exists_ = value;
  712. // @@protoc_insertion_point(field_set:google.firestore.v1beta1.Precondition.exists)
  713. }
  714. // .google.protobuf.Timestamp update_time = 2;
  715. inline bool Precondition::has_update_time() const {
  716. return condition_type_case() == kUpdateTime;
  717. }
  718. inline void Precondition::set_has_update_time() {
  719. _oneof_case_[0] = kUpdateTime;
  720. }
  721. inline ::google::protobuf::Timestamp* Precondition::release_update_time() {
  722. // @@protoc_insertion_point(field_release:google.firestore.v1beta1.Precondition.update_time)
  723. if (has_update_time()) {
  724. clear_has_condition_type();
  725. ::google::protobuf::Timestamp* temp = condition_type_.update_time_;
  726. condition_type_.update_time_ = NULL;
  727. return temp;
  728. } else {
  729. return NULL;
  730. }
  731. }
  732. inline const ::google::protobuf::Timestamp& Precondition::update_time() const {
  733. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.Precondition.update_time)
  734. return has_update_time()
  735. ? *condition_type_.update_time_
  736. : *reinterpret_cast< ::google::protobuf::Timestamp*>(&::google::protobuf::_Timestamp_default_instance_);
  737. }
  738. inline ::google::protobuf::Timestamp* Precondition::mutable_update_time() {
  739. if (!has_update_time()) {
  740. clear_condition_type();
  741. set_has_update_time();
  742. condition_type_.update_time_ = new ::google::protobuf::Timestamp;
  743. }
  744. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.Precondition.update_time)
  745. return condition_type_.update_time_;
  746. }
  747. inline bool Precondition::has_condition_type() const {
  748. return condition_type_case() != CONDITION_TYPE_NOT_SET;
  749. }
  750. inline void Precondition::clear_has_condition_type() {
  751. _oneof_case_[0] = CONDITION_TYPE_NOT_SET;
  752. }
  753. inline Precondition::ConditionTypeCase Precondition::condition_type_case() const {
  754. return Precondition::ConditionTypeCase(_oneof_case_[0]);
  755. }
  756. // -------------------------------------------------------------------
  757. // TransactionOptions_ReadWrite
  758. // bytes retry_transaction = 1;
  759. inline void TransactionOptions_ReadWrite::clear_retry_transaction() {
  760. retry_transaction_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  761. }
  762. inline const ::std::string& TransactionOptions_ReadWrite::retry_transaction() const {
  763. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  764. return retry_transaction_.GetNoArena();
  765. }
  766. inline void TransactionOptions_ReadWrite::set_retry_transaction(const ::std::string& value) {
  767. retry_transaction_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  768. // @@protoc_insertion_point(field_set:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  769. }
  770. #if LANG_CXX11
  771. inline void TransactionOptions_ReadWrite::set_retry_transaction(::std::string&& value) {
  772. retry_transaction_.SetNoArena(
  773. &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  774. // @@protoc_insertion_point(field_set_rvalue:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  775. }
  776. #endif
  777. inline void TransactionOptions_ReadWrite::set_retry_transaction(const char* value) {
  778. GOOGLE_DCHECK(value != NULL);
  779. retry_transaction_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  780. // @@protoc_insertion_point(field_set_char:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  781. }
  782. inline void TransactionOptions_ReadWrite::set_retry_transaction(const void* value, size_t size) {
  783. retry_transaction_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  784. ::std::string(reinterpret_cast<const char*>(value), size));
  785. // @@protoc_insertion_point(field_set_pointer:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  786. }
  787. inline ::std::string* TransactionOptions_ReadWrite::mutable_retry_transaction() {
  788. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  789. return retry_transaction_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  790. }
  791. inline ::std::string* TransactionOptions_ReadWrite::release_retry_transaction() {
  792. // @@protoc_insertion_point(field_release:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  793. return retry_transaction_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  794. }
  795. inline void TransactionOptions_ReadWrite::set_allocated_retry_transaction(::std::string* retry_transaction) {
  796. if (retry_transaction != NULL) {
  797. } else {
  798. }
  799. retry_transaction_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), retry_transaction);
  800. // @@protoc_insertion_point(field_set_allocated:google.firestore.v1beta1.TransactionOptions.ReadWrite.retry_transaction)
  801. }
  802. // -------------------------------------------------------------------
  803. // TransactionOptions_ReadOnly
  804. // .google.protobuf.Timestamp read_time = 2;
  805. inline bool TransactionOptions_ReadOnly::has_read_time() const {
  806. return consistency_selector_case() == kReadTime;
  807. }
  808. inline void TransactionOptions_ReadOnly::set_has_read_time() {
  809. _oneof_case_[0] = kReadTime;
  810. }
  811. inline ::google::protobuf::Timestamp* TransactionOptions_ReadOnly::release_read_time() {
  812. // @@protoc_insertion_point(field_release:google.firestore.v1beta1.TransactionOptions.ReadOnly.read_time)
  813. if (has_read_time()) {
  814. clear_has_consistency_selector();
  815. ::google::protobuf::Timestamp* temp = consistency_selector_.read_time_;
  816. consistency_selector_.read_time_ = NULL;
  817. return temp;
  818. } else {
  819. return NULL;
  820. }
  821. }
  822. inline const ::google::protobuf::Timestamp& TransactionOptions_ReadOnly::read_time() const {
  823. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.TransactionOptions.ReadOnly.read_time)
  824. return has_read_time()
  825. ? *consistency_selector_.read_time_
  826. : *reinterpret_cast< ::google::protobuf::Timestamp*>(&::google::protobuf::_Timestamp_default_instance_);
  827. }
  828. inline ::google::protobuf::Timestamp* TransactionOptions_ReadOnly::mutable_read_time() {
  829. if (!has_read_time()) {
  830. clear_consistency_selector();
  831. set_has_read_time();
  832. consistency_selector_.read_time_ = new ::google::protobuf::Timestamp;
  833. }
  834. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.TransactionOptions.ReadOnly.read_time)
  835. return consistency_selector_.read_time_;
  836. }
  837. inline bool TransactionOptions_ReadOnly::has_consistency_selector() const {
  838. return consistency_selector_case() != CONSISTENCY_SELECTOR_NOT_SET;
  839. }
  840. inline void TransactionOptions_ReadOnly::clear_has_consistency_selector() {
  841. _oneof_case_[0] = CONSISTENCY_SELECTOR_NOT_SET;
  842. }
  843. inline TransactionOptions_ReadOnly::ConsistencySelectorCase TransactionOptions_ReadOnly::consistency_selector_case() const {
  844. return TransactionOptions_ReadOnly::ConsistencySelectorCase(_oneof_case_[0]);
  845. }
  846. // -------------------------------------------------------------------
  847. // TransactionOptions
  848. // .google.firestore.v1beta1.TransactionOptions.ReadOnly read_only = 2;
  849. inline bool TransactionOptions::has_read_only() const {
  850. return mode_case() == kReadOnly;
  851. }
  852. inline void TransactionOptions::set_has_read_only() {
  853. _oneof_case_[0] = kReadOnly;
  854. }
  855. inline void TransactionOptions::clear_read_only() {
  856. if (has_read_only()) {
  857. delete mode_.read_only_;
  858. clear_has_mode();
  859. }
  860. }
  861. inline ::google::firestore::v1beta1::TransactionOptions_ReadOnly* TransactionOptions::release_read_only() {
  862. // @@protoc_insertion_point(field_release:google.firestore.v1beta1.TransactionOptions.read_only)
  863. if (has_read_only()) {
  864. clear_has_mode();
  865. ::google::firestore::v1beta1::TransactionOptions_ReadOnly* temp = mode_.read_only_;
  866. mode_.read_only_ = NULL;
  867. return temp;
  868. } else {
  869. return NULL;
  870. }
  871. }
  872. inline const ::google::firestore::v1beta1::TransactionOptions_ReadOnly& TransactionOptions::read_only() const {
  873. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.TransactionOptions.read_only)
  874. return has_read_only()
  875. ? *mode_.read_only_
  876. : *reinterpret_cast< ::google::firestore::v1beta1::TransactionOptions_ReadOnly*>(&::google::firestore::v1beta1::_TransactionOptions_ReadOnly_default_instance_);
  877. }
  878. inline ::google::firestore::v1beta1::TransactionOptions_ReadOnly* TransactionOptions::mutable_read_only() {
  879. if (!has_read_only()) {
  880. clear_mode();
  881. set_has_read_only();
  882. mode_.read_only_ = new ::google::firestore::v1beta1::TransactionOptions_ReadOnly;
  883. }
  884. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.TransactionOptions.read_only)
  885. return mode_.read_only_;
  886. }
  887. // .google.firestore.v1beta1.TransactionOptions.ReadWrite read_write = 3;
  888. inline bool TransactionOptions::has_read_write() const {
  889. return mode_case() == kReadWrite;
  890. }
  891. inline void TransactionOptions::set_has_read_write() {
  892. _oneof_case_[0] = kReadWrite;
  893. }
  894. inline void TransactionOptions::clear_read_write() {
  895. if (has_read_write()) {
  896. delete mode_.read_write_;
  897. clear_has_mode();
  898. }
  899. }
  900. inline ::google::firestore::v1beta1::TransactionOptions_ReadWrite* TransactionOptions::release_read_write() {
  901. // @@protoc_insertion_point(field_release:google.firestore.v1beta1.TransactionOptions.read_write)
  902. if (has_read_write()) {
  903. clear_has_mode();
  904. ::google::firestore::v1beta1::TransactionOptions_ReadWrite* temp = mode_.read_write_;
  905. mode_.read_write_ = NULL;
  906. return temp;
  907. } else {
  908. return NULL;
  909. }
  910. }
  911. inline const ::google::firestore::v1beta1::TransactionOptions_ReadWrite& TransactionOptions::read_write() const {
  912. // @@protoc_insertion_point(field_get:google.firestore.v1beta1.TransactionOptions.read_write)
  913. return has_read_write()
  914. ? *mode_.read_write_
  915. : *reinterpret_cast< ::google::firestore::v1beta1::TransactionOptions_ReadWrite*>(&::google::firestore::v1beta1::_TransactionOptions_ReadWrite_default_instance_);
  916. }
  917. inline ::google::firestore::v1beta1::TransactionOptions_ReadWrite* TransactionOptions::mutable_read_write() {
  918. if (!has_read_write()) {
  919. clear_mode();
  920. set_has_read_write();
  921. mode_.read_write_ = new ::google::firestore::v1beta1::TransactionOptions_ReadWrite;
  922. }
  923. // @@protoc_insertion_point(field_mutable:google.firestore.v1beta1.TransactionOptions.read_write)
  924. return mode_.read_write_;
  925. }
  926. inline bool TransactionOptions::has_mode() const {
  927. return mode_case() != MODE_NOT_SET;
  928. }
  929. inline void TransactionOptions::clear_has_mode() {
  930. _oneof_case_[0] = MODE_NOT_SET;
  931. }
  932. inline TransactionOptions::ModeCase TransactionOptions::mode_case() const {
  933. return TransactionOptions::ModeCase(_oneof_case_[0]);
  934. }
  935. #ifdef __GNUC__
  936. #pragma GCC diagnostic pop
  937. #endif // __GNUC__
  938. // -------------------------------------------------------------------
  939. // -------------------------------------------------------------------
  940. // -------------------------------------------------------------------
  941. // -------------------------------------------------------------------
  942. // @@protoc_insertion_point(namespace_scope)
  943. } // namespace v1beta1
  944. } // namespace firestore
  945. } // namespace google
  946. // @@protoc_insertion_point(global_scope)
  947. #endif // PROTOBUF_google_2ffirestore_2fv1beta1_2fcommon_2eproto__INCLUDED