From 6e0dc69afa4c7171f9e31a50ad20d561189f7346 Mon Sep 17 00:00:00 2001
From: fujuntang <fujuntang@smartai.com>
Date: 星期二, 31 八月 2021 17:44:55 +0800
Subject: [PATCH] Merge branch 'master' of http://os.smartai.com:9091/valib/c_bhomebus
---
proto/source/bhome_msg.pb.h | 0
src/bh_api.cc | 4
proto/source/bhome_msg.proto | 0
proto/source/error_msg.pb.h | 0
proto/source/error_msg.proto | 0
proto/source/bhome_msg.pb.cc | 0
proto/source/bhome_msg/bhome_msg.pb.go | 2812 +++++++++++
proto/bhome_msg/error_msg.pb.go | 424 +
proto/source/bhome_msg_api.pb.cc | 0
test_socket/CMakeLists.txt | 1
proto/source/bhome_msg_api.proto | 0
proto/bhome_msg/bhome_msg_api.pb.go | 3762 ++++++++++++++++
api/bhsgo/bhome_node.go | 6
proto/source/bhome_msg/error_msg.pb.go | 424 +
proto/source/bhome_msg_api.pb.h | 0
src/CMakeLists.txt | 6
proto/source/bhome_msg/bhome_msg_api.pb.go | 3762 ++++++++++++++++
src/bh_api.cpp | 7
proto/bhome_msg/bhome_msg.pb.go | 2812 +++++++++++
proto/cpp/CMakeLists.txt | 56
proto/source/error_msg.pb.cc | 0
21 files changed, 14,062 insertions(+), 14 deletions(-)
diff --git a/api/bhsgo/bhome_node.go b/api/bhsgo/bhome_node.go
index 7787e18..7e558ec 100644
--- a/api/bhsgo/bhome_node.go
+++ b/api/bhsgo/bhome_node.go
@@ -1,16 +1,16 @@
package bhsgo
/*
-#include "bh_api_go.h"
+#include "../../src/bh_api.h"
*/
-// #cgo LDFLAGS: -L/home/lichao/code/shmsg/build/lib -L/usr/local/lib -lbhome_shmq -lstdc++ -lpthread -lrt
+// #cgo LDFLAGS: -L/usr/local/lib -lbhome_shmq -lstdc++ -lpthread -lrt
import "C"
import (
"unsafe"
- bh "basic.com/valib/bhshmq.git/proto/source/bhome_msg"
+ bh "basic.com/valib/c_bhomebus.git/proto/source/bhome_msg"
)
func getPtr(n *[]byte) unsafe.Pointer {
diff --git a/proto/bhome_msg/bhome_msg.pb.go b/proto/bhome_msg/bhome_msg.pb.go
new file mode 100644
index 0000000..1010ed1
--- /dev/null
+++ b/proto/bhome_msg/bhome_msg.pb.go
@@ -0,0 +1,2812 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: bhome_msg.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type MsgType int32
+
+const (
+ MsgType_kMsgTypeInvalid MsgType = 0
+ MsgType_kMsgTypeRawData MsgType = 1
+ MsgType_kMsgTypeCommonReply MsgType = 2
+ MsgType_kMsgTypeProcInit MsgType = 8
+ MsgType_kMsgTypeProcInitReply MsgType = 9
+ MsgType_kMsgTypeRegister MsgType = 10
+ // kMsgTypeRegisterReply= 11;
+ MsgType_kMsgTypeHeartbeat MsgType = 12
+ // kMsgTypeHeartbeatReply = 13;
+ MsgType_kMsgTypeQueryTopic MsgType = 14
+ MsgType_kMsgTypeQueryTopicReply MsgType = 15
+ MsgType_kMsgTypeRequestTopic MsgType = 16
+ MsgType_kMsgTypeRequestTopicReply MsgType = 17
+ MsgType_kMsgTypeRegisterRPC MsgType = 18
+ MsgType_kMsgTypePublish MsgType = 20
+ // kMsgTypePublishReply = 21;
+ MsgType_kMsgTypeSubscribe MsgType = 22
+ // kMsgTypeSubscribeReply = 23;
+ MsgType_kMsgTypeUnsubscribe MsgType = 24
+ // kMsgTypeUnsubscribeReply = 25;
+ MsgType_kMsgTypeUnregister MsgType = 26
+ // kMsgTypeUnregisterReply = 27;
+ MsgType_kMsgTypeQueryProc MsgType = 28
+ MsgType_kMsgTypeQueryProcReply MsgType = 29
+)
+
+var MsgType_name = map[int32]string{
+ 0: "kMsgTypeInvalid",
+ 1: "kMsgTypeRawData",
+ 2: "kMsgTypeCommonReply",
+ 8: "kMsgTypeProcInit",
+ 9: "kMsgTypeProcInitReply",
+ 10: "kMsgTypeRegister",
+ 12: "kMsgTypeHeartbeat",
+ 14: "kMsgTypeQueryTopic",
+ 15: "kMsgTypeQueryTopicReply",
+ 16: "kMsgTypeRequestTopic",
+ 17: "kMsgTypeRequestTopicReply",
+ 18: "kMsgTypeRegisterRPC",
+ 20: "kMsgTypePublish",
+ 22: "kMsgTypeSubscribe",
+ 24: "kMsgTypeUnsubscribe",
+ 26: "kMsgTypeUnregister",
+ 28: "kMsgTypeQueryProc",
+ 29: "kMsgTypeQueryProcReply",
+}
+
+var MsgType_value = map[string]int32{
+ "kMsgTypeInvalid": 0,
+ "kMsgTypeRawData": 1,
+ "kMsgTypeCommonReply": 2,
+ "kMsgTypeProcInit": 8,
+ "kMsgTypeProcInitReply": 9,
+ "kMsgTypeRegister": 10,
+ "kMsgTypeHeartbeat": 12,
+ "kMsgTypeQueryTopic": 14,
+ "kMsgTypeQueryTopicReply": 15,
+ "kMsgTypeRequestTopic": 16,
+ "kMsgTypeRequestTopicReply": 17,
+ "kMsgTypeRegisterRPC": 18,
+ "kMsgTypePublish": 20,
+ "kMsgTypeSubscribe": 22,
+ "kMsgTypeUnsubscribe": 24,
+ "kMsgTypeUnregister": 26,
+ "kMsgTypeQueryProc": 28,
+ "kMsgTypeQueryProcReply": 29,
+}
+
+func (x MsgType) String() string {
+ return proto.EnumName(MsgType_name, int32(x))
+}
+
+func (MsgType) EnumDescriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{0}
+}
+
+type BHMsgHead struct {
+ MsgId []byte `protobuf:"bytes,1,opt,name=msg_id,json=msgId,proto3" json:"msg_id,omitempty"`
+ Route []*BHAddress `protobuf:"bytes,2,rep,name=route,proto3" json:"route,omitempty"`
+ Timestamp int64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
+ Type int32 `protobuf:"varint,4,opt,name=type,proto3" json:"type,omitempty"`
+ SsnId uint64 `protobuf:"varint,5,opt,name=ssn_id,json=ssnId,proto3" json:"ssn_id,omitempty"`
+ ProcId []byte `protobuf:"bytes,6,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Topic []byte `protobuf:"bytes,7,opt,name=topic,proto3" json:"topic,omitempty"`
+ Dest *BHAddress `protobuf:"bytes,8,opt,name=dest,proto3" json:"dest,omitempty"`
+}
+
+func (m *BHMsgHead) Reset() { *m = BHMsgHead{} }
+func (m *BHMsgHead) String() string { return proto.CompactTextString(m) }
+func (*BHMsgHead) ProtoMessage() {}
+func (*BHMsgHead) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{0}
+}
+func (m *BHMsgHead) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHMsgHead) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHMsgHead.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHMsgHead) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHMsgHead.Merge(m, src)
+}
+func (m *BHMsgHead) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHMsgHead) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHMsgHead.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHMsgHead proto.InternalMessageInfo
+
+func (m *BHMsgHead) GetMsgId() []byte {
+ if m != nil {
+ return m.MsgId
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetRoute() []*BHAddress {
+ if m != nil {
+ return m.Route
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetTimestamp() int64 {
+ if m != nil {
+ return m.Timestamp
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetType() int32 {
+ if m != nil {
+ return m.Type
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetSsnId() uint64 {
+ if m != nil {
+ return m.SsnId
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetDest() *BHAddress {
+ if m != nil {
+ return m.Dest
+ }
+ return nil
+}
+
+type MsgSubscribe struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+ Network bool `protobuf:"varint,2,opt,name=network,proto3" json:"network,omitempty"`
+}
+
+func (m *MsgSubscribe) Reset() { *m = MsgSubscribe{} }
+func (m *MsgSubscribe) String() string { return proto.CompactTextString(m) }
+func (*MsgSubscribe) ProtoMessage() {}
+func (*MsgSubscribe) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{1}
+}
+func (m *MsgSubscribe) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgSubscribe) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgSubscribe.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgSubscribe) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgSubscribe.Merge(m, src)
+}
+func (m *MsgSubscribe) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgSubscribe) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgSubscribe.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgSubscribe proto.InternalMessageInfo
+
+func (m *MsgSubscribe) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+func (m *MsgSubscribe) GetNetwork() bool {
+ if m != nil {
+ return m.Network
+ }
+ return false
+}
+
+type MsgUnsubscribe struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+ Network bool `protobuf:"varint,2,opt,name=network,proto3" json:"network,omitempty"`
+}
+
+func (m *MsgUnsubscribe) Reset() { *m = MsgUnsubscribe{} }
+func (m *MsgUnsubscribe) String() string { return proto.CompactTextString(m) }
+func (*MsgUnsubscribe) ProtoMessage() {}
+func (*MsgUnsubscribe) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{2}
+}
+func (m *MsgUnsubscribe) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgUnsubscribe) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUnsubscribe.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgUnsubscribe) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUnsubscribe.Merge(m, src)
+}
+func (m *MsgUnsubscribe) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgUnsubscribe) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUnsubscribe.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUnsubscribe proto.InternalMessageInfo
+
+func (m *MsgUnsubscribe) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+func (m *MsgUnsubscribe) GetNetwork() bool {
+ if m != nil {
+ return m.Network
+ }
+ return false
+}
+
+type MsgRegisterRPC struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+}
+
+func (m *MsgRegisterRPC) Reset() { *m = MsgRegisterRPC{} }
+func (m *MsgRegisterRPC) String() string { return proto.CompactTextString(m) }
+func (*MsgRegisterRPC) ProtoMessage() {}
+func (*MsgRegisterRPC) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{3}
+}
+func (m *MsgRegisterRPC) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRegisterRPC) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRegisterRPC.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRegisterRPC) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRegisterRPC.Merge(m, src)
+}
+func (m *MsgRegisterRPC) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRegisterRPC) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRegisterRPC.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRegisterRPC proto.InternalMessageInfo
+
+func (m *MsgRegisterRPC) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+type MsgProcInit struct {
+ ExtraMqNum int32 `protobuf:"varint,1,opt,name=extra_mq_num,json=extraMqNum,proto3" json:"extra_mq_num,omitempty"`
+}
+
+func (m *MsgProcInit) Reset() { *m = MsgProcInit{} }
+func (m *MsgProcInit) String() string { return proto.CompactTextString(m) }
+func (*MsgProcInit) ProtoMessage() {}
+func (*MsgProcInit) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{4}
+}
+func (m *MsgProcInit) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgProcInit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgProcInit.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgProcInit) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgProcInit.Merge(m, src)
+}
+func (m *MsgProcInit) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgProcInit) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgProcInit.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgProcInit proto.InternalMessageInfo
+
+func (m *MsgProcInit) GetExtraMqNum() int32 {
+ if m != nil {
+ return m.ExtraMqNum
+ }
+ return 0
+}
+
+type MsgProcInitReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ ProcIndex int32 `protobuf:"varint,2,opt,name=proc_index,json=procIndex,proto3" json:"proc_index,omitempty"`
+ ExtraMqs []*BHAddress `protobuf:"bytes,3,rep,name=extra_mqs,json=extraMqs,proto3" json:"extra_mqs,omitempty"`
+}
+
+func (m *MsgProcInitReply) Reset() { *m = MsgProcInitReply{} }
+func (m *MsgProcInitReply) String() string { return proto.CompactTextString(m) }
+func (*MsgProcInitReply) ProtoMessage() {}
+func (*MsgProcInitReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{5}
+}
+func (m *MsgProcInitReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgProcInitReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgProcInitReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgProcInitReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgProcInitReply.Merge(m, src)
+}
+func (m *MsgProcInitReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgProcInitReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgProcInitReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgProcInitReply proto.InternalMessageInfo
+
+func (m *MsgProcInitReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgProcInitReply) GetProcIndex() int32 {
+ if m != nil {
+ return m.ProcIndex
+ }
+ return 0
+}
+
+func (m *MsgProcInitReply) GetExtraMqs() []*BHAddress {
+ if m != nil {
+ return m.ExtraMqs
+ }
+ return nil
+}
+
+type MsgRequest struct {
+ // oneof body;
+ //
+ // Types that are valid to be assigned to Request:
+ // *MsgRequest_Register
+ // *MsgRequest_TopicRequest
+ // *MsgRequest_TopicQuery
+ Request isMsgRequest_Request `protobuf_oneof:"request"`
+}
+
+func (m *MsgRequest) Reset() { *m = MsgRequest{} }
+func (m *MsgRequest) String() string { return proto.CompactTextString(m) }
+func (*MsgRequest) ProtoMessage() {}
+func (*MsgRequest) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{6}
+}
+func (m *MsgRequest) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequest.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequest) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequest.Merge(m, src)
+}
+func (m *MsgRequest) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequest) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequest.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequest proto.InternalMessageInfo
+
+type isMsgRequest_Request interface {
+ isMsgRequest_Request()
+ MarshalTo([]byte) (int, error)
+ Size() int
+}
+
+type MsgRequest_Register struct {
+ Register *MsgRegister `protobuf:"bytes,1,opt,name=register,proto3,oneof"`
+}
+type MsgRequest_TopicRequest struct {
+ TopicRequest *MsgRequestTopic `protobuf:"bytes,2,opt,name=topic_request,json=topicRequest,proto3,oneof"`
+}
+type MsgRequest_TopicQuery struct {
+ TopicQuery *MsgQueryTopic `protobuf:"bytes,3,opt,name=topic_query,json=topicQuery,proto3,oneof"`
+}
+
+func (*MsgRequest_Register) isMsgRequest_Request() {}
+func (*MsgRequest_TopicRequest) isMsgRequest_Request() {}
+func (*MsgRequest_TopicQuery) isMsgRequest_Request() {}
+
+func (m *MsgRequest) GetRequest() isMsgRequest_Request {
+ if m != nil {
+ return m.Request
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetRegister() *MsgRegister {
+ if x, ok := m.GetRequest().(*MsgRequest_Register); ok {
+ return x.Register
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetTopicRequest() *MsgRequestTopic {
+ if x, ok := m.GetRequest().(*MsgRequest_TopicRequest); ok {
+ return x.TopicRequest
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetTopicQuery() *MsgQueryTopic {
+ if x, ok := m.GetRequest().(*MsgRequest_TopicQuery); ok {
+ return x.TopicQuery
+ }
+ return nil
+}
+
+// XXX_OneofFuncs is for the internal use of the proto package.
+func (*MsgRequest) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
+ return _MsgRequest_OneofMarshaler, _MsgRequest_OneofUnmarshaler, _MsgRequest_OneofSizer, []interface{}{
+ (*MsgRequest_Register)(nil),
+ (*MsgRequest_TopicRequest)(nil),
+ (*MsgRequest_TopicQuery)(nil),
+ }
+}
+
+func _MsgRequest_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
+ m := msg.(*MsgRequest)
+ // request
+ switch x := m.Request.(type) {
+ case *MsgRequest_Register:
+ _ = b.EncodeVarint(1<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Register); err != nil {
+ return err
+ }
+ case *MsgRequest_TopicRequest:
+ _ = b.EncodeVarint(2<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.TopicRequest); err != nil {
+ return err
+ }
+ case *MsgRequest_TopicQuery:
+ _ = b.EncodeVarint(3<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.TopicQuery); err != nil {
+ return err
+ }
+ case nil:
+ default:
+ return fmt.Errorf("MsgRequest.Request has unexpected type %T", x)
+ }
+ return nil
+}
+
+func _MsgRequest_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
+ m := msg.(*MsgRequest)
+ switch tag {
+ case 1: // request.register
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRegister)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_Register{msg}
+ return true, err
+ case 2: // request.topic_request
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRequestTopic)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_TopicRequest{msg}
+ return true, err
+ case 3: // request.topic_query
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgQueryTopic)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_TopicQuery{msg}
+ return true, err
+ default:
+ return false, nil
+ }
+}
+
+func _MsgRequest_OneofSizer(msg proto.Message) (n int) {
+ m := msg.(*MsgRequest)
+ // request
+ switch x := m.Request.(type) {
+ case *MsgRequest_Register:
+ s := proto.Size(x.Register)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *MsgRequest_TopicRequest:
+ s := proto.Size(x.TopicRequest)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *MsgRequest_TopicQuery:
+ s := proto.Size(x.TopicQuery)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case nil:
+ default:
+ panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
+ }
+ return n
+}
+
+type MsgReply struct {
+ ErrMsg *ErrorMsg `protobuf:"bytes,1,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"`
+}
+
+func (m *MsgReply) Reset() { *m = MsgReply{} }
+func (m *MsgReply) String() string { return proto.CompactTextString(m) }
+func (*MsgReply) ProtoMessage() {}
+func (*MsgReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{7}
+}
+func (m *MsgReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgReply.Merge(m, src)
+}
+func (m *MsgReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgReply proto.InternalMessageInfo
+
+func (m *MsgReply) GetErrMsg() *ErrorMsg {
+ if m != nil {
+ return m.ErrMsg
+ }
+ return nil
+}
+
+type BHMsgBody struct {
+ // Types that are valid to be assigned to Reqrep:
+ // *BHMsgBody_Request
+ // *BHMsgBody_Reply
+ Reqrep isBHMsgBody_Reqrep `protobuf_oneof:"reqrep"`
+}
+
+func (m *BHMsgBody) Reset() { *m = BHMsgBody{} }
+func (m *BHMsgBody) String() string { return proto.CompactTextString(m) }
+func (*BHMsgBody) ProtoMessage() {}
+func (*BHMsgBody) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{8}
+}
+func (m *BHMsgBody) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHMsgBody) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHMsgBody.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHMsgBody) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHMsgBody.Merge(m, src)
+}
+func (m *BHMsgBody) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHMsgBody) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHMsgBody.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHMsgBody proto.InternalMessageInfo
+
+type isBHMsgBody_Reqrep interface {
+ isBHMsgBody_Reqrep()
+ MarshalTo([]byte) (int, error)
+ Size() int
+}
+
+type BHMsgBody_Request struct {
+ Request *MsgRequest `protobuf:"bytes,1,opt,name=request,proto3,oneof"`
+}
+type BHMsgBody_Reply struct {
+ Reply *MsgReply `protobuf:"bytes,2,opt,name=reply,proto3,oneof"`
+}
+
+func (*BHMsgBody_Request) isBHMsgBody_Reqrep() {}
+func (*BHMsgBody_Reply) isBHMsgBody_Reqrep() {}
+
+func (m *BHMsgBody) GetReqrep() isBHMsgBody_Reqrep {
+ if m != nil {
+ return m.Reqrep
+ }
+ return nil
+}
+
+func (m *BHMsgBody) GetRequest() *MsgRequest {
+ if x, ok := m.GetReqrep().(*BHMsgBody_Request); ok {
+ return x.Request
+ }
+ return nil
+}
+
+func (m *BHMsgBody) GetReply() *MsgReply {
+ if x, ok := m.GetReqrep().(*BHMsgBody_Reply); ok {
+ return x.Reply
+ }
+ return nil
+}
+
+// XXX_OneofFuncs is for the internal use of the proto package.
+func (*BHMsgBody) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
+ return _BHMsgBody_OneofMarshaler, _BHMsgBody_OneofUnmarshaler, _BHMsgBody_OneofSizer, []interface{}{
+ (*BHMsgBody_Request)(nil),
+ (*BHMsgBody_Reply)(nil),
+ }
+}
+
+func _BHMsgBody_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
+ m := msg.(*BHMsgBody)
+ // reqrep
+ switch x := m.Reqrep.(type) {
+ case *BHMsgBody_Request:
+ _ = b.EncodeVarint(1<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Request); err != nil {
+ return err
+ }
+ case *BHMsgBody_Reply:
+ _ = b.EncodeVarint(2<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Reply); err != nil {
+ return err
+ }
+ case nil:
+ default:
+ return fmt.Errorf("BHMsgBody.Reqrep has unexpected type %T", x)
+ }
+ return nil
+}
+
+func _BHMsgBody_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
+ m := msg.(*BHMsgBody)
+ switch tag {
+ case 1: // reqrep.request
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRequest)
+ err := b.DecodeMessage(msg)
+ m.Reqrep = &BHMsgBody_Request{msg}
+ return true, err
+ case 2: // reqrep.reply
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgReply)
+ err := b.DecodeMessage(msg)
+ m.Reqrep = &BHMsgBody_Reply{msg}
+ return true, err
+ default:
+ return false, nil
+ }
+}
+
+func _BHMsgBody_OneofSizer(msg proto.Message) (n int) {
+ m := msg.(*BHMsgBody)
+ // reqrep
+ switch x := m.Reqrep.(type) {
+ case *BHMsgBody_Request:
+ s := proto.Size(x.Request)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *BHMsgBody_Reply:
+ s := proto.Size(x.Reply)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case nil:
+ default:
+ panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
+ }
+ return n
+}
+
+func init() {
+ proto.RegisterEnum("bhome_msg.MsgType", MsgType_name, MsgType_value)
+ proto.RegisterType((*BHMsgHead)(nil), "bhome_msg.BHMsgHead")
+ proto.RegisterType((*MsgSubscribe)(nil), "bhome_msg.MsgSubscribe")
+ proto.RegisterType((*MsgUnsubscribe)(nil), "bhome_msg.MsgUnsubscribe")
+ proto.RegisterType((*MsgRegisterRPC)(nil), "bhome_msg.MsgRegisterRPC")
+ proto.RegisterType((*MsgProcInit)(nil), "bhome_msg.MsgProcInit")
+ proto.RegisterType((*MsgProcInitReply)(nil), "bhome_msg.MsgProcInitReply")
+ proto.RegisterType((*MsgRequest)(nil), "bhome_msg.MsgRequest")
+ proto.RegisterType((*MsgReply)(nil), "bhome_msg.MsgReply")
+ proto.RegisterType((*BHMsgBody)(nil), "bhome_msg.BHMsgBody")
+}
+
+func init() { proto.RegisterFile("bhome_msg.proto", fileDescriptor_88ce6d52215a3d3f) }
+
+var fileDescriptor_88ce6d52215a3d3f = []byte{
+ // 809 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x55, 0xcd, 0x6e, 0xdb, 0x46,
+ 0x10, 0x16, 0x2d, 0x53, 0xa2, 0x46, 0x6a, 0xbc, 0x19, 0xc9, 0x36, 0xa3, 0xc6, 0x02, 0xc1, 0x4b,
+ 0x85, 0xa4, 0xb0, 0x11, 0xb5, 0x87, 0x02, 0xbd, 0xd4, 0x72, 0x0a, 0xd0, 0x40, 0x55, 0xb8, 0xdb,
+ 0xe6, 0xd0, 0xf6, 0x20, 0x50, 0xe6, 0x82, 0x21, 0x22, 0xfe, 0x68, 0x77, 0xd9, 0x44, 0x6f, 0xd1,
+ 0xf6, 0x8d, 0x7a, 0xeb, 0xa5, 0x40, 0x8e, 0x3d, 0x16, 0xf6, 0x0b, 0xf4, 0x11, 0x8a, 0x5d, 0x92,
+ 0x12, 0xe3, 0xc4, 0x31, 0x7a, 0xc8, 0x6d, 0xf7, 0x9b, 0xf9, 0xbe, 0xf9, 0xd9, 0x19, 0x12, 0xf6,
+ 0x16, 0xcf, 0xd3, 0x98, 0xcd, 0x63, 0x11, 0x1e, 0x67, 0x3c, 0x95, 0x29, 0x76, 0x36, 0xc0, 0xb0,
+ 0xbf, 0x39, 0xce, 0xfd, 0x2c, 0x2a, 0xec, 0xc3, 0x3d, 0xc6, 0x79, 0xca, 0xb7, 0x04, 0xf7, 0x5f,
+ 0x03, 0x3a, 0x53, 0x6f, 0x26, 0x42, 0x8f, 0xf9, 0x01, 0xee, 0x43, 0x4b, 0xf9, 0x47, 0x81, 0x6d,
+ 0x38, 0xc6, 0xb8, 0x47, 0xcd, 0x58, 0x84, 0xe7, 0x01, 0x3e, 0x02, 0x93, 0xa7, 0xb9, 0x64, 0xf6,
+ 0x8e, 0xd3, 0x1c, 0x77, 0x27, 0x83, 0xe3, 0x6d, 0xd8, 0xa9, 0x77, 0x1a, 0x04, 0x9c, 0x09, 0x41,
+ 0x0b, 0x17, 0x7c, 0x08, 0x1d, 0x19, 0xc5, 0x4c, 0x48, 0x3f, 0xce, 0xec, 0xa6, 0x63, 0x8c, 0x9b,
+ 0x74, 0x0b, 0x20, 0xc2, 0xae, 0x5c, 0x67, 0xcc, 0xde, 0x75, 0x8c, 0xb1, 0x49, 0xf5, 0x59, 0x05,
+ 0x15, 0x22, 0x51, 0x41, 0x4d, 0xc7, 0x18, 0xef, 0x52, 0x53, 0x88, 0xe4, 0x3c, 0xc0, 0x43, 0x68,
+ 0x67, 0x3c, 0xbd, 0x54, 0x78, 0x4b, 0x27, 0xd3, 0x52, 0xd7, 0xf3, 0x00, 0x07, 0x60, 0xca, 0x34,
+ 0x8b, 0x2e, 0xed, 0x76, 0x91, 0xa3, 0xbe, 0xe0, 0x18, 0x76, 0x03, 0x26, 0xa4, 0x6d, 0x39, 0xc6,
+ 0xad, 0x29, 0x6a, 0x0f, 0xf7, 0x47, 0xe8, 0xcd, 0x44, 0xf8, 0x7d, 0xbe, 0x10, 0x97, 0x3c, 0x5a,
+ 0x30, 0x3c, 0x81, 0x96, 0x96, 0x10, 0xba, 0xe8, 0xee, 0xe4, 0xb0, 0xc6, 0x9d, 0x89, 0xf0, 0x07,
+ 0x65, 0xfb, 0x26, 0x12, 0x92, 0x96, 0x6e, 0x68, 0x43, 0x3b, 0x61, 0xf2, 0x65, 0xca, 0x5f, 0xd8,
+ 0x3b, 0x8e, 0x31, 0xb6, 0x68, 0x75, 0x75, 0x7f, 0x86, 0x7b, 0x33, 0x11, 0x3e, 0x4b, 0xc4, 0x87,
+ 0x10, 0x3f, 0xd5, 0xe2, 0x94, 0x85, 0x91, 0x90, 0x8c, 0xd3, 0x8b, 0xb3, 0xff, 0x2d, 0xee, 0x9e,
+ 0x40, 0x77, 0x26, 0xc2, 0x0b, 0xd5, 0xc7, 0x24, 0x92, 0xe8, 0x40, 0x8f, 0xbd, 0x92, 0xdc, 0x9f,
+ 0xc7, 0xab, 0x79, 0x92, 0xc7, 0x5a, 0xc5, 0xa4, 0xa0, 0xb1, 0xd9, 0xea, 0xdb, 0x3c, 0x76, 0x7f,
+ 0x33, 0x80, 0xd4, 0x18, 0x94, 0x65, 0xcb, 0x35, 0x3e, 0x86, 0x16, 0xe3, 0x3c, 0x16, 0x61, 0x19,
+ 0xb6, 0x5f, 0x0b, 0xfb, 0xb5, 0x9a, 0x2f, 0x95, 0x66, 0xe9, 0x82, 0x47, 0x00, 0xc5, 0x33, 0x26,
+ 0x01, 0x7b, 0xa5, 0x4b, 0x32, 0x69, 0x47, 0xbf, 0xa4, 0x02, 0xf0, 0x09, 0x74, 0xaa, 0x14, 0x84,
+ 0xdd, 0x7c, 0xcf, 0x78, 0x59, 0x65, 0x56, 0xc2, 0xfd, 0xcb, 0x00, 0xd0, 0x8d, 0x58, 0xe5, 0x4c,
+ 0x48, 0xfc, 0x1c, 0x2c, 0x5e, 0xf6, 0xa4, 0xcc, 0xe7, 0xe0, 0xcd, 0x36, 0x54, 0x1d, 0xf3, 0x1a,
+ 0x74, 0xe3, 0x89, 0xa7, 0xf0, 0x91, 0xee, 0xc9, 0x9c, 0x17, 0x32, 0x3a, 0xb3, 0xee, 0x64, 0x78,
+ 0x93, 0xaa, 0x8d, 0xba, 0x91, 0x5e, 0x83, 0xf6, 0x34, 0xa5, 0x0a, 0xfc, 0x25, 0x74, 0x0b, 0x89,
+ 0x55, 0xce, 0xf8, 0x5a, 0xcf, 0x7a, 0x77, 0x62, 0xbf, 0x29, 0xf0, 0x9d, 0x32, 0x55, 0x74, 0xd0,
+ 0xee, 0x1a, 0x9a, 0x76, 0xa0, 0x5d, 0x46, 0x76, 0xbf, 0x00, 0x4b, 0x87, 0x52, 0xad, 0xfd, 0x14,
+ 0xda, 0x8c, 0xeb, 0xfd, 0xbc, 0xab, 0xb7, 0x33, 0x11, 0xba, 0x79, 0xb9, 0xbb, 0xd3, 0x34, 0x58,
+ 0xe3, 0x93, 0x8d, 0x62, 0x49, 0xdd, 0x7f, 0x67, 0x2d, 0x5e, 0x83, 0x56, 0x7e, 0xf8, 0x18, 0x4c,
+ 0xae, 0xc2, 0x96, 0xc5, 0xf7, 0x6f, 0x12, 0xb2, 0xe5, 0xda, 0x6b, 0xd0, 0xc2, 0x67, 0x6a, 0x41,
+ 0x8b, 0xb3, 0x15, 0x67, 0xd9, 0xa3, 0x3f, 0x9a, 0xd0, 0x56, 0xe3, 0xa5, 0x96, 0xb7, 0x0f, 0x7b,
+ 0x2f, 0xca, 0xf3, 0x79, 0xf2, 0x8b, 0xbf, 0x8c, 0x02, 0xd2, 0xa8, 0x83, 0xd4, 0x7f, 0xf9, 0xd4,
+ 0x97, 0x3e, 0x31, 0xf0, 0x10, 0xfa, 0x15, 0x78, 0x96, 0xc6, 0x71, 0x9a, 0x68, 0x7d, 0xb2, 0x83,
+ 0x03, 0x20, 0x95, 0xa1, 0x9a, 0x33, 0x62, 0xe1, 0x03, 0xd8, 0xbf, 0x89, 0x16, 0x84, 0x4e, 0x9d,
+ 0x50, 0xbd, 0x2d, 0x01, 0xdc, 0x87, 0xfb, 0x15, 0xea, 0x31, 0x9f, 0xcb, 0x05, 0xf3, 0x25, 0xe9,
+ 0xe1, 0x01, 0x60, 0x05, 0x6f, 0x1f, 0x83, 0xdc, 0xc3, 0x8f, 0xe1, 0xf0, 0x6d, 0xbc, 0x88, 0xb0,
+ 0x87, 0x36, 0x0c, 0xb6, 0x11, 0xb6, 0x23, 0x40, 0x08, 0x1e, 0xc1, 0x83, 0x77, 0x59, 0x0a, 0xe2,
+ 0xfd, 0x7a, 0x91, 0xb5, 0x45, 0x25, 0x58, 0x6f, 0xc9, 0x45, 0xbe, 0x58, 0x46, 0xe2, 0x39, 0x19,
+ 0xd4, 0x53, 0xde, 0x7c, 0x8e, 0xc8, 0x41, 0x5d, 0xa4, 0xf6, 0x29, 0x21, 0x76, 0xbd, 0x96, 0x67,
+ 0x49, 0x35, 0xca, 0x64, 0x58, 0xd7, 0xd1, 0xb5, 0xa8, 0x86, 0x91, 0x87, 0x38, 0x84, 0x83, 0xb7,
+ 0xe0, 0x22, 0xd1, 0xa3, 0xc9, 0xef, 0x06, 0x58, 0x45, 0xe6, 0x17, 0x67, 0xf8, 0x15, 0x98, 0xda,
+ 0x01, 0x6f, 0x9d, 0xde, 0xe1, 0xd1, 0x6d, 0x96, 0x62, 0x6e, 0x9f, 0x42, 0xbb, 0x5a, 0x8b, 0xf7,
+ 0xac, 0xd0, 0x1d, 0x2a, 0xd3, 0x4f, 0xfe, 0xbc, 0x1a, 0x19, 0xaf, 0xaf, 0x46, 0xc6, 0x3f, 0x57,
+ 0x23, 0xe3, 0xd7, 0xeb, 0x51, 0xe3, 0xf5, 0xf5, 0xa8, 0xf1, 0xf7, 0xf5, 0xa8, 0xe1, 0x35, 0x7f,
+ 0xea, 0x1e, 0x9f, 0x6c, 0xb8, 0x8b, 0x96, 0xfe, 0x79, 0x7d, 0xf6, 0x5f, 0x00, 0x00, 0x00, 0xff,
+ 0xff, 0x27, 0x28, 0x5d, 0xb5, 0x00, 0x07, 0x00, 0x00,
+}
+
+func (m *BHMsgHead) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHMsgHead) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.MsgId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.MsgId)))
+ i += copy(dAtA[i:], m.MsgId)
+ }
+ if len(m.Route) > 0 {
+ for _, msg := range m.Route {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ if m.Timestamp != 0 {
+ dAtA[i] = 0x18
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Timestamp))
+ }
+ if m.Type != 0 {
+ dAtA[i] = 0x20
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Type))
+ }
+ if m.SsnId != 0 {
+ dAtA[i] = 0x28
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.SsnId))
+ }
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0x32
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0x3a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if m.Dest != nil {
+ dAtA[i] = 0x42
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Dest.Size()))
+ n1, err1 := m.Dest.MarshalTo(dAtA[i:])
+ if err1 != nil {
+ return 0, err1
+ }
+ i += n1
+ }
+ return i, nil
+}
+
+func (m *MsgSubscribe) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgSubscribe) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n2, err2 := m.Topics.MarshalTo(dAtA[i:])
+ if err2 != nil {
+ return 0, err2
+ }
+ i += n2
+ }
+ if m.Network {
+ dAtA[i] = 0x10
+ i++
+ if m.Network {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ return i, nil
+}
+
+func (m *MsgUnsubscribe) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgUnsubscribe) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n3, err3 := m.Topics.MarshalTo(dAtA[i:])
+ if err3 != nil {
+ return 0, err3
+ }
+ i += n3
+ }
+ if m.Network {
+ dAtA[i] = 0x10
+ i++
+ if m.Network {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ return i, nil
+}
+
+func (m *MsgRegisterRPC) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRegisterRPC) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n4, err4 := m.Topics.MarshalTo(dAtA[i:])
+ if err4 != nil {
+ return 0, err4
+ }
+ i += n4
+ }
+ return i, nil
+}
+
+func (m *MsgProcInit) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgProcInit) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ExtraMqNum != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ExtraMqNum))
+ }
+ return i, nil
+}
+
+func (m *MsgProcInitReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgProcInitReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Errmsg.Size()))
+ n5, err5 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err5 != nil {
+ return 0, err5
+ }
+ i += n5
+ }
+ if m.ProcIndex != 0 {
+ dAtA[i] = 0x10
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ProcIndex))
+ }
+ if len(m.ExtraMqs) > 0 {
+ for _, msg := range m.ExtraMqs {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgRequest) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequest) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Request != nil {
+ nn6, err6 := m.Request.MarshalTo(dAtA[i:])
+ if err6 != nil {
+ return 0, err6
+ }
+ i += nn6
+ }
+ return i, nil
+}
+
+func (m *MsgRequest_Register) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Register != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Register.Size()))
+ n7, err7 := m.Register.MarshalTo(dAtA[i:])
+ if err7 != nil {
+ return 0, err7
+ }
+ i += n7
+ }
+ return i, nil
+}
+func (m *MsgRequest_TopicRequest) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.TopicRequest != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.TopicRequest.Size()))
+ n8, err8 := m.TopicRequest.MarshalTo(dAtA[i:])
+ if err8 != nil {
+ return 0, err8
+ }
+ i += n8
+ }
+ return i, nil
+}
+func (m *MsgRequest_TopicQuery) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.TopicQuery != nil {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.TopicQuery.Size()))
+ n9, err9 := m.TopicQuery.MarshalTo(dAtA[i:])
+ if err9 != nil {
+ return 0, err9
+ }
+ i += n9
+ }
+ return i, nil
+}
+func (m *MsgReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ErrMsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ErrMsg.Size()))
+ n10, err10 := m.ErrMsg.MarshalTo(dAtA[i:])
+ if err10 != nil {
+ return 0, err10
+ }
+ i += n10
+ }
+ return i, nil
+}
+
+func (m *BHMsgBody) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHMsgBody) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Reqrep != nil {
+ nn11, err11 := m.Reqrep.MarshalTo(dAtA[i:])
+ if err11 != nil {
+ return 0, err11
+ }
+ i += nn11
+ }
+ return i, nil
+}
+
+func (m *BHMsgBody_Request) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Request != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Request.Size()))
+ n12, err12 := m.Request.MarshalTo(dAtA[i:])
+ if err12 != nil {
+ return 0, err12
+ }
+ i += n12
+ }
+ return i, nil
+}
+func (m *BHMsgBody_Reply) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Reply != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Reply.Size()))
+ n13, err13 := m.Reply.MarshalTo(dAtA[i:])
+ if err13 != nil {
+ return 0, err13
+ }
+ i += n13
+ }
+ return i, nil
+}
+func encodeVarintBhomeMsg(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *BHMsgHead) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.MsgId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if len(m.Route) > 0 {
+ for _, e := range m.Route {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ }
+ if m.Timestamp != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.Timestamp))
+ }
+ if m.Type != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.Type))
+ }
+ if m.SsnId != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.SsnId))
+ }
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Dest != nil {
+ l = m.Dest.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgSubscribe) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Network {
+ n += 2
+ }
+ return n
+}
+
+func (m *MsgUnsubscribe) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Network {
+ n += 2
+ }
+ return n
+}
+
+func (m *MsgRegisterRPC) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgProcInit) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ExtraMqNum != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.ExtraMqNum))
+ }
+ return n
+}
+
+func (m *MsgProcInitReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.ProcIndex != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.ProcIndex))
+ }
+ if len(m.ExtraMqs) > 0 {
+ for _, e := range m.ExtraMqs {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgRequest) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Request != nil {
+ n += m.Request.Size()
+ }
+ return n
+}
+
+func (m *MsgRequest_Register) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Register != nil {
+ l = m.Register.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgRequest_TopicRequest) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.TopicRequest != nil {
+ l = m.TopicRequest.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgRequest_TopicQuery) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.TopicQuery != nil {
+ l = m.TopicQuery.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ErrMsg != nil {
+ l = m.ErrMsg.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *BHMsgBody) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Reqrep != nil {
+ n += m.Reqrep.Size()
+ }
+ return n
+}
+
+func (m *BHMsgBody_Request) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Request != nil {
+ l = m.Request.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *BHMsgBody_Reply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Reply != nil {
+ l = m.Reply.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func sovBhomeMsg(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozBhomeMsg(x uint64) (n int) {
+ return sovBhomeMsg(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *BHMsgHead) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHMsgHead: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHMsgHead: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field MsgId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.MsgId = append(m.MsgId[:0], dAtA[iNdEx:postIndex]...)
+ if m.MsgId == nil {
+ m.MsgId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Route", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Route = append(m.Route, &BHAddress{})
+ if err := m.Route[len(m.Route)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 3:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Timestamp", wireType)
+ }
+ m.Timestamp = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Timestamp |= int64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 4:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
+ }
+ m.Type = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Type |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 5:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field SsnId", wireType)
+ }
+ m.SsnId = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.SsnId |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 6:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 7:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 8:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Dest", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Dest == nil {
+ m.Dest = &BHAddress{}
+ }
+ if err := m.Dest.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgSubscribe) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgSubscribe: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgSubscribe: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Network = bool(v != 0)
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgUnsubscribe) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgUnsubscribe: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUnsubscribe: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Network = bool(v != 0)
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRegisterRPC) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRegisterRPC: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRegisterRPC: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgProcInit) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgProcInit: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgProcInit: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ExtraMqNum", wireType)
+ }
+ m.ExtraMqNum = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ExtraMqNum |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgProcInitReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgProcInitReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgProcInitReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcIndex", wireType)
+ }
+ m.ProcIndex = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ProcIndex |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ExtraMqs", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ExtraMqs = append(m.ExtraMqs, &BHAddress{})
+ if err := m.ExtraMqs[len(m.ExtraMqs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequest) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequest: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequest: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Register", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRegister{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_Register{v}
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicRequest", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRequestTopic{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_TopicRequest{v}
+ iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicQuery", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgQueryTopic{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_TopicQuery{v}
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrMsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.ErrMsg == nil {
+ m.ErrMsg = &ErrorMsg{}
+ }
+ if err := m.ErrMsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *BHMsgBody) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHMsgBody: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHMsgBody: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Request", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRequest{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Reqrep = &BHMsgBody_Request{v}
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Reply", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgReply{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Reqrep = &BHMsgBody_Reply{v}
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipBhomeMsg(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipBhomeMsg(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthBhomeMsg = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowBhomeMsg = fmt.Errorf("proto: integer overflow")
+)
diff --git a/proto/bhome_msg/bhome_msg_api.pb.go b/proto/bhome_msg/bhome_msg_api.pb.go
new file mode 100644
index 0000000..8a62e34
--- /dev/null
+++ b/proto/bhome_msg/bhome_msg_api.pb.go
@@ -0,0 +1,3762 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: bhome_msg_api.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type BHAddress struct {
+ MqId uint64 `protobuf:"varint,1,opt,name=mq_id,json=mqId,proto3" json:"mq_id,omitempty"`
+ AbsAddr int64 `protobuf:"varint,2,opt,name=abs_addr,json=absAddr,proto3" json:"abs_addr,omitempty"`
+ Ip []byte `protobuf:"bytes,3,opt,name=ip,proto3" json:"ip,omitempty"`
+ Port int32 `protobuf:"varint,4,opt,name=port,proto3" json:"port,omitempty"`
+}
+
+func (m *BHAddress) Reset() { *m = BHAddress{} }
+func (m *BHAddress) String() string { return proto.CompactTextString(m) }
+func (*BHAddress) ProtoMessage() {}
+func (*BHAddress) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{0}
+}
+func (m *BHAddress) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHAddress.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHAddress) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHAddress.Merge(m, src)
+}
+func (m *BHAddress) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHAddress) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHAddress.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHAddress proto.InternalMessageInfo
+
+func (m *BHAddress) GetMqId() uint64 {
+ if m != nil {
+ return m.MqId
+ }
+ return 0
+}
+
+func (m *BHAddress) GetAbsAddr() int64 {
+ if m != nil {
+ return m.AbsAddr
+ }
+ return 0
+}
+
+func (m *BHAddress) GetIp() []byte {
+ if m != nil {
+ return m.Ip
+ }
+ return nil
+}
+
+func (m *BHAddress) GetPort() int32 {
+ if m != nil {
+ return m.Port
+ }
+ return 0
+}
+
+type ProcInfo struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Name []byte `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
+ PublicInfo []byte `protobuf:"bytes,3,opt,name=public_info,json=publicInfo,proto3" json:"public_info,omitempty"`
+ PrivateInfo []byte `protobuf:"bytes,4,opt,name=private_info,json=privateInfo,proto3" json:"private_info,omitempty"`
+}
+
+func (m *ProcInfo) Reset() { *m = ProcInfo{} }
+func (m *ProcInfo) String() string { return proto.CompactTextString(m) }
+func (*ProcInfo) ProtoMessage() {}
+func (*ProcInfo) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{1}
+}
+func (m *ProcInfo) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *ProcInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_ProcInfo.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *ProcInfo) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ProcInfo.Merge(m, src)
+}
+func (m *ProcInfo) XXX_Size() int {
+ return m.Size()
+}
+func (m *ProcInfo) XXX_DiscardUnknown() {
+ xxx_messageInfo_ProcInfo.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_ProcInfo proto.InternalMessageInfo
+
+func (m *ProcInfo) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetName() []byte {
+ if m != nil {
+ return m.Name
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetPublicInfo() []byte {
+ if m != nil {
+ return m.PublicInfo
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetPrivateInfo() []byte {
+ if m != nil {
+ return m.PrivateInfo
+ }
+ return nil
+}
+
+type MsgTopicList struct {
+ TopicList [][]byte `protobuf:"bytes,1,rep,name=topic_list,json=topicList,proto3" json:"topic_list,omitempty"`
+}
+
+func (m *MsgTopicList) Reset() { *m = MsgTopicList{} }
+func (m *MsgTopicList) String() string { return proto.CompactTextString(m) }
+func (*MsgTopicList) ProtoMessage() {}
+func (*MsgTopicList) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{2}
+}
+func (m *MsgTopicList) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgTopicList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgTopicList.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgTopicList) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgTopicList.Merge(m, src)
+}
+func (m *MsgTopicList) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgTopicList) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgTopicList.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgTopicList proto.InternalMessageInfo
+
+func (m *MsgTopicList) GetTopicList() [][]byte {
+ if m != nil {
+ return m.TopicList
+ }
+ return nil
+}
+
+type MsgPublish struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgPublish) Reset() { *m = MsgPublish{} }
+func (m *MsgPublish) String() string { return proto.CompactTextString(m) }
+func (*MsgPublish) ProtoMessage() {}
+func (*MsgPublish) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{3}
+}
+func (m *MsgPublish) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgPublish) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgPublish.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgPublish) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgPublish.Merge(m, src)
+}
+func (m *MsgPublish) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgPublish) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgPublish.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgPublish proto.InternalMessageInfo
+
+func (m *MsgPublish) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *MsgPublish) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgCommonReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+}
+
+func (m *MsgCommonReply) Reset() { *m = MsgCommonReply{} }
+func (m *MsgCommonReply) String() string { return proto.CompactTextString(m) }
+func (*MsgCommonReply) ProtoMessage() {}
+func (*MsgCommonReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{4}
+}
+func (m *MsgCommonReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgCommonReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgCommonReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgCommonReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgCommonReply.Merge(m, src)
+}
+func (m *MsgCommonReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgCommonReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgCommonReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgCommonReply proto.InternalMessageInfo
+
+func (m *MsgCommonReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+type MsgRequestTopic struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgRequestTopic) Reset() { *m = MsgRequestTopic{} }
+func (m *MsgRequestTopic) String() string { return proto.CompactTextString(m) }
+func (*MsgRequestTopic) ProtoMessage() {}
+func (*MsgRequestTopic) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{5}
+}
+func (m *MsgRequestTopic) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequestTopic) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequestTopic.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequestTopic) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequestTopic.Merge(m, src)
+}
+func (m *MsgRequestTopic) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequestTopic) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequestTopic.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequestTopic proto.InternalMessageInfo
+
+func (m *MsgRequestTopic) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *MsgRequestTopic) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgRequestTopicReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgRequestTopicReply) Reset() { *m = MsgRequestTopicReply{} }
+func (m *MsgRequestTopicReply) String() string { return proto.CompactTextString(m) }
+func (*MsgRequestTopicReply) ProtoMessage() {}
+func (*MsgRequestTopicReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{6}
+}
+func (m *MsgRequestTopicReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequestTopicReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequestTopicReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequestTopicReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequestTopicReply.Merge(m, src)
+}
+func (m *MsgRequestTopicReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequestTopicReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequestTopicReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequestTopicReply proto.InternalMessageInfo
+
+func (m *MsgRequestTopicReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgRequestTopicReply) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgRegister struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgRegister) Reset() { *m = MsgRegister{} }
+func (m *MsgRegister) String() string { return proto.CompactTextString(m) }
+func (*MsgRegister) ProtoMessage() {}
+func (*MsgRegister) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{7}
+}
+func (m *MsgRegister) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRegister) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRegister.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRegister) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRegister.Merge(m, src)
+}
+func (m *MsgRegister) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRegister) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRegister.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRegister proto.InternalMessageInfo
+
+func (m *MsgRegister) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgUnregister struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgUnregister) Reset() { *m = MsgUnregister{} }
+func (m *MsgUnregister) String() string { return proto.CompactTextString(m) }
+func (*MsgUnregister) ProtoMessage() {}
+func (*MsgUnregister) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{8}
+}
+func (m *MsgUnregister) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgUnregister) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUnregister.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgUnregister) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUnregister.Merge(m, src)
+}
+func (m *MsgUnregister) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgUnregister) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUnregister.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUnregister proto.InternalMessageInfo
+
+func (m *MsgUnregister) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgHeartbeat struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgHeartbeat) Reset() { *m = MsgHeartbeat{} }
+func (m *MsgHeartbeat) String() string { return proto.CompactTextString(m) }
+func (*MsgHeartbeat) ProtoMessage() {}
+func (*MsgHeartbeat) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{9}
+}
+func (m *MsgHeartbeat) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgHeartbeat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgHeartbeat.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgHeartbeat) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgHeartbeat.Merge(m, src)
+}
+func (m *MsgHeartbeat) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgHeartbeat) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgHeartbeat.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgHeartbeat proto.InternalMessageInfo
+
+func (m *MsgHeartbeat) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgQueryTopic struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+}
+
+func (m *MsgQueryTopic) Reset() { *m = MsgQueryTopic{} }
+func (m *MsgQueryTopic) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopic) ProtoMessage() {}
+func (*MsgQueryTopic) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{10}
+}
+func (m *MsgQueryTopic) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopic) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopic.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopic) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopic.Merge(m, src)
+}
+func (m *MsgQueryTopic) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopic) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopic.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopic proto.InternalMessageInfo
+
+func (m *MsgQueryTopic) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+type MsgQueryTopicReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ NodeAddress []*MsgQueryTopicReply_BHNodeAddress `protobuf:"bytes,2,rep,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty"`
+}
+
+func (m *MsgQueryTopicReply) Reset() { *m = MsgQueryTopicReply{} }
+func (m *MsgQueryTopicReply) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopicReply) ProtoMessage() {}
+func (*MsgQueryTopicReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{11}
+}
+func (m *MsgQueryTopicReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopicReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopicReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopicReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopicReply.Merge(m, src)
+}
+func (m *MsgQueryTopicReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopicReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopicReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopicReply proto.InternalMessageInfo
+
+func (m *MsgQueryTopicReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgQueryTopicReply) GetNodeAddress() []*MsgQueryTopicReply_BHNodeAddress {
+ if m != nil {
+ return m.NodeAddress
+ }
+ return nil
+}
+
+type MsgQueryTopicReply_BHNodeAddress struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Addr *BHAddress `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"`
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Reset() { *m = MsgQueryTopicReply_BHNodeAddress{} }
+func (m *MsgQueryTopicReply_BHNodeAddress) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopicReply_BHNodeAddress) ProtoMessage() {}
+func (*MsgQueryTopicReply_BHNodeAddress) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{11, 0}
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.Merge(m, src)
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress proto.InternalMessageInfo
+
+func (m *MsgQueryTopicReply_BHNodeAddress) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) GetAddr() *BHAddress {
+ if m != nil {
+ return m.Addr
+ }
+ return nil
+}
+
+type MsgQueryProc struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+}
+
+func (m *MsgQueryProc) Reset() { *m = MsgQueryProc{} }
+func (m *MsgQueryProc) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProc) ProtoMessage() {}
+func (*MsgQueryProc) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{12}
+}
+func (m *MsgQueryProc) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProc) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProc.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProc) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProc.Merge(m, src)
+}
+func (m *MsgQueryProc) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProc) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProc.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProc proto.InternalMessageInfo
+
+func (m *MsgQueryProc) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+type MsgQueryProcReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ ProcList []*MsgQueryProcReply_Info `protobuf:"bytes,2,rep,name=proc_list,json=procList,proto3" json:"proc_list,omitempty"`
+}
+
+func (m *MsgQueryProcReply) Reset() { *m = MsgQueryProcReply{} }
+func (m *MsgQueryProcReply) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProcReply) ProtoMessage() {}
+func (*MsgQueryProcReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{13}
+}
+func (m *MsgQueryProcReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProcReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProcReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProcReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProcReply.Merge(m, src)
+}
+func (m *MsgQueryProcReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProcReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProcReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProcReply proto.InternalMessageInfo
+
+func (m *MsgQueryProcReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply) GetProcList() []*MsgQueryProcReply_Info {
+ if m != nil {
+ return m.ProcList
+ }
+ return nil
+}
+
+type MsgQueryProcReply_Info struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+ Online bool `protobuf:"varint,2,opt,name=online,proto3" json:"online,omitempty"`
+ Service *MsgTopicList `protobuf:"bytes,3,opt,name=service,proto3" json:"service,omitempty"`
+ LocalSub *MsgTopicList `protobuf:"bytes,4,opt,name=local_sub,json=localSub,proto3" json:"local_sub,omitempty"`
+ NetSub *MsgTopicList `protobuf:"bytes,5,opt,name=net_sub,json=netSub,proto3" json:"net_sub,omitempty"`
+}
+
+func (m *MsgQueryProcReply_Info) Reset() { *m = MsgQueryProcReply_Info{} }
+func (m *MsgQueryProcReply_Info) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProcReply_Info) ProtoMessage() {}
+func (*MsgQueryProcReply_Info) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{13, 0}
+}
+func (m *MsgQueryProcReply_Info) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProcReply_Info) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProcReply_Info.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProcReply_Info) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProcReply_Info.Merge(m, src)
+}
+func (m *MsgQueryProcReply_Info) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProcReply_Info) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProcReply_Info.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProcReply_Info proto.InternalMessageInfo
+
+func (m *MsgQueryProcReply_Info) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetOnline() bool {
+ if m != nil {
+ return m.Online
+ }
+ return false
+}
+
+func (m *MsgQueryProcReply_Info) GetService() *MsgTopicList {
+ if m != nil {
+ return m.Service
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetLocalSub() *MsgTopicList {
+ if m != nil {
+ return m.LocalSub
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetNetSub() *MsgTopicList {
+ if m != nil {
+ return m.NetSub
+ }
+ return nil
+}
+
+func init() {
+ proto.RegisterType((*BHAddress)(nil), "bhome_msg.BHAddress")
+ proto.RegisterType((*ProcInfo)(nil), "bhome_msg.ProcInfo")
+ proto.RegisterType((*MsgTopicList)(nil), "bhome_msg.MsgTopicList")
+ proto.RegisterType((*MsgPublish)(nil), "bhome_msg.MsgPublish")
+ proto.RegisterType((*MsgCommonReply)(nil), "bhome_msg.MsgCommonReply")
+ proto.RegisterType((*MsgRequestTopic)(nil), "bhome_msg.MsgRequestTopic")
+ proto.RegisterType((*MsgRequestTopicReply)(nil), "bhome_msg.MsgRequestTopicReply")
+ proto.RegisterType((*MsgRegister)(nil), "bhome_msg.MsgRegister")
+ proto.RegisterType((*MsgUnregister)(nil), "bhome_msg.MsgUnregister")
+ proto.RegisterType((*MsgHeartbeat)(nil), "bhome_msg.MsgHeartbeat")
+ proto.RegisterType((*MsgQueryTopic)(nil), "bhome_msg.MsgQueryTopic")
+ proto.RegisterType((*MsgQueryTopicReply)(nil), "bhome_msg.MsgQueryTopicReply")
+ proto.RegisterType((*MsgQueryTopicReply_BHNodeAddress)(nil), "bhome_msg.MsgQueryTopicReply.BHNodeAddress")
+ proto.RegisterType((*MsgQueryProc)(nil), "bhome_msg.MsgQueryProc")
+ proto.RegisterType((*MsgQueryProcReply)(nil), "bhome_msg.MsgQueryProcReply")
+ proto.RegisterType((*MsgQueryProcReply_Info)(nil), "bhome_msg.MsgQueryProcReply.Info")
+}
+
+func init() { proto.RegisterFile("bhome_msg_api.proto", fileDescriptor_a49c9c1f511a168c) }
+
+var fileDescriptor_a49c9c1f511a168c = []byte{
+ // 640 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0x6f, 0x6b, 0x13, 0x4f,
+ 0x10, 0xee, 0x25, 0x97, 0x7f, 0x73, 0xd7, 0x96, 0xdf, 0xb6, 0xfc, 0x1a, 0x0b, 0xc6, 0xf4, 0x40,
+ 0x7a, 0x50, 0x8c, 0x1a, 0xa5, 0x0a, 0xa2, 0x60, 0x45, 0x48, 0xc1, 0x94, 0xba, 0x55, 0x04, 0xdf,
+ 0x1c, 0x77, 0xb9, 0xed, 0x75, 0x21, 0x77, 0x7b, 0xdd, 0xdd, 0x14, 0x8a, 0x5f, 0xc2, 0x8f, 0xe5,
+ 0xcb, 0xbe, 0xf4, 0xa5, 0xa4, 0xf4, 0x7b, 0xc8, 0x4e, 0x92, 0xb3, 0xd5, 0xb6, 0xb4, 0x7d, 0xb7,
+ 0xb3, 0xf3, 0x3c, 0xcf, 0x0c, 0x33, 0x3c, 0x03, 0x4b, 0xd1, 0x81, 0x48, 0x59, 0x90, 0xaa, 0x24,
+ 0x08, 0x73, 0xde, 0xc9, 0xa5, 0xd0, 0x82, 0x34, 0x8a, 0xcf, 0xd5, 0x45, 0x26, 0xa5, 0x90, 0xe6,
+ 0x39, 0xc9, 0x79, 0x01, 0x34, 0xb6, 0x7a, 0x6f, 0xe3, 0x58, 0x32, 0xa5, 0xc8, 0x12, 0x54, 0xd2,
+ 0xc3, 0x80, 0xc7, 0x4d, 0xab, 0x6d, 0xf9, 0x36, 0xb5, 0xd3, 0xc3, 0xed, 0x98, 0xdc, 0x83, 0x7a,
+ 0x18, 0xa9, 0x20, 0x8c, 0x63, 0xd9, 0x2c, 0xb5, 0x2d, 0xbf, 0x4c, 0x6b, 0x61, 0xa4, 0x0c, 0x85,
+ 0x2c, 0x40, 0x89, 0xe7, 0xcd, 0x72, 0xdb, 0xf2, 0x5d, 0x5a, 0xe2, 0x39, 0x21, 0x60, 0xe7, 0x42,
+ 0xea, 0xa6, 0xdd, 0xb6, 0xfc, 0x0a, 0xc5, 0xb7, 0xf7, 0x0d, 0xea, 0xbb, 0x52, 0x0c, 0xb6, 0xb3,
+ 0x7d, 0x41, 0x56, 0xa0, 0x96, 0x4b, 0x31, 0x98, 0x55, 0x70, 0x69, 0xd5, 0x84, 0xdb, 0xb1, 0x21,
+ 0x66, 0x61, 0xca, 0x50, 0xdf, 0xa5, 0xf8, 0x26, 0x0f, 0xc0, 0xc9, 0x47, 0xd1, 0x90, 0x0f, 0x02,
+ 0x9e, 0xed, 0x8b, 0x69, 0x15, 0x98, 0x7c, 0xa1, 0xda, 0x1a, 0xb8, 0xb9, 0xe4, 0x47, 0xa1, 0x66,
+ 0x13, 0x84, 0x8d, 0x08, 0x67, 0xfa, 0x67, 0x20, 0xde, 0x23, 0x70, 0xfb, 0x2a, 0xf9, 0x24, 0x72,
+ 0x3e, 0xf8, 0xc0, 0x95, 0x26, 0xf7, 0x01, 0xb4, 0x09, 0x82, 0x21, 0x57, 0xba, 0x69, 0xb5, 0xcb,
+ 0xbe, 0x4b, 0x1b, 0x7a, 0x96, 0xf6, 0x36, 0x01, 0xfa, 0x2a, 0xd9, 0x35, 0x25, 0xd4, 0x01, 0x59,
+ 0x86, 0x0a, 0xa6, 0xa6, 0xbd, 0x4e, 0x02, 0xd3, 0x6a, 0x1c, 0xea, 0x70, 0xd6, 0xaa, 0x79, 0x7b,
+ 0xaf, 0x61, 0xa1, 0xaf, 0x92, 0x77, 0x22, 0x4d, 0x45, 0x46, 0x59, 0x3e, 0x3c, 0x26, 0x1b, 0x50,
+ 0x65, 0x52, 0xa6, 0x2a, 0x41, 0xb2, 0xd3, 0x5d, 0xea, 0x14, 0x3b, 0xe8, 0xbc, 0x37, 0x2b, 0xe8,
+ 0xab, 0x84, 0x4e, 0x21, 0xde, 0x2b, 0x58, 0x34, 0x21, 0x3b, 0x1c, 0x31, 0xa5, 0xb1, 0xd9, 0x5b,
+ 0xd4, 0xfe, 0x02, 0xcb, 0x7f, 0x91, 0x6f, 0xdf, 0xc1, 0xa5, 0xc2, 0x9b, 0xe0, 0xa0, 0x70, 0xc2,
+ 0x95, 0x66, 0x92, 0xac, 0x83, 0x6d, 0x96, 0x75, 0x89, 0xda, 0x6c, 0xbd, 0x14, 0x01, 0xde, 0x4b,
+ 0x98, 0xef, 0xab, 0xe4, 0x73, 0x26, 0x6f, 0xcd, 0x7c, 0x81, 0xdb, 0xea, 0xb1, 0x50, 0xea, 0x88,
+ 0x85, 0xfa, 0xe6, 0xc4, 0x87, 0x58, 0xf2, 0xe3, 0x88, 0xc9, 0xe3, 0x6b, 0xc6, 0xe7, 0x9d, 0x59,
+ 0x40, 0x2e, 0xe0, 0xee, 0x30, 0xa9, 0x1d, 0x70, 0x33, 0x11, 0x33, 0xb4, 0x03, 0x53, 0xaa, 0x59,
+ 0x6a, 0x97, 0x7d, 0xa7, 0xbb, 0x71, 0x8e, 0xf2, 0x6f, 0x85, 0xce, 0x56, 0x6f, 0x47, 0xc4, 0x6c,
+ 0xea, 0x32, 0xea, 0x64, 0x7f, 0x82, 0x55, 0x0a, 0xf3, 0x17, 0xb2, 0x57, 0x7b, 0xc4, 0x07, 0xbb,
+ 0xf0, 0xa0, 0xd3, 0x5d, 0x3e, 0x57, 0xb1, 0x30, 0x30, 0x45, 0x84, 0xb7, 0x8e, 0x73, 0xc4, 0x26,
+ 0xcc, 0xa0, 0xae, 0x94, 0xf4, 0xce, 0x4a, 0xf0, 0xdf, 0x79, 0xe4, 0x1d, 0xe6, 0xf1, 0x06, 0x1a,
+ 0xa8, 0x8d, 0x86, 0x9a, 0x0c, 0x63, 0xed, 0x92, 0x61, 0x14, 0xea, 0x1d, 0x5c, 0x5b, 0xdd, 0x70,
+ 0x8c, 0xe5, 0x56, 0xc7, 0x16, 0xd8, 0xe8, 0xe6, 0x9b, 0x2e, 0x9b, 0xfc, 0x0f, 0x55, 0x91, 0x0d,
+ 0x79, 0x36, 0xb9, 0x16, 0x75, 0x3a, 0x8d, 0xc8, 0x53, 0xa8, 0x29, 0x26, 0x8f, 0xf8, 0x80, 0xe1,
+ 0xad, 0x70, 0xba, 0x2b, 0x17, 0xfb, 0x28, 0xae, 0x00, 0x9d, 0xe1, 0xc8, 0x73, 0x68, 0x0c, 0xc5,
+ 0x20, 0x1c, 0x06, 0x6a, 0x14, 0xe1, 0xf9, 0xb8, 0x86, 0x54, 0x47, 0xe4, 0xde, 0x28, 0x22, 0x4f,
+ 0xa0, 0x96, 0x31, 0x8d, 0x9c, 0xca, 0xf5, 0x9c, 0x6a, 0xc6, 0xf4, 0xde, 0x28, 0xda, 0x5a, 0xff,
+ 0x31, 0x6e, 0x59, 0x27, 0xe3, 0x96, 0xf5, 0x6b, 0xdc, 0xb2, 0xbe, 0x9f, 0xb6, 0xe6, 0x4e, 0x4e,
+ 0x5b, 0x73, 0x3f, 0x4f, 0x5b, 0x73, 0xbd, 0xf2, 0x57, 0xa7, 0xf3, 0xb8, 0x60, 0x47, 0x55, 0x3c,
+ 0xca, 0xcf, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0x71, 0x22, 0x26, 0xc9, 0xc7, 0x05, 0x00, 0x00,
+}
+
+func (m *BHAddress) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHAddress) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.MqId != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.MqId))
+ }
+ if m.AbsAddr != 0 {
+ dAtA[i] = 0x10
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.AbsAddr))
+ }
+ if len(m.Ip) > 0 {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Ip)))
+ i += copy(dAtA[i:], m.Ip)
+ }
+ if m.Port != 0 {
+ dAtA[i] = 0x20
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Port))
+ }
+ return i, nil
+}
+
+func (m *ProcInfo) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *ProcInfo) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if len(m.Name) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Name)))
+ i += copy(dAtA[i:], m.Name)
+ }
+ if len(m.PublicInfo) > 0 {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.PublicInfo)))
+ i += copy(dAtA[i:], m.PublicInfo)
+ }
+ if len(m.PrivateInfo) > 0 {
+ dAtA[i] = 0x22
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.PrivateInfo)))
+ i += copy(dAtA[i:], m.PrivateInfo)
+ }
+ return i, nil
+}
+
+func (m *MsgTopicList) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgTopicList) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.TopicList) > 0 {
+ for _, b := range m.TopicList {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(b)))
+ i += copy(dAtA[i:], b)
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgPublish) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgPublish) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgCommonReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgCommonReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n1, err1 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err1 != nil {
+ return 0, err1
+ }
+ i += n1
+ }
+ return i, nil
+}
+
+func (m *MsgRequestTopic) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequestTopic) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgRequestTopicReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequestTopicReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n2, err2 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err2 != nil {
+ return 0, err2
+ }
+ i += n2
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgRegister) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRegister) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n3, err3 := m.Proc.MarshalTo(dAtA[i:])
+ if err3 != nil {
+ return 0, err3
+ }
+ i += n3
+ }
+ return i, nil
+}
+
+func (m *MsgUnregister) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgUnregister) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n4, err4 := m.Proc.MarshalTo(dAtA[i:])
+ if err4 != nil {
+ return 0, err4
+ }
+ i += n4
+ }
+ return i, nil
+}
+
+func (m *MsgHeartbeat) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgHeartbeat) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n5, err5 := m.Proc.MarshalTo(dAtA[i:])
+ if err5 != nil {
+ return 0, err5
+ }
+ i += n5
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopic) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopic) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopicReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopicReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n6, err6 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err6 != nil {
+ return 0, err6
+ }
+ i += n6
+ }
+ if len(m.NodeAddress) > 0 {
+ for _, msg := range m.NodeAddress {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if m.Addr != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Addr.Size()))
+ n7, err7 := m.Addr.MarshalTo(dAtA[i:])
+ if err7 != nil {
+ return 0, err7
+ }
+ i += n7
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProc) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProc) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProcReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProcReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n8, err8 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err8 != nil {
+ return 0, err8
+ }
+ i += n8
+ }
+ if len(m.ProcList) > 0 {
+ for _, msg := range m.ProcList {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProcReply_Info) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProcReply_Info) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n9, err9 := m.Proc.MarshalTo(dAtA[i:])
+ if err9 != nil {
+ return 0, err9
+ }
+ i += n9
+ }
+ if m.Online {
+ dAtA[i] = 0x10
+ i++
+ if m.Online {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ if m.Service != nil {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Service.Size()))
+ n10, err10 := m.Service.MarshalTo(dAtA[i:])
+ if err10 != nil {
+ return 0, err10
+ }
+ i += n10
+ }
+ if m.LocalSub != nil {
+ dAtA[i] = 0x22
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.LocalSub.Size()))
+ n11, err11 := m.LocalSub.MarshalTo(dAtA[i:])
+ if err11 != nil {
+ return 0, err11
+ }
+ i += n11
+ }
+ if m.NetSub != nil {
+ dAtA[i] = 0x2a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.NetSub.Size()))
+ n12, err12 := m.NetSub.MarshalTo(dAtA[i:])
+ if err12 != nil {
+ return 0, err12
+ }
+ i += n12
+ }
+ return i, nil
+}
+
+func encodeVarintBhomeMsgApi(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *BHAddress) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.MqId != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.MqId))
+ }
+ if m.AbsAddr != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.AbsAddr))
+ }
+ l = len(m.Ip)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Port != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.Port))
+ }
+ return n
+}
+
+func (m *ProcInfo) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Name)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.PublicInfo)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.PrivateInfo)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgTopicList) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if len(m.TopicList) > 0 {
+ for _, b := range m.TopicList {
+ l = len(b)
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgPublish) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgCommonReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRequestTopic) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRequestTopicReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRegister) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgUnregister) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgHeartbeat) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryTopic) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryTopicReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if len(m.NodeAddress) > 0 {
+ for _, e := range m.NodeAddress {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Addr != nil {
+ l = m.Addr.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryProc) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryProcReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if len(m.ProcList) > 0 {
+ for _, e := range m.ProcList {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgQueryProcReply_Info) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Online {
+ n += 2
+ }
+ if m.Service != nil {
+ l = m.Service.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.LocalSub != nil {
+ l = m.LocalSub.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.NetSub != nil {
+ l = m.NetSub.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func sovBhomeMsgApi(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozBhomeMsgApi(x uint64) (n int) {
+ return sovBhomeMsgApi(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *BHAddress) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHAddress: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHAddress: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field MqId", wireType)
+ }
+ m.MqId = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.MqId |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field AbsAddr", wireType)
+ }
+ m.AbsAddr = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.AbsAddr |= int64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Ip", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Ip = append(m.Ip[:0], dAtA[iNdEx:postIndex]...)
+ if m.Ip == nil {
+ m.Ip = []byte{}
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
+ }
+ m.Port = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Port |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *ProcInfo) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: ProcInfo: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: ProcInfo: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Name = append(m.Name[:0], dAtA[iNdEx:postIndex]...)
+ if m.Name == nil {
+ m.Name = []byte{}
+ }
+ iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field PublicInfo", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.PublicInfo = append(m.PublicInfo[:0], dAtA[iNdEx:postIndex]...)
+ if m.PublicInfo == nil {
+ m.PublicInfo = []byte{}
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field PrivateInfo", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.PrivateInfo = append(m.PrivateInfo[:0], dAtA[iNdEx:postIndex]...)
+ if m.PrivateInfo == nil {
+ m.PrivateInfo = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgTopicList) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgTopicList: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgTopicList: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicList", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.TopicList = append(m.TopicList, make([]byte, postIndex-iNdEx))
+ copy(m.TopicList[len(m.TopicList)-1], dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgPublish) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgPublish: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgPublish: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgCommonReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgCommonReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgCommonReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequestTopic) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequestTopic: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequestTopic: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequestTopicReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequestTopicReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequestTopicReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRegister) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRegister: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRegister: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgUnregister) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgUnregister: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUnregister: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgHeartbeat) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgHeartbeat: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgHeartbeat: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopic) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryTopic: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryTopic: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopicReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryTopicReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryTopicReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field NodeAddress", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.NodeAddress = append(m.NodeAddress, &MsgQueryTopicReply_BHNodeAddress{})
+ if err := m.NodeAddress[len(m.NodeAddress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHNodeAddress: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHNodeAddress: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Addr", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Addr == nil {
+ m.Addr = &BHAddress{}
+ }
+ if err := m.Addr.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProc) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryProc: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryProc: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProcReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryProcReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryProcReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcList", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcList = append(m.ProcList, &MsgQueryProcReply_Info{})
+ if err := m.ProcList[len(m.ProcList)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProcReply_Info) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: Info: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: Info: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Online", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Online = bool(v != 0)
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Service == nil {
+ m.Service = &MsgTopicList{}
+ }
+ if err := m.Service.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field LocalSub", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.LocalSub == nil {
+ m.LocalSub = &MsgTopicList{}
+ }
+ if err := m.LocalSub.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 5:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field NetSub", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.NetSub == nil {
+ m.NetSub = &MsgTopicList{}
+ }
+ if err := m.NetSub.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipBhomeMsgApi(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipBhomeMsgApi(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthBhomeMsgApi = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowBhomeMsgApi = fmt.Errorf("proto: integer overflow")
+)
diff --git a/proto/bhome_msg/error_msg.pb.go b/proto/bhome_msg/error_msg.pb.go
new file mode 100644
index 0000000..6a13b8b
--- /dev/null
+++ b/proto/bhome_msg/error_msg.pb.go
@@ -0,0 +1,424 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: error_msg.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type ErrorCode int32
+
+const (
+ ErrorCode_eSuccess ErrorCode = 0
+ ErrorCode_eError ErrorCode = 1
+ ErrorCode_eInvalidInput ErrorCode = 2
+ ErrorCode_eNotRegistered ErrorCode = 3
+ ErrorCode_eNotFound ErrorCode = 4
+ ErrorCode_eOffline ErrorCode = 5
+ ErrorCode_eNoRespond ErrorCode = 6
+ ErrorCode_eAddressNotMatch ErrorCode = 7
+)
+
+var ErrorCode_name = map[int32]string{
+ 0: "eSuccess",
+ 1: "eError",
+ 2: "eInvalidInput",
+ 3: "eNotRegistered",
+ 4: "eNotFound",
+ 5: "eOffline",
+ 6: "eNoRespond",
+ 7: "eAddressNotMatch",
+}
+
+var ErrorCode_value = map[string]int32{
+ "eSuccess": 0,
+ "eError": 1,
+ "eInvalidInput": 2,
+ "eNotRegistered": 3,
+ "eNotFound": 4,
+ "eOffline": 5,
+ "eNoRespond": 6,
+ "eAddressNotMatch": 7,
+}
+
+func (x ErrorCode) String() string {
+ return proto.EnumName(ErrorCode_name, int32(x))
+}
+
+func (ErrorCode) EnumDescriptor() ([]byte, []int) {
+ return fileDescriptor_da93925f7641a6e0, []int{0}
+}
+
+type ErrorMsg struct {
+ ErrCode ErrorCode `protobuf:"varint,1,opt,name=errCode,proto3,enum=bhome_msg.ErrorCode" json:"errCode,omitempty"`
+ ErrString []byte `protobuf:"bytes,2,opt,name=errString,proto3" json:"errString,omitempty"`
+}
+
+func (m *ErrorMsg) Reset() { *m = ErrorMsg{} }
+func (m *ErrorMsg) String() string { return proto.CompactTextString(m) }
+func (*ErrorMsg) ProtoMessage() {}
+func (*ErrorMsg) Descriptor() ([]byte, []int) {
+ return fileDescriptor_da93925f7641a6e0, []int{0}
+}
+func (m *ErrorMsg) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *ErrorMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_ErrorMsg.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *ErrorMsg) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ErrorMsg.Merge(m, src)
+}
+func (m *ErrorMsg) XXX_Size() int {
+ return m.Size()
+}
+func (m *ErrorMsg) XXX_DiscardUnknown() {
+ xxx_messageInfo_ErrorMsg.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_ErrorMsg proto.InternalMessageInfo
+
+func (m *ErrorMsg) GetErrCode() ErrorCode {
+ if m != nil {
+ return m.ErrCode
+ }
+ return ErrorCode_eSuccess
+}
+
+func (m *ErrorMsg) GetErrString() []byte {
+ if m != nil {
+ return m.ErrString
+ }
+ return nil
+}
+
+func init() {
+ proto.RegisterEnum("bhome_msg.ErrorCode", ErrorCode_name, ErrorCode_value)
+ proto.RegisterType((*ErrorMsg)(nil), "bhome_msg.ErrorMsg")
+}
+
+func init() { proto.RegisterFile("error_msg.proto", fileDescriptor_da93925f7641a6e0) }
+
+var fileDescriptor_da93925f7641a6e0 = []byte{
+ // 274 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x44, 0x90, 0xc1, 0x4a, 0xf3, 0x40,
+ 0x10, 0x80, 0xb3, 0xed, 0xff, 0xb7, 0xcd, 0xd8, 0xc6, 0x75, 0xe9, 0xa1, 0x07, 0x59, 0x8a, 0x17,
+ 0x8b, 0x87, 0x08, 0xfa, 0x04, 0x2a, 0x8a, 0x3d, 0x34, 0x42, 0x7a, 0x11, 0x2f, 0xd2, 0x66, 0xa7,
+ 0x69, 0xa0, 0xdd, 0x0d, 0xb3, 0x1b, 0x5f, 0x43, 0x1f, 0xcb, 0x63, 0x8f, 0x1e, 0x25, 0x79, 0x11,
+ 0x49, 0xc0, 0x78, 0xfd, 0xbe, 0x6f, 0x06, 0x66, 0xe0, 0x18, 0x89, 0x0c, 0xbd, 0xee, 0x6d, 0x1a,
+ 0xe6, 0x64, 0x9c, 0x11, 0xfe, 0x7a, 0x6b, 0xf6, 0x58, 0x83, 0xb3, 0x67, 0x18, 0xdc, 0xd7, 0x76,
+ 0x61, 0x53, 0x11, 0x42, 0x1f, 0x89, 0xee, 0x8c, 0xc2, 0x09, 0x9b, 0xb2, 0x59, 0x70, 0x35, 0x0e,
+ 0xdb, 0x30, 0x6c, 0xaa, 0xda, 0xc5, 0xbf, 0x91, 0x38, 0x05, 0x1f, 0x89, 0x96, 0x8e, 0x32, 0x9d,
+ 0x4e, 0x3a, 0x53, 0x36, 0x1b, 0xc6, 0x7f, 0xe0, 0xe2, 0x9d, 0x81, 0xdf, 0x0e, 0x89, 0x21, 0x0c,
+ 0x70, 0x59, 0x24, 0x09, 0x5a, 0xcb, 0x3d, 0x01, 0xd0, 0xc3, 0xc6, 0x71, 0x26, 0x4e, 0x60, 0x84,
+ 0x73, 0xfd, 0xb6, 0xda, 0x65, 0x6a, 0xae, 0xf3, 0xc2, 0xf1, 0x8e, 0x10, 0x10, 0x60, 0x64, 0x5c,
+ 0x8c, 0x69, 0x66, 0x1d, 0x12, 0x2a, 0xde, 0x15, 0x23, 0xf0, 0x6b, 0xf6, 0x60, 0x0a, 0xad, 0xf8,
+ 0xbf, 0x66, 0xdf, 0xd3, 0x66, 0xb3, 0xcb, 0x34, 0xf2, 0xff, 0x22, 0x00, 0xc0, 0xc8, 0xc4, 0x68,
+ 0x73, 0xa3, 0x15, 0xef, 0x89, 0x31, 0x70, 0xbc, 0x51, 0x8a, 0xd0, 0xda, 0xc8, 0xb8, 0xc5, 0xca,
+ 0x25, 0x5b, 0xde, 0xbf, 0x3d, 0xff, 0x2c, 0x25, 0x3b, 0x94, 0x92, 0x7d, 0x97, 0x92, 0x7d, 0x54,
+ 0xd2, 0x3b, 0x54, 0xd2, 0xfb, 0xaa, 0xa4, 0xf7, 0xd8, 0x7d, 0x39, 0x0a, 0x2f, 0xdb, 0x5b, 0xd7,
+ 0xbd, 0xe6, 0x4d, 0xd7, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x33, 0xa4, 0xff, 0xc0, 0x39, 0x01,
+ 0x00, 0x00,
+}
+
+func (m *ErrorMsg) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *ErrorMsg) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ErrCode != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintErrorMsg(dAtA, i, uint64(m.ErrCode))
+ }
+ if len(m.ErrString) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintErrorMsg(dAtA, i, uint64(len(m.ErrString)))
+ i += copy(dAtA[i:], m.ErrString)
+ }
+ return i, nil
+}
+
+func encodeVarintErrorMsg(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *ErrorMsg) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ErrCode != 0 {
+ n += 1 + sovErrorMsg(uint64(m.ErrCode))
+ }
+ l = len(m.ErrString)
+ if l > 0 {
+ n += 1 + l + sovErrorMsg(uint64(l))
+ }
+ return n
+}
+
+func sovErrorMsg(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozErrorMsg(x uint64) (n int) {
+ return sovErrorMsg(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *ErrorMsg) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: ErrorMsg: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: ErrorMsg: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrCode", wireType)
+ }
+ m.ErrCode = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ErrCode |= ErrorCode(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrString", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ErrString = append(m.ErrString[:0], dAtA[iNdEx:postIndex]...)
+ if m.ErrString == nil {
+ m.ErrString = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipErrorMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipErrorMsg(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipErrorMsg(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthErrorMsg = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowErrorMsg = fmt.Errorf("proto: integer overflow")
+)
diff --git a/proto/cpp/CMakeLists.txt b/proto/cpp/CMakeLists.txt
new file mode 100644
index 0000000..f193a2e
--- /dev/null
+++ b/proto/cpp/CMakeLists.txt
@@ -0,0 +1,56 @@
+cmake_minimum_required(VERSION 3.0)
+
+set (Target "bhome_msg")
+project(${Target})
+
+#璁剧疆杈撳嚭璺緞
+SET(MESSAGE_DIR ${CMAKE_SOURCE_DIR}/proto)
+if(EXISTS "${CMAKE_SOURCE_DIR}/proto" AND IS_DIRECTORY "${CMAKE_SOURCE_DIR}/proto")
+ SET(PROTO_META_BASE_DIR ${MESSAGE_DIR})
+else()
+ file(MAKE_DIRECTORY ${MESSAGE_DIR})
+ SET(PROTO_META_BASE_DIR ${MESSAGE_DIR})
+endif()
+
+
+#鑾峰彇闇�瑕佺紪璇戠殑proto鏂囦欢
+set(MSG_PROTOS
+ bhome_msg.proto
+ bhome_msg_api.proto
+ error_msg.proto
+ )
+
+set(MESSAGE_SRC "")
+set(MESSAGE_HDRS "")
+
+foreach(msg ${MSG_PROTOS})
+ message(${msg})
+
+ get_filename_component(FIL_WE ${msg} NAME_WE)
+ message(${FIL_WE})
+
+ list(APPEND MESSAGE_SRC "${MESSAGE_DIR}/${FIL_WE}.pb.cc")
+ list(APPEND MESSAGE_HDRS "${MESSAGE_DIR}/${FIL_WE}.pb.h")
+
+ # 浣跨敤鑷畾涔夊懡浠�
+ execute_process(
+ COMMAND ${CMAKE_SOURCE_DIR}/protobuf/protoc --cpp_out=${MESSAGE_DIR} --proto_path=${CMAKE_SOURCE_DIR}/proto/source ${msg}
+ )
+
+endforeach()
+
+# 璁剧疆鏂囦欢灞炴�т负 GENERATED
+set_source_files_properties(${MESSAGE_SRC} ${MESSAGE_HDRS} PROPERTIES GENERATED TRUE)
+
+# 娣诲姞鑷畾涔塼arget
+add_custom_target(generate_message ALL
+ DEPENDS ${MESSAGE_SRC} ${MESSAGE_HDRS}
+ COMMENT "generate message target"
+ VERBATIM
+ )
+
+
+include_directories(${CMAKE_SOURCE_DIR}/protobuf/include)
+
+add_library(${Target} STATIC ${MESSAGE_SRC})
+target_link_libraries(${Target} ${CMAKE_SOURCE_DIR}/protobuf/lib/libprotobuf-lite.a)
\ No newline at end of file
diff --git a/src/proto/bhome_msg.pb.cc b/proto/source/bhome_msg.pb.cc
similarity index 100%
rename from src/proto/bhome_msg.pb.cc
rename to proto/source/bhome_msg.pb.cc
diff --git a/src/proto/bhome_msg.pb.h b/proto/source/bhome_msg.pb.h
similarity index 100%
rename from src/proto/bhome_msg.pb.h
rename to proto/source/bhome_msg.pb.h
diff --git a/src/proto/bhome_msg.proto b/proto/source/bhome_msg.proto
similarity index 100%
rename from src/proto/bhome_msg.proto
rename to proto/source/bhome_msg.proto
diff --git a/proto/source/bhome_msg/bhome_msg.pb.go b/proto/source/bhome_msg/bhome_msg.pb.go
new file mode 100644
index 0000000..1010ed1
--- /dev/null
+++ b/proto/source/bhome_msg/bhome_msg.pb.go
@@ -0,0 +1,2812 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: bhome_msg.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type MsgType int32
+
+const (
+ MsgType_kMsgTypeInvalid MsgType = 0
+ MsgType_kMsgTypeRawData MsgType = 1
+ MsgType_kMsgTypeCommonReply MsgType = 2
+ MsgType_kMsgTypeProcInit MsgType = 8
+ MsgType_kMsgTypeProcInitReply MsgType = 9
+ MsgType_kMsgTypeRegister MsgType = 10
+ // kMsgTypeRegisterReply= 11;
+ MsgType_kMsgTypeHeartbeat MsgType = 12
+ // kMsgTypeHeartbeatReply = 13;
+ MsgType_kMsgTypeQueryTopic MsgType = 14
+ MsgType_kMsgTypeQueryTopicReply MsgType = 15
+ MsgType_kMsgTypeRequestTopic MsgType = 16
+ MsgType_kMsgTypeRequestTopicReply MsgType = 17
+ MsgType_kMsgTypeRegisterRPC MsgType = 18
+ MsgType_kMsgTypePublish MsgType = 20
+ // kMsgTypePublishReply = 21;
+ MsgType_kMsgTypeSubscribe MsgType = 22
+ // kMsgTypeSubscribeReply = 23;
+ MsgType_kMsgTypeUnsubscribe MsgType = 24
+ // kMsgTypeUnsubscribeReply = 25;
+ MsgType_kMsgTypeUnregister MsgType = 26
+ // kMsgTypeUnregisterReply = 27;
+ MsgType_kMsgTypeQueryProc MsgType = 28
+ MsgType_kMsgTypeQueryProcReply MsgType = 29
+)
+
+var MsgType_name = map[int32]string{
+ 0: "kMsgTypeInvalid",
+ 1: "kMsgTypeRawData",
+ 2: "kMsgTypeCommonReply",
+ 8: "kMsgTypeProcInit",
+ 9: "kMsgTypeProcInitReply",
+ 10: "kMsgTypeRegister",
+ 12: "kMsgTypeHeartbeat",
+ 14: "kMsgTypeQueryTopic",
+ 15: "kMsgTypeQueryTopicReply",
+ 16: "kMsgTypeRequestTopic",
+ 17: "kMsgTypeRequestTopicReply",
+ 18: "kMsgTypeRegisterRPC",
+ 20: "kMsgTypePublish",
+ 22: "kMsgTypeSubscribe",
+ 24: "kMsgTypeUnsubscribe",
+ 26: "kMsgTypeUnregister",
+ 28: "kMsgTypeQueryProc",
+ 29: "kMsgTypeQueryProcReply",
+}
+
+var MsgType_value = map[string]int32{
+ "kMsgTypeInvalid": 0,
+ "kMsgTypeRawData": 1,
+ "kMsgTypeCommonReply": 2,
+ "kMsgTypeProcInit": 8,
+ "kMsgTypeProcInitReply": 9,
+ "kMsgTypeRegister": 10,
+ "kMsgTypeHeartbeat": 12,
+ "kMsgTypeQueryTopic": 14,
+ "kMsgTypeQueryTopicReply": 15,
+ "kMsgTypeRequestTopic": 16,
+ "kMsgTypeRequestTopicReply": 17,
+ "kMsgTypeRegisterRPC": 18,
+ "kMsgTypePublish": 20,
+ "kMsgTypeSubscribe": 22,
+ "kMsgTypeUnsubscribe": 24,
+ "kMsgTypeUnregister": 26,
+ "kMsgTypeQueryProc": 28,
+ "kMsgTypeQueryProcReply": 29,
+}
+
+func (x MsgType) String() string {
+ return proto.EnumName(MsgType_name, int32(x))
+}
+
+func (MsgType) EnumDescriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{0}
+}
+
+type BHMsgHead struct {
+ MsgId []byte `protobuf:"bytes,1,opt,name=msg_id,json=msgId,proto3" json:"msg_id,omitempty"`
+ Route []*BHAddress `protobuf:"bytes,2,rep,name=route,proto3" json:"route,omitempty"`
+ Timestamp int64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
+ Type int32 `protobuf:"varint,4,opt,name=type,proto3" json:"type,omitempty"`
+ SsnId uint64 `protobuf:"varint,5,opt,name=ssn_id,json=ssnId,proto3" json:"ssn_id,omitempty"`
+ ProcId []byte `protobuf:"bytes,6,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Topic []byte `protobuf:"bytes,7,opt,name=topic,proto3" json:"topic,omitempty"`
+ Dest *BHAddress `protobuf:"bytes,8,opt,name=dest,proto3" json:"dest,omitempty"`
+}
+
+func (m *BHMsgHead) Reset() { *m = BHMsgHead{} }
+func (m *BHMsgHead) String() string { return proto.CompactTextString(m) }
+func (*BHMsgHead) ProtoMessage() {}
+func (*BHMsgHead) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{0}
+}
+func (m *BHMsgHead) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHMsgHead) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHMsgHead.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHMsgHead) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHMsgHead.Merge(m, src)
+}
+func (m *BHMsgHead) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHMsgHead) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHMsgHead.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHMsgHead proto.InternalMessageInfo
+
+func (m *BHMsgHead) GetMsgId() []byte {
+ if m != nil {
+ return m.MsgId
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetRoute() []*BHAddress {
+ if m != nil {
+ return m.Route
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetTimestamp() int64 {
+ if m != nil {
+ return m.Timestamp
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetType() int32 {
+ if m != nil {
+ return m.Type
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetSsnId() uint64 {
+ if m != nil {
+ return m.SsnId
+ }
+ return 0
+}
+
+func (m *BHMsgHead) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *BHMsgHead) GetDest() *BHAddress {
+ if m != nil {
+ return m.Dest
+ }
+ return nil
+}
+
+type MsgSubscribe struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+ Network bool `protobuf:"varint,2,opt,name=network,proto3" json:"network,omitempty"`
+}
+
+func (m *MsgSubscribe) Reset() { *m = MsgSubscribe{} }
+func (m *MsgSubscribe) String() string { return proto.CompactTextString(m) }
+func (*MsgSubscribe) ProtoMessage() {}
+func (*MsgSubscribe) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{1}
+}
+func (m *MsgSubscribe) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgSubscribe) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgSubscribe.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgSubscribe) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgSubscribe.Merge(m, src)
+}
+func (m *MsgSubscribe) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgSubscribe) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgSubscribe.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgSubscribe proto.InternalMessageInfo
+
+func (m *MsgSubscribe) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+func (m *MsgSubscribe) GetNetwork() bool {
+ if m != nil {
+ return m.Network
+ }
+ return false
+}
+
+type MsgUnsubscribe struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+ Network bool `protobuf:"varint,2,opt,name=network,proto3" json:"network,omitempty"`
+}
+
+func (m *MsgUnsubscribe) Reset() { *m = MsgUnsubscribe{} }
+func (m *MsgUnsubscribe) String() string { return proto.CompactTextString(m) }
+func (*MsgUnsubscribe) ProtoMessage() {}
+func (*MsgUnsubscribe) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{2}
+}
+func (m *MsgUnsubscribe) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgUnsubscribe) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUnsubscribe.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgUnsubscribe) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUnsubscribe.Merge(m, src)
+}
+func (m *MsgUnsubscribe) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgUnsubscribe) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUnsubscribe.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUnsubscribe proto.InternalMessageInfo
+
+func (m *MsgUnsubscribe) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+func (m *MsgUnsubscribe) GetNetwork() bool {
+ if m != nil {
+ return m.Network
+ }
+ return false
+}
+
+type MsgRegisterRPC struct {
+ Topics *MsgTopicList `protobuf:"bytes,1,opt,name=topics,proto3" json:"topics,omitempty"`
+}
+
+func (m *MsgRegisterRPC) Reset() { *m = MsgRegisterRPC{} }
+func (m *MsgRegisterRPC) String() string { return proto.CompactTextString(m) }
+func (*MsgRegisterRPC) ProtoMessage() {}
+func (*MsgRegisterRPC) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{3}
+}
+func (m *MsgRegisterRPC) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRegisterRPC) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRegisterRPC.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRegisterRPC) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRegisterRPC.Merge(m, src)
+}
+func (m *MsgRegisterRPC) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRegisterRPC) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRegisterRPC.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRegisterRPC proto.InternalMessageInfo
+
+func (m *MsgRegisterRPC) GetTopics() *MsgTopicList {
+ if m != nil {
+ return m.Topics
+ }
+ return nil
+}
+
+type MsgProcInit struct {
+ ExtraMqNum int32 `protobuf:"varint,1,opt,name=extra_mq_num,json=extraMqNum,proto3" json:"extra_mq_num,omitempty"`
+}
+
+func (m *MsgProcInit) Reset() { *m = MsgProcInit{} }
+func (m *MsgProcInit) String() string { return proto.CompactTextString(m) }
+func (*MsgProcInit) ProtoMessage() {}
+func (*MsgProcInit) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{4}
+}
+func (m *MsgProcInit) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgProcInit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgProcInit.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgProcInit) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgProcInit.Merge(m, src)
+}
+func (m *MsgProcInit) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgProcInit) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgProcInit.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgProcInit proto.InternalMessageInfo
+
+func (m *MsgProcInit) GetExtraMqNum() int32 {
+ if m != nil {
+ return m.ExtraMqNum
+ }
+ return 0
+}
+
+type MsgProcInitReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ ProcIndex int32 `protobuf:"varint,2,opt,name=proc_index,json=procIndex,proto3" json:"proc_index,omitempty"`
+ ExtraMqs []*BHAddress `protobuf:"bytes,3,rep,name=extra_mqs,json=extraMqs,proto3" json:"extra_mqs,omitempty"`
+}
+
+func (m *MsgProcInitReply) Reset() { *m = MsgProcInitReply{} }
+func (m *MsgProcInitReply) String() string { return proto.CompactTextString(m) }
+func (*MsgProcInitReply) ProtoMessage() {}
+func (*MsgProcInitReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{5}
+}
+func (m *MsgProcInitReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgProcInitReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgProcInitReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgProcInitReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgProcInitReply.Merge(m, src)
+}
+func (m *MsgProcInitReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgProcInitReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgProcInitReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgProcInitReply proto.InternalMessageInfo
+
+func (m *MsgProcInitReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgProcInitReply) GetProcIndex() int32 {
+ if m != nil {
+ return m.ProcIndex
+ }
+ return 0
+}
+
+func (m *MsgProcInitReply) GetExtraMqs() []*BHAddress {
+ if m != nil {
+ return m.ExtraMqs
+ }
+ return nil
+}
+
+type MsgRequest struct {
+ // oneof body;
+ //
+ // Types that are valid to be assigned to Request:
+ // *MsgRequest_Register
+ // *MsgRequest_TopicRequest
+ // *MsgRequest_TopicQuery
+ Request isMsgRequest_Request `protobuf_oneof:"request"`
+}
+
+func (m *MsgRequest) Reset() { *m = MsgRequest{} }
+func (m *MsgRequest) String() string { return proto.CompactTextString(m) }
+func (*MsgRequest) ProtoMessage() {}
+func (*MsgRequest) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{6}
+}
+func (m *MsgRequest) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequest.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequest) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequest.Merge(m, src)
+}
+func (m *MsgRequest) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequest) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequest.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequest proto.InternalMessageInfo
+
+type isMsgRequest_Request interface {
+ isMsgRequest_Request()
+ MarshalTo([]byte) (int, error)
+ Size() int
+}
+
+type MsgRequest_Register struct {
+ Register *MsgRegister `protobuf:"bytes,1,opt,name=register,proto3,oneof"`
+}
+type MsgRequest_TopicRequest struct {
+ TopicRequest *MsgRequestTopic `protobuf:"bytes,2,opt,name=topic_request,json=topicRequest,proto3,oneof"`
+}
+type MsgRequest_TopicQuery struct {
+ TopicQuery *MsgQueryTopic `protobuf:"bytes,3,opt,name=topic_query,json=topicQuery,proto3,oneof"`
+}
+
+func (*MsgRequest_Register) isMsgRequest_Request() {}
+func (*MsgRequest_TopicRequest) isMsgRequest_Request() {}
+func (*MsgRequest_TopicQuery) isMsgRequest_Request() {}
+
+func (m *MsgRequest) GetRequest() isMsgRequest_Request {
+ if m != nil {
+ return m.Request
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetRegister() *MsgRegister {
+ if x, ok := m.GetRequest().(*MsgRequest_Register); ok {
+ return x.Register
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetTopicRequest() *MsgRequestTopic {
+ if x, ok := m.GetRequest().(*MsgRequest_TopicRequest); ok {
+ return x.TopicRequest
+ }
+ return nil
+}
+
+func (m *MsgRequest) GetTopicQuery() *MsgQueryTopic {
+ if x, ok := m.GetRequest().(*MsgRequest_TopicQuery); ok {
+ return x.TopicQuery
+ }
+ return nil
+}
+
+// XXX_OneofFuncs is for the internal use of the proto package.
+func (*MsgRequest) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
+ return _MsgRequest_OneofMarshaler, _MsgRequest_OneofUnmarshaler, _MsgRequest_OneofSizer, []interface{}{
+ (*MsgRequest_Register)(nil),
+ (*MsgRequest_TopicRequest)(nil),
+ (*MsgRequest_TopicQuery)(nil),
+ }
+}
+
+func _MsgRequest_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
+ m := msg.(*MsgRequest)
+ // request
+ switch x := m.Request.(type) {
+ case *MsgRequest_Register:
+ _ = b.EncodeVarint(1<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Register); err != nil {
+ return err
+ }
+ case *MsgRequest_TopicRequest:
+ _ = b.EncodeVarint(2<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.TopicRequest); err != nil {
+ return err
+ }
+ case *MsgRequest_TopicQuery:
+ _ = b.EncodeVarint(3<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.TopicQuery); err != nil {
+ return err
+ }
+ case nil:
+ default:
+ return fmt.Errorf("MsgRequest.Request has unexpected type %T", x)
+ }
+ return nil
+}
+
+func _MsgRequest_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
+ m := msg.(*MsgRequest)
+ switch tag {
+ case 1: // request.register
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRegister)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_Register{msg}
+ return true, err
+ case 2: // request.topic_request
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRequestTopic)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_TopicRequest{msg}
+ return true, err
+ case 3: // request.topic_query
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgQueryTopic)
+ err := b.DecodeMessage(msg)
+ m.Request = &MsgRequest_TopicQuery{msg}
+ return true, err
+ default:
+ return false, nil
+ }
+}
+
+func _MsgRequest_OneofSizer(msg proto.Message) (n int) {
+ m := msg.(*MsgRequest)
+ // request
+ switch x := m.Request.(type) {
+ case *MsgRequest_Register:
+ s := proto.Size(x.Register)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *MsgRequest_TopicRequest:
+ s := proto.Size(x.TopicRequest)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *MsgRequest_TopicQuery:
+ s := proto.Size(x.TopicQuery)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case nil:
+ default:
+ panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
+ }
+ return n
+}
+
+type MsgReply struct {
+ ErrMsg *ErrorMsg `protobuf:"bytes,1,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"`
+}
+
+func (m *MsgReply) Reset() { *m = MsgReply{} }
+func (m *MsgReply) String() string { return proto.CompactTextString(m) }
+func (*MsgReply) ProtoMessage() {}
+func (*MsgReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{7}
+}
+func (m *MsgReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgReply.Merge(m, src)
+}
+func (m *MsgReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgReply proto.InternalMessageInfo
+
+func (m *MsgReply) GetErrMsg() *ErrorMsg {
+ if m != nil {
+ return m.ErrMsg
+ }
+ return nil
+}
+
+type BHMsgBody struct {
+ // Types that are valid to be assigned to Reqrep:
+ // *BHMsgBody_Request
+ // *BHMsgBody_Reply
+ Reqrep isBHMsgBody_Reqrep `protobuf_oneof:"reqrep"`
+}
+
+func (m *BHMsgBody) Reset() { *m = BHMsgBody{} }
+func (m *BHMsgBody) String() string { return proto.CompactTextString(m) }
+func (*BHMsgBody) ProtoMessage() {}
+func (*BHMsgBody) Descriptor() ([]byte, []int) {
+ return fileDescriptor_88ce6d52215a3d3f, []int{8}
+}
+func (m *BHMsgBody) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHMsgBody) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHMsgBody.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHMsgBody) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHMsgBody.Merge(m, src)
+}
+func (m *BHMsgBody) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHMsgBody) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHMsgBody.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHMsgBody proto.InternalMessageInfo
+
+type isBHMsgBody_Reqrep interface {
+ isBHMsgBody_Reqrep()
+ MarshalTo([]byte) (int, error)
+ Size() int
+}
+
+type BHMsgBody_Request struct {
+ Request *MsgRequest `protobuf:"bytes,1,opt,name=request,proto3,oneof"`
+}
+type BHMsgBody_Reply struct {
+ Reply *MsgReply `protobuf:"bytes,2,opt,name=reply,proto3,oneof"`
+}
+
+func (*BHMsgBody_Request) isBHMsgBody_Reqrep() {}
+func (*BHMsgBody_Reply) isBHMsgBody_Reqrep() {}
+
+func (m *BHMsgBody) GetReqrep() isBHMsgBody_Reqrep {
+ if m != nil {
+ return m.Reqrep
+ }
+ return nil
+}
+
+func (m *BHMsgBody) GetRequest() *MsgRequest {
+ if x, ok := m.GetReqrep().(*BHMsgBody_Request); ok {
+ return x.Request
+ }
+ return nil
+}
+
+func (m *BHMsgBody) GetReply() *MsgReply {
+ if x, ok := m.GetReqrep().(*BHMsgBody_Reply); ok {
+ return x.Reply
+ }
+ return nil
+}
+
+// XXX_OneofFuncs is for the internal use of the proto package.
+func (*BHMsgBody) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
+ return _BHMsgBody_OneofMarshaler, _BHMsgBody_OneofUnmarshaler, _BHMsgBody_OneofSizer, []interface{}{
+ (*BHMsgBody_Request)(nil),
+ (*BHMsgBody_Reply)(nil),
+ }
+}
+
+func _BHMsgBody_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
+ m := msg.(*BHMsgBody)
+ // reqrep
+ switch x := m.Reqrep.(type) {
+ case *BHMsgBody_Request:
+ _ = b.EncodeVarint(1<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Request); err != nil {
+ return err
+ }
+ case *BHMsgBody_Reply:
+ _ = b.EncodeVarint(2<<3 | proto.WireBytes)
+ if err := b.EncodeMessage(x.Reply); err != nil {
+ return err
+ }
+ case nil:
+ default:
+ return fmt.Errorf("BHMsgBody.Reqrep has unexpected type %T", x)
+ }
+ return nil
+}
+
+func _BHMsgBody_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
+ m := msg.(*BHMsgBody)
+ switch tag {
+ case 1: // reqrep.request
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgRequest)
+ err := b.DecodeMessage(msg)
+ m.Reqrep = &BHMsgBody_Request{msg}
+ return true, err
+ case 2: // reqrep.reply
+ if wire != proto.WireBytes {
+ return true, proto.ErrInternalBadWireType
+ }
+ msg := new(MsgReply)
+ err := b.DecodeMessage(msg)
+ m.Reqrep = &BHMsgBody_Reply{msg}
+ return true, err
+ default:
+ return false, nil
+ }
+}
+
+func _BHMsgBody_OneofSizer(msg proto.Message) (n int) {
+ m := msg.(*BHMsgBody)
+ // reqrep
+ switch x := m.Reqrep.(type) {
+ case *BHMsgBody_Request:
+ s := proto.Size(x.Request)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case *BHMsgBody_Reply:
+ s := proto.Size(x.Reply)
+ n += 1 // tag and wire
+ n += proto.SizeVarint(uint64(s))
+ n += s
+ case nil:
+ default:
+ panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
+ }
+ return n
+}
+
+func init() {
+ proto.RegisterEnum("bhome_msg.MsgType", MsgType_name, MsgType_value)
+ proto.RegisterType((*BHMsgHead)(nil), "bhome_msg.BHMsgHead")
+ proto.RegisterType((*MsgSubscribe)(nil), "bhome_msg.MsgSubscribe")
+ proto.RegisterType((*MsgUnsubscribe)(nil), "bhome_msg.MsgUnsubscribe")
+ proto.RegisterType((*MsgRegisterRPC)(nil), "bhome_msg.MsgRegisterRPC")
+ proto.RegisterType((*MsgProcInit)(nil), "bhome_msg.MsgProcInit")
+ proto.RegisterType((*MsgProcInitReply)(nil), "bhome_msg.MsgProcInitReply")
+ proto.RegisterType((*MsgRequest)(nil), "bhome_msg.MsgRequest")
+ proto.RegisterType((*MsgReply)(nil), "bhome_msg.MsgReply")
+ proto.RegisterType((*BHMsgBody)(nil), "bhome_msg.BHMsgBody")
+}
+
+func init() { proto.RegisterFile("bhome_msg.proto", fileDescriptor_88ce6d52215a3d3f) }
+
+var fileDescriptor_88ce6d52215a3d3f = []byte{
+ // 809 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x55, 0xcd, 0x6e, 0xdb, 0x46,
+ 0x10, 0x16, 0x2d, 0x53, 0xa2, 0x46, 0x6a, 0xbc, 0x19, 0xc9, 0x36, 0xa3, 0xc6, 0x02, 0xc1, 0x4b,
+ 0x85, 0xa4, 0xb0, 0x11, 0xb5, 0x87, 0x02, 0xbd, 0xd4, 0x72, 0x0a, 0xd0, 0x40, 0x55, 0xb8, 0xdb,
+ 0xe6, 0xd0, 0xf6, 0x20, 0x50, 0xe6, 0x82, 0x21, 0x22, 0xfe, 0x68, 0x77, 0xd9, 0x44, 0x6f, 0xd1,
+ 0xf6, 0x8d, 0x7a, 0xeb, 0xa5, 0x40, 0x8e, 0x3d, 0x16, 0xf6, 0x0b, 0xf4, 0x11, 0x8a, 0x5d, 0x92,
+ 0x12, 0xe3, 0xc4, 0x31, 0x7a, 0xc8, 0x6d, 0xf7, 0x9b, 0xf9, 0xbe, 0xf9, 0xd9, 0x19, 0x12, 0xf6,
+ 0x16, 0xcf, 0xd3, 0x98, 0xcd, 0x63, 0x11, 0x1e, 0x67, 0x3c, 0x95, 0x29, 0x76, 0x36, 0xc0, 0xb0,
+ 0xbf, 0x39, 0xce, 0xfd, 0x2c, 0x2a, 0xec, 0xc3, 0x3d, 0xc6, 0x79, 0xca, 0xb7, 0x04, 0xf7, 0x5f,
+ 0x03, 0x3a, 0x53, 0x6f, 0x26, 0x42, 0x8f, 0xf9, 0x01, 0xee, 0x43, 0x4b, 0xf9, 0x47, 0x81, 0x6d,
+ 0x38, 0xc6, 0xb8, 0x47, 0xcd, 0x58, 0x84, 0xe7, 0x01, 0x3e, 0x02, 0x93, 0xa7, 0xb9, 0x64, 0xf6,
+ 0x8e, 0xd3, 0x1c, 0x77, 0x27, 0x83, 0xe3, 0x6d, 0xd8, 0xa9, 0x77, 0x1a, 0x04, 0x9c, 0x09, 0x41,
+ 0x0b, 0x17, 0x7c, 0x08, 0x1d, 0x19, 0xc5, 0x4c, 0x48, 0x3f, 0xce, 0xec, 0xa6, 0x63, 0x8c, 0x9b,
+ 0x74, 0x0b, 0x20, 0xc2, 0xae, 0x5c, 0x67, 0xcc, 0xde, 0x75, 0x8c, 0xb1, 0x49, 0xf5, 0x59, 0x05,
+ 0x15, 0x22, 0x51, 0x41, 0x4d, 0xc7, 0x18, 0xef, 0x52, 0x53, 0x88, 0xe4, 0x3c, 0xc0, 0x43, 0x68,
+ 0x67, 0x3c, 0xbd, 0x54, 0x78, 0x4b, 0x27, 0xd3, 0x52, 0xd7, 0xf3, 0x00, 0x07, 0x60, 0xca, 0x34,
+ 0x8b, 0x2e, 0xed, 0x76, 0x91, 0xa3, 0xbe, 0xe0, 0x18, 0x76, 0x03, 0x26, 0xa4, 0x6d, 0x39, 0xc6,
+ 0xad, 0x29, 0x6a, 0x0f, 0xf7, 0x47, 0xe8, 0xcd, 0x44, 0xf8, 0x7d, 0xbe, 0x10, 0x97, 0x3c, 0x5a,
+ 0x30, 0x3c, 0x81, 0x96, 0x96, 0x10, 0xba, 0xe8, 0xee, 0xe4, 0xb0, 0xc6, 0x9d, 0x89, 0xf0, 0x07,
+ 0x65, 0xfb, 0x26, 0x12, 0x92, 0x96, 0x6e, 0x68, 0x43, 0x3b, 0x61, 0xf2, 0x65, 0xca, 0x5f, 0xd8,
+ 0x3b, 0x8e, 0x31, 0xb6, 0x68, 0x75, 0x75, 0x7f, 0x86, 0x7b, 0x33, 0x11, 0x3e, 0x4b, 0xc4, 0x87,
+ 0x10, 0x3f, 0xd5, 0xe2, 0x94, 0x85, 0x91, 0x90, 0x8c, 0xd3, 0x8b, 0xb3, 0xff, 0x2d, 0xee, 0x9e,
+ 0x40, 0x77, 0x26, 0xc2, 0x0b, 0xd5, 0xc7, 0x24, 0x92, 0xe8, 0x40, 0x8f, 0xbd, 0x92, 0xdc, 0x9f,
+ 0xc7, 0xab, 0x79, 0x92, 0xc7, 0x5a, 0xc5, 0xa4, 0xa0, 0xb1, 0xd9, 0xea, 0xdb, 0x3c, 0x76, 0x7f,
+ 0x33, 0x80, 0xd4, 0x18, 0x94, 0x65, 0xcb, 0x35, 0x3e, 0x86, 0x16, 0xe3, 0x3c, 0x16, 0x61, 0x19,
+ 0xb6, 0x5f, 0x0b, 0xfb, 0xb5, 0x9a, 0x2f, 0x95, 0x66, 0xe9, 0x82, 0x47, 0x00, 0xc5, 0x33, 0x26,
+ 0x01, 0x7b, 0xa5, 0x4b, 0x32, 0x69, 0x47, 0xbf, 0xa4, 0x02, 0xf0, 0x09, 0x74, 0xaa, 0x14, 0x84,
+ 0xdd, 0x7c, 0xcf, 0x78, 0x59, 0x65, 0x56, 0xc2, 0xfd, 0xcb, 0x00, 0xd0, 0x8d, 0x58, 0xe5, 0x4c,
+ 0x48, 0xfc, 0x1c, 0x2c, 0x5e, 0xf6, 0xa4, 0xcc, 0xe7, 0xe0, 0xcd, 0x36, 0x54, 0x1d, 0xf3, 0x1a,
+ 0x74, 0xe3, 0x89, 0xa7, 0xf0, 0x91, 0xee, 0xc9, 0x9c, 0x17, 0x32, 0x3a, 0xb3, 0xee, 0x64, 0x78,
+ 0x93, 0xaa, 0x8d, 0xba, 0x91, 0x5e, 0x83, 0xf6, 0x34, 0xa5, 0x0a, 0xfc, 0x25, 0x74, 0x0b, 0x89,
+ 0x55, 0xce, 0xf8, 0x5a, 0xcf, 0x7a, 0x77, 0x62, 0xbf, 0x29, 0xf0, 0x9d, 0x32, 0x55, 0x74, 0xd0,
+ 0xee, 0x1a, 0x9a, 0x76, 0xa0, 0x5d, 0x46, 0x76, 0xbf, 0x00, 0x4b, 0x87, 0x52, 0xad, 0xfd, 0x14,
+ 0xda, 0x8c, 0xeb, 0xfd, 0xbc, 0xab, 0xb7, 0x33, 0x11, 0xba, 0x79, 0xb9, 0xbb, 0xd3, 0x34, 0x58,
+ 0xe3, 0x93, 0x8d, 0x62, 0x49, 0xdd, 0x7f, 0x67, 0x2d, 0x5e, 0x83, 0x56, 0x7e, 0xf8, 0x18, 0x4c,
+ 0xae, 0xc2, 0x96, 0xc5, 0xf7, 0x6f, 0x12, 0xb2, 0xe5, 0xda, 0x6b, 0xd0, 0xc2, 0x67, 0x6a, 0x41,
+ 0x8b, 0xb3, 0x15, 0x67, 0xd9, 0xa3, 0x3f, 0x9a, 0xd0, 0x56, 0xe3, 0xa5, 0x96, 0xb7, 0x0f, 0x7b,
+ 0x2f, 0xca, 0xf3, 0x79, 0xf2, 0x8b, 0xbf, 0x8c, 0x02, 0xd2, 0xa8, 0x83, 0xd4, 0x7f, 0xf9, 0xd4,
+ 0x97, 0x3e, 0x31, 0xf0, 0x10, 0xfa, 0x15, 0x78, 0x96, 0xc6, 0x71, 0x9a, 0x68, 0x7d, 0xb2, 0x83,
+ 0x03, 0x20, 0x95, 0xa1, 0x9a, 0x33, 0x62, 0xe1, 0x03, 0xd8, 0xbf, 0x89, 0x16, 0x84, 0x4e, 0x9d,
+ 0x50, 0xbd, 0x2d, 0x01, 0xdc, 0x87, 0xfb, 0x15, 0xea, 0x31, 0x9f, 0xcb, 0x05, 0xf3, 0x25, 0xe9,
+ 0xe1, 0x01, 0x60, 0x05, 0x6f, 0x1f, 0x83, 0xdc, 0xc3, 0x8f, 0xe1, 0xf0, 0x6d, 0xbc, 0x88, 0xb0,
+ 0x87, 0x36, 0x0c, 0xb6, 0x11, 0xb6, 0x23, 0x40, 0x08, 0x1e, 0xc1, 0x83, 0x77, 0x59, 0x0a, 0xe2,
+ 0xfd, 0x7a, 0x91, 0xb5, 0x45, 0x25, 0x58, 0x6f, 0xc9, 0x45, 0xbe, 0x58, 0x46, 0xe2, 0x39, 0x19,
+ 0xd4, 0x53, 0xde, 0x7c, 0x8e, 0xc8, 0x41, 0x5d, 0xa4, 0xf6, 0x29, 0x21, 0x76, 0xbd, 0x96, 0x67,
+ 0x49, 0x35, 0xca, 0x64, 0x58, 0xd7, 0xd1, 0xb5, 0xa8, 0x86, 0x91, 0x87, 0x38, 0x84, 0x83, 0xb7,
+ 0xe0, 0x22, 0xd1, 0xa3, 0xc9, 0xef, 0x06, 0x58, 0x45, 0xe6, 0x17, 0x67, 0xf8, 0x15, 0x98, 0xda,
+ 0x01, 0x6f, 0x9d, 0xde, 0xe1, 0xd1, 0x6d, 0x96, 0x62, 0x6e, 0x9f, 0x42, 0xbb, 0x5a, 0x8b, 0xf7,
+ 0xac, 0xd0, 0x1d, 0x2a, 0xd3, 0x4f, 0xfe, 0xbc, 0x1a, 0x19, 0xaf, 0xaf, 0x46, 0xc6, 0x3f, 0x57,
+ 0x23, 0xe3, 0xd7, 0xeb, 0x51, 0xe3, 0xf5, 0xf5, 0xa8, 0xf1, 0xf7, 0xf5, 0xa8, 0xe1, 0x35, 0x7f,
+ 0xea, 0x1e, 0x9f, 0x6c, 0xb8, 0x8b, 0x96, 0xfe, 0x79, 0x7d, 0xf6, 0x5f, 0x00, 0x00, 0x00, 0xff,
+ 0xff, 0x27, 0x28, 0x5d, 0xb5, 0x00, 0x07, 0x00, 0x00,
+}
+
+func (m *BHMsgHead) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHMsgHead) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.MsgId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.MsgId)))
+ i += copy(dAtA[i:], m.MsgId)
+ }
+ if len(m.Route) > 0 {
+ for _, msg := range m.Route {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ if m.Timestamp != 0 {
+ dAtA[i] = 0x18
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Timestamp))
+ }
+ if m.Type != 0 {
+ dAtA[i] = 0x20
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Type))
+ }
+ if m.SsnId != 0 {
+ dAtA[i] = 0x28
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.SsnId))
+ }
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0x32
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0x3a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if m.Dest != nil {
+ dAtA[i] = 0x42
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Dest.Size()))
+ n1, err1 := m.Dest.MarshalTo(dAtA[i:])
+ if err1 != nil {
+ return 0, err1
+ }
+ i += n1
+ }
+ return i, nil
+}
+
+func (m *MsgSubscribe) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgSubscribe) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n2, err2 := m.Topics.MarshalTo(dAtA[i:])
+ if err2 != nil {
+ return 0, err2
+ }
+ i += n2
+ }
+ if m.Network {
+ dAtA[i] = 0x10
+ i++
+ if m.Network {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ return i, nil
+}
+
+func (m *MsgUnsubscribe) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgUnsubscribe) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n3, err3 := m.Topics.MarshalTo(dAtA[i:])
+ if err3 != nil {
+ return 0, err3
+ }
+ i += n3
+ }
+ if m.Network {
+ dAtA[i] = 0x10
+ i++
+ if m.Network {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ return i, nil
+}
+
+func (m *MsgRegisterRPC) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRegisterRPC) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Topics != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Topics.Size()))
+ n4, err4 := m.Topics.MarshalTo(dAtA[i:])
+ if err4 != nil {
+ return 0, err4
+ }
+ i += n4
+ }
+ return i, nil
+}
+
+func (m *MsgProcInit) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgProcInit) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ExtraMqNum != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ExtraMqNum))
+ }
+ return i, nil
+}
+
+func (m *MsgProcInitReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgProcInitReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Errmsg.Size()))
+ n5, err5 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err5 != nil {
+ return 0, err5
+ }
+ i += n5
+ }
+ if m.ProcIndex != 0 {
+ dAtA[i] = 0x10
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ProcIndex))
+ }
+ if len(m.ExtraMqs) > 0 {
+ for _, msg := range m.ExtraMqs {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgRequest) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequest) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Request != nil {
+ nn6, err6 := m.Request.MarshalTo(dAtA[i:])
+ if err6 != nil {
+ return 0, err6
+ }
+ i += nn6
+ }
+ return i, nil
+}
+
+func (m *MsgRequest_Register) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Register != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Register.Size()))
+ n7, err7 := m.Register.MarshalTo(dAtA[i:])
+ if err7 != nil {
+ return 0, err7
+ }
+ i += n7
+ }
+ return i, nil
+}
+func (m *MsgRequest_TopicRequest) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.TopicRequest != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.TopicRequest.Size()))
+ n8, err8 := m.TopicRequest.MarshalTo(dAtA[i:])
+ if err8 != nil {
+ return 0, err8
+ }
+ i += n8
+ }
+ return i, nil
+}
+func (m *MsgRequest_TopicQuery) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.TopicQuery != nil {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.TopicQuery.Size()))
+ n9, err9 := m.TopicQuery.MarshalTo(dAtA[i:])
+ if err9 != nil {
+ return 0, err9
+ }
+ i += n9
+ }
+ return i, nil
+}
+func (m *MsgReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ErrMsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.ErrMsg.Size()))
+ n10, err10 := m.ErrMsg.MarshalTo(dAtA[i:])
+ if err10 != nil {
+ return 0, err10
+ }
+ i += n10
+ }
+ return i, nil
+}
+
+func (m *BHMsgBody) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHMsgBody) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Reqrep != nil {
+ nn11, err11 := m.Reqrep.MarshalTo(dAtA[i:])
+ if err11 != nil {
+ return 0, err11
+ }
+ i += nn11
+ }
+ return i, nil
+}
+
+func (m *BHMsgBody_Request) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Request != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Request.Size()))
+ n12, err12 := m.Request.MarshalTo(dAtA[i:])
+ if err12 != nil {
+ return 0, err12
+ }
+ i += n12
+ }
+ return i, nil
+}
+func (m *BHMsgBody_Reply) MarshalTo(dAtA []byte) (int, error) {
+ i := 0
+ if m.Reply != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsg(dAtA, i, uint64(m.Reply.Size()))
+ n13, err13 := m.Reply.MarshalTo(dAtA[i:])
+ if err13 != nil {
+ return 0, err13
+ }
+ i += n13
+ }
+ return i, nil
+}
+func encodeVarintBhomeMsg(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *BHMsgHead) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.MsgId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if len(m.Route) > 0 {
+ for _, e := range m.Route {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ }
+ if m.Timestamp != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.Timestamp))
+ }
+ if m.Type != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.Type))
+ }
+ if m.SsnId != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.SsnId))
+ }
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Dest != nil {
+ l = m.Dest.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgSubscribe) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Network {
+ n += 2
+ }
+ return n
+}
+
+func (m *MsgUnsubscribe) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.Network {
+ n += 2
+ }
+ return n
+}
+
+func (m *MsgRegisterRPC) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Topics != nil {
+ l = m.Topics.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgProcInit) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ExtraMqNum != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.ExtraMqNum))
+ }
+ return n
+}
+
+func (m *MsgProcInitReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ if m.ProcIndex != 0 {
+ n += 1 + sovBhomeMsg(uint64(m.ProcIndex))
+ }
+ if len(m.ExtraMqs) > 0 {
+ for _, e := range m.ExtraMqs {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgRequest) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Request != nil {
+ n += m.Request.Size()
+ }
+ return n
+}
+
+func (m *MsgRequest_Register) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Register != nil {
+ l = m.Register.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgRequest_TopicRequest) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.TopicRequest != nil {
+ l = m.TopicRequest.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgRequest_TopicQuery) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.TopicQuery != nil {
+ l = m.TopicQuery.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *MsgReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ErrMsg != nil {
+ l = m.ErrMsg.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func (m *BHMsgBody) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Reqrep != nil {
+ n += m.Reqrep.Size()
+ }
+ return n
+}
+
+func (m *BHMsgBody_Request) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Request != nil {
+ l = m.Request.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+func (m *BHMsgBody_Reply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Reply != nil {
+ l = m.Reply.Size()
+ n += 1 + l + sovBhomeMsg(uint64(l))
+ }
+ return n
+}
+
+func sovBhomeMsg(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozBhomeMsg(x uint64) (n int) {
+ return sovBhomeMsg(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *BHMsgHead) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHMsgHead: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHMsgHead: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field MsgId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.MsgId = append(m.MsgId[:0], dAtA[iNdEx:postIndex]...)
+ if m.MsgId == nil {
+ m.MsgId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Route", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Route = append(m.Route, &BHAddress{})
+ if err := m.Route[len(m.Route)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 3:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Timestamp", wireType)
+ }
+ m.Timestamp = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Timestamp |= int64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 4:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
+ }
+ m.Type = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Type |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 5:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field SsnId", wireType)
+ }
+ m.SsnId = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.SsnId |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 6:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 7:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 8:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Dest", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Dest == nil {
+ m.Dest = &BHAddress{}
+ }
+ if err := m.Dest.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgSubscribe) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgSubscribe: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgSubscribe: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Network = bool(v != 0)
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgUnsubscribe) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgUnsubscribe: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUnsubscribe: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Network = bool(v != 0)
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRegisterRPC) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRegisterRPC: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRegisterRPC: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topics", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Topics == nil {
+ m.Topics = &MsgTopicList{}
+ }
+ if err := m.Topics.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgProcInit) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgProcInit: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgProcInit: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ExtraMqNum", wireType)
+ }
+ m.ExtraMqNum = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ExtraMqNum |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgProcInitReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgProcInitReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgProcInitReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcIndex", wireType)
+ }
+ m.ProcIndex = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ProcIndex |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ExtraMqs", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ExtraMqs = append(m.ExtraMqs, &BHAddress{})
+ if err := m.ExtraMqs[len(m.ExtraMqs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequest) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequest: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequest: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Register", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRegister{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_Register{v}
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicRequest", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRequestTopic{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_TopicRequest{v}
+ iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicQuery", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgQueryTopic{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Request = &MsgRequest_TopicQuery{v}
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrMsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.ErrMsg == nil {
+ m.ErrMsg = &ErrorMsg{}
+ }
+ if err := m.ErrMsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *BHMsgBody) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHMsgBody: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHMsgBody: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Request", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgRequest{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Reqrep = &BHMsgBody_Request{v}
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Reply", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ v := &MsgReply{}
+ if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ m.Reqrep = &BHMsgBody_Reply{v}
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipBhomeMsg(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipBhomeMsg(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsg
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthBhomeMsg = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowBhomeMsg = fmt.Errorf("proto: integer overflow")
+)
diff --git a/proto/source/bhome_msg/bhome_msg_api.pb.go b/proto/source/bhome_msg/bhome_msg_api.pb.go
new file mode 100644
index 0000000..8a62e34
--- /dev/null
+++ b/proto/source/bhome_msg/bhome_msg_api.pb.go
@@ -0,0 +1,3762 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: bhome_msg_api.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type BHAddress struct {
+ MqId uint64 `protobuf:"varint,1,opt,name=mq_id,json=mqId,proto3" json:"mq_id,omitempty"`
+ AbsAddr int64 `protobuf:"varint,2,opt,name=abs_addr,json=absAddr,proto3" json:"abs_addr,omitempty"`
+ Ip []byte `protobuf:"bytes,3,opt,name=ip,proto3" json:"ip,omitempty"`
+ Port int32 `protobuf:"varint,4,opt,name=port,proto3" json:"port,omitempty"`
+}
+
+func (m *BHAddress) Reset() { *m = BHAddress{} }
+func (m *BHAddress) String() string { return proto.CompactTextString(m) }
+func (*BHAddress) ProtoMessage() {}
+func (*BHAddress) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{0}
+}
+func (m *BHAddress) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *BHAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_BHAddress.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *BHAddress) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_BHAddress.Merge(m, src)
+}
+func (m *BHAddress) XXX_Size() int {
+ return m.Size()
+}
+func (m *BHAddress) XXX_DiscardUnknown() {
+ xxx_messageInfo_BHAddress.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_BHAddress proto.InternalMessageInfo
+
+func (m *BHAddress) GetMqId() uint64 {
+ if m != nil {
+ return m.MqId
+ }
+ return 0
+}
+
+func (m *BHAddress) GetAbsAddr() int64 {
+ if m != nil {
+ return m.AbsAddr
+ }
+ return 0
+}
+
+func (m *BHAddress) GetIp() []byte {
+ if m != nil {
+ return m.Ip
+ }
+ return nil
+}
+
+func (m *BHAddress) GetPort() int32 {
+ if m != nil {
+ return m.Port
+ }
+ return 0
+}
+
+type ProcInfo struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Name []byte `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
+ PublicInfo []byte `protobuf:"bytes,3,opt,name=public_info,json=publicInfo,proto3" json:"public_info,omitempty"`
+ PrivateInfo []byte `protobuf:"bytes,4,opt,name=private_info,json=privateInfo,proto3" json:"private_info,omitempty"`
+}
+
+func (m *ProcInfo) Reset() { *m = ProcInfo{} }
+func (m *ProcInfo) String() string { return proto.CompactTextString(m) }
+func (*ProcInfo) ProtoMessage() {}
+func (*ProcInfo) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{1}
+}
+func (m *ProcInfo) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *ProcInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_ProcInfo.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *ProcInfo) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ProcInfo.Merge(m, src)
+}
+func (m *ProcInfo) XXX_Size() int {
+ return m.Size()
+}
+func (m *ProcInfo) XXX_DiscardUnknown() {
+ xxx_messageInfo_ProcInfo.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_ProcInfo proto.InternalMessageInfo
+
+func (m *ProcInfo) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetName() []byte {
+ if m != nil {
+ return m.Name
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetPublicInfo() []byte {
+ if m != nil {
+ return m.PublicInfo
+ }
+ return nil
+}
+
+func (m *ProcInfo) GetPrivateInfo() []byte {
+ if m != nil {
+ return m.PrivateInfo
+ }
+ return nil
+}
+
+type MsgTopicList struct {
+ TopicList [][]byte `protobuf:"bytes,1,rep,name=topic_list,json=topicList,proto3" json:"topic_list,omitempty"`
+}
+
+func (m *MsgTopicList) Reset() { *m = MsgTopicList{} }
+func (m *MsgTopicList) String() string { return proto.CompactTextString(m) }
+func (*MsgTopicList) ProtoMessage() {}
+func (*MsgTopicList) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{2}
+}
+func (m *MsgTopicList) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgTopicList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgTopicList.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgTopicList) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgTopicList.Merge(m, src)
+}
+func (m *MsgTopicList) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgTopicList) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgTopicList.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgTopicList proto.InternalMessageInfo
+
+func (m *MsgTopicList) GetTopicList() [][]byte {
+ if m != nil {
+ return m.TopicList
+ }
+ return nil
+}
+
+type MsgPublish struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgPublish) Reset() { *m = MsgPublish{} }
+func (m *MsgPublish) String() string { return proto.CompactTextString(m) }
+func (*MsgPublish) ProtoMessage() {}
+func (*MsgPublish) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{3}
+}
+func (m *MsgPublish) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgPublish) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgPublish.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgPublish) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgPublish.Merge(m, src)
+}
+func (m *MsgPublish) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgPublish) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgPublish.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgPublish proto.InternalMessageInfo
+
+func (m *MsgPublish) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *MsgPublish) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgCommonReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+}
+
+func (m *MsgCommonReply) Reset() { *m = MsgCommonReply{} }
+func (m *MsgCommonReply) String() string { return proto.CompactTextString(m) }
+func (*MsgCommonReply) ProtoMessage() {}
+func (*MsgCommonReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{4}
+}
+func (m *MsgCommonReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgCommonReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgCommonReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgCommonReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgCommonReply.Merge(m, src)
+}
+func (m *MsgCommonReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgCommonReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgCommonReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgCommonReply proto.InternalMessageInfo
+
+func (m *MsgCommonReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+type MsgRequestTopic struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgRequestTopic) Reset() { *m = MsgRequestTopic{} }
+func (m *MsgRequestTopic) String() string { return proto.CompactTextString(m) }
+func (*MsgRequestTopic) ProtoMessage() {}
+func (*MsgRequestTopic) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{5}
+}
+func (m *MsgRequestTopic) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequestTopic) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequestTopic.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequestTopic) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequestTopic.Merge(m, src)
+}
+func (m *MsgRequestTopic) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequestTopic) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequestTopic.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequestTopic proto.InternalMessageInfo
+
+func (m *MsgRequestTopic) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+func (m *MsgRequestTopic) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgRequestTopicReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (m *MsgRequestTopicReply) Reset() { *m = MsgRequestTopicReply{} }
+func (m *MsgRequestTopicReply) String() string { return proto.CompactTextString(m) }
+func (*MsgRequestTopicReply) ProtoMessage() {}
+func (*MsgRequestTopicReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{6}
+}
+func (m *MsgRequestTopicReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRequestTopicReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRequestTopicReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRequestTopicReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRequestTopicReply.Merge(m, src)
+}
+func (m *MsgRequestTopicReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRequestTopicReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRequestTopicReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRequestTopicReply proto.InternalMessageInfo
+
+func (m *MsgRequestTopicReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgRequestTopicReply) GetData() []byte {
+ if m != nil {
+ return m.Data
+ }
+ return nil
+}
+
+type MsgRegister struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgRegister) Reset() { *m = MsgRegister{} }
+func (m *MsgRegister) String() string { return proto.CompactTextString(m) }
+func (*MsgRegister) ProtoMessage() {}
+func (*MsgRegister) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{7}
+}
+func (m *MsgRegister) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgRegister) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgRegister.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgRegister) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgRegister.Merge(m, src)
+}
+func (m *MsgRegister) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgRegister) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgRegister.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgRegister proto.InternalMessageInfo
+
+func (m *MsgRegister) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgUnregister struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgUnregister) Reset() { *m = MsgUnregister{} }
+func (m *MsgUnregister) String() string { return proto.CompactTextString(m) }
+func (*MsgUnregister) ProtoMessage() {}
+func (*MsgUnregister) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{8}
+}
+func (m *MsgUnregister) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgUnregister) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUnregister.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgUnregister) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUnregister.Merge(m, src)
+}
+func (m *MsgUnregister) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgUnregister) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUnregister.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUnregister proto.InternalMessageInfo
+
+func (m *MsgUnregister) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgHeartbeat struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+}
+
+func (m *MsgHeartbeat) Reset() { *m = MsgHeartbeat{} }
+func (m *MsgHeartbeat) String() string { return proto.CompactTextString(m) }
+func (*MsgHeartbeat) ProtoMessage() {}
+func (*MsgHeartbeat) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{9}
+}
+func (m *MsgHeartbeat) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgHeartbeat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgHeartbeat.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgHeartbeat) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgHeartbeat.Merge(m, src)
+}
+func (m *MsgHeartbeat) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgHeartbeat) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgHeartbeat.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgHeartbeat proto.InternalMessageInfo
+
+func (m *MsgHeartbeat) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+type MsgQueryTopic struct {
+ Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"`
+}
+
+func (m *MsgQueryTopic) Reset() { *m = MsgQueryTopic{} }
+func (m *MsgQueryTopic) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopic) ProtoMessage() {}
+func (*MsgQueryTopic) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{10}
+}
+func (m *MsgQueryTopic) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopic) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopic.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopic) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopic.Merge(m, src)
+}
+func (m *MsgQueryTopic) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopic) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopic.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopic proto.InternalMessageInfo
+
+func (m *MsgQueryTopic) GetTopic() []byte {
+ if m != nil {
+ return m.Topic
+ }
+ return nil
+}
+
+type MsgQueryTopicReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ NodeAddress []*MsgQueryTopicReply_BHNodeAddress `protobuf:"bytes,2,rep,name=node_address,json=nodeAddress,proto3" json:"node_address,omitempty"`
+}
+
+func (m *MsgQueryTopicReply) Reset() { *m = MsgQueryTopicReply{} }
+func (m *MsgQueryTopicReply) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopicReply) ProtoMessage() {}
+func (*MsgQueryTopicReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{11}
+}
+func (m *MsgQueryTopicReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopicReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopicReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopicReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopicReply.Merge(m, src)
+}
+func (m *MsgQueryTopicReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopicReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopicReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopicReply proto.InternalMessageInfo
+
+func (m *MsgQueryTopicReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgQueryTopicReply) GetNodeAddress() []*MsgQueryTopicReply_BHNodeAddress {
+ if m != nil {
+ return m.NodeAddress
+ }
+ return nil
+}
+
+type MsgQueryTopicReply_BHNodeAddress struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+ Addr *BHAddress `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"`
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Reset() { *m = MsgQueryTopicReply_BHNodeAddress{} }
+func (m *MsgQueryTopicReply_BHNodeAddress) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryTopicReply_BHNodeAddress) ProtoMessage() {}
+func (*MsgQueryTopicReply_BHNodeAddress) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{11, 0}
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.Merge(m, src)
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryTopicReply_BHNodeAddress proto.InternalMessageInfo
+
+func (m *MsgQueryTopicReply_BHNodeAddress) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) GetAddr() *BHAddress {
+ if m != nil {
+ return m.Addr
+ }
+ return nil
+}
+
+type MsgQueryProc struct {
+ ProcId []byte `protobuf:"bytes,1,opt,name=proc_id,json=procId,proto3" json:"proc_id,omitempty"`
+}
+
+func (m *MsgQueryProc) Reset() { *m = MsgQueryProc{} }
+func (m *MsgQueryProc) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProc) ProtoMessage() {}
+func (*MsgQueryProc) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{12}
+}
+func (m *MsgQueryProc) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProc) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProc.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProc) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProc.Merge(m, src)
+}
+func (m *MsgQueryProc) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProc) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProc.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProc proto.InternalMessageInfo
+
+func (m *MsgQueryProc) GetProcId() []byte {
+ if m != nil {
+ return m.ProcId
+ }
+ return nil
+}
+
+type MsgQueryProcReply struct {
+ Errmsg *ErrorMsg `protobuf:"bytes,1,opt,name=errmsg,proto3" json:"errmsg,omitempty"`
+ ProcList []*MsgQueryProcReply_Info `protobuf:"bytes,2,rep,name=proc_list,json=procList,proto3" json:"proc_list,omitempty"`
+}
+
+func (m *MsgQueryProcReply) Reset() { *m = MsgQueryProcReply{} }
+func (m *MsgQueryProcReply) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProcReply) ProtoMessage() {}
+func (*MsgQueryProcReply) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{13}
+}
+func (m *MsgQueryProcReply) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProcReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProcReply.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProcReply) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProcReply.Merge(m, src)
+}
+func (m *MsgQueryProcReply) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProcReply) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProcReply.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProcReply proto.InternalMessageInfo
+
+func (m *MsgQueryProcReply) GetErrmsg() *ErrorMsg {
+ if m != nil {
+ return m.Errmsg
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply) GetProcList() []*MsgQueryProcReply_Info {
+ if m != nil {
+ return m.ProcList
+ }
+ return nil
+}
+
+type MsgQueryProcReply_Info struct {
+ Proc *ProcInfo `protobuf:"bytes,1,opt,name=proc,proto3" json:"proc,omitempty"`
+ Online bool `protobuf:"varint,2,opt,name=online,proto3" json:"online,omitempty"`
+ Service *MsgTopicList `protobuf:"bytes,3,opt,name=service,proto3" json:"service,omitempty"`
+ LocalSub *MsgTopicList `protobuf:"bytes,4,opt,name=local_sub,json=localSub,proto3" json:"local_sub,omitempty"`
+ NetSub *MsgTopicList `protobuf:"bytes,5,opt,name=net_sub,json=netSub,proto3" json:"net_sub,omitempty"`
+}
+
+func (m *MsgQueryProcReply_Info) Reset() { *m = MsgQueryProcReply_Info{} }
+func (m *MsgQueryProcReply_Info) String() string { return proto.CompactTextString(m) }
+func (*MsgQueryProcReply_Info) ProtoMessage() {}
+func (*MsgQueryProcReply_Info) Descriptor() ([]byte, []int) {
+ return fileDescriptor_a49c9c1f511a168c, []int{13, 0}
+}
+func (m *MsgQueryProcReply_Info) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *MsgQueryProcReply_Info) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgQueryProcReply_Info.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *MsgQueryProcReply_Info) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgQueryProcReply_Info.Merge(m, src)
+}
+func (m *MsgQueryProcReply_Info) XXX_Size() int {
+ return m.Size()
+}
+func (m *MsgQueryProcReply_Info) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgQueryProcReply_Info.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgQueryProcReply_Info proto.InternalMessageInfo
+
+func (m *MsgQueryProcReply_Info) GetProc() *ProcInfo {
+ if m != nil {
+ return m.Proc
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetOnline() bool {
+ if m != nil {
+ return m.Online
+ }
+ return false
+}
+
+func (m *MsgQueryProcReply_Info) GetService() *MsgTopicList {
+ if m != nil {
+ return m.Service
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetLocalSub() *MsgTopicList {
+ if m != nil {
+ return m.LocalSub
+ }
+ return nil
+}
+
+func (m *MsgQueryProcReply_Info) GetNetSub() *MsgTopicList {
+ if m != nil {
+ return m.NetSub
+ }
+ return nil
+}
+
+func init() {
+ proto.RegisterType((*BHAddress)(nil), "bhome_msg.BHAddress")
+ proto.RegisterType((*ProcInfo)(nil), "bhome_msg.ProcInfo")
+ proto.RegisterType((*MsgTopicList)(nil), "bhome_msg.MsgTopicList")
+ proto.RegisterType((*MsgPublish)(nil), "bhome_msg.MsgPublish")
+ proto.RegisterType((*MsgCommonReply)(nil), "bhome_msg.MsgCommonReply")
+ proto.RegisterType((*MsgRequestTopic)(nil), "bhome_msg.MsgRequestTopic")
+ proto.RegisterType((*MsgRequestTopicReply)(nil), "bhome_msg.MsgRequestTopicReply")
+ proto.RegisterType((*MsgRegister)(nil), "bhome_msg.MsgRegister")
+ proto.RegisterType((*MsgUnregister)(nil), "bhome_msg.MsgUnregister")
+ proto.RegisterType((*MsgHeartbeat)(nil), "bhome_msg.MsgHeartbeat")
+ proto.RegisterType((*MsgQueryTopic)(nil), "bhome_msg.MsgQueryTopic")
+ proto.RegisterType((*MsgQueryTopicReply)(nil), "bhome_msg.MsgQueryTopicReply")
+ proto.RegisterType((*MsgQueryTopicReply_BHNodeAddress)(nil), "bhome_msg.MsgQueryTopicReply.BHNodeAddress")
+ proto.RegisterType((*MsgQueryProc)(nil), "bhome_msg.MsgQueryProc")
+ proto.RegisterType((*MsgQueryProcReply)(nil), "bhome_msg.MsgQueryProcReply")
+ proto.RegisterType((*MsgQueryProcReply_Info)(nil), "bhome_msg.MsgQueryProcReply.Info")
+}
+
+func init() { proto.RegisterFile("bhome_msg_api.proto", fileDescriptor_a49c9c1f511a168c) }
+
+var fileDescriptor_a49c9c1f511a168c = []byte{
+ // 640 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0x6f, 0x6b, 0x13, 0x4f,
+ 0x10, 0xee, 0x25, 0x97, 0x7f, 0x73, 0xd7, 0x96, 0xdf, 0xb6, 0xfc, 0x1a, 0x0b, 0xc6, 0xf4, 0x40,
+ 0x7a, 0x50, 0x8c, 0x1a, 0xa5, 0x0a, 0xa2, 0x60, 0x45, 0x48, 0xc1, 0x94, 0xba, 0x55, 0x04, 0xdf,
+ 0x1c, 0x77, 0xb9, 0xed, 0x75, 0x21, 0x77, 0x7b, 0xdd, 0xdd, 0x14, 0x8a, 0x5f, 0xc2, 0x8f, 0xe5,
+ 0xcb, 0xbe, 0xf4, 0xa5, 0xa4, 0xf4, 0x7b, 0xc8, 0x4e, 0x92, 0xb3, 0xd5, 0xb6, 0xb4, 0x7d, 0xb7,
+ 0xb3, 0xf3, 0x3c, 0xcf, 0x0c, 0x33, 0x3c, 0x03, 0x4b, 0xd1, 0x81, 0x48, 0x59, 0x90, 0xaa, 0x24,
+ 0x08, 0x73, 0xde, 0xc9, 0xa5, 0xd0, 0x82, 0x34, 0x8a, 0xcf, 0xd5, 0x45, 0x26, 0xa5, 0x90, 0xe6,
+ 0x39, 0xc9, 0x79, 0x01, 0x34, 0xb6, 0x7a, 0x6f, 0xe3, 0x58, 0x32, 0xa5, 0xc8, 0x12, 0x54, 0xd2,
+ 0xc3, 0x80, 0xc7, 0x4d, 0xab, 0x6d, 0xf9, 0x36, 0xb5, 0xd3, 0xc3, 0xed, 0x98, 0xdc, 0x83, 0x7a,
+ 0x18, 0xa9, 0x20, 0x8c, 0x63, 0xd9, 0x2c, 0xb5, 0x2d, 0xbf, 0x4c, 0x6b, 0x61, 0xa4, 0x0c, 0x85,
+ 0x2c, 0x40, 0x89, 0xe7, 0xcd, 0x72, 0xdb, 0xf2, 0x5d, 0x5a, 0xe2, 0x39, 0x21, 0x60, 0xe7, 0x42,
+ 0xea, 0xa6, 0xdd, 0xb6, 0xfc, 0x0a, 0xc5, 0xb7, 0xf7, 0x0d, 0xea, 0xbb, 0x52, 0x0c, 0xb6, 0xb3,
+ 0x7d, 0x41, 0x56, 0xa0, 0x96, 0x4b, 0x31, 0x98, 0x55, 0x70, 0x69, 0xd5, 0x84, 0xdb, 0xb1, 0x21,
+ 0x66, 0x61, 0xca, 0x50, 0xdf, 0xa5, 0xf8, 0x26, 0x0f, 0xc0, 0xc9, 0x47, 0xd1, 0x90, 0x0f, 0x02,
+ 0x9e, 0xed, 0x8b, 0x69, 0x15, 0x98, 0x7c, 0xa1, 0xda, 0x1a, 0xb8, 0xb9, 0xe4, 0x47, 0xa1, 0x66,
+ 0x13, 0x84, 0x8d, 0x08, 0x67, 0xfa, 0x67, 0x20, 0xde, 0x23, 0x70, 0xfb, 0x2a, 0xf9, 0x24, 0x72,
+ 0x3e, 0xf8, 0xc0, 0x95, 0x26, 0xf7, 0x01, 0xb4, 0x09, 0x82, 0x21, 0x57, 0xba, 0x69, 0xb5, 0xcb,
+ 0xbe, 0x4b, 0x1b, 0x7a, 0x96, 0xf6, 0x36, 0x01, 0xfa, 0x2a, 0xd9, 0x35, 0x25, 0xd4, 0x01, 0x59,
+ 0x86, 0x0a, 0xa6, 0xa6, 0xbd, 0x4e, 0x02, 0xd3, 0x6a, 0x1c, 0xea, 0x70, 0xd6, 0xaa, 0x79, 0x7b,
+ 0xaf, 0x61, 0xa1, 0xaf, 0x92, 0x77, 0x22, 0x4d, 0x45, 0x46, 0x59, 0x3e, 0x3c, 0x26, 0x1b, 0x50,
+ 0x65, 0x52, 0xa6, 0x2a, 0x41, 0xb2, 0xd3, 0x5d, 0xea, 0x14, 0x3b, 0xe8, 0xbc, 0x37, 0x2b, 0xe8,
+ 0xab, 0x84, 0x4e, 0x21, 0xde, 0x2b, 0x58, 0x34, 0x21, 0x3b, 0x1c, 0x31, 0xa5, 0xb1, 0xd9, 0x5b,
+ 0xd4, 0xfe, 0x02, 0xcb, 0x7f, 0x91, 0x6f, 0xdf, 0xc1, 0xa5, 0xc2, 0x9b, 0xe0, 0xa0, 0x70, 0xc2,
+ 0x95, 0x66, 0x92, 0xac, 0x83, 0x6d, 0x96, 0x75, 0x89, 0xda, 0x6c, 0xbd, 0x14, 0x01, 0xde, 0x4b,
+ 0x98, 0xef, 0xab, 0xe4, 0x73, 0x26, 0x6f, 0xcd, 0x7c, 0x81, 0xdb, 0xea, 0xb1, 0x50, 0xea, 0x88,
+ 0x85, 0xfa, 0xe6, 0xc4, 0x87, 0x58, 0xf2, 0xe3, 0x88, 0xc9, 0xe3, 0x6b, 0xc6, 0xe7, 0x9d, 0x59,
+ 0x40, 0x2e, 0xe0, 0xee, 0x30, 0xa9, 0x1d, 0x70, 0x33, 0x11, 0x33, 0xb4, 0x03, 0x53, 0xaa, 0x59,
+ 0x6a, 0x97, 0x7d, 0xa7, 0xbb, 0x71, 0x8e, 0xf2, 0x6f, 0x85, 0xce, 0x56, 0x6f, 0x47, 0xc4, 0x6c,
+ 0xea, 0x32, 0xea, 0x64, 0x7f, 0x82, 0x55, 0x0a, 0xf3, 0x17, 0xb2, 0x57, 0x7b, 0xc4, 0x07, 0xbb,
+ 0xf0, 0xa0, 0xd3, 0x5d, 0x3e, 0x57, 0xb1, 0x30, 0x30, 0x45, 0x84, 0xb7, 0x8e, 0x73, 0xc4, 0x26,
+ 0xcc, 0xa0, 0xae, 0x94, 0xf4, 0xce, 0x4a, 0xf0, 0xdf, 0x79, 0xe4, 0x1d, 0xe6, 0xf1, 0x06, 0x1a,
+ 0xa8, 0x8d, 0x86, 0x9a, 0x0c, 0x63, 0xed, 0x92, 0x61, 0x14, 0xea, 0x1d, 0x5c, 0x5b, 0xdd, 0x70,
+ 0x8c, 0xe5, 0x56, 0xc7, 0x16, 0xd8, 0xe8, 0xe6, 0x9b, 0x2e, 0x9b, 0xfc, 0x0f, 0x55, 0x91, 0x0d,
+ 0x79, 0x36, 0xb9, 0x16, 0x75, 0x3a, 0x8d, 0xc8, 0x53, 0xa8, 0x29, 0x26, 0x8f, 0xf8, 0x80, 0xe1,
+ 0xad, 0x70, 0xba, 0x2b, 0x17, 0xfb, 0x28, 0xae, 0x00, 0x9d, 0xe1, 0xc8, 0x73, 0x68, 0x0c, 0xc5,
+ 0x20, 0x1c, 0x06, 0x6a, 0x14, 0xe1, 0xf9, 0xb8, 0x86, 0x54, 0x47, 0xe4, 0xde, 0x28, 0x22, 0x4f,
+ 0xa0, 0x96, 0x31, 0x8d, 0x9c, 0xca, 0xf5, 0x9c, 0x6a, 0xc6, 0xf4, 0xde, 0x28, 0xda, 0x5a, 0xff,
+ 0x31, 0x6e, 0x59, 0x27, 0xe3, 0x96, 0xf5, 0x6b, 0xdc, 0xb2, 0xbe, 0x9f, 0xb6, 0xe6, 0x4e, 0x4e,
+ 0x5b, 0x73, 0x3f, 0x4f, 0x5b, 0x73, 0xbd, 0xf2, 0x57, 0xa7, 0xf3, 0xb8, 0x60, 0x47, 0x55, 0x3c,
+ 0xca, 0xcf, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0x71, 0x22, 0x26, 0xc9, 0xc7, 0x05, 0x00, 0x00,
+}
+
+func (m *BHAddress) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *BHAddress) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.MqId != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.MqId))
+ }
+ if m.AbsAddr != 0 {
+ dAtA[i] = 0x10
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.AbsAddr))
+ }
+ if len(m.Ip) > 0 {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Ip)))
+ i += copy(dAtA[i:], m.Ip)
+ }
+ if m.Port != 0 {
+ dAtA[i] = 0x20
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Port))
+ }
+ return i, nil
+}
+
+func (m *ProcInfo) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *ProcInfo) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if len(m.Name) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Name)))
+ i += copy(dAtA[i:], m.Name)
+ }
+ if len(m.PublicInfo) > 0 {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.PublicInfo)))
+ i += copy(dAtA[i:], m.PublicInfo)
+ }
+ if len(m.PrivateInfo) > 0 {
+ dAtA[i] = 0x22
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.PrivateInfo)))
+ i += copy(dAtA[i:], m.PrivateInfo)
+ }
+ return i, nil
+}
+
+func (m *MsgTopicList) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgTopicList) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.TopicList) > 0 {
+ for _, b := range m.TopicList {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(b)))
+ i += copy(dAtA[i:], b)
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgPublish) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgPublish) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgCommonReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgCommonReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n1, err1 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err1 != nil {
+ return 0, err1
+ }
+ i += n1
+ }
+ return i, nil
+}
+
+func (m *MsgRequestTopic) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequestTopic) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgRequestTopicReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRequestTopicReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n2, err2 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err2 != nil {
+ return 0, err2
+ }
+ i += n2
+ }
+ if len(m.Data) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Data)))
+ i += copy(dAtA[i:], m.Data)
+ }
+ return i, nil
+}
+
+func (m *MsgRegister) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgRegister) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n3, err3 := m.Proc.MarshalTo(dAtA[i:])
+ if err3 != nil {
+ return 0, err3
+ }
+ i += n3
+ }
+ return i, nil
+}
+
+func (m *MsgUnregister) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgUnregister) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n4, err4 := m.Proc.MarshalTo(dAtA[i:])
+ if err4 != nil {
+ return 0, err4
+ }
+ i += n4
+ }
+ return i, nil
+}
+
+func (m *MsgHeartbeat) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgHeartbeat) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n5, err5 := m.Proc.MarshalTo(dAtA[i:])
+ if err5 != nil {
+ return 0, err5
+ }
+ i += n5
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopic) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopic) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.Topic) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.Topic)))
+ i += copy(dAtA[i:], m.Topic)
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopicReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopicReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n6, err6 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err6 != nil {
+ return 0, err6
+ }
+ i += n6
+ }
+ if len(m.NodeAddress) > 0 {
+ for _, msg := range m.NodeAddress {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ if m.Addr != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Addr.Size()))
+ n7, err7 := m.Addr.MarshalTo(dAtA[i:])
+ if err7 != nil {
+ return 0, err7
+ }
+ i += n7
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProc) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProc) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if len(m.ProcId) > 0 {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(len(m.ProcId)))
+ i += copy(dAtA[i:], m.ProcId)
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProcReply) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProcReply) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Errmsg.Size()))
+ n8, err8 := m.Errmsg.MarshalTo(dAtA[i:])
+ if err8 != nil {
+ return 0, err8
+ }
+ i += n8
+ }
+ if len(m.ProcList) > 0 {
+ for _, msg := range m.ProcList {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(msg.Size()))
+ n, err := msg.MarshalTo(dAtA[i:])
+ if err != nil {
+ return 0, err
+ }
+ i += n
+ }
+ }
+ return i, nil
+}
+
+func (m *MsgQueryProcReply_Info) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *MsgQueryProcReply_Info) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.Proc != nil {
+ dAtA[i] = 0xa
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Proc.Size()))
+ n9, err9 := m.Proc.MarshalTo(dAtA[i:])
+ if err9 != nil {
+ return 0, err9
+ }
+ i += n9
+ }
+ if m.Online {
+ dAtA[i] = 0x10
+ i++
+ if m.Online {
+ dAtA[i] = 1
+ } else {
+ dAtA[i] = 0
+ }
+ i++
+ }
+ if m.Service != nil {
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.Service.Size()))
+ n10, err10 := m.Service.MarshalTo(dAtA[i:])
+ if err10 != nil {
+ return 0, err10
+ }
+ i += n10
+ }
+ if m.LocalSub != nil {
+ dAtA[i] = 0x22
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.LocalSub.Size()))
+ n11, err11 := m.LocalSub.MarshalTo(dAtA[i:])
+ if err11 != nil {
+ return 0, err11
+ }
+ i += n11
+ }
+ if m.NetSub != nil {
+ dAtA[i] = 0x2a
+ i++
+ i = encodeVarintBhomeMsgApi(dAtA, i, uint64(m.NetSub.Size()))
+ n12, err12 := m.NetSub.MarshalTo(dAtA[i:])
+ if err12 != nil {
+ return 0, err12
+ }
+ i += n12
+ }
+ return i, nil
+}
+
+func encodeVarintBhomeMsgApi(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *BHAddress) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.MqId != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.MqId))
+ }
+ if m.AbsAddr != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.AbsAddr))
+ }
+ l = len(m.Ip)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Port != 0 {
+ n += 1 + sovBhomeMsgApi(uint64(m.Port))
+ }
+ return n
+}
+
+func (m *ProcInfo) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Name)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.PublicInfo)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.PrivateInfo)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgTopicList) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if len(m.TopicList) > 0 {
+ for _, b := range m.TopicList {
+ l = len(b)
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgPublish) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgCommonReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRequestTopic) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRequestTopicReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ l = len(m.Data)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgRegister) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgUnregister) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgHeartbeat) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryTopic) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Topic)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryTopicReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if len(m.NodeAddress) > 0 {
+ for _, e := range m.NodeAddress {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgQueryTopicReply_BHNodeAddress) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Addr != nil {
+ l = m.Addr.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryProc) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.ProcId)
+ if l > 0 {
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgQueryProcReply) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Errmsg != nil {
+ l = m.Errmsg.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if len(m.ProcList) > 0 {
+ for _, e := range m.ProcList {
+ l = e.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ }
+ return n
+}
+
+func (m *MsgQueryProcReply_Info) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.Proc != nil {
+ l = m.Proc.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.Online {
+ n += 2
+ }
+ if m.Service != nil {
+ l = m.Service.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.LocalSub != nil {
+ l = m.LocalSub.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ if m.NetSub != nil {
+ l = m.NetSub.Size()
+ n += 1 + l + sovBhomeMsgApi(uint64(l))
+ }
+ return n
+}
+
+func sovBhomeMsgApi(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozBhomeMsgApi(x uint64) (n int) {
+ return sovBhomeMsgApi(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *BHAddress) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHAddress: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHAddress: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field MqId", wireType)
+ }
+ m.MqId = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.MqId |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field AbsAddr", wireType)
+ }
+ m.AbsAddr = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.AbsAddr |= int64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Ip", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Ip = append(m.Ip[:0], dAtA[iNdEx:postIndex]...)
+ if m.Ip == nil {
+ m.Ip = []byte{}
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
+ }
+ m.Port = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.Port |= int32(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *ProcInfo) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: ProcInfo: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: ProcInfo: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Name = append(m.Name[:0], dAtA[iNdEx:postIndex]...)
+ if m.Name == nil {
+ m.Name = []byte{}
+ }
+ iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field PublicInfo", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.PublicInfo = append(m.PublicInfo[:0], dAtA[iNdEx:postIndex]...)
+ if m.PublicInfo == nil {
+ m.PublicInfo = []byte{}
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field PrivateInfo", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.PrivateInfo = append(m.PrivateInfo[:0], dAtA[iNdEx:postIndex]...)
+ if m.PrivateInfo == nil {
+ m.PrivateInfo = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgTopicList) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgTopicList: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgTopicList: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field TopicList", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.TopicList = append(m.TopicList, make([]byte, postIndex-iNdEx))
+ copy(m.TopicList[len(m.TopicList)-1], dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgPublish) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgPublish: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgPublish: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgCommonReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgCommonReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgCommonReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequestTopic) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequestTopic: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequestTopic: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRequestTopicReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRequestTopicReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRequestTopicReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
+ if m.Data == nil {
+ m.Data = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgRegister) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgRegister: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgRegister: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgUnregister) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgUnregister: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUnregister: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgHeartbeat) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgHeartbeat: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgHeartbeat: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopic) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryTopic: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryTopic: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Topic", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.Topic = append(m.Topic[:0], dAtA[iNdEx:postIndex]...)
+ if m.Topic == nil {
+ m.Topic = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopicReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryTopicReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryTopicReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field NodeAddress", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.NodeAddress = append(m.NodeAddress, &MsgQueryTopicReply_BHNodeAddress{})
+ if err := m.NodeAddress[len(m.NodeAddress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryTopicReply_BHNodeAddress) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: BHNodeAddress: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: BHNodeAddress: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Addr", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Addr == nil {
+ m.Addr = &BHAddress{}
+ }
+ if err := m.Addr.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProc) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryProc: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryProc: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcId", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcId = append(m.ProcId[:0], dAtA[iNdEx:postIndex]...)
+ if m.ProcId == nil {
+ m.ProcId = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProcReply) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: MsgQueryProcReply: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgQueryProcReply: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Errmsg", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Errmsg == nil {
+ m.Errmsg = &ErrorMsg{}
+ }
+ if err := m.Errmsg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ProcList", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ProcList = append(m.ProcList, &MsgQueryProcReply_Info{})
+ if err := m.ProcList[len(m.ProcList)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func (m *MsgQueryProcReply_Info) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: Info: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: Info: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Proc", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Proc == nil {
+ m.Proc = &ProcInfo{}
+ }
+ if err := m.Proc.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 2:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Online", wireType)
+ }
+ var v int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ v |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ m.Online = bool(v != 0)
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.Service == nil {
+ m.Service = &MsgTopicList{}
+ }
+ if err := m.Service.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 4:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field LocalSub", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.LocalSub == nil {
+ m.LocalSub = &MsgTopicList{}
+ }
+ if err := m.LocalSub.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ case 5:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field NetSub", wireType)
+ }
+ var msglen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ msglen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if msglen < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ postIndex := iNdEx + msglen
+ if postIndex < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ if m.NetSub == nil {
+ m.NetSub = &MsgTopicList{}
+ }
+ if err := m.NetSub.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
+ return err
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipBhomeMsgApi(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthBhomeMsgApi
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipBhomeMsgApi(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowBhomeMsgApi
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipBhomeMsgApi(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthBhomeMsgApi
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthBhomeMsgApi = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowBhomeMsgApi = fmt.Errorf("proto: integer overflow")
+)
diff --git a/proto/source/bhome_msg/error_msg.pb.go b/proto/source/bhome_msg/error_msg.pb.go
new file mode 100644
index 0000000..6a13b8b
--- /dev/null
+++ b/proto/source/bhome_msg/error_msg.pb.go
@@ -0,0 +1,424 @@
+// Code generated by protoc-gen-gogo. DO NOT EDIT.
+// source: error_msg.proto
+
+package bhome_msg
+
+import (
+ fmt "fmt"
+ proto "github.com/gogo/protobuf/proto"
+ io "io"
+ math "math"
+ math_bits "math/bits"
+)
+
+// Reference imports to suppress errors if they are not otherwise used.
+var _ = proto.Marshal
+var _ = fmt.Errorf
+var _ = math.Inf
+
+// This is a compile-time assertion to ensure that this generated file
+// is compatible with the proto package it is being compiled against.
+// A compilation error at this line likely means your copy of the
+// proto package needs to be updated.
+const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
+
+type ErrorCode int32
+
+const (
+ ErrorCode_eSuccess ErrorCode = 0
+ ErrorCode_eError ErrorCode = 1
+ ErrorCode_eInvalidInput ErrorCode = 2
+ ErrorCode_eNotRegistered ErrorCode = 3
+ ErrorCode_eNotFound ErrorCode = 4
+ ErrorCode_eOffline ErrorCode = 5
+ ErrorCode_eNoRespond ErrorCode = 6
+ ErrorCode_eAddressNotMatch ErrorCode = 7
+)
+
+var ErrorCode_name = map[int32]string{
+ 0: "eSuccess",
+ 1: "eError",
+ 2: "eInvalidInput",
+ 3: "eNotRegistered",
+ 4: "eNotFound",
+ 5: "eOffline",
+ 6: "eNoRespond",
+ 7: "eAddressNotMatch",
+}
+
+var ErrorCode_value = map[string]int32{
+ "eSuccess": 0,
+ "eError": 1,
+ "eInvalidInput": 2,
+ "eNotRegistered": 3,
+ "eNotFound": 4,
+ "eOffline": 5,
+ "eNoRespond": 6,
+ "eAddressNotMatch": 7,
+}
+
+func (x ErrorCode) String() string {
+ return proto.EnumName(ErrorCode_name, int32(x))
+}
+
+func (ErrorCode) EnumDescriptor() ([]byte, []int) {
+ return fileDescriptor_da93925f7641a6e0, []int{0}
+}
+
+type ErrorMsg struct {
+ ErrCode ErrorCode `protobuf:"varint,1,opt,name=errCode,proto3,enum=bhome_msg.ErrorCode" json:"errCode,omitempty"`
+ ErrString []byte `protobuf:"bytes,2,opt,name=errString,proto3" json:"errString,omitempty"`
+}
+
+func (m *ErrorMsg) Reset() { *m = ErrorMsg{} }
+func (m *ErrorMsg) String() string { return proto.CompactTextString(m) }
+func (*ErrorMsg) ProtoMessage() {}
+func (*ErrorMsg) Descriptor() ([]byte, []int) {
+ return fileDescriptor_da93925f7641a6e0, []int{0}
+}
+func (m *ErrorMsg) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+func (m *ErrorMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_ErrorMsg.Marshal(b, m, deterministic)
+ } else {
+ b = b[:cap(b)]
+ n, err := m.MarshalTo(b)
+ if err != nil {
+ return nil, err
+ }
+ return b[:n], nil
+ }
+}
+func (m *ErrorMsg) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ErrorMsg.Merge(m, src)
+}
+func (m *ErrorMsg) XXX_Size() int {
+ return m.Size()
+}
+func (m *ErrorMsg) XXX_DiscardUnknown() {
+ xxx_messageInfo_ErrorMsg.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_ErrorMsg proto.InternalMessageInfo
+
+func (m *ErrorMsg) GetErrCode() ErrorCode {
+ if m != nil {
+ return m.ErrCode
+ }
+ return ErrorCode_eSuccess
+}
+
+func (m *ErrorMsg) GetErrString() []byte {
+ if m != nil {
+ return m.ErrString
+ }
+ return nil
+}
+
+func init() {
+ proto.RegisterEnum("bhome_msg.ErrorCode", ErrorCode_name, ErrorCode_value)
+ proto.RegisterType((*ErrorMsg)(nil), "bhome_msg.ErrorMsg")
+}
+
+func init() { proto.RegisterFile("error_msg.proto", fileDescriptor_da93925f7641a6e0) }
+
+var fileDescriptor_da93925f7641a6e0 = []byte{
+ // 274 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x44, 0x90, 0xc1, 0x4a, 0xf3, 0x40,
+ 0x10, 0x80, 0xb3, 0xed, 0xff, 0xb7, 0xcd, 0xd8, 0xc6, 0x75, 0xe9, 0xa1, 0x07, 0x59, 0x8a, 0x17,
+ 0x8b, 0x87, 0x08, 0xfa, 0x04, 0x2a, 0x8a, 0x3d, 0x34, 0x42, 0x7a, 0x11, 0x2f, 0xd2, 0x66, 0xa7,
+ 0x69, 0xa0, 0xdd, 0x0d, 0xb3, 0x1b, 0x5f, 0x43, 0x1f, 0xcb, 0x63, 0x8f, 0x1e, 0x25, 0x79, 0x11,
+ 0x49, 0xc0, 0x78, 0xfd, 0xbe, 0x6f, 0x06, 0x66, 0xe0, 0x18, 0x89, 0x0c, 0xbd, 0xee, 0x6d, 0x1a,
+ 0xe6, 0x64, 0x9c, 0x11, 0xfe, 0x7a, 0x6b, 0xf6, 0x58, 0x83, 0xb3, 0x67, 0x18, 0xdc, 0xd7, 0x76,
+ 0x61, 0x53, 0x11, 0x42, 0x1f, 0x89, 0xee, 0x8c, 0xc2, 0x09, 0x9b, 0xb2, 0x59, 0x70, 0x35, 0x0e,
+ 0xdb, 0x30, 0x6c, 0xaa, 0xda, 0xc5, 0xbf, 0x91, 0x38, 0x05, 0x1f, 0x89, 0x96, 0x8e, 0x32, 0x9d,
+ 0x4e, 0x3a, 0x53, 0x36, 0x1b, 0xc6, 0x7f, 0xe0, 0xe2, 0x9d, 0x81, 0xdf, 0x0e, 0x89, 0x21, 0x0c,
+ 0x70, 0x59, 0x24, 0x09, 0x5a, 0xcb, 0x3d, 0x01, 0xd0, 0xc3, 0xc6, 0x71, 0x26, 0x4e, 0x60, 0x84,
+ 0x73, 0xfd, 0xb6, 0xda, 0x65, 0x6a, 0xae, 0xf3, 0xc2, 0xf1, 0x8e, 0x10, 0x10, 0x60, 0x64, 0x5c,
+ 0x8c, 0x69, 0x66, 0x1d, 0x12, 0x2a, 0xde, 0x15, 0x23, 0xf0, 0x6b, 0xf6, 0x60, 0x0a, 0xad, 0xf8,
+ 0xbf, 0x66, 0xdf, 0xd3, 0x66, 0xb3, 0xcb, 0x34, 0xf2, 0xff, 0x22, 0x00, 0xc0, 0xc8, 0xc4, 0x68,
+ 0x73, 0xa3, 0x15, 0xef, 0x89, 0x31, 0x70, 0xbc, 0x51, 0x8a, 0xd0, 0xda, 0xc8, 0xb8, 0xc5, 0xca,
+ 0x25, 0x5b, 0xde, 0xbf, 0x3d, 0xff, 0x2c, 0x25, 0x3b, 0x94, 0x92, 0x7d, 0x97, 0x92, 0x7d, 0x54,
+ 0xd2, 0x3b, 0x54, 0xd2, 0xfb, 0xaa, 0xa4, 0xf7, 0xd8, 0x7d, 0x39, 0x0a, 0x2f, 0xdb, 0x5b, 0xd7,
+ 0xbd, 0xe6, 0x4d, 0xd7, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x33, 0xa4, 0xff, 0xc0, 0x39, 0x01,
+ 0x00, 0x00,
+}
+
+func (m *ErrorMsg) Marshal() (dAtA []byte, err error) {
+ size := m.Size()
+ dAtA = make([]byte, size)
+ n, err := m.MarshalTo(dAtA)
+ if err != nil {
+ return nil, err
+ }
+ return dAtA[:n], nil
+}
+
+func (m *ErrorMsg) MarshalTo(dAtA []byte) (int, error) {
+ var i int
+ _ = i
+ var l int
+ _ = l
+ if m.ErrCode != 0 {
+ dAtA[i] = 0x8
+ i++
+ i = encodeVarintErrorMsg(dAtA, i, uint64(m.ErrCode))
+ }
+ if len(m.ErrString) > 0 {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintErrorMsg(dAtA, i, uint64(len(m.ErrString)))
+ i += copy(dAtA[i:], m.ErrString)
+ }
+ return i, nil
+}
+
+func encodeVarintErrorMsg(dAtA []byte, offset int, v uint64) int {
+ for v >= 1<<7 {
+ dAtA[offset] = uint8(v&0x7f | 0x80)
+ v >>= 7
+ offset++
+ }
+ dAtA[offset] = uint8(v)
+ return offset + 1
+}
+func (m *ErrorMsg) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ if m.ErrCode != 0 {
+ n += 1 + sovErrorMsg(uint64(m.ErrCode))
+ }
+ l = len(m.ErrString)
+ if l > 0 {
+ n += 1 + l + sovErrorMsg(uint64(l))
+ }
+ return n
+}
+
+func sovErrorMsg(x uint64) (n int) {
+ return (math_bits.Len64(x|1) + 6) / 7
+}
+func sozErrorMsg(x uint64) (n int) {
+ return sovErrorMsg(uint64((x << 1) ^ uint64((int64(x) >> 63))))
+}
+func (m *ErrorMsg) Unmarshal(dAtA []byte) error {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ preIndex := iNdEx
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= uint64(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ fieldNum := int32(wire >> 3)
+ wireType := int(wire & 0x7)
+ if wireType == 4 {
+ return fmt.Errorf("proto: ErrorMsg: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: ErrorMsg: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 0 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrCode", wireType)
+ }
+ m.ErrCode = 0
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ m.ErrCode |= ErrorCode(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ErrString", wireType)
+ }
+ var byteLen int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ byteLen |= int(b&0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if byteLen < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ postIndex := iNdEx + byteLen
+ if postIndex < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.ErrString = append(m.ErrString[:0], dAtA[iNdEx:postIndex]...)
+ if m.ErrString == nil {
+ m.ErrString = []byte{}
+ }
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipErrorMsg(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if skippy < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if (iNdEx + skippy) < 0 {
+ return ErrInvalidLengthErrorMsg
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+func skipErrorMsg(dAtA []byte) (n int, err error) {
+ l := len(dAtA)
+ iNdEx := 0
+ for iNdEx < l {
+ var wire uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ wire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ wireType := int(wire & 0x7)
+ switch wireType {
+ case 0:
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ iNdEx++
+ if dAtA[iNdEx-1] < 0x80 {
+ break
+ }
+ }
+ return iNdEx, nil
+ case 1:
+ iNdEx += 8
+ return iNdEx, nil
+ case 2:
+ var length int
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ length |= (int(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ if length < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ iNdEx += length
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ return iNdEx, nil
+ case 3:
+ for {
+ var innerWire uint64
+ var start int = iNdEx
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return 0, ErrIntOverflowErrorMsg
+ }
+ if iNdEx >= l {
+ return 0, io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ innerWire |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ innerWireType := int(innerWire & 0x7)
+ if innerWireType == 4 {
+ break
+ }
+ next, err := skipErrorMsg(dAtA[start:])
+ if err != nil {
+ return 0, err
+ }
+ iNdEx = start + next
+ if iNdEx < 0 {
+ return 0, ErrInvalidLengthErrorMsg
+ }
+ }
+ return iNdEx, nil
+ case 4:
+ return iNdEx, nil
+ case 5:
+ iNdEx += 4
+ return iNdEx, nil
+ default:
+ return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
+ }
+ }
+ panic("unreachable")
+}
+
+var (
+ ErrInvalidLengthErrorMsg = fmt.Errorf("proto: negative length found during unmarshaling")
+ ErrIntOverflowErrorMsg = fmt.Errorf("proto: integer overflow")
+)
diff --git a/src/proto/bhome_msg_api.pb.cc b/proto/source/bhome_msg_api.pb.cc
similarity index 100%
rename from src/proto/bhome_msg_api.pb.cc
rename to proto/source/bhome_msg_api.pb.cc
diff --git a/src/proto/bhome_msg_api.pb.h b/proto/source/bhome_msg_api.pb.h
similarity index 100%
rename from src/proto/bhome_msg_api.pb.h
rename to proto/source/bhome_msg_api.pb.h
diff --git a/src/proto/bhome_msg_api.proto b/proto/source/bhome_msg_api.proto
similarity index 100%
rename from src/proto/bhome_msg_api.proto
rename to proto/source/bhome_msg_api.proto
diff --git a/src/proto/error_msg.pb.cc b/proto/source/error_msg.pb.cc
similarity index 100%
rename from src/proto/error_msg.pb.cc
rename to proto/source/error_msg.pb.cc
diff --git a/src/proto/error_msg.pb.h b/proto/source/error_msg.pb.h
similarity index 100%
rename from src/proto/error_msg.pb.h
rename to proto/source/error_msg.pb.h
diff --git a/src/proto/error_msg.proto b/proto/source/error_msg.proto
similarity index 100%
rename from src/proto/error_msg.proto
rename to proto/source/error_msg.proto
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index eb3f4c9..276c547 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -26,9 +26,9 @@
./net/net_mod_socket.cpp
./net/net_mod_socket_io.cpp
./net/net_mod_server_socket.cpp
-./proto/bhome_msg_api.pb.cc
-./proto/bhome_msg.pb.cc
-./proto/error_msg.pb.cc
+../proto/source/bhome_msg_api.pb.cc
+../proto/source/bhome_msg.pb.cc
+../proto/source/error_msg.pb.cc
./shm/shm_mm_wrapper.cpp
./shm/mm.cpp
./shm/hashtable.cpp
diff --git a/src/bh_api.cc b/src/bh_api.cc
index 6cf1b22..a13701e 100644
--- a/src/bh_api.cc
+++ b/src/bh_api.cc
@@ -1,8 +1,8 @@
#include "bh_api.h"
#include <stdlib.h>
#include <string.h>
-#include "proto/bhome_msg.pb.h"
-#include "proto/bhome_msg_api.pb.h"
+#include "../proto/bhome_msg.pb.h"
+#include "../proto/bhome_msg_api.pb.h"
using namespace bhome_msg;
diff --git a/src/bh_api.cpp b/src/bh_api.cpp
index 9de5c0b..9b151fa 100644
--- a/src/bh_api.cpp
+++ b/src/bh_api.cpp
@@ -7,11 +7,8 @@
#include "bh_api.h"
#include <pthread.h>
#include <getopt.h>
-#include "bhome_msg_api.pb.h"
-#include "bhome_msg.pb.h"
-#include "error_msg.pb.h"
-#include "proto/bhome_msg.pb.h"
-#include "proto/bhome_msg_api.pb.h"
+#include "../proto/source/bhome_msg.pb.h"
+#include "../proto/source/bhome_msg_api.pb.h"
static Logger *logger = LoggerFactory::getLogger();
diff --git a/test_socket/CMakeLists.txt b/test_socket/CMakeLists.txt
index a096136..2b9f44a 100644
--- a/test_socket/CMakeLists.txt
+++ b/test_socket/CMakeLists.txt
@@ -30,4 +30,3 @@
add_executable(heart_beat heart_beat.cpp ${CMAKE_CURRENT_BINARY_DIR}/heart_beat.sh)
target_link_libraries(heart_beat PRIVATE shm_queue ${EXTRA_LIBS} )
-
--
Gitblit v1.8.0