timestamp.pb.h 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248
  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/protobuf/timestamp.proto
  18. #ifndef PROTOBUF_google_2fprotobuf_2ftimestamp_2eproto__INCLUDED
  19. #define PROTOBUF_google_2fprotobuf_2ftimestamp_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. // @@protoc_insertion_point(includes)
  43. namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto {
  44. // Internal implementation detail -- do not use these members.
  45. struct TableStruct {
  46. static const ::google::protobuf::internal::ParseTableField entries[];
  47. static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
  48. static const ::google::protobuf::internal::ParseTable schema[1];
  49. static const ::google::protobuf::internal::FieldMetadata field_metadata[];
  50. static const ::google::protobuf::internal::SerializationTable serialization_table[];
  51. static const ::google::protobuf::uint32 offsets[];
  52. };
  53. void AddDescriptors();
  54. void InitDefaultsTimestampImpl();
  55. void InitDefaultsTimestamp();
  56. inline void InitDefaults() {
  57. InitDefaultsTimestamp();
  58. }
  59. } // namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto
  60. namespace google {
  61. namespace protobuf {
  62. class Timestamp;
  63. class TimestampDefaultTypeInternal;
  64. extern TimestampDefaultTypeInternal _Timestamp_default_instance_;
  65. } // namespace protobuf
  66. } // namespace google
  67. namespace google {
  68. namespace protobuf {
  69. // ===================================================================
  70. class Timestamp : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Timestamp) */ {
  71. public:
  72. Timestamp();
  73. virtual ~Timestamp();
  74. Timestamp(const Timestamp& from);
  75. inline Timestamp& operator=(const Timestamp& from) {
  76. CopyFrom(from);
  77. return *this;
  78. }
  79. #if LANG_CXX11
  80. Timestamp(Timestamp&& from) noexcept
  81. : Timestamp() {
  82. *this = ::std::move(from);
  83. }
  84. inline Timestamp& operator=(Timestamp&& from) noexcept {
  85. if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
  86. if (this != &from) InternalSwap(&from);
  87. } else {
  88. CopyFrom(from);
  89. }
  90. return *this;
  91. }
  92. #endif
  93. inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL {
  94. return GetArenaNoVirtual();
  95. }
  96. inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL {
  97. return MaybeArenaPtr();
  98. }
  99. static const ::google::protobuf::Descriptor* descriptor();
  100. static const Timestamp& default_instance();
  101. static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
  102. static inline const Timestamp* internal_default_instance() {
  103. return reinterpret_cast<const Timestamp*>(
  104. &_Timestamp_default_instance_);
  105. }
  106. static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
  107. 0;
  108. void UnsafeArenaSwap(Timestamp* other);
  109. void Swap(Timestamp* other);
  110. friend void swap(Timestamp& a, Timestamp& b) {
  111. a.Swap(&b);
  112. }
  113. // implements Message ----------------------------------------------
  114. inline Timestamp* New() const PROTOBUF_FINAL { return New(NULL); }
  115. Timestamp* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
  116. void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  117. void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
  118. void CopyFrom(const Timestamp& from);
  119. void MergeFrom(const Timestamp& from);
  120. void Clear() PROTOBUF_FINAL;
  121. bool IsInitialized() const PROTOBUF_FINAL;
  122. size_t ByteSizeLong() const PROTOBUF_FINAL;
  123. bool MergePartialFromCodedStream(
  124. ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
  125. void SerializeWithCachedSizes(
  126. ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
  127. ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
  128. bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
  129. int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
  130. private:
  131. void SharedCtor();
  132. void SharedDtor();
  133. void SetCachedSize(int size) const PROTOBUF_FINAL;
  134. void InternalSwap(Timestamp* other);
  135. protected:
  136. explicit Timestamp(::google::protobuf::Arena* arena);
  137. private:
  138. static void ArenaDtor(void* object);
  139. inline void RegisterArenaDtor(::google::protobuf::Arena* arena);
  140. private:
  141. inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
  142. return _internal_metadata_.arena();
  143. }
  144. inline void* MaybeArenaPtr() const {
  145. return _internal_metadata_.raw_arena_ptr();
  146. }
  147. public:
  148. ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
  149. // nested types ----------------------------------------------------
  150. // accessors -------------------------------------------------------
  151. // int64 seconds = 1;
  152. void clear_seconds();
  153. static const int kSecondsFieldNumber = 1;
  154. ::google::protobuf::int64 seconds() const;
  155. void set_seconds(::google::protobuf::int64 value);
  156. // int32 nanos = 2;
  157. void clear_nanos();
  158. static const int kNanosFieldNumber = 2;
  159. ::google::protobuf::int32 nanos() const;
  160. void set_nanos(::google::protobuf::int32 value);
  161. // @@protoc_insertion_point(class_scope:google.protobuf.Timestamp)
  162. private:
  163. ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
  164. template <typename T> friend class ::google::protobuf::Arena::InternalHelper;
  165. typedef void InternalArenaConstructable_;
  166. typedef void DestructorSkippable_;
  167. ::google::protobuf::int64 seconds_;
  168. ::google::protobuf::int32 nanos_;
  169. mutable int _cached_size_;
  170. friend struct ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::TableStruct;
  171. friend void ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestampImpl();
  172. };
  173. // ===================================================================
  174. // ===================================================================
  175. #ifdef __GNUC__
  176. #pragma GCC diagnostic push
  177. #pragma GCC diagnostic ignored "-Wstrict-aliasing"
  178. #endif // __GNUC__
  179. // Timestamp
  180. // int64 seconds = 1;
  181. inline void Timestamp::clear_seconds() {
  182. seconds_ = GOOGLE_LONGLONG(0);
  183. }
  184. inline ::google::protobuf::int64 Timestamp::seconds() const {
  185. // @@protoc_insertion_point(field_get:google.protobuf.Timestamp.seconds)
  186. return seconds_;
  187. }
  188. inline void Timestamp::set_seconds(::google::protobuf::int64 value) {
  189. seconds_ = value;
  190. // @@protoc_insertion_point(field_set:google.protobuf.Timestamp.seconds)
  191. }
  192. // int32 nanos = 2;
  193. inline void Timestamp::clear_nanos() {
  194. nanos_ = 0;
  195. }
  196. inline ::google::protobuf::int32 Timestamp::nanos() const {
  197. // @@protoc_insertion_point(field_get:google.protobuf.Timestamp.nanos)
  198. return nanos_;
  199. }
  200. inline void Timestamp::set_nanos(::google::protobuf::int32 value) {
  201. nanos_ = value;
  202. // @@protoc_insertion_point(field_set:google.protobuf.Timestamp.nanos)
  203. }
  204. #ifdef __GNUC__
  205. #pragma GCC diagnostic pop
  206. #endif // __GNUC__
  207. // @@protoc_insertion_point(namespace_scope)
  208. } // namespace protobuf
  209. } // namespace google
  210. // @@protoc_insertion_point(global_scope)
  211. #endif // PROTOBUF_google_2fprotobuf_2ftimestamp_2eproto__INCLUDED