// Generated by the protocol buffer compiler. DO NOT EDIT! // source: im_proto.proto #define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION #include "im_proto.pb.h" #include #include #include #include #include #include #include #include #include // @@protoc_insertion_point(includes) namespace im { namespace { const ::google::protobuf::Descriptor* IMSocketConnect_descriptor_ = NULL; const ::google::protobuf::internal::GeneratedMessageReflection* IMSocketConnect_reflection_ = NULL; const ::google::protobuf::Descriptor* IMSocketDisconnect_descriptor_ = NULL; const ::google::protobuf::internal::GeneratedMessageReflection* IMSocketDisconnect_reflection_ = NULL; const ::google::protobuf::EnumDescriptor* Constant_e_descriptor_ = NULL; } // namespace void protobuf_AssignDesc_im_5fproto_2eproto() { protobuf_AddDesc_im_5fproto_2eproto(); const ::google::protobuf::FileDescriptor* file = ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName( "im_proto.proto"); GOOGLE_CHECK(file != NULL); IMSocketConnect_descriptor_ = file->message_type(0); static const int IMSocketConnect_offsets_[4] = { GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, is_websocket_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, host_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, url_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, query_str_), }; IMSocketConnect_reflection_ = new ::google::protobuf::internal::GeneratedMessageReflection( IMSocketConnect_descriptor_, IMSocketConnect::default_instance_, IMSocketConnect_offsets_, GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, _has_bits_[0]), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketConnect, _unknown_fields_), -1, ::google::protobuf::DescriptorPool::generated_pool(), ::google::protobuf::MessageFactory::generated_factory(), sizeof(IMSocketConnect)); IMSocketDisconnect_descriptor_ = file->message_type(1); static const int IMSocketDisconnect_offsets_[1] = { }; IMSocketDisconnect_reflection_ = new ::google::protobuf::internal::GeneratedMessageReflection( IMSocketDisconnect_descriptor_, IMSocketDisconnect::default_instance_, IMSocketDisconnect_offsets_, GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketDisconnect, _has_bits_[0]), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(IMSocketDisconnect, _unknown_fields_), -1, ::google::protobuf::DescriptorPool::generated_pool(), ::google::protobuf::MessageFactory::generated_factory(), sizeof(IMSocketDisconnect)); Constant_e_descriptor_ = file->enum_type(0); } namespace { GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_); inline void protobuf_AssignDescriptorsOnce() { ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_, &protobuf_AssignDesc_im_5fproto_2eproto); } void protobuf_RegisterTypes(const ::std::string&) { protobuf_AssignDescriptorsOnce(); ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage( IMSocketConnect_descriptor_, &IMSocketConnect::default_instance()); ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage( IMSocketDisconnect_descriptor_, &IMSocketDisconnect::default_instance()); } } // namespace void protobuf_ShutdownFile_im_5fproto_2eproto() { delete IMSocketConnect::default_instance_; delete IMSocketConnect_reflection_; delete IMSocketDisconnect::default_instance_; delete IMSocketDisconnect_reflection_; } void protobuf_AddDesc_im_5fproto_2eproto() { static bool already_here = false; if (already_here) return; already_here = true; GOOGLE_PROTOBUF_VERIFY_VERSION; ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( "\n\016im_proto.proto\022\002im\"U\n\017IMSocketConnect\022" "\024\n\014is_websocket\030\001 \001(\010\022\014\n\004host\030\002 \001(\t\022\013\n\003u" "rl\030\003 \001(\t\022\021\n\tquery_str\030\004 \001(\t\"\024\n\022IMSocketD" "isconnect*\034\n\nConstant_e\022\016\n\nMaxIMMsgId\020\007", 159); ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( "im_proto.proto", &protobuf_RegisterTypes); IMSocketConnect::default_instance_ = new IMSocketConnect(); IMSocketDisconnect::default_instance_ = new IMSocketDisconnect(); IMSocketConnect::default_instance_->InitAsDefaultInstance(); IMSocketDisconnect::default_instance_->InitAsDefaultInstance(); ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_im_5fproto_2eproto); } // Force AddDescriptors() to be called at static initialization time. struct StaticDescriptorInitializer_im_5fproto_2eproto { StaticDescriptorInitializer_im_5fproto_2eproto() { protobuf_AddDesc_im_5fproto_2eproto(); } } static_descriptor_initializer_im_5fproto_2eproto_; const ::google::protobuf::EnumDescriptor* Constant_e_descriptor() { protobuf_AssignDescriptorsOnce(); return Constant_e_descriptor_; } bool Constant_e_IsValid(int value) { switch(value) { case 7: return true; default: return false; } } // =================================================================== #ifndef _MSC_VER const int IMSocketConnect::kIsWebsocketFieldNumber; const int IMSocketConnect::kHostFieldNumber; const int IMSocketConnect::kUrlFieldNumber; const int IMSocketConnect::kQueryStrFieldNumber; #endif // !_MSC_VER IMSocketConnect::IMSocketConnect() : ::google::protobuf::Message() { SharedCtor(); } void IMSocketConnect::InitAsDefaultInstance() { } IMSocketConnect::IMSocketConnect(const IMSocketConnect& from) : ::google::protobuf::Message() { SharedCtor(); MergeFrom(from); } void IMSocketConnect::SharedCtor() { _cached_size_ = 0; is_websocket_ = false; host_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString); url_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString); query_str_ = const_cast< ::std::string*>(&::google::protobuf::internal::kEmptyString); ::memset(_has_bits_, 0, sizeof(_has_bits_)); } IMSocketConnect::~IMSocketConnect() { SharedDtor(); } void IMSocketConnect::SharedDtor() { if (host_ != &::google::protobuf::internal::kEmptyString) { delete host_; } if (url_ != &::google::protobuf::internal::kEmptyString) { delete url_; } if (query_str_ != &::google::protobuf::internal::kEmptyString) { delete query_str_; } if (this != default_instance_) { } } void IMSocketConnect::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* IMSocketConnect::descriptor() { protobuf_AssignDescriptorsOnce(); return IMSocketConnect_descriptor_; } const IMSocketConnect& IMSocketConnect::default_instance() { if (default_instance_ == NULL) protobuf_AddDesc_im_5fproto_2eproto(); return *default_instance_; } IMSocketConnect* IMSocketConnect::default_instance_ = NULL; IMSocketConnect* IMSocketConnect::New() const { return new IMSocketConnect; } void IMSocketConnect::Clear() { if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { is_websocket_ = false; if (has_host()) { if (host_ != &::google::protobuf::internal::kEmptyString) { host_->clear(); } } if (has_url()) { if (url_ != &::google::protobuf::internal::kEmptyString) { url_->clear(); } } if (has_query_str()) { if (query_str_ != &::google::protobuf::internal::kEmptyString) { query_str_->clear(); } } } ::memset(_has_bits_, 0, sizeof(_has_bits_)); mutable_unknown_fields()->Clear(); } bool IMSocketConnect::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 bool is_websocket = 1; case 1: { if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) { DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( input, &is_websocket_))); set_has_is_websocket(); } else { goto handle_uninterpreted; } if (input->ExpectTag(18)) goto parse_host; break; } // optional string host = 2; case 2: { if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) { parse_host: DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_host())); ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->host().data(), this->host().length(), ::google::protobuf::internal::WireFormat::PARSE); } else { goto handle_uninterpreted; } if (input->ExpectTag(26)) goto parse_url; break; } // optional string url = 3; case 3: { if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) { parse_url: DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_url())); ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->url().data(), this->url().length(), ::google::protobuf::internal::WireFormat::PARSE); } else { goto handle_uninterpreted; } if (input->ExpectTag(34)) goto parse_query_str; break; } // optional string query_str = 4; case 4: { if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED) { parse_query_str: DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_query_str())); ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->query_str().data(), this->query_str().length(), ::google::protobuf::internal::WireFormat::PARSE); } 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 IMSocketConnect::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // optional bool is_websocket = 1; if (has_is_websocket()) { ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->is_websocket(), output); } // optional string host = 2; if (has_host()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->host().data(), this->host().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); ::google::protobuf::internal::WireFormatLite::WriteString( 2, this->host(), output); } // optional string url = 3; if (has_url()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->url().data(), this->url().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); ::google::protobuf::internal::WireFormatLite::WriteString( 3, this->url(), output); } // optional string query_str = 4; if (has_query_str()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->query_str().data(), this->query_str().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); ::google::protobuf::internal::WireFormatLite::WriteString( 4, this->query_str(), output); } if (!unknown_fields().empty()) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( unknown_fields(), output); } } ::google::protobuf::uint8* IMSocketConnect::SerializeWithCachedSizesToArray( ::google::protobuf::uint8* target) const { // optional bool is_websocket = 1; if (has_is_websocket()) { target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->is_websocket(), target); } // optional string host = 2; if (has_host()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->host().data(), this->host().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 2, this->host(), target); } // optional string url = 3; if (has_url()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->url().data(), this->url().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 3, this->url(), target); } // optional string query_str = 4; if (has_query_str()) { ::google::protobuf::internal::WireFormat::VerifyUTF8String( this->query_str().data(), this->query_str().length(), ::google::protobuf::internal::WireFormat::SERIALIZE); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 4, this->query_str(), target); } if (!unknown_fields().empty()) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( unknown_fields(), target); } return target; } int IMSocketConnect::ByteSize() const { int total_size = 0; if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { // optional bool is_websocket = 1; if (has_is_websocket()) { total_size += 1 + 1; } // optional string host = 2; if (has_host()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->host()); } // optional string url = 3; if (has_url()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->url()); } // optional string query_str = 4; if (has_query_str()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->query_str()); } } 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 IMSocketConnect::MergeFrom(const ::google::protobuf::Message& from) { GOOGLE_CHECK_NE(&from, this); const IMSocketConnect* source = ::google::protobuf::internal::dynamic_cast_if_available( &from); if (source == NULL) { ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { MergeFrom(*source); } } void IMSocketConnect::MergeFrom(const IMSocketConnect& from) { GOOGLE_CHECK_NE(&from, this); if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { if (from.has_is_websocket()) { set_is_websocket(from.is_websocket()); } if (from.has_host()) { set_host(from.host()); } if (from.has_url()) { set_url(from.url()); } if (from.has_query_str()) { set_query_str(from.query_str()); } } mutable_unknown_fields()->MergeFrom(from.unknown_fields()); } void IMSocketConnect::CopyFrom(const ::google::protobuf::Message& from) { if (&from == this) return; Clear(); MergeFrom(from); } void IMSocketConnect::CopyFrom(const IMSocketConnect& from) { if (&from == this) return; Clear(); MergeFrom(from); } bool IMSocketConnect::IsInitialized() const { return true; } void IMSocketConnect::Swap(IMSocketConnect* other) { if (other != this) { std::swap(is_websocket_, other->is_websocket_); std::swap(host_, other->host_); std::swap(url_, other->url_); std::swap(query_str_, other->query_str_); 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 IMSocketConnect::GetMetadata() const { protobuf_AssignDescriptorsOnce(); ::google::protobuf::Metadata metadata; metadata.descriptor = IMSocketConnect_descriptor_; metadata.reflection = IMSocketConnect_reflection_; return metadata; } // =================================================================== #ifndef _MSC_VER #endif // !_MSC_VER IMSocketDisconnect::IMSocketDisconnect() : ::google::protobuf::Message() { SharedCtor(); } void IMSocketDisconnect::InitAsDefaultInstance() { } IMSocketDisconnect::IMSocketDisconnect(const IMSocketDisconnect& from) : ::google::protobuf::Message() { SharedCtor(); MergeFrom(from); } void IMSocketDisconnect::SharedCtor() { _cached_size_ = 0; ::memset(_has_bits_, 0, sizeof(_has_bits_)); } IMSocketDisconnect::~IMSocketDisconnect() { SharedDtor(); } void IMSocketDisconnect::SharedDtor() { if (this != default_instance_) { } } void IMSocketDisconnect::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* IMSocketDisconnect::descriptor() { protobuf_AssignDescriptorsOnce(); return IMSocketDisconnect_descriptor_; } const IMSocketDisconnect& IMSocketDisconnect::default_instance() { if (default_instance_ == NULL) protobuf_AddDesc_im_5fproto_2eproto(); return *default_instance_; } IMSocketDisconnect* IMSocketDisconnect::default_instance_ = NULL; IMSocketDisconnect* IMSocketDisconnect::New() const { return new IMSocketDisconnect; } void IMSocketDisconnect::Clear() { ::memset(_has_bits_, 0, sizeof(_has_bits_)); mutable_unknown_fields()->Clear(); } bool IMSocketDisconnect::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!(EXPRESSION)) return false ::google::protobuf::uint32 tag; while ((tag = input->ReadTag()) != 0) { 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())); } return true; #undef DO_ } void IMSocketDisconnect::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { if (!unknown_fields().empty()) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( unknown_fields(), output); } } ::google::protobuf::uint8* IMSocketDisconnect::SerializeWithCachedSizesToArray( ::google::protobuf::uint8* target) const { if (!unknown_fields().empty()) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( unknown_fields(), target); } return target; } int IMSocketDisconnect::ByteSize() const { int total_size = 0; 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 IMSocketDisconnect::MergeFrom(const ::google::protobuf::Message& from) { GOOGLE_CHECK_NE(&from, this); const IMSocketDisconnect* source = ::google::protobuf::internal::dynamic_cast_if_available( &from); if (source == NULL) { ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { MergeFrom(*source); } } void IMSocketDisconnect::MergeFrom(const IMSocketDisconnect& from) { GOOGLE_CHECK_NE(&from, this); mutable_unknown_fields()->MergeFrom(from.unknown_fields()); } void IMSocketDisconnect::CopyFrom(const ::google::protobuf::Message& from) { if (&from == this) return; Clear(); MergeFrom(from); } void IMSocketDisconnect::CopyFrom(const IMSocketDisconnect& from) { if (&from == this) return; Clear(); MergeFrom(from); } bool IMSocketDisconnect::IsInitialized() const { return true; } void IMSocketDisconnect::Swap(IMSocketDisconnect* other) { if (other != this) { _unknown_fields_.Swap(&other->_unknown_fields_); std::swap(_cached_size_, other->_cached_size_); } } ::google::protobuf::Metadata IMSocketDisconnect::GetMetadata() const { protobuf_AssignDescriptorsOnce(); ::google::protobuf::Metadata metadata; metadata.descriptor = IMSocketDisconnect_descriptor_; metadata.reflection = IMSocketDisconnect_reflection_; return metadata; } // @@protoc_insertion_point(namespace_scope) } // namespace im // @@protoc_insertion_point(global_scope)