github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/c-deps/libroach/protos/util/hlc/legacy_timestamp.pb.h (about) 1 // Generated by the protocol buffer compiler. DO NOT EDIT! 2 // source: util/hlc/legacy_timestamp.proto 3 4 #ifndef PROTOBUF_INCLUDED_util_2fhlc_2flegacy_5ftimestamp_2eproto 5 #define PROTOBUF_INCLUDED_util_2fhlc_2flegacy_5ftimestamp_2eproto 6 7 #include <string> 8 9 #include <google/protobuf/stubs/common.h> 10 11 #if GOOGLE_PROTOBUF_VERSION < 3006000 12 #error This file was generated by a newer version of protoc which is 13 #error incompatible with your Protocol Buffer headers. Please update 14 #error your headers. 15 #endif 16 #if 3006000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION 17 #error This file was generated by an older version of protoc which is 18 #error incompatible with your Protocol Buffer headers. Please 19 #error regenerate this file with a newer version of protoc. 20 #endif 21 22 #include <google/protobuf/io/coded_stream.h> 23 #include <google/protobuf/arena.h> 24 #include <google/protobuf/arenastring.h> 25 #include <google/protobuf/generated_message_table_driven.h> 26 #include <google/protobuf/generated_message_util.h> 27 #include <google/protobuf/inlined_string_field.h> 28 #include <google/protobuf/metadata_lite.h> 29 #include <google/protobuf/message_lite.h> 30 #include <google/protobuf/repeated_field.h> // IWYU pragma: export 31 #include <google/protobuf/extension_set.h> // IWYU pragma: export 32 // @@protoc_insertion_point(includes) 33 #define PROTOBUF_INTERNAL_EXPORT_protobuf_util_2fhlc_2flegacy_5ftimestamp_2eproto 34 35 namespace protobuf_util_2fhlc_2flegacy_5ftimestamp_2eproto { 36 // Internal implementation detail -- do not use these members. 37 struct TableStruct { 38 static const ::google::protobuf::internal::ParseTableField entries[]; 39 static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; 40 static const ::google::protobuf::internal::ParseTable schema[1]; 41 static const ::google::protobuf::internal::FieldMetadata field_metadata[]; 42 static const ::google::protobuf::internal::SerializationTable serialization_table[]; 43 static const ::google::protobuf::uint32 offsets[]; 44 }; 45 } // namespace protobuf_util_2fhlc_2flegacy_5ftimestamp_2eproto 46 namespace cockroach { 47 namespace util { 48 namespace hlc { 49 class LegacyTimestamp; 50 class LegacyTimestampDefaultTypeInternal; 51 extern LegacyTimestampDefaultTypeInternal _LegacyTimestamp_default_instance_; 52 } // namespace hlc 53 } // namespace util 54 } // namespace cockroach 55 namespace google { 56 namespace protobuf { 57 template<> ::cockroach::util::hlc::LegacyTimestamp* Arena::CreateMaybeMessage<::cockroach::util::hlc::LegacyTimestamp>(Arena*); 58 } // namespace protobuf 59 } // namespace google 60 namespace cockroach { 61 namespace util { 62 namespace hlc { 63 64 // =================================================================== 65 66 class LegacyTimestamp : public ::google::protobuf::MessageLite /* @@protoc_insertion_point(class_definition:cockroach.util.hlc.LegacyTimestamp) */ { 67 public: 68 LegacyTimestamp(); 69 virtual ~LegacyTimestamp(); 70 71 LegacyTimestamp(const LegacyTimestamp& from); 72 73 inline LegacyTimestamp& operator=(const LegacyTimestamp& from) { 74 CopyFrom(from); 75 return *this; 76 } 77 #if LANG_CXX11 78 LegacyTimestamp(LegacyTimestamp&& from) noexcept 79 : LegacyTimestamp() { 80 *this = ::std::move(from); 81 } 82 83 inline LegacyTimestamp& operator=(LegacyTimestamp&& from) noexcept { 84 if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { 85 if (this != &from) InternalSwap(&from); 86 } else { 87 CopyFrom(from); 88 } 89 return *this; 90 } 91 #endif 92 inline const ::std::string& unknown_fields() const { 93 return _internal_metadata_.unknown_fields(); 94 } 95 inline ::std::string* mutable_unknown_fields() { 96 return _internal_metadata_.mutable_unknown_fields(); 97 } 98 99 static const LegacyTimestamp& default_instance(); 100 101 static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY 102 static inline const LegacyTimestamp* internal_default_instance() { 103 return reinterpret_cast<const LegacyTimestamp*>( 104 &_LegacyTimestamp_default_instance_); 105 } 106 static constexpr int kIndexInFileMessages = 107 0; 108 109 void Swap(LegacyTimestamp* other); 110 friend void swap(LegacyTimestamp& a, LegacyTimestamp& b) { 111 a.Swap(&b); 112 } 113 114 // implements Message ---------------------------------------------- 115 116 inline LegacyTimestamp* New() const final { 117 return CreateMaybeMessage<LegacyTimestamp>(NULL); 118 } 119 120 LegacyTimestamp* New(::google::protobuf::Arena* arena) const final { 121 return CreateMaybeMessage<LegacyTimestamp>(arena); 122 } 123 void CheckTypeAndMergeFrom(const ::google::protobuf::MessageLite& from) 124 final; 125 void CopyFrom(const LegacyTimestamp& from); 126 void MergeFrom(const LegacyTimestamp& from); 127 void Clear() final; 128 bool IsInitialized() const final; 129 130 size_t ByteSizeLong() const final; 131 bool MergePartialFromCodedStream( 132 ::google::protobuf::io::CodedInputStream* input) final; 133 void SerializeWithCachedSizes( 134 ::google::protobuf::io::CodedOutputStream* output) const final; 135 void DiscardUnknownFields(); 136 int GetCachedSize() const final { return _cached_size_.Get(); } 137 138 private: 139 void SharedCtor(); 140 void SharedDtor(); 141 void SetCachedSize(int size) const; 142 void InternalSwap(LegacyTimestamp* other); 143 private: 144 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { 145 return NULL; 146 } 147 inline void* MaybeArenaPtr() const { 148 return NULL; 149 } 150 public: 151 152 ::std::string GetTypeName() const final; 153 154 // nested types ---------------------------------------------------- 155 156 // accessors ------------------------------------------------------- 157 158 bool has_wall_time() const; 159 void clear_wall_time(); 160 static const int kWallTimeFieldNumber = 1; 161 ::google::protobuf::int64 wall_time() const; 162 void set_wall_time(::google::protobuf::int64 value); 163 164 bool has_logical() const; 165 void clear_logical(); 166 static const int kLogicalFieldNumber = 2; 167 ::google::protobuf::int32 logical() const; 168 void set_logical(::google::protobuf::int32 value); 169 170 // @@protoc_insertion_point(class_scope:cockroach.util.hlc.LegacyTimestamp) 171 private: 172 void set_has_wall_time(); 173 void clear_has_wall_time(); 174 void set_has_logical(); 175 void clear_has_logical(); 176 177 ::google::protobuf::internal::InternalMetadataWithArenaLite _internal_metadata_; 178 ::google::protobuf::internal::HasBits<1> _has_bits_; 179 mutable ::google::protobuf::internal::CachedSize _cached_size_; 180 ::google::protobuf::int64 wall_time_; 181 ::google::protobuf::int32 logical_; 182 friend struct ::protobuf_util_2fhlc_2flegacy_5ftimestamp_2eproto::TableStruct; 183 }; 184 // =================================================================== 185 186 187 // =================================================================== 188 189 #ifdef __GNUC__ 190 #pragma GCC diagnostic push 191 #pragma GCC diagnostic ignored "-Wstrict-aliasing" 192 #endif // __GNUC__ 193 // LegacyTimestamp 194 195 inline bool LegacyTimestamp::has_wall_time() const { 196 return (_has_bits_[0] & 0x00000001u) != 0; 197 } 198 inline void LegacyTimestamp::set_has_wall_time() { 199 _has_bits_[0] |= 0x00000001u; 200 } 201 inline void LegacyTimestamp::clear_has_wall_time() { 202 _has_bits_[0] &= ~0x00000001u; 203 } 204 inline void LegacyTimestamp::clear_wall_time() { 205 wall_time_ = GOOGLE_LONGLONG(0); 206 clear_has_wall_time(); 207 } 208 inline ::google::protobuf::int64 LegacyTimestamp::wall_time() const { 209 // @@protoc_insertion_point(field_get:cockroach.util.hlc.LegacyTimestamp.wall_time) 210 return wall_time_; 211 } 212 inline void LegacyTimestamp::set_wall_time(::google::protobuf::int64 value) { 213 set_has_wall_time(); 214 wall_time_ = value; 215 // @@protoc_insertion_point(field_set:cockroach.util.hlc.LegacyTimestamp.wall_time) 216 } 217 218 inline bool LegacyTimestamp::has_logical() const { 219 return (_has_bits_[0] & 0x00000002u) != 0; 220 } 221 inline void LegacyTimestamp::set_has_logical() { 222 _has_bits_[0] |= 0x00000002u; 223 } 224 inline void LegacyTimestamp::clear_has_logical() { 225 _has_bits_[0] &= ~0x00000002u; 226 } 227 inline void LegacyTimestamp::clear_logical() { 228 logical_ = 0; 229 clear_has_logical(); 230 } 231 inline ::google::protobuf::int32 LegacyTimestamp::logical() const { 232 // @@protoc_insertion_point(field_get:cockroach.util.hlc.LegacyTimestamp.logical) 233 return logical_; 234 } 235 inline void LegacyTimestamp::set_logical(::google::protobuf::int32 value) { 236 set_has_logical(); 237 logical_ = value; 238 // @@protoc_insertion_point(field_set:cockroach.util.hlc.LegacyTimestamp.logical) 239 } 240 241 #ifdef __GNUC__ 242 #pragma GCC diagnostic pop 243 #endif // __GNUC__ 244 245 // @@protoc_insertion_point(namespace_scope) 246 247 } // namespace hlc 248 } // namespace util 249 } // namespace cockroach 250 251 // @@protoc_insertion_point(global_scope) 252 253 #endif // PROTOBUF_INCLUDED_util_2fhlc_2flegacy_5ftimestamp_2eproto