// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: client/v3beta/dto/channel/model/channel_model.proto

#include "client/v3beta/dto/channel/model/channel_model.pb.h"

#include <algorithm>

#include <herogoogle/protobuf/io/coded_stream.h>
#include <herogoogle/protobuf/extension_set.h>
#include <herogoogle/protobuf/wire_format_lite.h>
#include <herogoogle/protobuf/descriptor.h>
#include <herogoogle/protobuf/generated_message_reflection.h>
#include <herogoogle/protobuf/reflection_ops.h>
#include <herogoogle/protobuf/wire_format.h>
// @@protoc_insertion_point(includes)


PROTOBUF_PRAGMA_INIT_SEG
namespace heroim {
namespace client {
namespace v3beta {
namespace dto {
namespace channel {
namespace model {
constexpr Channel::Channel(
  ::herogoogle::protobuf::internal::ConstantInitialized)
  : channelid_(&::herogoogle::protobuf::internal::fixed_address_empty_string)
  , title_(&::herogoogle::protobuf::internal::fixed_address_empty_string)
  , iconurl_(&::herogoogle::protobuf::internal::fixed_address_empty_string){}
struct ChannelDefaultTypeInternal {
  constexpr ChannelDefaultTypeInternal()
    : _instance(::herogoogle::protobuf::internal::ConstantInitialized{}) {}
  ~ChannelDefaultTypeInternal() {}
  union {
    Channel _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT ChannelDefaultTypeInternal _Channel_default_instance_;
}  // namespace model
}  // namespace channel
}  // namespace dto
}  // namespace v3beta
}  // namespace client
}  // namespace heroim
static ::herogoogle::protobuf::Metadata file_level_metadata_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto[1];
static constexpr ::herogoogle::protobuf::EnumDescriptor const** file_level_enum_descriptors_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto = nullptr;
static constexpr ::herogoogle::protobuf::ServiceDescriptor const** file_level_service_descriptors_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto = nullptr;

const ::herogoogle::protobuf::uint32 TableStruct_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::heroim::client::v3beta::dto::channel::model::Channel, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  ~0u,  // no _inlined_string_donated_
  PROTOBUF_FIELD_OFFSET(::heroim::client::v3beta::dto::channel::model::Channel, channelid_),
  PROTOBUF_FIELD_OFFSET(::heroim::client::v3beta::dto::channel::model::Channel, title_),
  PROTOBUF_FIELD_OFFSET(::heroim::client::v3beta::dto::channel::model::Channel, iconurl_),
};
static const ::herogoogle::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  { 0, -1, -1, sizeof(::heroim::client::v3beta::dto::channel::model::Channel)},
};

static ::herogoogle::protobuf::Message const * const file_default_instances[] = {
  reinterpret_cast<const ::herogoogle::protobuf::Message*>(&::heroim::client::v3beta::dto::channel::model::_Channel_default_instance_),
};
#ifdef _MSC_VER
#  pragma warning(disable : 4125)
#endif  /* _MSC_VER */
const char descriptor_table_protodef_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) =
  "\n3client/v3beta/dto/channel/model/channe"
  "l_model.proto\022&heroim.client.v3beta.dto."
  "channel.model\"<\n\007Channel\022\021\n\tchannelId\030\001 "
  "\001(\t\022\r\n\005title\030\002 \001(\t\022\017\n\007iconUrl\030\003 \001(\tB\222\001\n*"
  "com.hero.csdk.api.v3beta.dto.channel.mod"
  "elP\001Z*heroim/api/client/v3beta/dto/chann"
  "el/model\252\0025Im.CSDK.Unity.chat.entry.Runt"
  "ime.entry2.channel.modelb\006proto3"
  ;
static ::herogoogle::protobuf::internal::once_flag descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto_once;
const ::herogoogle::protobuf::internal::DescriptorTable descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto = {
  false, false, 312, descriptor_table_protodef_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto, "client/v3beta/dto/channel/model/channel_model.proto", 
  &descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto_once, nullptr, 0, 1,
  schemas, file_default_instances, TableStruct_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto::offsets,
  file_level_metadata_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto, file_level_enum_descriptors_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto, file_level_service_descriptors_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto,
};
PROTOBUF_ATTRIBUTE_WEAK const ::herogoogle::protobuf::internal::DescriptorTable* descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto_getter() {
  return &descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto;
}

// Force running AddDescriptors() at dynamic initialization time.
PROTOBUF_ATTRIBUTE_INIT_PRIORITY static ::herogoogle::protobuf::internal::AddDescriptorsRunner dynamic_init_dummy_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto(&descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto);
namespace heroim {
namespace client {
namespace v3beta {
namespace dto {
namespace channel {
namespace model {

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

class Channel::_Internal {
 public:
};

Channel::Channel(::herogoogle::protobuf::Arena* arena,
                         bool is_message_owned)
  : ::herogoogle::protobuf::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:heroim.client.v3beta.dto.channel.model.Channel)
}
Channel::Channel(const Channel& from)
  : ::herogoogle::protobuf::Message() {
  _internal_metadata_.MergeFrom<::herogoogle::protobuf::UnknownFieldSet>(from._internal_metadata_);
  channelid_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_channelid().empty()) {
    channelid_.Set(::herogoogle::protobuf::internal::ArenaStringPtr::EmptyDefault{}, from._internal_channelid(), 
      GetArenaForAllocation());
  }
  title_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_title().empty()) {
    title_.Set(::herogoogle::protobuf::internal::ArenaStringPtr::EmptyDefault{}, from._internal_title(), 
      GetArenaForAllocation());
  }
  iconurl_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_iconurl().empty()) {
    iconurl_.Set(::herogoogle::protobuf::internal::ArenaStringPtr::EmptyDefault{}, from._internal_iconurl(), 
      GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:heroim.client.v3beta.dto.channel.model.Channel)
}

void Channel::SharedCtor() {
channelid_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
title_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
iconurl_.UnsafeSetDefault(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
}

Channel::~Channel() {
  // @@protoc_insertion_point(destructor:heroim.client.v3beta.dto.channel.model.Channel)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::herogoogle::protobuf::UnknownFieldSet>();
}

inline void Channel::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  channelid_.DestroyNoArena(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
  title_.DestroyNoArena(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
  iconurl_.DestroyNoArena(&::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited());
}

void Channel::ArenaDtor(void* object) {
  Channel* _this = reinterpret_cast< Channel* >(object);
  (void)_this;
}
void Channel::RegisterArenaDtor(::herogoogle::protobuf::Arena*) {
}
void Channel::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void Channel::Clear() {
// @@protoc_insertion_point(message_clear_start:heroim.client.v3beta.dto.channel.model.Channel)
  ::herogoogle::protobuf::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  channelid_.ClearToEmpty();
  title_.ClearToEmpty();
  iconurl_.ClearToEmpty();
  _internal_metadata_.Clear<::herogoogle::protobuf::UnknownFieldSet>();
}

const char* Channel::_InternalParse(const char* ptr, ::herogoogle::protobuf::internal::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::herogoogle::protobuf::uint32 tag;
    ptr = ::herogoogle::protobuf::internal::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // string channelId = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::herogoogle::protobuf::uint8>(tag) == 10)) {
          auto str = _internal_mutable_channelid();
          ptr = ::herogoogle::protobuf::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::herogoogle::protobuf::internal::VerifyUTF8(str, "heroim.client.v3beta.dto.channel.model.Channel.channelId"));
          CHK_(ptr);
        } else
          goto handle_unusual;
        continue;
      // string title = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::herogoogle::protobuf::uint8>(tag) == 18)) {
          auto str = _internal_mutable_title();
          ptr = ::herogoogle::protobuf::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::herogoogle::protobuf::internal::VerifyUTF8(str, "heroim.client.v3beta.dto.channel.model.Channel.title"));
          CHK_(ptr);
        } else
          goto handle_unusual;
        continue;
      // string iconUrl = 3;
      case 3:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::herogoogle::protobuf::uint8>(tag) == 26)) {
          auto str = _internal_mutable_iconurl();
          ptr = ::herogoogle::protobuf::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::herogoogle::protobuf::internal::VerifyUTF8(str, "heroim.client.v3beta.dto.channel.model.Channel.iconUrl"));
          CHK_(ptr);
        } else
          goto handle_unusual;
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<::herogoogle::protobuf::UnknownFieldSet>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::herogoogle::protobuf::uint8* Channel::_InternalSerialize(
    ::herogoogle::protobuf::uint8* target, ::herogoogle::protobuf::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:heroim.client.v3beta.dto.channel.model.Channel)
  ::herogoogle::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // string channelId = 1;
  if (!this->_internal_channelid().empty()) {
    ::herogoogle::protobuf::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_channelid().data(), static_cast<int>(this->_internal_channelid().length()),
      ::herogoogle::protobuf::internal::WireFormatLite::SERIALIZE,
      "heroim.client.v3beta.dto.channel.model.Channel.channelId");
    target = stream->WriteStringMaybeAliased(
        1, this->_internal_channelid(), target);
  }

  // string title = 2;
  if (!this->_internal_title().empty()) {
    ::herogoogle::protobuf::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_title().data(), static_cast<int>(this->_internal_title().length()),
      ::herogoogle::protobuf::internal::WireFormatLite::SERIALIZE,
      "heroim.client.v3beta.dto.channel.model.Channel.title");
    target = stream->WriteStringMaybeAliased(
        2, this->_internal_title(), target);
  }

  // string iconUrl = 3;
  if (!this->_internal_iconurl().empty()) {
    ::herogoogle::protobuf::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_iconurl().data(), static_cast<int>(this->_internal_iconurl().length()),
      ::herogoogle::protobuf::internal::WireFormatLite::SERIALIZE,
      "heroim.client.v3beta.dto.channel.model.Channel.iconUrl");
    target = stream->WriteStringMaybeAliased(
        3, this->_internal_iconurl(), target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = ::herogoogle::protobuf::internal::WireFormat::InternalSerializeUnknownFieldsToArray(
        _internal_metadata_.unknown_fields<::herogoogle::protobuf::UnknownFieldSet>(::herogoogle::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:heroim.client.v3beta.dto.channel.model.Channel)
  return target;
}

size_t Channel::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:heroim.client.v3beta.dto.channel.model.Channel)
  size_t total_size = 0;

  ::herogoogle::protobuf::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // string channelId = 1;
  if (!this->_internal_channelid().empty()) {
    total_size += 1 +
      ::herogoogle::protobuf::internal::WireFormatLite::StringSize(
        this->_internal_channelid());
  }

  // string title = 2;
  if (!this->_internal_title().empty()) {
    total_size += 1 +
      ::herogoogle::protobuf::internal::WireFormatLite::StringSize(
        this->_internal_title());
  }

  // string iconUrl = 3;
  if (!this->_internal_iconurl().empty()) {
    total_size += 1 +
      ::herogoogle::protobuf::internal::WireFormatLite::StringSize(
        this->_internal_iconurl());
  }

  return MaybeComputeUnknownFieldsSize(total_size, &_cached_size_);
}

const ::herogoogle::protobuf::Message::ClassData Channel::_class_data_ = {
    ::herogoogle::protobuf::Message::CopyWithSizeCheck,
    Channel::MergeImpl
};
const ::herogoogle::protobuf::Message::ClassData*Channel::GetClassData() const { return &_class_data_; }

void Channel::MergeImpl(::herogoogle::protobuf::Message* to,
                      const ::herogoogle::protobuf::Message& from) {
  static_cast<Channel *>(to)->MergeFrom(
      static_cast<const Channel &>(from));
}


void Channel::MergeFrom(const Channel& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:heroim.client.v3beta.dto.channel.model.Channel)
  GOOGLE_DCHECK_NE(&from, this);
  ::herogoogle::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_channelid().empty()) {
    _internal_set_channelid(from._internal_channelid());
  }
  if (!from._internal_title().empty()) {
    _internal_set_title(from._internal_title());
  }
  if (!from._internal_iconurl().empty()) {
    _internal_set_iconurl(from._internal_iconurl());
  }
  _internal_metadata_.MergeFrom<::herogoogle::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void Channel::CopyFrom(const Channel& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:heroim.client.v3beta.dto.channel.model.Channel)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool Channel::IsInitialized() const {
  return true;
}

void Channel::InternalSwap(Channel* other) {
  using std::swap;
  auto* lhs_arena = GetArenaForAllocation();
  auto* rhs_arena = other->GetArenaForAllocation();
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::herogoogle::protobuf::internal::ArenaStringPtr::InternalSwap(
      &::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited(),
      &channelid_, lhs_arena,
      &other->channelid_, rhs_arena
  );
  ::herogoogle::protobuf::internal::ArenaStringPtr::InternalSwap(
      &::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited(),
      &title_, lhs_arena,
      &other->title_, rhs_arena
  );
  ::herogoogle::protobuf::internal::ArenaStringPtr::InternalSwap(
      &::herogoogle::protobuf::internal::GetEmptyStringAlreadyInited(),
      &iconurl_, lhs_arena,
      &other->iconurl_, rhs_arena
  );
}

::herogoogle::protobuf::Metadata Channel::GetMetadata() const {
  return ::herogoogle::protobuf::internal::AssignDescriptors(
      &descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto_getter, &descriptor_table_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto_once,
      file_level_metadata_client_2fv3beta_2fdto_2fchannel_2fmodel_2fchannel_5fmodel_2eproto[0]);
}

// @@protoc_insertion_point(namespace_scope)
}  // namespace model
}  // namespace channel
}  // namespace dto
}  // namespace v3beta
}  // namespace client
}  // namespace heroim
PROTOBUF_NAMESPACE_OPEN
template<> PROTOBUF_NOINLINE ::heroim::client::v3beta::dto::channel::model::Channel* Arena::CreateMaybeMessage< ::heroim::client::v3beta::dto::channel::model::Channel >(Arena* arena) {
  return Arena::CreateMessageInternal< ::heroim::client::v3beta::dto::channel::model::Channel >(arena);
}
PROTOBUF_NAMESPACE_CLOSE

// @@protoc_insertion_point(global_scope)

