// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: client2gate_protocol.proto

#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "client2gate_protocol.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 client2gate_protocols {

namespace {

const ::google::protobuf::Descriptor* packetc2g_heartbeat_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  packetc2g_heartbeat_reflection_ = NULL;
const ::google::protobuf::Descriptor* packetg2c_heartbeat_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  packetg2c_heartbeat_reflection_ = NULL;
const ::google::protobuf::Descriptor* msg_packet_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  msg_packet_reflection_ = NULL;
const ::google::protobuf::Descriptor* packet_g2c_send_msglist_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
  packet_g2c_send_msglist_reflection_ = NULL;

}  // namespace


void protobuf_AssignDesc_client2gate_5fprotocol_2eproto() {
  protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  const ::google::protobuf::FileDescriptor* file =
    ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
      "client2gate_protocol.proto");
  GOOGLE_CHECK(file != NULL);
  packetc2g_heartbeat_descriptor_ = file->message_type(0);
  static const int packetc2g_heartbeat_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetc2g_heartbeat, packet_id_),
  };
  packetc2g_heartbeat_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      packetc2g_heartbeat_descriptor_,
      packetc2g_heartbeat::default_instance_,
      packetc2g_heartbeat_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetc2g_heartbeat, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetc2g_heartbeat, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(packetc2g_heartbeat));
  packetg2c_heartbeat_descriptor_ = file->message_type(1);
  static const int packetg2c_heartbeat_offsets_[1] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetg2c_heartbeat, packet_id_),
  };
  packetg2c_heartbeat_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      packetg2c_heartbeat_descriptor_,
      packetg2c_heartbeat::default_instance_,
      packetg2c_heartbeat_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetg2c_heartbeat, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packetg2c_heartbeat, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(packetg2c_heartbeat));
  msg_packet_descriptor_ = file->message_type(2);
  static const int msg_packet_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(msg_packet, msgid_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(msg_packet, msginfo_),
  };
  msg_packet_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      msg_packet_descriptor_,
      msg_packet::default_instance_,
      msg_packet_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(msg_packet, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(msg_packet, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(msg_packet));
  packet_g2c_send_msglist_descriptor_ = file->message_type(3);
  static const int packet_g2c_send_msglist_offsets_[2] = {
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packet_g2c_send_msglist, packet_id_),
    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packet_g2c_send_msglist, msgpaks_),
  };
  packet_g2c_send_msglist_reflection_ =
    new ::google::protobuf::internal::GeneratedMessageReflection(
      packet_g2c_send_msglist_descriptor_,
      packet_g2c_send_msglist::default_instance_,
      packet_g2c_send_msglist_offsets_,
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packet_g2c_send_msglist, _has_bits_[0]),
      GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(packet_g2c_send_msglist, _unknown_fields_),
      -1,
      ::google::protobuf::DescriptorPool::generated_pool(),
      ::google::protobuf::MessageFactory::generated_factory(),
      sizeof(packet_g2c_send_msglist));
}

namespace {

GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
inline void protobuf_AssignDescriptorsOnce() {
  ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
                 &protobuf_AssignDesc_client2gate_5fprotocol_2eproto);
}

void protobuf_RegisterTypes(const ::std::string&) {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    packetc2g_heartbeat_descriptor_, &packetc2g_heartbeat::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    packetg2c_heartbeat_descriptor_, &packetg2c_heartbeat::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    msg_packet_descriptor_, &msg_packet::default_instance());
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
    packet_g2c_send_msglist_descriptor_, &packet_g2c_send_msglist::default_instance());
}

}  // namespace

void protobuf_ShutdownFile_client2gate_5fprotocol_2eproto() {
  delete packetc2g_heartbeat::default_instance_;
  delete packetc2g_heartbeat_reflection_;
  delete packetg2c_heartbeat::default_instance_;
  delete packetg2c_heartbeat_reflection_;
  delete msg_packet::default_instance_;
  delete msg_packet_reflection_;
  delete packet_g2c_send_msglist::default_instance_;
  delete packet_g2c_send_msglist_reflection_;
}

void protobuf_AddDesc_client2gate_5fprotocol_2eproto() {
  static bool already_here = false;
  if (already_here) return;
  already_here = true;
  GOOGLE_PROTOBUF_VERIFY_VERSION;

  ::client2gate_protocols::protobuf_AddDesc_client2gate_5fmsg_5ftype_2eproto();
  ::msg_type_def::protobuf_AddDesc_msg_5ftype_5fdef_2eproto();
  ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
    "\n\032client2gate_protocol.proto\022\025client2gat"
    "e_protocols\032\032client2gate_msg_type.proto\032"
    "\022msg_type_def.proto\"g\n\023packetc2g_heartbe"
    "at\022P\n\tpacket_id\030\001 \001(\0162(.client2gate_prot"
    "ocols.e_server_msg_type:\023e_mst_c2g_heart"
    "beat\"g\n\023packetg2c_heartbeat\022P\n\tpacket_id"
    "\030\001 \001(\0162(.client2gate_protocols.e_server_"
    "msg_type:\023e_mst_g2c_heartbeat\",\n\nmsg_pac"
    "ket\022\r\n\005msgid\030\001 \001(\005\022\017\n\007msginfo\030\002 \001(\014\"\242\001\n\027"
    "packet_g2c_send_msglist\022S\n\tpacket_id\030\001 \001"
    "(\0162(.client2gate_protocols.e_server_msg_"
    "type:\026e_mst_g2c_send_msglist\0222\n\007msgpaks\030"
    "\003 \003(\0132!.client2gate_protocols.msg_packet", 520);
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
    "client2gate_protocol.proto", &protobuf_RegisterTypes);
  packetc2g_heartbeat::default_instance_ = new packetc2g_heartbeat();
  packetg2c_heartbeat::default_instance_ = new packetg2c_heartbeat();
  msg_packet::default_instance_ = new msg_packet();
  packet_g2c_send_msglist::default_instance_ = new packet_g2c_send_msglist();
  packetc2g_heartbeat::default_instance_->InitAsDefaultInstance();
  packetg2c_heartbeat::default_instance_->InitAsDefaultInstance();
  msg_packet::default_instance_->InitAsDefaultInstance();
  packet_g2c_send_msglist::default_instance_->InitAsDefaultInstance();
  ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_client2gate_5fprotocol_2eproto);
}

// Force AddDescriptors() to be called at static initialization time.
struct StaticDescriptorInitializer_client2gate_5fprotocol_2eproto {
  StaticDescriptorInitializer_client2gate_5fprotocol_2eproto() {
    protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  }
} static_descriptor_initializer_client2gate_5fprotocol_2eproto_;

// ===================================================================

#ifndef _MSC_VER
const int packetc2g_heartbeat::kPacketIdFieldNumber;
#endif  // !_MSC_VER

packetc2g_heartbeat::packetc2g_heartbeat()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void packetc2g_heartbeat::InitAsDefaultInstance() {
}

packetc2g_heartbeat::packetc2g_heartbeat(const packetc2g_heartbeat& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void packetc2g_heartbeat::SharedCtor() {
  _cached_size_ = 0;
  packet_id_ = 301;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

packetc2g_heartbeat::~packetc2g_heartbeat() {
  SharedDtor();
}

void packetc2g_heartbeat::SharedDtor() {
  if (this != default_instance_) {
  }
}

void packetc2g_heartbeat::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* packetc2g_heartbeat::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return packetc2g_heartbeat_descriptor_;
}

const packetc2g_heartbeat& packetc2g_heartbeat::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  return *default_instance_;
}

packetc2g_heartbeat* packetc2g_heartbeat::default_instance_ = NULL;

packetc2g_heartbeat* packetc2g_heartbeat::New() const {
  return new packetc2g_heartbeat;
}

void packetc2g_heartbeat::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    packet_id_ = 301;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool packetc2g_heartbeat::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 .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_c2g_heartbeat];
      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 (::client2gate_protocols::e_server_msg_type_IsValid(value)) {
            set_packet_id(static_cast< ::client2gate_protocols::e_server_msg_type >(value));
          } else {
            mutable_unknown_fields()->AddVarint(1, value);
          }
        } 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 packetc2g_heartbeat::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_c2g_heartbeat];
  if (has_packet_id()) {
    ::google::protobuf::internal::WireFormatLite::WriteEnum(
      1, this->packet_id(), output);
  }

  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* packetc2g_heartbeat::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_c2g_heartbeat];
  if (has_packet_id()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
      1, this->packet_id(), target);
  }

  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int packetc2g_heartbeat::ByteSize() const {
  int total_size = 0;

  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_c2g_heartbeat];
    if (has_packet_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::EnumSize(this->packet_id());
    }

  }
  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 packetc2g_heartbeat::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const packetc2g_heartbeat* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const packetc2g_heartbeat*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void packetc2g_heartbeat::MergeFrom(const packetc2g_heartbeat& 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());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void packetc2g_heartbeat::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void packetc2g_heartbeat::CopyFrom(const packetc2g_heartbeat& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool packetc2g_heartbeat::IsInitialized() const {

  return true;
}

void packetc2g_heartbeat::Swap(packetc2g_heartbeat* other) {
  if (other != this) {
    std::swap(packet_id_, other->packet_id_);
    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 packetc2g_heartbeat::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = packetc2g_heartbeat_descriptor_;
  metadata.reflection = packetc2g_heartbeat_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int packetg2c_heartbeat::kPacketIdFieldNumber;
#endif  // !_MSC_VER

packetg2c_heartbeat::packetg2c_heartbeat()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void packetg2c_heartbeat::InitAsDefaultInstance() {
}

packetg2c_heartbeat::packetg2c_heartbeat(const packetg2c_heartbeat& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void packetg2c_heartbeat::SharedCtor() {
  _cached_size_ = 0;
  packet_id_ = 403;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

packetg2c_heartbeat::~packetg2c_heartbeat() {
  SharedDtor();
}

void packetg2c_heartbeat::SharedDtor() {
  if (this != default_instance_) {
  }
}

void packetg2c_heartbeat::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* packetg2c_heartbeat::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return packetg2c_heartbeat_descriptor_;
}

const packetg2c_heartbeat& packetg2c_heartbeat::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  return *default_instance_;
}

packetg2c_heartbeat* packetg2c_heartbeat::default_instance_ = NULL;

packetg2c_heartbeat* packetg2c_heartbeat::New() const {
  return new packetg2c_heartbeat;
}

void packetg2c_heartbeat::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    packet_id_ = 403;
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool packetg2c_heartbeat::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 .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_heartbeat];
      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 (::client2gate_protocols::e_server_msg_type_IsValid(value)) {
            set_packet_id(static_cast< ::client2gate_protocols::e_server_msg_type >(value));
          } else {
            mutable_unknown_fields()->AddVarint(1, value);
          }
        } 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 packetg2c_heartbeat::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_heartbeat];
  if (has_packet_id()) {
    ::google::protobuf::internal::WireFormatLite::WriteEnum(
      1, this->packet_id(), output);
  }

  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* packetg2c_heartbeat::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_heartbeat];
  if (has_packet_id()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
      1, this->packet_id(), target);
  }

  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int packetg2c_heartbeat::ByteSize() const {
  int total_size = 0;

  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_heartbeat];
    if (has_packet_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::EnumSize(this->packet_id());
    }

  }
  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 packetg2c_heartbeat::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const packetg2c_heartbeat* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const packetg2c_heartbeat*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void packetg2c_heartbeat::MergeFrom(const packetg2c_heartbeat& 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());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void packetg2c_heartbeat::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void packetg2c_heartbeat::CopyFrom(const packetg2c_heartbeat& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool packetg2c_heartbeat::IsInitialized() const {

  return true;
}

void packetg2c_heartbeat::Swap(packetg2c_heartbeat* other) {
  if (other != this) {
    std::swap(packet_id_, other->packet_id_);
    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 packetg2c_heartbeat::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = packetg2c_heartbeat_descriptor_;
  metadata.reflection = packetg2c_heartbeat_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int msg_packet::kMsgidFieldNumber;
const int msg_packet::kMsginfoFieldNumber;
#endif  // !_MSC_VER

msg_packet::msg_packet()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void msg_packet::InitAsDefaultInstance() {
}

msg_packet::msg_packet(const msg_packet& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void msg_packet::SharedCtor() {
  _cached_size_ = 0;
  msgid_ = 0;
  msginfo_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString);
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

msg_packet::~msg_packet() {
  SharedDtor();
}

void msg_packet::SharedDtor() {
  if (msginfo_ != &::google::protobuf::internal::kEmptyString) {
    delete msginfo_;
  }
  if (this != default_instance_) {
  }
}

void msg_packet::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* msg_packet::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return msg_packet_descriptor_;
}

const msg_packet& msg_packet::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  return *default_instance_;
}

msg_packet* msg_packet::default_instance_ = NULL;

msg_packet* msg_packet::New() const {
  return new msg_packet;
}

void msg_packet::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    msgid_ = 0;
    if (has_msginfo()) {
      if (msginfo_ != &::google::protobuf::internal::kEmptyString) {
        msginfo_->clear();
      }
    }
  }
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool msg_packet::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 int32 msgid = 1;
      case 1: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &msgid_)));
          set_has_msgid();
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(18)) goto parse_msginfo;
        break;
      }

      // optional bytes msginfo = 2;
      case 2: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
         parse_msginfo:
          DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
                input, this->mutable_msginfo()));
        } 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 msg_packet::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // optional int32 msgid = 1;
  if (has_msgid()) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->msgid(), output);
  }

  // optional bytes msginfo = 2;
  if (has_msginfo()) {
    ::google::protobuf::internal::WireFormatLite::WriteBytes(
      2, this->msginfo(), output);
  }

  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* msg_packet::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // optional int32 msgid = 1;
  if (has_msgid()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->msgid(), target);
  }

  // optional bytes msginfo = 2;
  if (has_msginfo()) {
    target =
      ::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
        2, this->msginfo(), target);
  }

  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int msg_packet::ByteSize() const {
  int total_size = 0;

  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // optional int32 msgid = 1;
    if (has_msgid()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->msgid());
    }

    // optional bytes msginfo = 2;
    if (has_msginfo()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::BytesSize(
          this->msginfo());
    }

  }
  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 msg_packet::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const msg_packet* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const msg_packet*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void msg_packet::MergeFrom(const msg_packet& from) {
  GOOGLE_CHECK_NE(&from, this);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_msgid()) {
      set_msgid(from.msgid());
    }
    if (from.has_msginfo()) {
      set_msginfo(from.msginfo());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void msg_packet::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void msg_packet::CopyFrom(const msg_packet& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool msg_packet::IsInitialized() const {

  return true;
}

void msg_packet::Swap(msg_packet* other) {
  if (other != this) {
    std::swap(msgid_, other->msgid_);
    std::swap(msginfo_, other->msginfo_);
    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 msg_packet::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = msg_packet_descriptor_;
  metadata.reflection = msg_packet_reflection_;
  return metadata;
}


// ===================================================================

#ifndef _MSC_VER
const int packet_g2c_send_msglist::kPacketIdFieldNumber;
const int packet_g2c_send_msglist::kMsgpaksFieldNumber;
#endif  // !_MSC_VER

packet_g2c_send_msglist::packet_g2c_send_msglist()
  : ::google::protobuf::Message() {
  SharedCtor();
}

void packet_g2c_send_msglist::InitAsDefaultInstance() {
}

packet_g2c_send_msglist::packet_g2c_send_msglist(const packet_g2c_send_msglist& from)
  : ::google::protobuf::Message() {
  SharedCtor();
  MergeFrom(from);
}

void packet_g2c_send_msglist::SharedCtor() {
  _cached_size_ = 0;
  packet_id_ = 402;
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
}

packet_g2c_send_msglist::~packet_g2c_send_msglist() {
  SharedDtor();
}

void packet_g2c_send_msglist::SharedDtor() {
  if (this != default_instance_) {
  }
}

void packet_g2c_send_msglist::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* packet_g2c_send_msglist::descriptor() {
  protobuf_AssignDescriptorsOnce();
  return packet_g2c_send_msglist_descriptor_;
}

const packet_g2c_send_msglist& packet_g2c_send_msglist::default_instance() {
  if (default_instance_ == NULL) protobuf_AddDesc_client2gate_5fprotocol_2eproto();
  return *default_instance_;
}

packet_g2c_send_msglist* packet_g2c_send_msglist::default_instance_ = NULL;

packet_g2c_send_msglist* packet_g2c_send_msglist::New() const {
  return new packet_g2c_send_msglist;
}

void packet_g2c_send_msglist::Clear() {
  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    packet_id_ = 402;
  }
  msgpaks_.Clear();
  ::memset(_has_bits_, 0, sizeof(_has_bits_));
  mutable_unknown_fields()->Clear();
}

bool packet_g2c_send_msglist::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 .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_send_msglist];
      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 (::client2gate_protocols::e_server_msg_type_IsValid(value)) {
            set_packet_id(static_cast< ::client2gate_protocols::e_server_msg_type >(value));
          } else {
            mutable_unknown_fields()->AddVarint(1, value);
          }
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(26)) goto parse_msgpaks;
        break;
      }

      // repeated .client2gate_protocols.msg_packet msgpaks = 3;
      case 3: {
        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
            ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) {
         parse_msgpaks:
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
                input, add_msgpaks()));
        } else {
          goto handle_uninterpreted;
        }
        if (input->ExpectTag(26)) goto parse_msgpaks;
        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 packet_g2c_send_msglist::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_send_msglist];
  if (has_packet_id()) {
    ::google::protobuf::internal::WireFormatLite::WriteEnum(
      1, this->packet_id(), output);
  }

  // repeated .client2gate_protocols.msg_packet msgpaks = 3;
  for (int i = 0; i < this->msgpaks_size(); i++) {
    ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
      3, this->msgpaks(i), output);
  }

  if (!unknown_fields().empty()) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        unknown_fields(), output);
  }
}

::google::protobuf::uint8* packet_g2c_send_msglist::SerializeWithCachedSizesToArray(
    ::google::protobuf::uint8* target) const {
  // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_send_msglist];
  if (has_packet_id()) {
    target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
      1, this->packet_id(), target);
  }

  // repeated .client2gate_protocols.msg_packet msgpaks = 3;
  for (int i = 0; i < this->msgpaks_size(); i++) {
    target = ::google::protobuf::internal::WireFormatLite::
      WriteMessageNoVirtualToArray(
        3, this->msgpaks(i), target);
  }

  if (!unknown_fields().empty()) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        unknown_fields(), target);
  }
  return target;
}

int packet_g2c_send_msglist::ByteSize() const {
  int total_size = 0;

  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    // optional .client2gate_protocols.e_server_msg_type packet_id = 1 [default = e_mst_g2c_send_msglist];
    if (has_packet_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::EnumSize(this->packet_id());
    }

  }
  // repeated .client2gate_protocols.msg_packet msgpaks = 3;
  total_size += 1 * this->msgpaks_size();
  for (int i = 0; i < this->msgpaks_size(); i++) {
    total_size +=
      ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
        this->msgpaks(i));
  }

  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 packet_g2c_send_msglist::MergeFrom(const ::google::protobuf::Message& from) {
  GOOGLE_CHECK_NE(&from, this);
  const packet_g2c_send_msglist* source =
    ::google::protobuf::internal::dynamic_cast_if_available<const packet_g2c_send_msglist*>(
      &from);
  if (source == NULL) {
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
    MergeFrom(*source);
  }
}

void packet_g2c_send_msglist::MergeFrom(const packet_g2c_send_msglist& from) {
  GOOGLE_CHECK_NE(&from, this);
  msgpaks_.MergeFrom(from.msgpaks_);
  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
    if (from.has_packet_id()) {
      set_packet_id(from.packet_id());
    }
  }
  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
}

void packet_g2c_send_msglist::CopyFrom(const ::google::protobuf::Message& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void packet_g2c_send_msglist::CopyFrom(const packet_g2c_send_msglist& from) {
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool packet_g2c_send_msglist::IsInitialized() const {

  return true;
}

void packet_g2c_send_msglist::Swap(packet_g2c_send_msglist* other) {
  if (other != this) {
    std::swap(packet_id_, other->packet_id_);
    msgpaks_.Swap(&other->msgpaks_);
    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 packet_g2c_send_msglist::GetMetadata() const {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::Metadata metadata;
  metadata.descriptor = packet_g2c_send_msglist_descriptor_;
  metadata.reflection = packet_g2c_send_msglist_reflection_;
  return metadata;
}


// @@protoc_insertion_point(namespace_scope)

}  // namespace client2gate_protocols

// @@protoc_insertion_point(global_scope)
