123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734 |
- // Generated by the protocol buffer compiler. DO NOT EDIT!
- // source: client2world_chat.proto
- #define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
- #include "client2world_chat.pb.h"
- #include <algorithm>
- #include <google/protobuf/stubs/common.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>
- // @@protoc_insertion_point(includes)
- namespace client2world_protocols {
- namespace {
- const ::google::protobuf::Descriptor* packetw2c_notify_descriptor_ = NULL;
- const ::google::protobuf::internal::GeneratedMessageReflection*
- packetw2c_notify_reflection_ = NULL;
- } // namespace
- void protobuf_AssignDesc_client2world_5fchat_2eproto() {
- protobuf_AddDesc_client2world_5fchat_2eproto();
- const ::google::protobuf::FileDescriptor* file =
- ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
- "client2world_chat.proto");
- GOOGLE_CHECK(file != NULL);
- packetw2c_notify_descriptor_ = file->message_type(0);
- static const int packetw2c_notify_offsets_[10] = {
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, packet_id_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, content_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, notifytype_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, talkernickname_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, playerid_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, talkerviplevel_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, hasmonthcard_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, repcount_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, interval_),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, showpos_),
- };
- packetw2c_notify_reflection_ =
- new ::google::protobuf::internal::GeneratedMessageReflection(
- packetw2c_notify_descriptor_,
- packetw2c_notify::default_instance_,
- packetw2c_notify_offsets_,
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, _has_bits_[0]),
- GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetw2c_notify, _unknown_fields_),
- -1,
- ::google::protobuf::DescriptorPool::generated_pool(),
- ::google::protobuf::MessageFactory::generated_factory(),
- sizeof(packetw2c_notify));
- }
- namespace {
- GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
- inline void protobuf_AssignDescriptorsOnce() {
- ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
- &protobuf_AssignDesc_client2world_5fchat_2eproto);
- }
- void protobuf_RegisterTypes(const ::std::string&) {
- protobuf_AssignDescriptorsOnce();
- ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
- packetw2c_notify_descriptor_, &packetw2c_notify::default_instance());
- }
- } // namespace
- void protobuf_ShutdownFile_client2world_5fchat_2eproto() {
- delete packetw2c_notify::default_instance_;
- delete packetw2c_notify_reflection_;
- }
- void protobuf_AddDesc_client2world_5fchat_2eproto() {
- static bool already_here = false;
- if (already_here) return;
- already_here = true;
- GOOGLE_PROTOBUF_VERIFY_VERSION;
- ::client2world_protocols::protobuf_AddDesc_client2world_5fmsg_5ftype_2eproto();
- ::msg_type_def::protobuf_AddDesc_msg_5ftype_5fdef_2eproto();
- ::msg_info_def::protobuf_AddDesc_msg_5finfo_5fdef_2eproto();
- ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
- "\n\027client2world_chat.proto\022\026client2world_"
- "protocols\032\033client2world_msg_type.proto\032\022"
- "msg_type_def.proto\032\022msg_info_def.proto\"\232"
- "\002\n\020packetw2c_notify\022N\n\tpacket_id\030\001 \001(\0162)"
- ".client2world_protocols.e_server_msg_typ"
- "e:\020e_mst_w2c_notify\022\017\n\007content\030\002 \001(\t\022\022\n\n"
- "notifyType\030\003 \001(\005\022\026\n\016talkerNickName\030\004 \001(\t"
- "\022\020\n\010playerId\030\005 \001(\005\022\026\n\016talkerVIPLevel\030\006 \001"
- "(\005\022\024\n\014hasMonthCard\030\007 \001(\010\022\023\n\010repCount\030\010 \001"
- "(\005:\0011\022\023\n\010interval\030\t \001(\005:\0010\022\017\n\007showPos\030\n "
- "\001(\005", 403);
- ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
- "client2world_chat.proto", &protobuf_RegisterTypes);
- packetw2c_notify::default_instance_ = new packetw2c_notify();
- packetw2c_notify::default_instance_->InitAsDefaultInstance();
- ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_client2world_5fchat_2eproto);
- }
- // Force AddDescriptors() to be called at static initialization time.
- struct StaticDescriptorInitializer_client2world_5fchat_2eproto {
- StaticDescriptorInitializer_client2world_5fchat_2eproto() {
- protobuf_AddDesc_client2world_5fchat_2eproto();
- }
- } static_descriptor_initializer_client2world_5fchat_2eproto_;
- // ===================================================================
- #ifndef _MSC_VER
- const int packetw2c_notify::kPacketIdFieldNumber;
- const int packetw2c_notify::kContentFieldNumber;
- const int packetw2c_notify::kNotifyTypeFieldNumber;
- const int packetw2c_notify::kTalkerNickNameFieldNumber;
- const int packetw2c_notify::kPlayerIdFieldNumber;
- const int packetw2c_notify::kTalkerVIPLevelFieldNumber;
- const int packetw2c_notify::kHasMonthCardFieldNumber;
- const int packetw2c_notify::kRepCountFieldNumber;
- const int packetw2c_notify::kIntervalFieldNumber;
- const int packetw2c_notify::kShowPosFieldNumber;
- #endif // !_MSC_VER
- packetw2c_notify::packetw2c_notify()
- : ::google::protobuf::Message() {
- SharedCtor();
- }
- void packetw2c_notify::InitAsDefaultInstance() {
- }
- packetw2c_notify::packetw2c_notify(const packetw2c_notify& from)
- : ::google::protobuf::Message() {
- SharedCtor();
- MergeFrom(from);
- }
- void packetw2c_notify::SharedCtor() {
- _cached_size_ = 0;
- packet_id_ = 7523;
- content_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
- notifytype_ = 0;
- talkernickname_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
- playerid_ = 0;
- talkerviplevel_ = 0;
- hasmonthcard_ = false;
- repcount_ = 1;
- interval_ = 0;
- showpos_ = 0;
- ::memset(_has_bits_, 0, sizeof(_has_bits_));
- }
- packetw2c_notify::~packetw2c_notify() {
- SharedDtor();
- }
- void packetw2c_notify::SharedDtor() {
- if (content_ != &::google::protobuf::internal::kEmptyString) {
- delete content_;
- }
- if (talkernickname_ != &::google::protobuf::internal::kEmptyString) {
- delete talkernickname_;
- }
- if (this != default_instance_) {
- }
- }
- void packetw2c_notify::SetCachedSize(int size) const {
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
- }
- const ::google::protobuf::Descriptor* packetw2c_notify::descriptor() {
- protobuf_AssignDescriptorsOnce();
- return packetw2c_notify_descriptor_;
- }
- const packetw2c_notify& packetw2c_notify::default_instance() {
- if (default_instance_ == NULL) protobuf_AddDesc_client2world_5fchat_2eproto();
- return *default_instance_;
- }
- packetw2c_notify* packetw2c_notify::default_instance_ = NULL;
- packetw2c_notify* packetw2c_notify::New() const {
- return new packetw2c_notify;
- }
- void packetw2c_notify::Clear() {
- if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
- packet_id_ = 7523;
- if (has_content()) {
- if (content_ != &::google::protobuf::internal::kEmptyString) {
- content_->clear();
- }
- }
- notifytype_ = 0;
- if (has_talkernickname()) {
- if (talkernickname_ != &::google::protobuf::internal::kEmptyString) {
- talkernickname_->clear();
- }
- }
- playerid_ = 0;
- talkerviplevel_ = 0;
- hasmonthcard_ = false;
- repcount_ = 1;
- }
- if (_has_bits_[8 / 32] & (0xffu << (8 % 32))) {
- interval_ = 0;
- showpos_ = 0;
- }
- ::memset(_has_bits_, 0, sizeof(_has_bits_));
- mutable_unknown_fields()->Clear();
- }
- bool packetw2c_notify::MergePartialFromCodedStream(
- ::google::protobuf::io::CodedInputStream* input) {
- #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
- ::google::protobuf::uint32 tag;
- while ((tag = input->ReadTag()) != 0) {
- switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
- // optional .client2world_protocols.e_server_msg_type packet_id = 1 [default = e_mst_w2c_notify];
- case 1: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- int value;
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
- input, &value)));
- if (::client2world_protocols::e_server_msg_type_IsValid(value)) {
- set_packet_id(static_cast< ::client2world_protocols::e_server_msg_type >(value));
- } else {
- mutable_unknown_fields()->AddVarint(1, value);
- }
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(18)) goto parse_content;
- break;
- }
- // optional string content = 2;
- case 2: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
- parse_content:
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_content()));
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->content().data(), this->content().length(),
- ::google::protobuf::internal::WireFormat::PARSE);
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(24)) goto parse_notifyType;
- break;
- }
- // optional int32 notifyType = 3;
- case 3: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_notifyType:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, ¬ifytype_)));
- set_has_notifytype();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(34)) goto parse_talkerNickName;
- break;
- }
- // optional string talkerNickName = 4;
- case 4: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
- parse_talkerNickName:
- DO_(::google::protobuf::internal::WireFormatLite::ReadString(
- input, this->mutable_talkernickname()));
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->talkernickname().data(), this->talkernickname().length(),
- ::google::protobuf::internal::WireFormat::PARSE);
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(40)) goto parse_playerId;
- break;
- }
- // optional int32 playerId = 5;
- case 5: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_playerId:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, &playerid_)));
- set_has_playerid();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(48)) goto parse_talkerVIPLevel;
- break;
- }
- // optional int32 talkerVIPLevel = 6;
- case 6: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_talkerVIPLevel:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, &talkerviplevel_)));
- set_has_talkerviplevel();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(56)) goto parse_hasMonthCard;
- break;
- }
- // optional bool hasMonthCard = 7;
- case 7: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_hasMonthCard:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
- input, &hasmonthcard_)));
- set_has_hasmonthcard();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(64)) goto parse_repCount;
- break;
- }
- // optional int32 repCount = 8 [default = 1];
- case 8: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_repCount:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, &repcount_)));
- set_has_repcount();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(72)) goto parse_interval;
- break;
- }
- // optional int32 interval = 9 [default = 0];
- case 9: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_interval:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, &interval_)));
- set_has_interval();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectTag(80)) goto parse_showPos;
- break;
- }
- // optional int32 showPos = 10;
- case 10: {
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
- parse_showPos:
- DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
- ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
- input, &showpos_)));
- set_has_showpos();
- } else {
- goto handle_uninterpreted;
- }
- if (input->ExpectAtEnd()) return true;
- break;
- }
- default: {
- handle_uninterpreted:
- if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
- ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
- return true;
- }
- DO_(::google::protobuf::internal::WireFormat::SkipField(
- input, tag, mutable_unknown_fields()));
- break;
- }
- }
- }
- return true;
- #undef DO_
- }
- void packetw2c_notify::SerializeWithCachedSizes(
- ::google::protobuf::io::CodedOutputStream* output) const {
- // optional .client2world_protocols.e_server_msg_type packet_id = 1 [default = e_mst_w2c_notify];
- if (has_packet_id()) {
- ::google::protobuf::internal::WireFormatLite::WriteEnum(
- 1, this->packet_id(), output);
- }
- // optional string content = 2;
- if (has_content()) {
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->content().data(), this->content().length(),
- ::google::protobuf::internal::WireFormat::SERIALIZE);
- ::google::protobuf::internal::WireFormatLite::WriteString(
- 2, this->content(), output);
- }
- // optional int32 notifyType = 3;
- if (has_notifytype()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->notifytype(), output);
- }
- // optional string talkerNickName = 4;
- if (has_talkernickname()) {
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->talkernickname().data(), this->talkernickname().length(),
- ::google::protobuf::internal::WireFormat::SERIALIZE);
- ::google::protobuf::internal::WireFormatLite::WriteString(
- 4, this->talkernickname(), output);
- }
- // optional int32 playerId = 5;
- if (has_playerid()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->playerid(), output);
- }
- // optional int32 talkerVIPLevel = 6;
- if (has_talkerviplevel()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(6, this->talkerviplevel(), output);
- }
- // optional bool hasMonthCard = 7;
- if (has_hasmonthcard()) {
- ::google::protobuf::internal::WireFormatLite::WriteBool(7, this->hasmonthcard(), output);
- }
- // optional int32 repCount = 8 [default = 1];
- if (has_repcount()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(8, this->repcount(), output);
- }
- // optional int32 interval = 9 [default = 0];
- if (has_interval()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(9, this->interval(), output);
- }
- // optional int32 showPos = 10;
- if (has_showpos()) {
- ::google::protobuf::internal::WireFormatLite::WriteInt32(10, this->showpos(), output);
- }
- if (!unknown_fields().empty()) {
- ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
- unknown_fields(), output);
- }
- }
- ::google::protobuf::uint8* packetw2c_notify::SerializeWithCachedSizesToArray(
- ::google::protobuf::uint8* target) const {
- // optional .client2world_protocols.e_server_msg_type packet_id = 1 [default = e_mst_w2c_notify];
- if (has_packet_id()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
- 1, this->packet_id(), target);
- }
- // optional string content = 2;
- if (has_content()) {
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->content().data(), this->content().length(),
- ::google::protobuf::internal::WireFormat::SERIALIZE);
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 2, this->content(), target);
- }
- // optional int32 notifyType = 3;
- if (has_notifytype()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->notifytype(), target);
- }
- // optional string talkerNickName = 4;
- if (has_talkernickname()) {
- ::google::protobuf::internal::WireFormat::VerifyUTF8String(
- this->talkernickname().data(), this->talkernickname().length(),
- ::google::protobuf::internal::WireFormat::SERIALIZE);
- target =
- ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
- 4, this->talkernickname(), target);
- }
- // optional int32 playerId = 5;
- if (has_playerid()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(5, this->playerid(), target);
- }
- // optional int32 talkerVIPLevel = 6;
- if (has_talkerviplevel()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(6, this->talkerviplevel(), target);
- }
- // optional bool hasMonthCard = 7;
- if (has_hasmonthcard()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(7, this->hasmonthcard(), target);
- }
- // optional int32 repCount = 8 [default = 1];
- if (has_repcount()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(8, this->repcount(), target);
- }
- // optional int32 interval = 9 [default = 0];
- if (has_interval()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(9, this->interval(), target);
- }
- // optional int32 showPos = 10;
- if (has_showpos()) {
- target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(10, this->showpos(), target);
- }
- if (!unknown_fields().empty()) {
- target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
- unknown_fields(), target);
- }
- return target;
- }
- int packetw2c_notify::ByteSize() const {
- int total_size = 0;
- if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
- // optional .client2world_protocols.e_server_msg_type packet_id = 1 [default = e_mst_w2c_notify];
- if (has_packet_id()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::EnumSize(this->packet_id());
- }
- // optional string content = 2;
- if (has_content()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->content());
- }
- // optional int32 notifyType = 3;
- if (has_notifytype()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->notifytype());
- }
- // optional string talkerNickName = 4;
- if (has_talkernickname()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::StringSize(
- this->talkernickname());
- }
- // optional int32 playerId = 5;
- if (has_playerid()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->playerid());
- }
- // optional int32 talkerVIPLevel = 6;
- if (has_talkerviplevel()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->talkerviplevel());
- }
- // optional bool hasMonthCard = 7;
- if (has_hasmonthcard()) {
- total_size += 1 + 1;
- }
- // optional int32 repCount = 8 [default = 1];
- if (has_repcount()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->repcount());
- }
- }
- if (_has_bits_[8 / 32] & (0xffu << (8 % 32))) {
- // optional int32 interval = 9 [default = 0];
- if (has_interval()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->interval());
- }
- // optional int32 showPos = 10;
- if (has_showpos()) {
- total_size += 1 +
- ::google::protobuf::internal::WireFormatLite::Int32Size(
- this->showpos());
- }
- }
- if (!unknown_fields().empty()) {
- total_size +=
- ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
- unknown_fields());
- }
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = total_size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
- return total_size;
- }
- void packetw2c_notify::MergeFrom(const ::google::protobuf::Message& from) {
- GOOGLE_CHECK_NE(&from, this);
- const packetw2c_notify* source =
- ::google::protobuf::internal::dynamic_cast_if_available<const packetw2c_notify*>(
- &from);
- if (source == NULL) {
- ::google::protobuf::internal::ReflectionOps::Merge(from, this);
- } else {
- MergeFrom(*source);
- }
- }
- void packetw2c_notify::MergeFrom(const packetw2c_notify& from) {
- GOOGLE_CHECK_NE(&from, this);
- if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
- if (from.has_packet_id()) {
- set_packet_id(from.packet_id());
- }
- if (from.has_content()) {
- set_content(from.content());
- }
- if (from.has_notifytype()) {
- set_notifytype(from.notifytype());
- }
- if (from.has_talkernickname()) {
- set_talkernickname(from.talkernickname());
- }
- if (from.has_playerid()) {
- set_playerid(from.playerid());
- }
- if (from.has_talkerviplevel()) {
- set_talkerviplevel(from.talkerviplevel());
- }
- if (from.has_hasmonthcard()) {
- set_hasmonthcard(from.hasmonthcard());
- }
- if (from.has_repcount()) {
- set_repcount(from.repcount());
- }
- }
- if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
- if (from.has_interval()) {
- set_interval(from.interval());
- }
- if (from.has_showpos()) {
- set_showpos(from.showpos());
- }
- }
- mutable_unknown_fields()->MergeFrom(from.unknown_fields());
- }
- void packetw2c_notify::CopyFrom(const ::google::protobuf::Message& from) {
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- void packetw2c_notify::CopyFrom(const packetw2c_notify& from) {
- if (&from == this) return;
- Clear();
- MergeFrom(from);
- }
- bool packetw2c_notify::IsInitialized() const {
- return true;
- }
- void packetw2c_notify::Swap(packetw2c_notify* other) {
- if (other != this) {
- std::swap(packet_id_, other->packet_id_);
- std::swap(content_, other->content_);
- std::swap(notifytype_, other->notifytype_);
- std::swap(talkernickname_, other->talkernickname_);
- std::swap(playerid_, other->playerid_);
- std::swap(talkerviplevel_, other->talkerviplevel_);
- std::swap(hasmonthcard_, other->hasmonthcard_);
- std::swap(repcount_, other->repcount_);
- std::swap(interval_, other->interval_);
- std::swap(showpos_, other->showpos_);
- std::swap(_has_bits_[0], other->_has_bits_[0]);
- _unknown_fields_.Swap(&other->_unknown_fields_);
- std::swap(_cached_size_, other->_cached_size_);
- }
- }
- ::google::protobuf::Metadata packetw2c_notify::GetMetadata() const {
- protobuf_AssignDescriptorsOnce();
- ::google::protobuf::Metadata metadata;
- metadata.descriptor = packetw2c_notify_descriptor_;
- metadata.reflection = packetw2c_notify_reflection_;
- return metadata;
- }
- // @@protoc_insertion_point(namespace_scope)
- } // namespace client2world_protocols
- // @@protoc_insertion_point(global_scope)
|