| // Generated by the protocol buffer compiler. DO NOT EDIT! |
| // source: http_tests.proto |
| |
| #include "http_tests.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/descriptor.h> |
| #include <google/protobuf/generated_message_reflection.h> |
| #include <google/protobuf/reflection_ops.h> |
| #include <google/protobuf/wire_format.h> |
| // This is a temporary google only hack |
| #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| #include "third_party/protobuf/version.h" |
| #endif |
| // @@protoc_insertion_point(includes) |
| namespace mesos { |
| namespace test { |
| class TestSlaveMessage_SomeSlaveMapEntry_DoNotUseDefaultTypeInternal { |
| public: |
| ::google::protobuf::internal::ExplicitlyConstructed<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> |
| _instance; |
| } _TestSlaveMessage_SomeSlaveMapEntry_DoNotUse_default_instance_; |
| class TestSlaveMessageDefaultTypeInternal { |
| public: |
| ::google::protobuf::internal::ExplicitlyConstructed<TestSlaveMessage> |
| _instance; |
| } _TestSlaveMessage_default_instance_; |
| class ParentMessageDefaultTypeInternal { |
| public: |
| ::google::protobuf::internal::ExplicitlyConstructed<ParentMessage> |
| _instance; |
| } _ParentMessage_default_instance_; |
| } // namespace test |
| } // namespace mesos |
| namespace protobuf_http_5ftests_2eproto { |
| void InitDefaultsTestSlaveMessage_SomeSlaveMapEntry_DoNotUseImpl() { |
| GOOGLE_PROTOBUF_VERIFY_VERSION; |
| |
| #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); |
| #else |
| ::google::protobuf::internal::InitProtobufDefaults(); |
| #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| { |
| void* ptr = &::mesos::test::_TestSlaveMessage_SomeSlaveMapEntry_DoNotUse_default_instance_; |
| new (ptr) ::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse(); |
| } |
| ::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::InitAsDefaultInstance(); |
| } |
| |
| void InitDefaultsTestSlaveMessage_SomeSlaveMapEntry_DoNotUse() { |
| static GOOGLE_PROTOBUF_DECLARE_ONCE(once); |
| ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsTestSlaveMessage_SomeSlaveMapEntry_DoNotUseImpl); |
| } |
| |
| void InitDefaultsTestSlaveMessageImpl() { |
| GOOGLE_PROTOBUF_VERIFY_VERSION; |
| |
| #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); |
| #else |
| ::google::protobuf::internal::InitProtobufDefaults(); |
| #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| protobuf_http_5ftests_2eproto::InitDefaultsTestSlaveMessage_SomeSlaveMapEntry_DoNotUse(); |
| { |
| void* ptr = &::mesos::test::_TestSlaveMessage_default_instance_; |
| new (ptr) ::mesos::test::TestSlaveMessage(); |
| ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
| } |
| ::mesos::test::TestSlaveMessage::InitAsDefaultInstance(); |
| } |
| |
| void InitDefaultsTestSlaveMessage() { |
| static GOOGLE_PROTOBUF_DECLARE_ONCE(once); |
| ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsTestSlaveMessageImpl); |
| } |
| |
| void InitDefaultsParentMessageImpl() { |
| GOOGLE_PROTOBUF_VERIFY_VERSION; |
| |
| #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); |
| #else |
| ::google::protobuf::internal::InitProtobufDefaults(); |
| #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| protobuf_http_5ftests_2eproto::InitDefaultsTestSlaveMessage(); |
| { |
| void* ptr = &::mesos::test::_ParentMessage_default_instance_; |
| new (ptr) ::mesos::test::ParentMessage(); |
| ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
| } |
| ::mesos::test::ParentMessage::InitAsDefaultInstance(); |
| } |
| |
| void InitDefaultsParentMessage() { |
| static GOOGLE_PROTOBUF_DECLARE_ONCE(once); |
| ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsParentMessageImpl); |
| } |
| |
| ::google::protobuf::Metadata file_level_metadata[3]; |
| const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1]; |
| |
| const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse, _has_bits_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse, _internal_metadata_), |
| ~0u, // no _extensions_ |
| ~0u, // no _oneof_case_ |
| ~0u, // no _weak_field_map_ |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse, key_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse, value_), |
| 0, |
| 1, |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, _has_bits_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, _internal_metadata_), |
| ~0u, // no _extensions_ |
| ~0u, // no _oneof_case_ |
| ~0u, // no _weak_field_map_ |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, some_slave_field_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, some_slave_fields_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, some_slave_map_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, some_slave_enum_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::TestSlaveMessage, some_slave_enums_), |
| 0, |
| ~0u, |
| ~0u, |
| 1, |
| ~0u, |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::ParentMessage, _has_bits_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::ParentMessage, _internal_metadata_), |
| ~0u, // no _extensions_ |
| ~0u, // no _oneof_case_ |
| ~0u, // no _weak_field_map_ |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::ParentMessage, some_slave_message_), |
| GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::mesos::test::ParentMessage, some_slave_messages_), |
| 0, |
| ~0u, |
| }; |
| static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| { 0, 7, sizeof(::mesos::test::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse)}, |
| { 9, 19, sizeof(::mesos::test::TestSlaveMessage)}, |
| { 24, 31, sizeof(::mesos::test::ParentMessage)}, |
| }; |
| |
| static ::google::protobuf::Message const * const file_default_instances[] = { |
| reinterpret_cast<const ::google::protobuf::Message*>(&::mesos::test::_TestSlaveMessage_SomeSlaveMapEntry_DoNotUse_default_instance_), |
| reinterpret_cast<const ::google::protobuf::Message*>(&::mesos::test::_TestSlaveMessage_default_instance_), |
| reinterpret_cast<const ::google::protobuf::Message*>(&::mesos::test::_ParentMessage_default_instance_), |
| }; |
| |
| void protobuf_AssignDescriptors() { |
| AddDescriptors(); |
| ::google::protobuf::MessageFactory* factory = NULL; |
| AssignDescriptors( |
| "http_tests.proto", schemas, file_default_instances, TableStruct::offsets, factory, |
| file_level_metadata, file_level_enum_descriptors, NULL); |
| } |
| |
| void protobuf_AssignDescriptorsOnce() { |
| static GOOGLE_PROTOBUF_DECLARE_ONCE(once); |
| ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors); |
| } |
| |
| void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD; |
| void protobuf_RegisterTypes(const ::std::string&) { |
| protobuf_AssignDescriptorsOnce(); |
| ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 3); |
| } |
| |
| void AddDescriptorsImpl() { |
| InitDefaults(); |
| static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| "\n\020http_tests.proto\022\nmesos.test\"\316\002\n\020TestS" |
| "laveMessage\022\030\n\020some_slave_field\030\001 \001(\010\022\031\n" |
| "\021some_slave_fields\030\002 \003(\010\022F\n\016some_slave_m" |
| "ap\030\003 \003(\0132..mesos.test.TestSlaveMessage.S" |
| "omeSlaveMapEntry\0227\n\017some_slave_enum\030\004 \001(" |
| "\0162\036.mesos.test.TestSlaveMessage.E\0228\n\020som" |
| "e_slave_enums\030\005 \003(\0162\036.mesos.test.TestSla" |
| "veMessage.E\0323\n\021SomeSlaveMapEntry\022\013\n\003key\030" |
| "\001 \001(\010\022\r\n\005value\030\002 \001(\010:\0028\001\"\025\n\001E\022\020\n\014A_SLAVE" |
| "_ENUM\020\000\"\204\001\n\rParentMessage\0228\n\022some_slave_" |
| "message\030\001 \001(\0132\034.mesos.test.TestSlaveMess" |
| "age\0229\n\023some_slave_messages\030\002 \003(\0132\034.mesos" |
| ".test.TestSlaveMessage" |
| }; |
| ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( |
| descriptor, 502); |
| ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( |
| "http_tests.proto", &protobuf_RegisterTypes); |
| } |
| |
| void AddDescriptors() { |
| static GOOGLE_PROTOBUF_DECLARE_ONCE(once); |
| ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); |
| } |
| // Force AddDescriptors() to be called at dynamic initialization time. |
| struct StaticDescriptorInitializer { |
| StaticDescriptorInitializer() { |
| AddDescriptors(); |
| } |
| } static_descriptor_initializer; |
| } // namespace protobuf_http_5ftests_2eproto |
| namespace mesos { |
| namespace test { |
| const ::google::protobuf::EnumDescriptor* TestSlaveMessage_E_descriptor() { |
| protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return protobuf_http_5ftests_2eproto::file_level_enum_descriptors[0]; |
| } |
| bool TestSlaveMessage_E_IsValid(int value) { |
| switch (value) { |
| case 0: |
| return true; |
| default: |
| return false; |
| } |
| } |
| |
| #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| const TestSlaveMessage_E TestSlaveMessage::A_SLAVE_ENUM; |
| const TestSlaveMessage_E TestSlaveMessage::E_MIN; |
| const TestSlaveMessage_E TestSlaveMessage::E_MAX; |
| const int TestSlaveMessage::E_ARRAYSIZE; |
| #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| |
| // =================================================================== |
| |
| TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse() {} |
| TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::TestSlaveMessage_SomeSlaveMapEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {} |
| void TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::MergeFrom(const TestSlaveMessage_SomeSlaveMapEntry_DoNotUse& other) { |
| MergeFromInternal(other); |
| } |
| ::google::protobuf::Metadata TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::GetMetadata() const { |
| ::protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return ::protobuf_http_5ftests_2eproto::file_level_metadata[0]; |
| } |
| void TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::MergeFrom( |
| const ::google::protobuf::Message& other) { |
| ::google::protobuf::Message::MergeFrom(other); |
| } |
| |
| |
| // =================================================================== |
| |
| void TestSlaveMessage::InitAsDefaultInstance() { |
| } |
| #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| const int TestSlaveMessage::kSomeSlaveFieldFieldNumber; |
| const int TestSlaveMessage::kSomeSlaveFieldsFieldNumber; |
| const int TestSlaveMessage::kSomeSlaveMapFieldNumber; |
| const int TestSlaveMessage::kSomeSlaveEnumFieldNumber; |
| const int TestSlaveMessage::kSomeSlaveEnumsFieldNumber; |
| #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| |
| TestSlaveMessage::TestSlaveMessage() |
| : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
| if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { |
| ::protobuf_http_5ftests_2eproto::InitDefaultsTestSlaveMessage(); |
| } |
| SharedCtor(); |
| // @@protoc_insertion_point(constructor:mesos.test.TestSlaveMessage) |
| } |
| TestSlaveMessage::TestSlaveMessage(const TestSlaveMessage& from) |
| : ::google::protobuf::Message(), |
| _internal_metadata_(NULL), |
| _has_bits_(from._has_bits_), |
| _cached_size_(0), |
| some_slave_fields_(from.some_slave_fields_), |
| some_slave_enums_(from.some_slave_enums_) { |
| _internal_metadata_.MergeFrom(from._internal_metadata_); |
| some_slave_map_.MergeFrom(from.some_slave_map_); |
| ::memcpy(&some_slave_field_, &from.some_slave_field_, |
| static_cast<size_t>(reinterpret_cast<char*>(&some_slave_enum_) - |
| reinterpret_cast<char*>(&some_slave_field_)) + sizeof(some_slave_enum_)); |
| // @@protoc_insertion_point(copy_constructor:mesos.test.TestSlaveMessage) |
| } |
| |
| void TestSlaveMessage::SharedCtor() { |
| _cached_size_ = 0; |
| ::memset(&some_slave_field_, 0, static_cast<size_t>( |
| reinterpret_cast<char*>(&some_slave_enum_) - |
| reinterpret_cast<char*>(&some_slave_field_)) + sizeof(some_slave_enum_)); |
| } |
| |
| TestSlaveMessage::~TestSlaveMessage() { |
| // @@protoc_insertion_point(destructor:mesos.test.TestSlaveMessage) |
| SharedDtor(); |
| } |
| |
| void TestSlaveMessage::SharedDtor() { |
| } |
| |
| void TestSlaveMessage::SetCachedSize(int size) const { |
| GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); |
| _cached_size_ = size; |
| GOOGLE_SAFE_CONCURRENT_WRITES_END(); |
| } |
| const ::google::protobuf::Descriptor* TestSlaveMessage::descriptor() { |
| ::protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return ::protobuf_http_5ftests_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
| } |
| |
| const TestSlaveMessage& TestSlaveMessage::default_instance() { |
| ::protobuf_http_5ftests_2eproto::InitDefaultsTestSlaveMessage(); |
| return *internal_default_instance(); |
| } |
| |
| TestSlaveMessage* TestSlaveMessage::New(::google::protobuf::Arena* arena) const { |
| TestSlaveMessage* n = new TestSlaveMessage; |
| if (arena != NULL) { |
| arena->Own(n); |
| } |
| return n; |
| } |
| |
| void TestSlaveMessage::Clear() { |
| // @@protoc_insertion_point(message_clear_start:mesos.test.TestSlaveMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| // Prevent compiler warnings about cached_has_bits being unused |
| (void) cached_has_bits; |
| |
| some_slave_fields_.Clear(); |
| some_slave_map_.Clear(); |
| some_slave_enums_.Clear(); |
| cached_has_bits = _has_bits_[0]; |
| if (cached_has_bits & 3u) { |
| ::memset(&some_slave_field_, 0, static_cast<size_t>( |
| reinterpret_cast<char*>(&some_slave_enum_) - |
| reinterpret_cast<char*>(&some_slave_field_)) + sizeof(some_slave_enum_)); |
| } |
| _has_bits_.Clear(); |
| _internal_metadata_.Clear(); |
| } |
| |
| bool TestSlaveMessage::MergePartialFromCodedStream( |
| ::google::protobuf::io::CodedInputStream* input) { |
| #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
| ::google::protobuf::uint32 tag; |
| // @@protoc_insertion_point(parse_start:mesos.test.TestSlaveMessage) |
| 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)) { |
| // optional bool some_slave_field = 1; |
| case 1: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { |
| set_has_some_slave_field(); |
| DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( |
| input, &some_slave_field_))); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| // repeated bool some_slave_fields = 2; |
| case 2: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) { |
| DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive< |
| bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( |
| 1, 16u, input, this->mutable_some_slave_fields()))); |
| } else if ( |
| static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { |
| DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline< |
| bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( |
| input, this->mutable_some_slave_fields()))); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| // map<bool, bool> some_slave_map = 3; |
| case 3: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { |
| TestSlaveMessage_SomeSlaveMapEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField< |
| TestSlaveMessage_SomeSlaveMapEntry_DoNotUse, |
| bool, bool, |
| ::google::protobuf::internal::WireFormatLite::TYPE_BOOL, |
| ::google::protobuf::internal::WireFormatLite::TYPE_BOOL, |
| 0 >, |
| ::google::protobuf::Map< bool, bool > > parser(&some_slave_map_); |
| DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( |
| input, &parser)); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| // optional .mesos.test.TestSlaveMessage.E some_slave_enum = 4; |
| case 4: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(32u /* 32 & 0xFF */)) { |
| int value; |
| DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( |
| input, &value))); |
| if (::mesos::test::TestSlaveMessage_E_IsValid(value)) { |
| set_some_slave_enum(static_cast< ::mesos::test::TestSlaveMessage_E >(value)); |
| } else { |
| mutable_unknown_fields()->AddVarint( |
| 4, static_cast< ::google::protobuf::uint64>(value)); |
| } |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage.E some_slave_enums = 5; |
| case 5: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) { |
| int value; |
| DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( |
| input, &value))); |
| if (::mesos::test::TestSlaveMessage_E_IsValid(value)) { |
| add_some_slave_enums(static_cast< ::mesos::test::TestSlaveMessage_E >(value)); |
| } else { |
| mutable_unknown_fields()->AddVarint( |
| 5, static_cast< ::google::protobuf::uint64>(value)); |
| } |
| } else if ( |
| static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) { |
| DO_((::google::protobuf::internal::WireFormat::ReadPackedEnumPreserveUnknowns( |
| input, |
| 5, |
| ::mesos::test::TestSlaveMessage_E_IsValid, |
| mutable_unknown_fields(), |
| this->mutable_some_slave_enums()))); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| default: { |
| handle_unusual: |
| if (tag == 0) { |
| goto success; |
| } |
| DO_(::google::protobuf::internal::WireFormat::SkipField( |
| input, tag, _internal_metadata_.mutable_unknown_fields())); |
| break; |
| } |
| } |
| } |
| success: |
| // @@protoc_insertion_point(parse_success:mesos.test.TestSlaveMessage) |
| return true; |
| failure: |
| // @@protoc_insertion_point(parse_failure:mesos.test.TestSlaveMessage) |
| return false; |
| #undef DO_ |
| } |
| |
| void TestSlaveMessage::SerializeWithCachedSizes( |
| ::google::protobuf::io::CodedOutputStream* output) const { |
| // @@protoc_insertion_point(serialize_start:mesos.test.TestSlaveMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| cached_has_bits = _has_bits_[0]; |
| // optional bool some_slave_field = 1; |
| if (cached_has_bits & 0x00000001u) { |
| ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->some_slave_field(), output); |
| } |
| |
| // repeated bool some_slave_fields = 2; |
| for (int i = 0, n = this->some_slave_fields_size(); i < n; i++) { |
| ::google::protobuf::internal::WireFormatLite::WriteBool( |
| 2, this->some_slave_fields(i), output); |
| } |
| |
| // map<bool, bool> some_slave_map = 3; |
| if (!this->some_slave_map().empty()) { |
| typedef ::google::protobuf::Map< bool, bool >::const_pointer |
| ConstPtr; |
| typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem; |
| typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less; |
| |
| if (output->IsSerializationDeterministic() && |
| this->some_slave_map().size() > 1) { |
| ::google::protobuf::scoped_array<SortItem> items( |
| new SortItem[this->some_slave_map().size()]); |
| typedef ::google::protobuf::Map< bool, bool >::size_type size_type; |
| size_type n = 0; |
| for (::google::protobuf::Map< bool, bool >::const_iterator |
| it = this->some_slave_map().begin(); |
| it != this->some_slave_map().end(); ++it, ++n) { |
| items[static_cast<ptrdiff_t>(n)] = SortItem(&*it); |
| } |
| ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less()); |
| ::google::protobuf::scoped_ptr<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> entry; |
| for (size_type i = 0; i < n; i++) { |
| entry.reset(some_slave_map_.NewEntryWrapper( |
| items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second)); |
| ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
| 3, *entry, output); |
| } |
| } else { |
| ::google::protobuf::scoped_ptr<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> entry; |
| for (::google::protobuf::Map< bool, bool >::const_iterator |
| it = this->some_slave_map().begin(); |
| it != this->some_slave_map().end(); ++it) { |
| entry.reset(some_slave_map_.NewEntryWrapper( |
| it->first, it->second)); |
| ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
| 3, *entry, output); |
| } |
| } |
| } |
| |
| // optional .mesos.test.TestSlaveMessage.E some_slave_enum = 4; |
| if (cached_has_bits & 0x00000002u) { |
| ::google::protobuf::internal::WireFormatLite::WriteEnum( |
| 4, this->some_slave_enum(), output); |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage.E some_slave_enums = 5; |
| for (int i = 0, n = this->some_slave_enums_size(); i < n; i++) { |
| ::google::protobuf::internal::WireFormatLite::WriteEnum( |
| 5, this->some_slave_enums(i), output); |
| } |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
| _internal_metadata_.unknown_fields(), output); |
| } |
| // @@protoc_insertion_point(serialize_end:mesos.test.TestSlaveMessage) |
| } |
| |
| ::google::protobuf::uint8* TestSlaveMessage::InternalSerializeWithCachedSizesToArray( |
| bool deterministic, ::google::protobuf::uint8* target) const { |
| (void)deterministic; // Unused |
| // @@protoc_insertion_point(serialize_to_array_start:mesos.test.TestSlaveMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| cached_has_bits = _has_bits_[0]; |
| // optional bool some_slave_field = 1; |
| if (cached_has_bits & 0x00000001u) { |
| target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->some_slave_field(), target); |
| } |
| |
| // repeated bool some_slave_fields = 2; |
| target = ::google::protobuf::internal::WireFormatLite:: |
| WriteBoolToArray(2, this->some_slave_fields_, target); |
| |
| // map<bool, bool> some_slave_map = 3; |
| if (!this->some_slave_map().empty()) { |
| typedef ::google::protobuf::Map< bool, bool >::const_pointer |
| ConstPtr; |
| typedef ::google::protobuf::internal::SortItem< bool, ConstPtr > SortItem; |
| typedef ::google::protobuf::internal::CompareByFirstField<SortItem> Less; |
| |
| if (deterministic && |
| this->some_slave_map().size() > 1) { |
| ::google::protobuf::scoped_array<SortItem> items( |
| new SortItem[this->some_slave_map().size()]); |
| typedef ::google::protobuf::Map< bool, bool >::size_type size_type; |
| size_type n = 0; |
| for (::google::protobuf::Map< bool, bool >::const_iterator |
| it = this->some_slave_map().begin(); |
| it != this->some_slave_map().end(); ++it, ++n) { |
| items[static_cast<ptrdiff_t>(n)] = SortItem(&*it); |
| } |
| ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less()); |
| ::google::protobuf::scoped_ptr<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> entry; |
| for (size_type i = 0; i < n; i++) { |
| entry.reset(some_slave_map_.NewEntryWrapper( |
| items[static_cast<ptrdiff_t>(i)].second->first, items[static_cast<ptrdiff_t>(i)].second->second)); |
| target = ::google::protobuf::internal::WireFormatLite:: |
| InternalWriteMessageNoVirtualToArray( |
| 3, *entry, deterministic, target); |
| ; |
| } |
| } else { |
| ::google::protobuf::scoped_ptr<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> entry; |
| for (::google::protobuf::Map< bool, bool >::const_iterator |
| it = this->some_slave_map().begin(); |
| it != this->some_slave_map().end(); ++it) { |
| entry.reset(some_slave_map_.NewEntryWrapper( |
| it->first, it->second)); |
| target = ::google::protobuf::internal::WireFormatLite:: |
| InternalWriteMessageNoVirtualToArray( |
| 3, *entry, deterministic, target); |
| ; |
| } |
| } |
| } |
| |
| // optional .mesos.test.TestSlaveMessage.E some_slave_enum = 4; |
| if (cached_has_bits & 0x00000002u) { |
| target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( |
| 4, this->some_slave_enum(), target); |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage.E some_slave_enums = 5; |
| target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( |
| 5, this->some_slave_enums_, target); |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
| _internal_metadata_.unknown_fields(), target); |
| } |
| // @@protoc_insertion_point(serialize_to_array_end:mesos.test.TestSlaveMessage) |
| return target; |
| } |
| |
| size_t TestSlaveMessage::ByteSizeLong() const { |
| // @@protoc_insertion_point(message_byte_size_start:mesos.test.TestSlaveMessage) |
| size_t total_size = 0; |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| total_size += |
| ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
| _internal_metadata_.unknown_fields()); |
| } |
| // repeated bool some_slave_fields = 2; |
| { |
| unsigned int count = static_cast<unsigned int>(this->some_slave_fields_size()); |
| size_t data_size = 1UL * count; |
| total_size += 1 * |
| ::google::protobuf::internal::FromIntSize(this->some_slave_fields_size()); |
| total_size += data_size; |
| } |
| |
| // map<bool, bool> some_slave_map = 3; |
| total_size += 1 * |
| ::google::protobuf::internal::FromIntSize(this->some_slave_map_size()); |
| { |
| ::google::protobuf::scoped_ptr<TestSlaveMessage_SomeSlaveMapEntry_DoNotUse> entry; |
| for (::google::protobuf::Map< bool, bool >::const_iterator |
| it = this->some_slave_map().begin(); |
| it != this->some_slave_map().end(); ++it) { |
| entry.reset(some_slave_map_.NewEntryWrapper(it->first, it->second)); |
| total_size += ::google::protobuf::internal::WireFormatLite:: |
| MessageSizeNoVirtual(*entry); |
| } |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage.E some_slave_enums = 5; |
| { |
| size_t data_size = 0; |
| unsigned int count = static_cast<unsigned int>(this->some_slave_enums_size());for (unsigned int i = 0; i < count; i++) { |
| data_size += ::google::protobuf::internal::WireFormatLite::EnumSize( |
| this->some_slave_enums(static_cast<int>(i))); |
| } |
| total_size += (1UL * count) + data_size; |
| } |
| |
| if (_has_bits_[0 / 32] & 3u) { |
| // optional bool some_slave_field = 1; |
| if (has_some_slave_field()) { |
| total_size += 1 + 1; |
| } |
| |
| // optional .mesos.test.TestSlaveMessage.E some_slave_enum = 4; |
| if (has_some_slave_enum()) { |
| total_size += 1 + |
| ::google::protobuf::internal::WireFormatLite::EnumSize(this->some_slave_enum()); |
| } |
| |
| } |
| 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 TestSlaveMessage::MergeFrom(const ::google::protobuf::Message& from) { |
| // @@protoc_insertion_point(generalized_merge_from_start:mesos.test.TestSlaveMessage) |
| GOOGLE_DCHECK_NE(&from, this); |
| const TestSlaveMessage* source = |
| ::google::protobuf::internal::DynamicCastToGenerated<const TestSlaveMessage>( |
| &from); |
| if (source == NULL) { |
| // @@protoc_insertion_point(generalized_merge_from_cast_fail:mesos.test.TestSlaveMessage) |
| ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
| } else { |
| // @@protoc_insertion_point(generalized_merge_from_cast_success:mesos.test.TestSlaveMessage) |
| MergeFrom(*source); |
| } |
| } |
| |
| void TestSlaveMessage::MergeFrom(const TestSlaveMessage& from) { |
| // @@protoc_insertion_point(class_specific_merge_from_start:mesos.test.TestSlaveMessage) |
| GOOGLE_DCHECK_NE(&from, this); |
| _internal_metadata_.MergeFrom(from._internal_metadata_); |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| some_slave_fields_.MergeFrom(from.some_slave_fields_); |
| some_slave_map_.MergeFrom(from.some_slave_map_); |
| some_slave_enums_.MergeFrom(from.some_slave_enums_); |
| cached_has_bits = from._has_bits_[0]; |
| if (cached_has_bits & 3u) { |
| if (cached_has_bits & 0x00000001u) { |
| some_slave_field_ = from.some_slave_field_; |
| } |
| if (cached_has_bits & 0x00000002u) { |
| some_slave_enum_ = from.some_slave_enum_; |
| } |
| _has_bits_[0] |= cached_has_bits; |
| } |
| } |
| |
| void TestSlaveMessage::CopyFrom(const ::google::protobuf::Message& from) { |
| // @@protoc_insertion_point(generalized_copy_from_start:mesos.test.TestSlaveMessage) |
| if (&from == this) return; |
| Clear(); |
| MergeFrom(from); |
| } |
| |
| void TestSlaveMessage::CopyFrom(const TestSlaveMessage& from) { |
| // @@protoc_insertion_point(class_specific_copy_from_start:mesos.test.TestSlaveMessage) |
| if (&from == this) return; |
| Clear(); |
| MergeFrom(from); |
| } |
| |
| bool TestSlaveMessage::IsInitialized() const { |
| return true; |
| } |
| |
| void TestSlaveMessage::Swap(TestSlaveMessage* other) { |
| if (other == this) return; |
| InternalSwap(other); |
| } |
| void TestSlaveMessage::InternalSwap(TestSlaveMessage* other) { |
| using std::swap; |
| some_slave_fields_.InternalSwap(&other->some_slave_fields_); |
| some_slave_map_.Swap(&other->some_slave_map_); |
| some_slave_enums_.InternalSwap(&other->some_slave_enums_); |
| swap(some_slave_field_, other->some_slave_field_); |
| swap(some_slave_enum_, other->some_slave_enum_); |
| swap(_has_bits_[0], other->_has_bits_[0]); |
| _internal_metadata_.Swap(&other->_internal_metadata_); |
| swap(_cached_size_, other->_cached_size_); |
| } |
| |
| ::google::protobuf::Metadata TestSlaveMessage::GetMetadata() const { |
| protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return ::protobuf_http_5ftests_2eproto::file_level_metadata[kIndexInFileMessages]; |
| } |
| |
| |
| // =================================================================== |
| |
| void ParentMessage::InitAsDefaultInstance() { |
| ::mesos::test::_ParentMessage_default_instance_._instance.get_mutable()->some_slave_message_ = const_cast< ::mesos::test::TestSlaveMessage*>( |
| ::mesos::test::TestSlaveMessage::internal_default_instance()); |
| } |
| #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| const int ParentMessage::kSomeSlaveMessageFieldNumber; |
| const int ParentMessage::kSomeSlaveMessagesFieldNumber; |
| #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| |
| ParentMessage::ParentMessage() |
| : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
| if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { |
| ::protobuf_http_5ftests_2eproto::InitDefaultsParentMessage(); |
| } |
| SharedCtor(); |
| // @@protoc_insertion_point(constructor:mesos.test.ParentMessage) |
| } |
| ParentMessage::ParentMessage(const ParentMessage& from) |
| : ::google::protobuf::Message(), |
| _internal_metadata_(NULL), |
| _has_bits_(from._has_bits_), |
| _cached_size_(0), |
| some_slave_messages_(from.some_slave_messages_) { |
| _internal_metadata_.MergeFrom(from._internal_metadata_); |
| if (from.has_some_slave_message()) { |
| some_slave_message_ = new ::mesos::test::TestSlaveMessage(*from.some_slave_message_); |
| } else { |
| some_slave_message_ = NULL; |
| } |
| // @@protoc_insertion_point(copy_constructor:mesos.test.ParentMessage) |
| } |
| |
| void ParentMessage::SharedCtor() { |
| _cached_size_ = 0; |
| some_slave_message_ = NULL; |
| } |
| |
| ParentMessage::~ParentMessage() { |
| // @@protoc_insertion_point(destructor:mesos.test.ParentMessage) |
| SharedDtor(); |
| } |
| |
| void ParentMessage::SharedDtor() { |
| if (this != internal_default_instance()) delete some_slave_message_; |
| } |
| |
| void ParentMessage::SetCachedSize(int size) const { |
| GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); |
| _cached_size_ = size; |
| GOOGLE_SAFE_CONCURRENT_WRITES_END(); |
| } |
| const ::google::protobuf::Descriptor* ParentMessage::descriptor() { |
| ::protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return ::protobuf_http_5ftests_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
| } |
| |
| const ParentMessage& ParentMessage::default_instance() { |
| ::protobuf_http_5ftests_2eproto::InitDefaultsParentMessage(); |
| return *internal_default_instance(); |
| } |
| |
| ParentMessage* ParentMessage::New(::google::protobuf::Arena* arena) const { |
| ParentMessage* n = new ParentMessage; |
| if (arena != NULL) { |
| arena->Own(n); |
| } |
| return n; |
| } |
| |
| void ParentMessage::Clear() { |
| // @@protoc_insertion_point(message_clear_start:mesos.test.ParentMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| // Prevent compiler warnings about cached_has_bits being unused |
| (void) cached_has_bits; |
| |
| some_slave_messages_.Clear(); |
| cached_has_bits = _has_bits_[0]; |
| if (cached_has_bits & 0x00000001u) { |
| GOOGLE_DCHECK(some_slave_message_ != NULL); |
| some_slave_message_->Clear(); |
| } |
| _has_bits_.Clear(); |
| _internal_metadata_.Clear(); |
| } |
| |
| bool ParentMessage::MergePartialFromCodedStream( |
| ::google::protobuf::io::CodedInputStream* input) { |
| #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
| ::google::protobuf::uint32 tag; |
| // @@protoc_insertion_point(parse_start:mesos.test.ParentMessage) |
| 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)) { |
| // optional .mesos.test.TestSlaveMessage some_slave_message = 1; |
| case 1: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { |
| DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
| input, mutable_some_slave_message())); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage some_slave_messages = 2; |
| case 2: { |
| if (static_cast< ::google::protobuf::uint8>(tag) == |
| static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { |
| DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_some_slave_messages())); |
| } else { |
| goto handle_unusual; |
| } |
| break; |
| } |
| |
| default: { |
| handle_unusual: |
| if (tag == 0) { |
| goto success; |
| } |
| DO_(::google::protobuf::internal::WireFormat::SkipField( |
| input, tag, _internal_metadata_.mutable_unknown_fields())); |
| break; |
| } |
| } |
| } |
| success: |
| // @@protoc_insertion_point(parse_success:mesos.test.ParentMessage) |
| return true; |
| failure: |
| // @@protoc_insertion_point(parse_failure:mesos.test.ParentMessage) |
| return false; |
| #undef DO_ |
| } |
| |
| void ParentMessage::SerializeWithCachedSizes( |
| ::google::protobuf::io::CodedOutputStream* output) const { |
| // @@protoc_insertion_point(serialize_start:mesos.test.ParentMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| cached_has_bits = _has_bits_[0]; |
| // optional .mesos.test.TestSlaveMessage some_slave_message = 1; |
| if (cached_has_bits & 0x00000001u) { |
| ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
| 1, *this->some_slave_message_, output); |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage some_slave_messages = 2; |
| for (unsigned int i = 0, |
| n = static_cast<unsigned int>(this->some_slave_messages_size()); i < n; i++) { |
| ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
| 2, this->some_slave_messages(static_cast<int>(i)), output); |
| } |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
| _internal_metadata_.unknown_fields(), output); |
| } |
| // @@protoc_insertion_point(serialize_end:mesos.test.ParentMessage) |
| } |
| |
| ::google::protobuf::uint8* ParentMessage::InternalSerializeWithCachedSizesToArray( |
| bool deterministic, ::google::protobuf::uint8* target) const { |
| (void)deterministic; // Unused |
| // @@protoc_insertion_point(serialize_to_array_start:mesos.test.ParentMessage) |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| cached_has_bits = _has_bits_[0]; |
| // optional .mesos.test.TestSlaveMessage some_slave_message = 1; |
| if (cached_has_bits & 0x00000001u) { |
| target = ::google::protobuf::internal::WireFormatLite:: |
| InternalWriteMessageToArray( |
| 1, *this->some_slave_message_, deterministic, target); |
| } |
| |
| // repeated .mesos.test.TestSlaveMessage some_slave_messages = 2; |
| for (unsigned int i = 0, |
| n = static_cast<unsigned int>(this->some_slave_messages_size()); i < n; i++) { |
| target = ::google::protobuf::internal::WireFormatLite:: |
| InternalWriteMessageToArray( |
| 2, this->some_slave_messages(static_cast<int>(i)), deterministic, target); |
| } |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
| _internal_metadata_.unknown_fields(), target); |
| } |
| // @@protoc_insertion_point(serialize_to_array_end:mesos.test.ParentMessage) |
| return target; |
| } |
| |
| size_t ParentMessage::ByteSizeLong() const { |
| // @@protoc_insertion_point(message_byte_size_start:mesos.test.ParentMessage) |
| size_t total_size = 0; |
| |
| if (_internal_metadata_.have_unknown_fields()) { |
| total_size += |
| ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
| _internal_metadata_.unknown_fields()); |
| } |
| // repeated .mesos.test.TestSlaveMessage some_slave_messages = 2; |
| { |
| unsigned int count = static_cast<unsigned int>(this->some_slave_messages_size()); |
| total_size += 1UL * count; |
| for (unsigned int i = 0; i < count; i++) { |
| total_size += |
| ::google::protobuf::internal::WireFormatLite::MessageSize( |
| this->some_slave_messages(static_cast<int>(i))); |
| } |
| } |
| |
| // optional .mesos.test.TestSlaveMessage some_slave_message = 1; |
| if (has_some_slave_message()) { |
| total_size += 1 + |
| ::google::protobuf::internal::WireFormatLite::MessageSize( |
| *this->some_slave_message_); |
| } |
| |
| 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 ParentMessage::MergeFrom(const ::google::protobuf::Message& from) { |
| // @@protoc_insertion_point(generalized_merge_from_start:mesos.test.ParentMessage) |
| GOOGLE_DCHECK_NE(&from, this); |
| const ParentMessage* source = |
| ::google::protobuf::internal::DynamicCastToGenerated<const ParentMessage>( |
| &from); |
| if (source == NULL) { |
| // @@protoc_insertion_point(generalized_merge_from_cast_fail:mesos.test.ParentMessage) |
| ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
| } else { |
| // @@protoc_insertion_point(generalized_merge_from_cast_success:mesos.test.ParentMessage) |
| MergeFrom(*source); |
| } |
| } |
| |
| void ParentMessage::MergeFrom(const ParentMessage& from) { |
| // @@protoc_insertion_point(class_specific_merge_from_start:mesos.test.ParentMessage) |
| GOOGLE_DCHECK_NE(&from, this); |
| _internal_metadata_.MergeFrom(from._internal_metadata_); |
| ::google::protobuf::uint32 cached_has_bits = 0; |
| (void) cached_has_bits; |
| |
| some_slave_messages_.MergeFrom(from.some_slave_messages_); |
| if (from.has_some_slave_message()) { |
| mutable_some_slave_message()->::mesos::test::TestSlaveMessage::MergeFrom(from.some_slave_message()); |
| } |
| } |
| |
| void ParentMessage::CopyFrom(const ::google::protobuf::Message& from) { |
| // @@protoc_insertion_point(generalized_copy_from_start:mesos.test.ParentMessage) |
| if (&from == this) return; |
| Clear(); |
| MergeFrom(from); |
| } |
| |
| void ParentMessage::CopyFrom(const ParentMessage& from) { |
| // @@protoc_insertion_point(class_specific_copy_from_start:mesos.test.ParentMessage) |
| if (&from == this) return; |
| Clear(); |
| MergeFrom(from); |
| } |
| |
| bool ParentMessage::IsInitialized() const { |
| return true; |
| } |
| |
| void ParentMessage::Swap(ParentMessage* other) { |
| if (other == this) return; |
| InternalSwap(other); |
| } |
| void ParentMessage::InternalSwap(ParentMessage* other) { |
| using std::swap; |
| some_slave_messages_.InternalSwap(&other->some_slave_messages_); |
| swap(some_slave_message_, other->some_slave_message_); |
| swap(_has_bits_[0], other->_has_bits_[0]); |
| _internal_metadata_.Swap(&other->_internal_metadata_); |
| swap(_cached_size_, other->_cached_size_); |
| } |
| |
| ::google::protobuf::Metadata ParentMessage::GetMetadata() const { |
| protobuf_http_5ftests_2eproto::protobuf_AssignDescriptorsOnce(); |
| return ::protobuf_http_5ftests_2eproto::file_level_metadata[kIndexInFileMessages]; |
| } |
| |
| |
| // @@protoc_insertion_point(namespace_scope) |
| } // namespace test |
| } // namespace mesos |
| |
| // @@protoc_insertion_point(global_scope) |