This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
zhuyujia-webhopper/collector/adg-linux/gen/components/sync/protocol/test.pb.cc
little_stone bd2d50cf35 code update
2022-05-05 20:41:28 +08:00

600 lines
18 KiB
C++
Executable File

// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: test.proto
#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "test.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/io/zero_copy_stream_impl_lite.h>
// @@protoc_insertion_point(includes)
namespace sync_pb {
class UnknownFieldsTestADefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<UnknownFieldsTestA> {
} _UnknownFieldsTestA_default_instance_;
class UnknownFieldsTestBDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<UnknownFieldsTestB> {
} _UnknownFieldsTestB_default_instance_;
namespace protobuf_test_2eproto {
PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTableField
const TableStruct::entries[] = {
{0, 0, 0, ::google::protobuf::internal::kInvalidMask, 0, 0},
};
PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::AuxillaryParseTableField
const TableStruct::aux[] = {
::google::protobuf::internal::AuxillaryParseTableField(),
};
PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTable const
TableStruct::schema[] = {
{ NULL, NULL, 0, -1, -1, false },
{ NULL, NULL, 0, -1, -1, false },
};
void TableStruct::Shutdown() {
_UnknownFieldsTestA_default_instance_.Shutdown();
_UnknownFieldsTestB_default_instance_.Shutdown();
}
void TableStruct::InitDefaultsImpl() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
::google::protobuf::internal::InitProtobufDefaults();
_UnknownFieldsTestA_default_instance_.DefaultConstruct();
_UnknownFieldsTestB_default_instance_.DefaultConstruct();
}
void InitDefaults() {
static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
::google::protobuf::GoogleOnceInit(&once, &TableStruct::InitDefaultsImpl);
}
void AddDescriptorsImpl() {
InitDefaults();
::google::protobuf::internal::OnShutdown(&TableStruct::Shutdown);
}
void AddDescriptors() {
static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
}
} // namespace protobuf_test_2eproto
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int UnknownFieldsTestA::kFooFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
UnknownFieldsTestA::UnknownFieldsTestA()
: ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
protobuf_test_2eproto::InitDefaults();
}
SharedCtor();
// @@protoc_insertion_point(constructor:sync_pb.UnknownFieldsTestA)
}
UnknownFieldsTestA::UnknownFieldsTestA(const UnknownFieldsTestA& from)
: ::google::protobuf::MessageLite(),
_internal_metadata_(NULL),
_has_bits_(from._has_bits_),
_cached_size_(0) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
foo_ = from.foo_;
// @@protoc_insertion_point(copy_constructor:sync_pb.UnknownFieldsTestA)
}
void UnknownFieldsTestA::SharedCtor() {
_cached_size_ = 0;
foo_ = false;
}
UnknownFieldsTestA::~UnknownFieldsTestA() {
// @@protoc_insertion_point(destructor:sync_pb.UnknownFieldsTestA)
SharedDtor();
}
void UnknownFieldsTestA::SharedDtor() {
}
void UnknownFieldsTestA::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const UnknownFieldsTestA& UnknownFieldsTestA::default_instance() {
protobuf_test_2eproto::InitDefaults();
return *internal_default_instance();
}
UnknownFieldsTestA* UnknownFieldsTestA::New(::google::protobuf::Arena* arena) const {
UnknownFieldsTestA* n = new UnknownFieldsTestA;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void UnknownFieldsTestA::Clear() {
// @@protoc_insertion_point(message_clear_start:sync_pb.UnknownFieldsTestA)
foo_ = false;
_has_bits_.Clear();
_internal_metadata_.Clear();
}
bool UnknownFieldsTestA::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
::google::protobuf::NewPermanentCallback(&_internal_metadata_,
&::google::protobuf::internal::InternalMetadataWithArenaLite::
mutable_unknown_fields));
::google::protobuf::io::CodedOutputStream unknown_fields_stream(
&unknown_fields_string, false);
// @@protoc_insertion_point(parse_start:sync_pb.UnknownFieldsTestA)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// required bool foo = 1;
case 1: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(8u)) {
set_has_foo();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &foo_)));
} else {
goto handle_unusual;
}
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormatLite::SkipField(
input, tag, &unknown_fields_stream));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:sync_pb.UnknownFieldsTestA)
return true;
failure:
// @@protoc_insertion_point(parse_failure:sync_pb.UnknownFieldsTestA)
return false;
#undef DO_
}
void UnknownFieldsTestA::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:sync_pb.UnknownFieldsTestA)
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = _has_bits_[0];
// required bool foo = 1;
if (cached_has_bits & 0x00000001u) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->foo(), output);
}
output->WriteRaw(unknown_fields().data(),
static_cast<int>(unknown_fields().size()));
// @@protoc_insertion_point(serialize_end:sync_pb.UnknownFieldsTestA)
}
size_t UnknownFieldsTestA::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:sync_pb.UnknownFieldsTestA)
size_t total_size = 0;
total_size += unknown_fields().size();
// required bool foo = 1;
if (has_foo()) {
total_size += 1 + 1;
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void UnknownFieldsTestA::CheckTypeAndMergeFrom(
const ::google::protobuf::MessageLite& from) {
MergeFrom(*::google::protobuf::down_cast<const UnknownFieldsTestA*>(&from));
}
void UnknownFieldsTestA::MergeFrom(const UnknownFieldsTestA& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:sync_pb.UnknownFieldsTestA)
GOOGLE_DCHECK_NE(&from, this);
_internal_metadata_.MergeFrom(from._internal_metadata_);
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
if (from.has_foo()) {
set_foo(from.foo());
}
}
void UnknownFieldsTestA::CopyFrom(const UnknownFieldsTestA& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:sync_pb.UnknownFieldsTestA)
if (&from == this) return;
Clear();
MergeFrom(from);
}
bool UnknownFieldsTestA::IsInitialized() const {
if ((_has_bits_[0] & 0x00000001) != 0x00000001) return false;
return true;
}
void UnknownFieldsTestA::Swap(UnknownFieldsTestA* other) {
if (other == this) return;
InternalSwap(other);
}
void UnknownFieldsTestA::InternalSwap(UnknownFieldsTestA* other) {
std::swap(foo_, other->foo_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::std::string UnknownFieldsTestA::GetTypeName() const {
return "sync_pb.UnknownFieldsTestA";
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// UnknownFieldsTestA
// required bool foo = 1;
bool UnknownFieldsTestA::has_foo() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void UnknownFieldsTestA::set_has_foo() {
_has_bits_[0] |= 0x00000001u;
}
void UnknownFieldsTestA::clear_has_foo() {
_has_bits_[0] &= ~0x00000001u;
}
void UnknownFieldsTestA::clear_foo() {
foo_ = false;
clear_has_foo();
}
bool UnknownFieldsTestA::foo() const {
// @@protoc_insertion_point(field_get:sync_pb.UnknownFieldsTestA.foo)
return foo_;
}
void UnknownFieldsTestA::set_foo(bool value) {
set_has_foo();
foo_ = value;
// @@protoc_insertion_point(field_set:sync_pb.UnknownFieldsTestA.foo)
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int UnknownFieldsTestB::kFooFieldNumber;
const int UnknownFieldsTestB::kBarFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
UnknownFieldsTestB::UnknownFieldsTestB()
: ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
protobuf_test_2eproto::InitDefaults();
}
SharedCtor();
// @@protoc_insertion_point(constructor:sync_pb.UnknownFieldsTestB)
}
UnknownFieldsTestB::UnknownFieldsTestB(const UnknownFieldsTestB& from)
: ::google::protobuf::MessageLite(),
_internal_metadata_(NULL),
_has_bits_(from._has_bits_),
_cached_size_(0) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
::memcpy(&foo_, &from.foo_,
static_cast<size_t>(reinterpret_cast<char*>(&bar_) -
reinterpret_cast<char*>(&foo_)) + sizeof(bar_));
// @@protoc_insertion_point(copy_constructor:sync_pb.UnknownFieldsTestB)
}
void UnknownFieldsTestB::SharedCtor() {
_cached_size_ = 0;
::memset(&foo_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&bar_) -
reinterpret_cast<char*>(&foo_)) + sizeof(bar_));
}
UnknownFieldsTestB::~UnknownFieldsTestB() {
// @@protoc_insertion_point(destructor:sync_pb.UnknownFieldsTestB)
SharedDtor();
}
void UnknownFieldsTestB::SharedDtor() {
}
void UnknownFieldsTestB::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const UnknownFieldsTestB& UnknownFieldsTestB::default_instance() {
protobuf_test_2eproto::InitDefaults();
return *internal_default_instance();
}
UnknownFieldsTestB* UnknownFieldsTestB::New(::google::protobuf::Arena* arena) const {
UnknownFieldsTestB* n = new UnknownFieldsTestB;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void UnknownFieldsTestB::Clear() {
// @@protoc_insertion_point(message_clear_start:sync_pb.UnknownFieldsTestB)
if (_has_bits_[0 / 32] & 3u) {
::memset(&foo_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&bar_) -
reinterpret_cast<char*>(&foo_)) + sizeof(bar_));
}
_has_bits_.Clear();
_internal_metadata_.Clear();
}
bool UnknownFieldsTestB::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
::google::protobuf::NewPermanentCallback(&_internal_metadata_,
&::google::protobuf::internal::InternalMetadataWithArenaLite::
mutable_unknown_fields));
::google::protobuf::io::CodedOutputStream unknown_fields_stream(
&unknown_fields_string, false);
// @@protoc_insertion_point(parse_start:sync_pb.UnknownFieldsTestB)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// required bool foo = 1;
case 1: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(8u)) {
set_has_foo();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &foo_)));
} else {
goto handle_unusual;
}
break;
}
// required bool bar = 2;
case 2: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(16u)) {
set_has_bar();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &bar_)));
} else {
goto handle_unusual;
}
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormatLite::SkipField(
input, tag, &unknown_fields_stream));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:sync_pb.UnknownFieldsTestB)
return true;
failure:
// @@protoc_insertion_point(parse_failure:sync_pb.UnknownFieldsTestB)
return false;
#undef DO_
}
void UnknownFieldsTestB::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:sync_pb.UnknownFieldsTestB)
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = _has_bits_[0];
// required bool foo = 1;
if (cached_has_bits & 0x00000001u) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->foo(), output);
}
// required bool bar = 2;
if (cached_has_bits & 0x00000002u) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->bar(), output);
}
output->WriteRaw(unknown_fields().data(),
static_cast<int>(unknown_fields().size()));
// @@protoc_insertion_point(serialize_end:sync_pb.UnknownFieldsTestB)
}
size_t UnknownFieldsTestB::RequiredFieldsByteSizeFallback() const {
// @@protoc_insertion_point(required_fields_byte_size_fallback_start:sync_pb.UnknownFieldsTestB)
size_t total_size = 0;
if (has_foo()) {
// required bool foo = 1;
total_size += 1 + 1;
}
if (has_bar()) {
// required bool bar = 2;
total_size += 1 + 1;
}
return total_size;
}
size_t UnknownFieldsTestB::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:sync_pb.UnknownFieldsTestB)
size_t total_size = 0;
total_size += unknown_fields().size();
if (((_has_bits_[0] & 0x00000003) ^ 0x00000003) == 0) { // All required fields are present.
// required bool foo = 1;
total_size += 1 + 1;
// required bool bar = 2;
total_size += 1 + 1;
} else {
total_size += RequiredFieldsByteSizeFallback();
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void UnknownFieldsTestB::CheckTypeAndMergeFrom(
const ::google::protobuf::MessageLite& from) {
MergeFrom(*::google::protobuf::down_cast<const UnknownFieldsTestB*>(&from));
}
void UnknownFieldsTestB::MergeFrom(const UnknownFieldsTestB& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:sync_pb.UnknownFieldsTestB)
GOOGLE_DCHECK_NE(&from, this);
_internal_metadata_.MergeFrom(from._internal_metadata_);
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = from._has_bits_[0];
if (cached_has_bits & 3u) {
if (cached_has_bits & 0x00000001u) {
foo_ = from.foo_;
}
if (cached_has_bits & 0x00000002u) {
bar_ = from.bar_;
}
_has_bits_[0] |= cached_has_bits;
}
}
void UnknownFieldsTestB::CopyFrom(const UnknownFieldsTestB& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:sync_pb.UnknownFieldsTestB)
if (&from == this) return;
Clear();
MergeFrom(from);
}
bool UnknownFieldsTestB::IsInitialized() const {
if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false;
return true;
}
void UnknownFieldsTestB::Swap(UnknownFieldsTestB* other) {
if (other == this) return;
InternalSwap(other);
}
void UnknownFieldsTestB::InternalSwap(UnknownFieldsTestB* other) {
std::swap(foo_, other->foo_);
std::swap(bar_, other->bar_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::std::string UnknownFieldsTestB::GetTypeName() const {
return "sync_pb.UnknownFieldsTestB";
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// UnknownFieldsTestB
// required bool foo = 1;
bool UnknownFieldsTestB::has_foo() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void UnknownFieldsTestB::set_has_foo() {
_has_bits_[0] |= 0x00000001u;
}
void UnknownFieldsTestB::clear_has_foo() {
_has_bits_[0] &= ~0x00000001u;
}
void UnknownFieldsTestB::clear_foo() {
foo_ = false;
clear_has_foo();
}
bool UnknownFieldsTestB::foo() const {
// @@protoc_insertion_point(field_get:sync_pb.UnknownFieldsTestB.foo)
return foo_;
}
void UnknownFieldsTestB::set_foo(bool value) {
set_has_foo();
foo_ = value;
// @@protoc_insertion_point(field_set:sync_pb.UnknownFieldsTestB.foo)
}
// required bool bar = 2;
bool UnknownFieldsTestB::has_bar() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void UnknownFieldsTestB::set_has_bar() {
_has_bits_[0] |= 0x00000002u;
}
void UnknownFieldsTestB::clear_has_bar() {
_has_bits_[0] &= ~0x00000002u;
}
void UnknownFieldsTestB::clear_bar() {
bar_ = false;
clear_has_bar();
}
bool UnknownFieldsTestB::bar() const {
// @@protoc_insertion_point(field_get:sync_pb.UnknownFieldsTestB.bar)
return bar_;
}
void UnknownFieldsTestB::set_bar(bool value) {
set_has_bar();
bar_ = value;
// @@protoc_insertion_point(field_set:sync_pb.UnknownFieldsTestB.bar)
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// @@protoc_insertion_point(namespace_scope)
} // namespace sync_pb
// @@protoc_insertion_point(global_scope)