YugabyteDB (2.13.0.0-b42, bfc6a6643e7399ac8a0e81d06a3ee6d6571b33ab)

Coverage Report

Created: 2022-03-09 17:30

/Users/deen/code/yugabyte-db/build/debugcov-clang-dynamic-arm64-ninja/src/yb/common/common_net.pb.cc
Line
Count
Source (jump to first uncovered line)
1
// Generated by the protocol buffer compiler.  DO NOT EDIT!
2
// source: yb/common/common_net.proto
3
4
#include "yb/common/common_net.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/stubs/once.h>
11
#include <google/protobuf/io/coded_stream.h>
12
#include <google/protobuf/wire_format_lite_inl.h>
13
#include <google/protobuf/descriptor.h>
14
#include <google/protobuf/generated_message_reflection.h>
15
#include <google/protobuf/reflection_ops.h>
16
#include <google/protobuf/wire_format.h>
17
// This is a temporary google only hack
18
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
19
#include "third_party/protobuf/version.h"
20
#endif
21
#include "yb/util/protobuf-annotations.h"
22
// @@protoc_insertion_point(includes)
23
namespace yb {
24
class HostPortPBDefaultTypeInternal {
25
 public:
26
  ::google::protobuf::internal::ExplicitlyConstructed<HostPortPB>
27
      _instance;
28
} _HostPortPB_default_instance_;
29
class CloudInfoPBDefaultTypeInternal {
30
 public:
31
  ::google::protobuf::internal::ExplicitlyConstructed<CloudInfoPB>
32
      _instance;
33
} _CloudInfoPB_default_instance_;
34
}  // namespace yb
35
namespace protobuf_yb_2fcommon_2fcommon_5fnet_2eproto {
36
17.1k
void InitDefaultsHostPortPBImpl() {
37
17.1k
  GOOGLE_PROTOBUF_VERIFY_VERSION;
38
39
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
40
  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
41
#else
42
17.1k
  ::google::protobuf::internal::InitProtobufDefaults();
43
17.1k
#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
44
17.1k
  {
45
17.1k
    void* ptr = &::yb::_HostPortPB_default_instance_;
46
17.1k
    new (ptr) ::yb::HostPortPB();
47
17.1k
    ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
48
17.1k
  }
49
17.1k
  ::yb::HostPortPB::InitAsDefaultInstance();
50
17.1k
}
51
52
215M
void InitDefaultsHostPortPB() {
53
215M
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
54
215M
  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsHostPortPBImpl);
55
215M
}
56
57
17.1k
void InitDefaultsCloudInfoPBImpl() {
58
17.1k
  GOOGLE_PROTOBUF_VERIFY_VERSION;
59
60
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
61
  ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
62
#else
63
17.1k
  ::google::protobuf::internal::InitProtobufDefaults();
64
17.1k
#endif  // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
65
17.1k
  {
66
17.1k
    void* ptr = &::yb::_CloudInfoPB_default_instance_;
67
17.1k
    new (ptr) ::yb::CloudInfoPB();
68
17.1k
    ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
69
17.1k
  }
70
17.1k
  ::yb::CloudInfoPB::InitAsDefaultInstance();
71
17.1k
}
72
73
196M
void InitDefaultsCloudInfoPB() {
74
196M
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
75
196M
  ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsCloudInfoPBImpl);
76
196M
}
77
78
::google::protobuf::Metadata file_level_metadata[2];
79
80
const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
81
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::HostPortPB, _has_bits_),
82
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::HostPortPB, _internal_metadata_),
83
  ~0u,  // no _extensions_
84
  ~0u,  // no _oneof_case_
85
  ~0u,  // no _weak_field_map_
86
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::HostPortPB, host_),
87
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::HostPortPB, port_),
88
  0,
89
  1,
90
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::CloudInfoPB, _has_bits_),
91
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::CloudInfoPB, _internal_metadata_),
92
  ~0u,  // no _extensions_
93
  ~0u,  // no _oneof_case_
94
  ~0u,  // no _weak_field_map_
95
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::CloudInfoPB, placement_cloud_),
96
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::CloudInfoPB, placement_region_),
97
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::yb::CloudInfoPB, placement_zone_),
98
  0,
99
  1,
100
  2,
101
};
102
static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
103
  { 0, 7, sizeof(::yb::HostPortPB)},
104
  { 9, 17, sizeof(::yb::CloudInfoPB)},
105
};
106
107
static ::google::protobuf::Message const * const file_default_instances[] = {
108
  reinterpret_cast<const ::google::protobuf::Message*>(&::yb::_HostPortPB_default_instance_),
109
  reinterpret_cast<const ::google::protobuf::Message*>(&::yb::_CloudInfoPB_default_instance_),
110
};
111
112
9.57k
void protobuf_AssignDescriptors() {
113
9.57k
  AddDescriptors();
114
9.57k
  ::google::protobuf::MessageFactory* factory = NULL;
115
9.57k
  AssignDescriptors(
116
9.57k
      "yb/common/common_net.proto", schemas, file_default_instances, TableStruct::offsets, factory,
117
9.57k
      file_level_metadata, NULL, NULL);
118
9.57k
}
119
120
156M
void protobuf_AssignDescriptorsOnce() {
121
156M
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
122
156M
  ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
123
156M
}
124
125
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
126
0
void protobuf_RegisterTypes(const ::std::string&) {
127
0
  protobuf_AssignDescriptorsOnce();
128
0
  ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 2);
129
0
}
130
131
17.1k
void AddDescriptorsImpl() {
132
17.1k
  InitDefaults();
133
17.1k
  static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
134
17.1k
      "\n\032yb/common/common_net.proto\022\002yb\"(\n\nHost"
135
17.1k
      "PortPB\022\014\n\004host\030\001 \002(\t\022\014\n\004port\030\002 \002(\r\"X\n\013Cl"
136
17.1k
      "oudInfoPB\022\027\n\017placement_cloud\030\001 \001(\t\022\030\n\020pl"
137
17.1k
      "acement_region\030\002 \001(\t\022\026\n\016placement_zone\030\003"
138
17.1k
      " \001(\tB\010\n\006org.yb"
139
17.1k
  };
140
17.1k
  ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
141
17.1k
      descriptor, 174);
142
17.1k
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
143
17.1k
    "yb/common/common_net.proto", &protobuf_RegisterTypes);
144
17.1k
}
145
146
200k
void AddDescriptors() {
147
200k
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
148
200k
  ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
149
200k
}
150
// Force AddDescriptors() to be called at dynamic initialization time.
151
struct StaticDescriptorInitializer {
152
17.1k
  StaticDescriptorInitializer() {
153
17.1k
    AddDescriptors();
154
17.1k
  }
155
} static_descriptor_initializer;
156
}  // namespace protobuf_yb_2fcommon_2fcommon_5fnet_2eproto
157
namespace yb {
158
159
// ===================================================================
160
161
17.1k
void HostPortPB::InitAsDefaultInstance() {
162
17.1k
}
163
#if !defined(_MSC_VER) || _MSC_VER >= 1900
164
const int HostPortPB::kHostFieldNumber;
165
const int HostPortPB::kPortFieldNumber;
166
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
167
168
HostPortPB::HostPortPB()
169
215M
  : ::google::protobuf::Message(), _internal_metadata_(NULL) {
170
215M
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
171
215M
    ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::InitDefaultsHostPortPB();
172
215M
  }
173
215M
  SharedCtor();
174
  // @@protoc_insertion_point(constructor:yb.HostPortPB)
175
215M
}
176
HostPortPB::HostPortPB(const HostPortPB& from)
177
  : ::google::protobuf::Message(),
178
      _internal_metadata_(NULL),
179
      _has_bits_(from._has_bits_),
180
32
      _cached_size_(0) {
181
32
  _internal_metadata_.MergeFrom(from._internal_metadata_);
182
32
  host_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
183
32
  if (from.has_host()) {
184
32
    host_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.host_);
185
32
  }
186
32
  port_ = from.port_;
187
  // @@protoc_insertion_point(copy_constructor:yb.HostPortPB)
188
32
}
189
190
215M
void HostPortPB::SharedCtor() {
191
215M
  _cached_size_ = 0;
192
215M
  host_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
193
215M
  port_ = 0u;
194
215M
}
195
196
214M
HostPortPB::~HostPortPB() {
197
  // @@protoc_insertion_point(destructor:yb.HostPortPB)
198
214M
  SharedDtor();
199
214M
}
200
201
214M
void HostPortPB::SharedDtor() {
202
214M
  host_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
203
214M
}
204
205
0
void HostPortPB::SetCachedSize(int size) const {
206
0
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
207
0
  _cached_size_ = size;
208
0
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
209
0
}
210
0
const ::google::protobuf::Descriptor* HostPortPB::descriptor() {
211
0
  ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::protobuf_AssignDescriptorsOnce();
212
0
  return ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
213
0
}
214
215
0
const HostPortPB& HostPortPB::default_instance() {
216
0
  ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::InitDefaultsHostPortPB();
217
0
  return *internal_default_instance();
218
0
}
219
220
0
HostPortPB* HostPortPB::New(::google::protobuf::Arena* arena) const {
221
0
  HostPortPB* n = new HostPortPB;
222
0
  if (arena != NULL) {
223
0
    arena->Own(n);
224
0
  }
225
0
  return n;
226
0
}
227
228
8.21M
void HostPortPB::Clear() {
229
// @@protoc_insertion_point(message_clear_start:yb.HostPortPB)
230
8.21M
  ::google::protobuf::uint32 cached_has_bits = 0;
231
  // Prevent compiler warnings about cached_has_bits being unused
232
8.21M
  (void) cached_has_bits;
233
234
8.21M
  cached_has_bits = _has_bits_[0];
235
8.21M
  if (cached_has_bits & 0x00000001u) {
236
8.19M
    GOOGLE_DCHECK(!host_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
237
8.19M
    (*host_.UnsafeRawStringPointer())->clear();
238
8.19M
  }
239
8.21M
  port_ = 0u;
240
8.21M
  _has_bits_.Clear();
241
8.21M
  _internal_metadata_.Clear();
242
8.21M
}
243
244
bool HostPortPB::MergePartialFromCodedStream(
245
12.8M
    ::google::protobuf::io::CodedInputStream* input) {
246
25.6M
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
247
12.8M
  ::google::protobuf::uint32 tag;
248
  // @@protoc_insertion_point(parse_start:yb.HostPortPB)
249
38.5M
  for (;;) {
250
38.5M
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
251
38.5M
    tag = p.first;
252
38.5M
    if (!p.second) goto handle_unusual;
253
25.6M
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
254
      // required string host = 1;
255
12.8M
      case 1: {
256
12.8M
        if (static_cast< ::google::protobuf::uint8>(tag) ==
257
12.8M
            static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
258
12.8M
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
259
12.8M
                input, this->mutable_host()));
260
12.8M
          ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
261
12.8M
            this->host().data(), static_cast<int>(this->host().length()),
262
12.8M
            ::google::protobuf::internal::WireFormat::PARSE,
263
12.8M
            "yb.HostPortPB.host");
264
18.4E
        } else {
265
18.4E
          goto handle_unusual;
266
18.4E
        }
267
12.8M
        break;
268
12.8M
      }
269
270
      // required uint32 port = 2;
271
12.8M
      case 2: {
272
12.8M
        if (static_cast< ::google::protobuf::uint8>(tag) ==
273
12.8M
            static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
274
12.8M
          set_has_port();
275
12.8M
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
276
12.8M
                   ::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
277
12.8M
                 input, &port_)));
278
18.4E
        } else {
279
18.4E
          goto handle_unusual;
280
18.4E
        }
281
12.8M
        break;
282
12.8M
      }
283
284
0
      default: {
285
12.8M
      handle_unusual:
286
12.8M
        if (tag == 0) {
287
12.8M
          goto success;
288
12.8M
        }
289
18.4E
        DO_(::google::protobuf::internal::WireFormat::SkipField(
290
18.4E
              input, tag, _internal_metadata_.mutable_unknown_fields()));
291
18.4E
        break;
292
18.4E
      }
293
25.6M
    }
294
25.6M
  }
295
12.8M
success:
296
  // @@protoc_insertion_point(parse_success:yb.HostPortPB)
297
12.8M
  return true;
298
0
failure:
299
  // @@protoc_insertion_point(parse_failure:yb.HostPortPB)
300
0
  return false;
301
12.8M
#undef DO_
302
12.8M
}
303
304
void HostPortPB::SerializeWithCachedSizes(
305
0
    ::google::protobuf::io::CodedOutputStream* output) const {
306
  // @@protoc_insertion_point(serialize_start:yb.HostPortPB)
307
0
  ::google::protobuf::uint32 cached_has_bits = 0;
308
0
  (void) cached_has_bits;
309
310
0
  cached_has_bits = _has_bits_[0];
311
  // required string host = 1;
312
0
  if (cached_has_bits & 0x00000001u) {
313
0
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
314
0
      this->host().data(), static_cast<int>(this->host().length()),
315
0
      ::google::protobuf::internal::WireFormat::SERIALIZE,
316
0
      "yb.HostPortPB.host");
317
0
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
318
0
      1, this->host(), output);
319
0
  }
320
321
  // required uint32 port = 2;
322
0
  if (cached_has_bits & 0x00000002u) {
323
0
    ::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->port(), output);
324
0
  }
325
326
0
  if (_internal_metadata_.have_unknown_fields()) {
327
0
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
328
0
        _internal_metadata_.unknown_fields(), output);
329
0
  }
330
  // @@protoc_insertion_point(serialize_end:yb.HostPortPB)
331
0
}
332
333
::google::protobuf::uint8* HostPortPB::InternalSerializeWithCachedSizesToArray(
334
13.5M
    bool deterministic, ::google::protobuf::uint8* target) const {
335
13.5M
  (void)deterministic; // Unused
336
  // @@protoc_insertion_point(serialize_to_array_start:yb.HostPortPB)
337
13.5M
  ::google::protobuf::uint32 cached_has_bits = 0;
338
13.5M
  (void) cached_has_bits;
339
340
13.5M
  cached_has_bits = _has_bits_[0];
341
  // required string host = 1;
342
13.5M
  if (cached_has_bits & 0x00000001u) {
343
13.5M
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
344
13.5M
      this->host().data(), static_cast<int>(this->host().length()),
345
13.5M
      ::google::protobuf::internal::WireFormat::SERIALIZE,
346
13.5M
      "yb.HostPortPB.host");
347
13.5M
    target =
348
13.5M
      ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
349
13.5M
        1, this->host(), target);
350
13.5M
  }
351
352
  // required uint32 port = 2;
353
13.5M
  if (cached_has_bits & 0x00000002u) {
354
13.5M
    target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->port(), target);
355
13.5M
  }
356
357
13.5M
  if (_internal_metadata_.have_unknown_fields()) {
358
0
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
359
0
        _internal_metadata_.unknown_fields(), target);
360
0
  }
361
  // @@protoc_insertion_point(serialize_to_array_end:yb.HostPortPB)
362
13.5M
  return target;
363
13.5M
}
364
365
0
size_t HostPortPB::RequiredFieldsByteSizeFallback() const {
366
// @@protoc_insertion_point(required_fields_byte_size_fallback_start:yb.HostPortPB)
367
0
  size_t total_size = 0;
368
369
0
  if (has_host()) {
370
    // required string host = 1;
371
0
    total_size += 1 +
372
0
      ::google::protobuf::internal::WireFormatLite::StringSize(
373
0
        this->host());
374
0
  }
375
376
0
  if (has_port()) {
377
    // required uint32 port = 2;
378
0
    total_size += 1 +
379
0
      ::google::protobuf::internal::WireFormatLite::UInt32Size(
380
0
        this->port());
381
0
  }
382
383
0
  return total_size;
384
0
}
385
25.9M
size_t HostPortPB::ByteSizeLong() const {
386
// @@protoc_insertion_point(message_byte_size_start:yb.HostPortPB)
387
25.9M
  size_t total_size = 0;
388
389
25.9M
  if (_internal_metadata_.have_unknown_fields()) {
390
0
    total_size +=
391
0
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
392
0
        _internal_metadata_.unknown_fields());
393
0
  }
394
25.9M
  if (((_has_bits_[0] & 0x00000003) ^ 0x00000003) == 0) {  // All required fields are present.
395
    // required string host = 1;
396
25.9M
    total_size += 1 +
397
25.9M
      ::google::protobuf::internal::WireFormatLite::StringSize(
398
25.9M
        this->host());
399
400
    // required uint32 port = 2;
401
25.9M
    total_size += 1 +
402
25.9M
      ::google::protobuf::internal::WireFormatLite::UInt32Size(
403
25.9M
        this->port());
404
405
21.9k
  } else {
406
21.9k
    total_size += RequiredFieldsByteSizeFallback();
407
21.9k
  }
408
25.9M
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
409
25.9M
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
410
25.9M
  _cached_size_ = cached_size;
411
25.9M
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
412
25.9M
  return total_size;
413
25.9M
}
414
415
0
void HostPortPB::MergeFrom(const ::google::protobuf::Message& from) {
416
// @@protoc_insertion_point(generalized_merge_from_start:yb.HostPortPB)
417
0
  GOOGLE_DCHECK_NE(&from, this);
418
0
  const HostPortPB* source =
419
0
      ::google::protobuf::internal::DynamicCastToGenerated<const HostPortPB>(
420
0
          &from);
421
0
  if (source == NULL) {
422
  // @@protoc_insertion_point(generalized_merge_from_cast_fail:yb.HostPortPB)
423
0
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
424
0
  } else {
425
  // @@protoc_insertion_point(generalized_merge_from_cast_success:yb.HostPortPB)
426
0
    MergeFrom(*source);
427
0
  }
428
0
}
429
430
205M
void HostPortPB::MergeFrom(const HostPortPB& from) {
431
// @@protoc_insertion_point(class_specific_merge_from_start:yb.HostPortPB)
432
205M
  GOOGLE_DCHECK_NE(&from, this);
433
205M
  _internal_metadata_.MergeFrom(from._internal_metadata_);
434
205M
  ::google::protobuf::uint32 cached_has_bits = 0;
435
205M
  (void) cached_has_bits;
436
437
205M
  cached_has_bits = from._has_bits_[0];
438
205M
  if (cached_has_bits & 3u) {
439
205M
    if (cached_has_bits & 0x00000001u) {
440
205M
      set_has_host();
441
205M
      host_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.host_);
442
205M
    }
443
205M
    if (cached_has_bits & 0x00000002u) {
444
205M
      port_ = from.port_;
445
205M
    }
446
205M
    _has_bits_[0] |= cached_has_bits;
447
205M
  }
448
205M
}
449
450
0
void HostPortPB::CopyFrom(const ::google::protobuf::Message& from) {
451
// @@protoc_insertion_point(generalized_copy_from_start:yb.HostPortPB)
452
0
  if (&from == this) return;
453
0
  Clear();
454
0
  MergeFrom(from);
455
0
}
456
457
0
void HostPortPB::CopyFrom(const HostPortPB& from) {
458
// @@protoc_insertion_point(class_specific_copy_from_start:yb.HostPortPB)
459
0
  if (&from == this) return;
460
0
  Clear();
461
0
  MergeFrom(from);
462
0
}
463
464
26.6M
bool HostPortPB::IsInitialized() const {
465
26.6M
  if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
466
26.6M
  return true;
467
26.6M
}
468
469
0
void HostPortPB::Swap(HostPortPB* other) {
470
0
  if (other == this) return;
471
0
  InternalSwap(other);
472
0
}
473
32
void HostPortPB::InternalSwap(HostPortPB* other) {
474
32
  using std::swap;
475
32
  host_.Swap(&other->host_);
476
32
  swap(port_, other->port_);
477
32
  swap(_has_bits_[0], other->_has_bits_[0]);
478
32
  _internal_metadata_.Swap(&other->_internal_metadata_);
479
32
  swap(_cached_size_, other->_cached_size_);
480
32
}
481
482
78.3M
::google::protobuf::Metadata HostPortPB::GetMetadata() const {
483
78.3M
  protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::protobuf_AssignDescriptorsOnce();
484
78.3M
  return ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::file_level_metadata[kIndexInFileMessages];
485
78.3M
}
486
487
488
// ===================================================================
489
490
17.1k
void CloudInfoPB::InitAsDefaultInstance() {
491
17.1k
}
492
#if !defined(_MSC_VER) || _MSC_VER >= 1900
493
const int CloudInfoPB::kPlacementCloudFieldNumber;
494
const int CloudInfoPB::kPlacementRegionFieldNumber;
495
const int CloudInfoPB::kPlacementZoneFieldNumber;
496
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
497
498
CloudInfoPB::CloudInfoPB()
499
196M
  : ::google::protobuf::Message(), _internal_metadata_(NULL) {
500
196M
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
501
196M
    ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::InitDefaultsCloudInfoPB();
502
196M
  }
503
196M
  SharedCtor();
504
  // @@protoc_insertion_point(constructor:yb.CloudInfoPB)
505
196M
}
506
CloudInfoPB::CloudInfoPB(const CloudInfoPB& from)
507
  : ::google::protobuf::Message(),
508
      _internal_metadata_(NULL),
509
      _has_bits_(from._has_bits_),
510
2.02M
      _cached_size_(0) {
511
2.02M
  _internal_metadata_.MergeFrom(from._internal_metadata_);
512
2.02M
  placement_cloud_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
513
2.02M
  if (from.has_placement_cloud()) {
514
2.01M
    placement_cloud_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_cloud_);
515
2.01M
  }
516
2.02M
  placement_region_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
517
2.02M
  if (from.has_placement_region()) {
518
2.02M
    placement_region_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_region_);
519
2.02M
  }
520
2.02M
  placement_zone_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
521
2.02M
  if (from.has_placement_zone()) {
522
2.01M
    placement_zone_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_zone_);
523
2.01M
  }
524
  // @@protoc_insertion_point(copy_constructor:yb.CloudInfoPB)
525
2.02M
}
526
527
196M
void CloudInfoPB::SharedCtor() {
528
196M
  _cached_size_ = 0;
529
196M
  placement_cloud_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
530
196M
  placement_region_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
531
196M
  placement_zone_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
532
196M
}
533
534
197M
CloudInfoPB::~CloudInfoPB() {
535
  // @@protoc_insertion_point(destructor:yb.CloudInfoPB)
536
197M
  SharedDtor();
537
197M
}
538
539
197M
void CloudInfoPB::SharedDtor() {
540
197M
  placement_cloud_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
541
197M
  placement_region_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
542
197M
  placement_zone_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
543
197M
}
544
545
0
void CloudInfoPB::SetCachedSize(int size) const {
546
0
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
547
0
  _cached_size_ = size;
548
0
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
549
0
}
550
0
const ::google::protobuf::Descriptor* CloudInfoPB::descriptor() {
551
0
  ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::protobuf_AssignDescriptorsOnce();
552
0
  return ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
553
0
}
554
555
0
const CloudInfoPB& CloudInfoPB::default_instance() {
556
0
  ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::InitDefaultsCloudInfoPB();
557
0
  return *internal_default_instance();
558
0
}
559
560
0
CloudInfoPB* CloudInfoPB::New(::google::protobuf::Arena* arena) const {
561
0
  CloudInfoPB* n = new CloudInfoPB;
562
0
  if (arena != NULL) {
563
0
    arena->Own(n);
564
0
  }
565
0
  return n;
566
0
}
567
568
5.38M
void CloudInfoPB::Clear() {
569
// @@protoc_insertion_point(message_clear_start:yb.CloudInfoPB)
570
5.38M
  ::google::protobuf::uint32 cached_has_bits = 0;
571
  // Prevent compiler warnings about cached_has_bits being unused
572
5.38M
  (void) cached_has_bits;
573
574
5.38M
  cached_has_bits = _has_bits_[0];
575
5.38M
  if (cached_has_bits & 7u) {
576
4.31M
    if (cached_has_bits & 0x00000001u) {
577
4.31M
      GOOGLE_DCHECK(!placement_cloud_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
578
4.31M
      (*placement_cloud_.UnsafeRawStringPointer())->clear();
579
4.31M
    }
580
4.31M
    if (cached_has_bits & 0x00000002u) {
581
4.30M
      GOOGLE_DCHECK(!placement_region_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
582
4.30M
      (*placement_region_.UnsafeRawStringPointer())->clear();
583
4.30M
    }
584
4.31M
    if (cached_has_bits & 0x00000004u) {
585
4.30M
      GOOGLE_DCHECK(!placement_zone_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
586
4.30M
      (*placement_zone_.UnsafeRawStringPointer())->clear();
587
4.30M
    }
588
4.31M
  }
589
5.38M
  _has_bits_.Clear();
590
5.38M
  _internal_metadata_.Clear();
591
5.38M
}
592
593
bool CloudInfoPB::MergePartialFromCodedStream(
594
7.58M
    ::google::protobuf::io::CodedInputStream* input) {
595
22.7M
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
596
7.58M
  ::google::protobuf::uint32 tag;
597
  // @@protoc_insertion_point(parse_start:yb.CloudInfoPB)
598
30.3M
  for (;;) {
599
30.3M
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
600
30.3M
    tag = p.first;
601
30.3M
    if (!p.second) goto handle_unusual;
602
22.7M
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
603
      // optional string placement_cloud = 1;
604
7.57M
      case 1: {
605
7.57M
        if (static_cast< ::google::protobuf::uint8>(tag) ==
606
7.57M
            static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
607
7.57M
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
608
7.57M
                input, this->mutable_placement_cloud()));
609
7.57M
          ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
610
7.57M
            this->placement_cloud().data(), static_cast<int>(this->placement_cloud().length()),
611
7.57M
            ::google::protobuf::internal::WireFormat::PARSE,
612
7.57M
            "yb.CloudInfoPB.placement_cloud");
613
18.4E
        } else {
614
18.4E
          goto handle_unusual;
615
18.4E
        }
616
7.57M
        break;
617
7.57M
      }
618
619
      // optional string placement_region = 2;
620
7.57M
      case 2: {
621
7.57M
        if (static_cast< ::google::protobuf::uint8>(tag) ==
622
7.57M
            static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
623
7.57M
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
624
7.57M
                input, this->mutable_placement_region()));
625
7.57M
          ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
626
7.57M
            this->placement_region().data(), static_cast<int>(this->placement_region().length()),
627
7.57M
            ::google::protobuf::internal::WireFormat::PARSE,
628
7.57M
            "yb.CloudInfoPB.placement_region");
629
18.4E
        } else {
630
18.4E
          goto handle_unusual;
631
18.4E
        }
632
7.57M
        break;
633
7.57M
      }
634
635
      // optional string placement_zone = 3;
636
7.58M
      case 3: {
637
7.58M
        if (static_cast< ::google::protobuf::uint8>(tag) ==
638
7.58M
            static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
639
7.58M
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
640
7.58M
                input, this->mutable_placement_zone()));
641
7.58M
          ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
642
7.58M
            this->placement_zone().data(), static_cast<int>(this->placement_zone().length()),
643
7.58M
            ::google::protobuf::internal::WireFormat::PARSE,
644
7.58M
            "yb.CloudInfoPB.placement_zone");
645
18.4E
        } else {
646
18.4E
          goto handle_unusual;
647
18.4E
        }
648
7.58M
        break;
649
7.58M
      }
650
651
0
      default: {
652
7.58M
      handle_unusual:
653
7.58M
        if (tag == 0) {
654
7.58M
          goto success;
655
7.58M
        }
656
18.4E
        DO_(::google::protobuf::internal::WireFormat::SkipField(
657
18.4E
              input, tag, _internal_metadata_.mutable_unknown_fields()));
658
18.4E
        break;
659
18.4E
      }
660
22.7M
    }
661
22.7M
  }
662
7.58M
success:
663
  // @@protoc_insertion_point(parse_success:yb.CloudInfoPB)
664
7.58M
  return true;
665
0
failure:
666
  // @@protoc_insertion_point(parse_failure:yb.CloudInfoPB)
667
0
  return false;
668
7.58M
#undef DO_
669
7.58M
}
670
671
void CloudInfoPB::SerializeWithCachedSizes(
672
0
    ::google::protobuf::io::CodedOutputStream* output) const {
673
  // @@protoc_insertion_point(serialize_start:yb.CloudInfoPB)
674
0
  ::google::protobuf::uint32 cached_has_bits = 0;
675
0
  (void) cached_has_bits;
676
677
0
  cached_has_bits = _has_bits_[0];
678
  // optional string placement_cloud = 1;
679
0
  if (cached_has_bits & 0x00000001u) {
680
0
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
681
0
      this->placement_cloud().data(), static_cast<int>(this->placement_cloud().length()),
682
0
      ::google::protobuf::internal::WireFormat::SERIALIZE,
683
0
      "yb.CloudInfoPB.placement_cloud");
684
0
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
685
0
      1, this->placement_cloud(), output);
686
0
  }
687
688
  // optional string placement_region = 2;
689
0
  if (cached_has_bits & 0x00000002u) {
690
0
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
691
0
      this->placement_region().data(), static_cast<int>(this->placement_region().length()),
692
0
      ::google::protobuf::internal::WireFormat::SERIALIZE,
693
0
      "yb.CloudInfoPB.placement_region");
694
0
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
695
0
      2, this->placement_region(), output);
696
0
  }
697
698
  // optional string placement_zone = 3;
699
0
  if (cached_has_bits & 0x00000004u) {
700
0
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
701
0
      this->placement_zone().data(), static_cast<int>(this->placement_zone().length()),
702
0
      ::google::protobuf::internal::WireFormat::SERIALIZE,
703
0
      "yb.CloudInfoPB.placement_zone");
704
0
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
705
0
      3, this->placement_zone(), output);
706
0
  }
707
708
0
  if (_internal_metadata_.have_unknown_fields()) {
709
0
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
710
0
        _internal_metadata_.unknown_fields(), output);
711
0
  }
712
  // @@protoc_insertion_point(serialize_end:yb.CloudInfoPB)
713
0
}
714
715
::google::protobuf::uint8* CloudInfoPB::InternalSerializeWithCachedSizesToArray(
716
8.35M
    bool deterministic, ::google::protobuf::uint8* target) const {
717
8.35M
  (void)deterministic; // Unused
718
  // @@protoc_insertion_point(serialize_to_array_start:yb.CloudInfoPB)
719
8.35M
  ::google::protobuf::uint32 cached_has_bits = 0;
720
8.35M
  (void) cached_has_bits;
721
722
8.35M
  cached_has_bits = _has_bits_[0];
723
  // optional string placement_cloud = 1;
724
8.35M
  if (cached_has_bits & 0x00000001u) {
725
8.34M
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
726
8.34M
      this->placement_cloud().data(), static_cast<int>(this->placement_cloud().length()),
727
8.34M
      ::google::protobuf::internal::WireFormat::SERIALIZE,
728
8.34M
      "yb.CloudInfoPB.placement_cloud");
729
8.34M
    target =
730
8.34M
      ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
731
8.34M
        1, this->placement_cloud(), target);
732
8.34M
  }
733
734
  // optional string placement_region = 2;
735
8.35M
  if (cached_has_bits & 0x00000002u) {
736
8.35M
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
737
8.35M
      this->placement_region().data(), static_cast<int>(this->placement_region().length()),
738
8.35M
      ::google::protobuf::internal::WireFormat::SERIALIZE,
739
8.35M
      "yb.CloudInfoPB.placement_region");
740
8.35M
    target =
741
8.35M
      ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
742
8.35M
        2, this->placement_region(), target);
743
8.35M
  }
744
745
  // optional string placement_zone = 3;
746
8.35M
  if (cached_has_bits & 0x00000004u) {
747
8.35M
    ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
748
8.35M
      this->placement_zone().data(), static_cast<int>(this->placement_zone().length()),
749
8.35M
      ::google::protobuf::internal::WireFormat::SERIALIZE,
750
8.35M
      "yb.CloudInfoPB.placement_zone");
751
8.35M
    target =
752
8.35M
      ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
753
8.35M
        3, this->placement_zone(), target);
754
8.35M
  }
755
756
8.35M
  if (_internal_metadata_.have_unknown_fields()) {
757
0
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
758
0
        _internal_metadata_.unknown_fields(), target);
759
0
  }
760
  // @@protoc_insertion_point(serialize_to_array_end:yb.CloudInfoPB)
761
8.35M
  return target;
762
8.35M
}
763
764
15.4M
size_t CloudInfoPB::ByteSizeLong() const {
765
// @@protoc_insertion_point(message_byte_size_start:yb.CloudInfoPB)
766
15.4M
  size_t total_size = 0;
767
768
15.4M
  if (_internal_metadata_.have_unknown_fields()) {
769
0
    total_size +=
770
0
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
771
0
        _internal_metadata_.unknown_fields());
772
0
  }
773
15.4M
  if (_has_bits_[0 / 32] & 7u) {
774
    // optional string placement_cloud = 1;
775
15.4M
    if (has_placement_cloud()) {
776
15.4M
      total_size += 1 +
777
15.4M
        ::google::protobuf::internal::WireFormatLite::StringSize(
778
15.4M
          this->placement_cloud());
779
15.4M
    }
780
781
    // optional string placement_region = 2;
782
15.4M
    if (has_placement_region()) {
783
15.4M
      total_size += 1 +
784
15.4M
        ::google::protobuf::internal::WireFormatLite::StringSize(
785
15.4M
          this->placement_region());
786
15.4M
    }
787
788
    // optional string placement_zone = 3;
789
15.4M
    if (has_placement_zone()) {
790
15.4M
      total_size += 1 +
791
15.4M
        ::google::protobuf::internal::WireFormatLite::StringSize(
792
15.4M
          this->placement_zone());
793
15.4M
    }
794
795
15.4M
  }
796
15.4M
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
797
15.4M
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
798
15.4M
  _cached_size_ = cached_size;
799
15.4M
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
800
15.4M
  return total_size;
801
15.4M
}
802
803
0
void CloudInfoPB::MergeFrom(const ::google::protobuf::Message& from) {
804
// @@protoc_insertion_point(generalized_merge_from_start:yb.CloudInfoPB)
805
0
  GOOGLE_DCHECK_NE(&from, this);
806
0
  const CloudInfoPB* source =
807
0
      ::google::protobuf::internal::DynamicCastToGenerated<const CloudInfoPB>(
808
0
          &from);
809
0
  if (source == NULL) {
810
  // @@protoc_insertion_point(generalized_merge_from_cast_fail:yb.CloudInfoPB)
811
0
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
812
0
  } else {
813
  // @@protoc_insertion_point(generalized_merge_from_cast_success:yb.CloudInfoPB)
814
0
    MergeFrom(*source);
815
0
  }
816
0
}
817
818
192M
void CloudInfoPB::MergeFrom(const CloudInfoPB& from) {
819
// @@protoc_insertion_point(class_specific_merge_from_start:yb.CloudInfoPB)
820
192M
  GOOGLE_DCHECK_NE(&from, this);
821
192M
  _internal_metadata_.MergeFrom(from._internal_metadata_);
822
192M
  ::google::protobuf::uint32 cached_has_bits = 0;
823
192M
  (void) cached_has_bits;
824
825
192M
  cached_has_bits = from._has_bits_[0];
826
192M
  if (cached_has_bits & 7u) {
827
192M
    if (cached_has_bits & 0x00000001u) {
828
192M
      set_has_placement_cloud();
829
192M
      placement_cloud_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_cloud_);
830
192M
    }
831
192M
    if (cached_has_bits & 0x00000002u) {
832
192M
      set_has_placement_region();
833
192M
      placement_region_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_region_);
834
192M
    }
835
192M
    if (cached_has_bits & 0x00000004u) {
836
192M
      set_has_placement_zone();
837
192M
      placement_zone_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.placement_zone_);
838
192M
    }
839
191M
  }
840
192M
}
841
842
0
void CloudInfoPB::CopyFrom(const ::google::protobuf::Message& from) {
843
// @@protoc_insertion_point(generalized_copy_from_start:yb.CloudInfoPB)
844
0
  if (&from == this) return;
845
0
  Clear();
846
0
  MergeFrom(from);
847
0
}
848
849
1.27M
void CloudInfoPB::CopyFrom(const CloudInfoPB& from) {
850
// @@protoc_insertion_point(class_specific_copy_from_start:yb.CloudInfoPB)
851
1.27M
  if (&from == this) return;
852
1.27M
  Clear();
853
1.27M
  MergeFrom(from);
854
1.27M
}
855
856
0
bool CloudInfoPB::IsInitialized() const {
857
0
  return true;
858
0
}
859
860
109k
void CloudInfoPB::Swap(CloudInfoPB* other) {
861
109k
  if (other == this) return;
862
109k
  InternalSwap(other);
863
109k
}
864
249k
void CloudInfoPB::InternalSwap(CloudInfoPB* other) {
865
249k
  using std::swap;
866
249k
  placement_cloud_.Swap(&other->placement_cloud_);
867
249k
  placement_region_.Swap(&other->placement_region_);
868
249k
  placement_zone_.Swap(&other->placement_zone_);
869
249k
  swap(_has_bits_[0], other->_has_bits_[0]);
870
249k
  _internal_metadata_.Swap(&other->_internal_metadata_);
871
249k
  swap(_cached_size_, other->_cached_size_);
872
249k
}
873
874
78.6M
::google::protobuf::Metadata CloudInfoPB::GetMetadata() const {
875
78.6M
  protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::protobuf_AssignDescriptorsOnce();
876
78.6M
  return ::protobuf_yb_2fcommon_2fcommon_5fnet_2eproto::file_level_metadata[kIndexInFileMessages];
877
78.6M
}
878
879
880
// @@protoc_insertion_point(namespace_scope)
881
}  // namespace yb
882
883
// @@protoc_insertion_point(global_scope)