github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/c-deps/libroach/protosccl/ccl/storageccl/engineccl/enginepbccl/stats.pb.cc (about) 1 // Generated by the protocol buffer compiler. DO NOT EDIT! 2 // source: ccl/storageccl/engineccl/enginepbccl/stats.proto 3 4 #include "ccl/storageccl/engineccl/enginepbccl/stats.pb.h" 5 6 #include <algorithm> 7 8 #include <google/protobuf/stubs/common.h> 9 #include <google/protobuf/stubs/port.h> 10 #include <google/protobuf/io/coded_stream.h> 11 #include <google/protobuf/wire_format_lite_inl.h> 12 #include <google/protobuf/io/zero_copy_stream_impl_lite.h> 13 // This is a temporary google only hack 14 #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS 15 #include "third_party/protobuf/version.h" 16 #endif 17 // @@protoc_insertion_point(includes) 18 19 namespace protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fkey_5fregistry_2eproto { 20 extern PROTOBUF_INTERNAL_EXPORT_protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fkey_5fregistry_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_KeyInfo; 21 } // namespace protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fkey_5fregistry_2eproto 22 namespace cockroach { 23 namespace ccl { 24 namespace storageccl { 25 namespace engineccl { 26 namespace enginepbccl { 27 class EncryptionStatusDefaultTypeInternal { 28 public: 29 ::google::protobuf::internal::ExplicitlyConstructed<EncryptionStatus> 30 _instance; 31 } _EncryptionStatus_default_instance_; 32 } // namespace enginepbccl 33 } // namespace engineccl 34 } // namespace storageccl 35 } // namespace ccl 36 } // namespace cockroach 37 namespace protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fstats_2eproto { 38 static void InitDefaultsEncryptionStatus() { 39 GOOGLE_PROTOBUF_VERIFY_VERSION; 40 41 { 42 void* ptr = &::cockroach::ccl::storageccl::engineccl::enginepbccl::_EncryptionStatus_default_instance_; 43 new (ptr) ::cockroach::ccl::storageccl::engineccl::enginepbccl::EncryptionStatus(); 44 ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); 45 } 46 ::cockroach::ccl::storageccl::engineccl::enginepbccl::EncryptionStatus::InitAsDefaultInstance(); 47 } 48 49 ::google::protobuf::internal::SCCInfo<1> scc_info_EncryptionStatus = 50 {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsEncryptionStatus}, { 51 &protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fkey_5fregistry_2eproto::scc_info_KeyInfo.base,}}; 52 53 void InitDefaults() { 54 ::google::protobuf::internal::InitSCC(&scc_info_EncryptionStatus.base); 55 } 56 57 } // namespace protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fstats_2eproto 58 namespace cockroach { 59 namespace ccl { 60 namespace storageccl { 61 namespace engineccl { 62 namespace enginepbccl { 63 64 // =================================================================== 65 66 void EncryptionStatus::InitAsDefaultInstance() { 67 ::cockroach::ccl::storageccl::engineccl::enginepbccl::_EncryptionStatus_default_instance_._instance.get_mutable()->active_store_key_ = const_cast< ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo*>( 68 ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo::internal_default_instance()); 69 ::cockroach::ccl::storageccl::engineccl::enginepbccl::_EncryptionStatus_default_instance_._instance.get_mutable()->active_data_key_ = const_cast< ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo*>( 70 ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo::internal_default_instance()); 71 } 72 void EncryptionStatus::clear_active_store_key() { 73 if (GetArenaNoVirtual() == NULL && active_store_key_ != NULL) { 74 delete active_store_key_; 75 } 76 active_store_key_ = NULL; 77 } 78 void EncryptionStatus::clear_active_data_key() { 79 if (GetArenaNoVirtual() == NULL && active_data_key_ != NULL) { 80 delete active_data_key_; 81 } 82 active_data_key_ = NULL; 83 } 84 #if !defined(_MSC_VER) || _MSC_VER >= 1900 85 const int EncryptionStatus::kActiveStoreKeyFieldNumber; 86 const int EncryptionStatus::kActiveDataKeyFieldNumber; 87 #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 88 89 EncryptionStatus::EncryptionStatus() 90 : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) { 91 ::google::protobuf::internal::InitSCC( 92 &protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fstats_2eproto::scc_info_EncryptionStatus.base); 93 SharedCtor(); 94 // @@protoc_insertion_point(constructor:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 95 } 96 EncryptionStatus::EncryptionStatus(const EncryptionStatus& from) 97 : ::google::protobuf::MessageLite(), 98 _internal_metadata_(NULL) { 99 _internal_metadata_.MergeFrom(from._internal_metadata_); 100 if (from.has_active_store_key()) { 101 active_store_key_ = new ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo(*from.active_store_key_); 102 } else { 103 active_store_key_ = NULL; 104 } 105 if (from.has_active_data_key()) { 106 active_data_key_ = new ::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo(*from.active_data_key_); 107 } else { 108 active_data_key_ = NULL; 109 } 110 // @@protoc_insertion_point(copy_constructor:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 111 } 112 113 void EncryptionStatus::SharedCtor() { 114 ::memset(&active_store_key_, 0, static_cast<size_t>( 115 reinterpret_cast<char*>(&active_data_key_) - 116 reinterpret_cast<char*>(&active_store_key_)) + sizeof(active_data_key_)); 117 } 118 119 EncryptionStatus::~EncryptionStatus() { 120 // @@protoc_insertion_point(destructor:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 121 SharedDtor(); 122 } 123 124 void EncryptionStatus::SharedDtor() { 125 if (this != internal_default_instance()) delete active_store_key_; 126 if (this != internal_default_instance()) delete active_data_key_; 127 } 128 129 void EncryptionStatus::SetCachedSize(int size) const { 130 _cached_size_.Set(size); 131 } 132 const EncryptionStatus& EncryptionStatus::default_instance() { 133 ::google::protobuf::internal::InitSCC(&protobuf_ccl_2fstorageccl_2fengineccl_2fenginepbccl_2fstats_2eproto::scc_info_EncryptionStatus.base); 134 return *internal_default_instance(); 135 } 136 137 138 void EncryptionStatus::Clear() { 139 // @@protoc_insertion_point(message_clear_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 140 ::google::protobuf::uint32 cached_has_bits = 0; 141 // Prevent compiler warnings about cached_has_bits being unused 142 (void) cached_has_bits; 143 144 if (GetArenaNoVirtual() == NULL && active_store_key_ != NULL) { 145 delete active_store_key_; 146 } 147 active_store_key_ = NULL; 148 if (GetArenaNoVirtual() == NULL && active_data_key_ != NULL) { 149 delete active_data_key_; 150 } 151 active_data_key_ = NULL; 152 _internal_metadata_.Clear(); 153 } 154 155 bool EncryptionStatus::MergePartialFromCodedStream( 156 ::google::protobuf::io::CodedInputStream* input) { 157 #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure 158 ::google::protobuf::uint32 tag; 159 ::google::protobuf::internal::LiteUnknownFieldSetter unknown_fields_setter( 160 &_internal_metadata_); 161 ::google::protobuf::io::StringOutputStream unknown_fields_output( 162 unknown_fields_setter.buffer()); 163 ::google::protobuf::io::CodedOutputStream unknown_fields_stream( 164 &unknown_fields_output, false); 165 // @@protoc_insertion_point(parse_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 166 for (;;) { 167 ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); 168 tag = p.first; 169 if (!p.second) goto handle_unusual; 170 switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { 171 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_store_key = 1; 172 case 1: { 173 if (static_cast< ::google::protobuf::uint8>(tag) == 174 static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { 175 DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( 176 input, mutable_active_store_key())); 177 } else { 178 goto handle_unusual; 179 } 180 break; 181 } 182 183 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_data_key = 2; 184 case 2: { 185 if (static_cast< ::google::protobuf::uint8>(tag) == 186 static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { 187 DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( 188 input, mutable_active_data_key())); 189 } else { 190 goto handle_unusual; 191 } 192 break; 193 } 194 195 default: { 196 handle_unusual: 197 if (tag == 0) { 198 goto success; 199 } 200 DO_(::google::protobuf::internal::WireFormatLite::SkipField( 201 input, tag, &unknown_fields_stream)); 202 break; 203 } 204 } 205 } 206 success: 207 // @@protoc_insertion_point(parse_success:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 208 return true; 209 failure: 210 // @@protoc_insertion_point(parse_failure:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 211 return false; 212 #undef DO_ 213 } 214 215 void EncryptionStatus::SerializeWithCachedSizes( 216 ::google::protobuf::io::CodedOutputStream* output) const { 217 // @@protoc_insertion_point(serialize_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 218 ::google::protobuf::uint32 cached_has_bits = 0; 219 (void) cached_has_bits; 220 221 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_store_key = 1; 222 if (this->has_active_store_key()) { 223 ::google::protobuf::internal::WireFormatLite::WriteMessage( 224 1, this->_internal_active_store_key(), output); 225 } 226 227 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_data_key = 2; 228 if (this->has_active_data_key()) { 229 ::google::protobuf::internal::WireFormatLite::WriteMessage( 230 2, this->_internal_active_data_key(), output); 231 } 232 233 output->WriteRaw((::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()).data(), 234 static_cast<int>((::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()).size())); 235 // @@protoc_insertion_point(serialize_end:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 236 } 237 238 size_t EncryptionStatus::ByteSizeLong() const { 239 // @@protoc_insertion_point(message_byte_size_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 240 size_t total_size = 0; 241 242 total_size += (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()).size(); 243 244 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_store_key = 1; 245 if (this->has_active_store_key()) { 246 total_size += 1 + 247 ::google::protobuf::internal::WireFormatLite::MessageSize( 248 *active_store_key_); 249 } 250 251 // .cockroach.ccl.storageccl.engineccl.enginepbccl.KeyInfo active_data_key = 2; 252 if (this->has_active_data_key()) { 253 total_size += 1 + 254 ::google::protobuf::internal::WireFormatLite::MessageSize( 255 *active_data_key_); 256 } 257 258 int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); 259 SetCachedSize(cached_size); 260 return total_size; 261 } 262 263 void EncryptionStatus::CheckTypeAndMergeFrom( 264 const ::google::protobuf::MessageLite& from) { 265 MergeFrom(*::google::protobuf::down_cast<const EncryptionStatus*>(&from)); 266 } 267 268 void EncryptionStatus::MergeFrom(const EncryptionStatus& from) { 269 // @@protoc_insertion_point(class_specific_merge_from_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 270 GOOGLE_DCHECK_NE(&from, this); 271 _internal_metadata_.MergeFrom(from._internal_metadata_); 272 ::google::protobuf::uint32 cached_has_bits = 0; 273 (void) cached_has_bits; 274 275 if (from.has_active_store_key()) { 276 mutable_active_store_key()->::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo::MergeFrom(from.active_store_key()); 277 } 278 if (from.has_active_data_key()) { 279 mutable_active_data_key()->::cockroach::ccl::storageccl::engineccl::enginepbccl::KeyInfo::MergeFrom(from.active_data_key()); 280 } 281 } 282 283 void EncryptionStatus::CopyFrom(const EncryptionStatus& from) { 284 // @@protoc_insertion_point(class_specific_copy_from_start:cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus) 285 if (&from == this) return; 286 Clear(); 287 MergeFrom(from); 288 } 289 290 bool EncryptionStatus::IsInitialized() const { 291 return true; 292 } 293 294 void EncryptionStatus::Swap(EncryptionStatus* other) { 295 if (other == this) return; 296 InternalSwap(other); 297 } 298 void EncryptionStatus::InternalSwap(EncryptionStatus* other) { 299 using std::swap; 300 swap(active_store_key_, other->active_store_key_); 301 swap(active_data_key_, other->active_data_key_); 302 _internal_metadata_.Swap(&other->_internal_metadata_); 303 } 304 305 ::std::string EncryptionStatus::GetTypeName() const { 306 return "cockroach.ccl.storageccl.engineccl.enginepbccl.EncryptionStatus"; 307 } 308 309 310 // @@protoc_insertion_point(namespace_scope) 311 } // namespace enginepbccl 312 } // namespace engineccl 313 } // namespace storageccl 314 } // namespace ccl 315 } // namespace cockroach 316 namespace google { 317 namespace protobuf { 318 template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::ccl::storageccl::engineccl::enginepbccl::EncryptionStatus* Arena::CreateMaybeMessage< ::cockroach::ccl::storageccl::engineccl::enginepbccl::EncryptionStatus >(Arena* arena) { 319 return Arena::CreateInternal< ::cockroach::ccl::storageccl::engineccl::enginepbccl::EncryptionStatus >(arena); 320 } 321 } // namespace protobuf 322 } // namespace google 323 324 // @@protoc_insertion_point(global_scope)