|
@@ -9,6 +9,7 @@ package pb
|
|
|
import (
|
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
|
+ structpb "google.golang.org/protobuf/types/known/structpb"
|
|
|
reflect "reflect"
|
|
|
sync "sync"
|
|
|
)
|
|
@@ -20,16 +21,18 @@ const (
|
|
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
|
)
|
|
|
|
|
|
-type ChatMsgReq struct {
|
|
|
+type CommandResp struct {
|
|
|
state protoimpl.MessageState
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
|
- ChatId string `protobuf:"bytes,1,opt,name=chat_id,json=chatId,proto3" json:"chat_id,omitempty"`
|
|
|
+ CommandCode int64 `protobuf:"varint,1,opt,name=command_code,json=commandCode,proto3" json:"command_code,omitempty"`
|
|
|
+ CommandMsg string `protobuf:"bytes,2,opt,name=command_msg,json=commandMsg,proto3" json:"command_msg,omitempty"`
|
|
|
+ CommandData *structpb.Struct `protobuf:"bytes,3,opt,name=command_data,json=commandData,proto3" json:"command_data,omitempty"`
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReq) Reset() {
|
|
|
- *x = ChatMsgReq{}
|
|
|
+func (x *CommandResp) Reset() {
|
|
|
+ *x = CommandResp{}
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
mi := &file_pb_rpcbff_proto_msgTypes[0]
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
@@ -37,13 +40,13 @@ func (x *ChatMsgReq) Reset() {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReq) String() string {
|
|
|
+func (x *CommandResp) String() string {
|
|
|
return protoimpl.X.MessageStringOf(x)
|
|
|
}
|
|
|
|
|
|
-func (*ChatMsgReq) ProtoMessage() {}
|
|
|
+func (*CommandResp) ProtoMessage() {}
|
|
|
|
|
|
-func (x *ChatMsgReq) ProtoReflect() protoreflect.Message {
|
|
|
+func (x *CommandResp) ProtoReflect() protoreflect.Message {
|
|
|
mi := &file_pb_rpcbff_proto_msgTypes[0]
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
@@ -55,29 +58,42 @@ func (x *ChatMsgReq) ProtoReflect() protoreflect.Message {
|
|
|
return mi.MessageOf(x)
|
|
|
}
|
|
|
|
|
|
-// Deprecated: Use ChatMsgReq.ProtoReflect.Descriptor instead.
|
|
|
-func (*ChatMsgReq) Descriptor() ([]byte, []int) {
|
|
|
+// Deprecated: Use CommandResp.ProtoReflect.Descriptor instead.
|
|
|
+func (*CommandResp) Descriptor() ([]byte, []int) {
|
|
|
return file_pb_rpcbff_proto_rawDescGZIP(), []int{0}
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReq) GetChatId() string {
|
|
|
+func (x *CommandResp) GetCommandCode() int64 {
|
|
|
if x != nil {
|
|
|
- return x.ChatId
|
|
|
+ return x.CommandCode
|
|
|
+ }
|
|
|
+ return 0
|
|
|
+}
|
|
|
+
|
|
|
+func (x *CommandResp) GetCommandMsg() string {
|
|
|
+ if x != nil {
|
|
|
+ return x.CommandMsg
|
|
|
}
|
|
|
return ""
|
|
|
}
|
|
|
|
|
|
-type ChatMsgReqResp struct {
|
|
|
+func (x *CommandResp) GetCommandData() *structpb.Struct {
|
|
|
+ if x != nil {
|
|
|
+ return x.CommandData
|
|
|
+ }
|
|
|
+ return nil
|
|
|
+}
|
|
|
+
|
|
|
+type CommandReq struct {
|
|
|
state protoimpl.MessageState
|
|
|
sizeCache protoimpl.SizeCache
|
|
|
unknownFields protoimpl.UnknownFields
|
|
|
|
|
|
- Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
|
|
|
- Pic string `protobuf:"bytes,2,opt,name=pic,proto3" json:"pic,omitempty"`
|
|
|
+ Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReqResp) Reset() {
|
|
|
- *x = ChatMsgReqResp{}
|
|
|
+func (x *CommandReq) Reset() {
|
|
|
+ *x = CommandReq{}
|
|
|
if protoimpl.UnsafeEnabled {
|
|
|
mi := &file_pb_rpcbff_proto_msgTypes[1]
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
@@ -85,13 +101,13 @@ func (x *ChatMsgReqResp) Reset() {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReqResp) String() string {
|
|
|
+func (x *CommandReq) String() string {
|
|
|
return protoimpl.X.MessageStringOf(x)
|
|
|
}
|
|
|
|
|
|
-func (*ChatMsgReqResp) ProtoMessage() {}
|
|
|
+func (*CommandReq) ProtoMessage() {}
|
|
|
|
|
|
-func (x *ChatMsgReqResp) ProtoReflect() protoreflect.Message {
|
|
|
+func (x *CommandReq) ProtoReflect() protoreflect.Message {
|
|
|
mi := &file_pb_rpcbff_proto_msgTypes[1]
|
|
|
if protoimpl.UnsafeEnabled && x != nil {
|
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
@@ -103,21 +119,14 @@ func (x *ChatMsgReqResp) ProtoReflect() protoreflect.Message {
|
|
|
return mi.MessageOf(x)
|
|
|
}
|
|
|
|
|
|
-// Deprecated: Use ChatMsgReqResp.ProtoReflect.Descriptor instead.
|
|
|
-func (*ChatMsgReqResp) Descriptor() ([]byte, []int) {
|
|
|
+// Deprecated: Use CommandReq.ProtoReflect.Descriptor instead.
|
|
|
+func (*CommandReq) Descriptor() ([]byte, []int) {
|
|
|
return file_pb_rpcbff_proto_rawDescGZIP(), []int{1}
|
|
|
}
|
|
|
|
|
|
-func (x *ChatMsgReqResp) GetText() string {
|
|
|
- if x != nil {
|
|
|
- return x.Text
|
|
|
- }
|
|
|
- return ""
|
|
|
-}
|
|
|
-
|
|
|
-func (x *ChatMsgReqResp) GetPic() string {
|
|
|
+func (x *CommandReq) GetToken() string {
|
|
|
if x != nil {
|
|
|
- return x.Pic
|
|
|
+ return x.Token
|
|
|
}
|
|
|
return ""
|
|
|
}
|
|
@@ -126,18 +135,27 @@ var File_pb_rpcbff_proto protoreflect.FileDescriptor
|
|
|
|
|
|
var file_pb_rpcbff_proto_rawDesc = []byte{
|
|
|
0x0a, 0x0f, 0x70, 0x62, 0x2f, 0x72, 0x70, 0x63, 0x62, 0x66, 0x66, 0x2e, 0x70, 0x72, 0x6f, 0x74,
|
|
|
- 0x6f, 0x12, 0x02, 0x70, 0x62, 0x22, 0x25, 0x0a, 0x0a, 0x43, 0x68, 0x61, 0x74, 0x4d, 0x73, 0x67,
|
|
|
- 0x52, 0x65, 0x71, 0x12, 0x17, 0x0a, 0x07, 0x63, 0x68, 0x61, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01,
|
|
|
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x68, 0x61, 0x74, 0x49, 0x64, 0x22, 0x36, 0x0a, 0x0e,
|
|
|
- 0x43, 0x68, 0x61, 0x74, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x71, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12,
|
|
|
- 0x0a, 0x04, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x65,
|
|
|
- 0x78, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x70, 0x69, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
|
|
|
- 0x03, 0x70, 0x69, 0x63, 0x32, 0x41, 0x0a, 0x06, 0x72, 0x70, 0x63, 0x62, 0x66, 0x66, 0x12, 0x37,
|
|
|
- 0x0a, 0x0f, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x72, 0x43, 0x68, 0x61, 0x74, 0x4d, 0x73,
|
|
|
- 0x67, 0x12, 0x0e, 0x2e, 0x70, 0x62, 0x2e, 0x43, 0x68, 0x61, 0x74, 0x4d, 0x73, 0x67, 0x52, 0x65,
|
|
|
- 0x71, 0x1a, 0x12, 0x2e, 0x70, 0x62, 0x2e, 0x43, 0x68, 0x61, 0x74, 0x4d, 0x73, 0x67, 0x52, 0x65,
|
|
|
- 0x71, 0x52, 0x65, 0x73, 0x70, 0x30, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x2f, 0x70, 0x62, 0x62,
|
|
|
- 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
|
+ 0x6f, 0x12, 0x02, 0x70, 0x62, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72,
|
|
|
+ 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72,
|
|
|
+ 0x6f, 0x74, 0x6f, 0x22, 0x8d, 0x01, 0x0a, 0x0b, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52,
|
|
|
+ 0x65, 0x73, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x5f, 0x63,
|
|
|
+ 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x63, 0x6f, 0x6d, 0x6d, 0x61,
|
|
|
+ 0x6e, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e,
|
|
|
+ 0x64, 0x5f, 0x6d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6d,
|
|
|
+ 0x6d, 0x61, 0x6e, 0x64, 0x4d, 0x73, 0x67, 0x12, 0x3a, 0x0a,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 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e,
|
|
|
+ 0x70, 0x62, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06,
|
|
|
+ 0x5a, 0x04, 0x2e, 0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
|
}
|
|
|
|
|
|
var (
|
|
@@ -154,17 +172,21 @@ func file_pb_rpcbff_proto_rawDescGZIP() []byte {
|
|
|
|
|
|
var file_pb_rpcbff_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
|
|
var file_pb_rpcbff_proto_goTypes = []interface{}{
|
|
|
- (*ChatMsgReq)(nil), // 0: pb.ChatMsgReq
|
|
|
- (*ChatMsgReqResp)(nil), // 1: pb.ChatMsgReqResp
|
|
|
+ (*CommandResp)(nil), // 0: pb.CommandResp
|
|
|
+ (*CommandReq)(nil), // 1: pb.CommandReq
|
|
|
+ (*structpb.Struct)(nil), // 2: google.protobuf.Struct
|
|
|
}
|
|
|
var file_pb_rpcbff_proto_depIdxs = []int32{
|
|
|
- 0, // 0: pb.rpcbff.receiverChatMsg:input_type -> pb.ChatMsgReq
|
|
|
- 1, // 1: pb.rpcbff.receiverChatMsg:output_type -> pb.ChatMsgReqResp
|
|
|
- 1, // [1:2] is the sub-list for method output_type
|
|
|
- 0, // [0:1] is the sub-list for method input_type
|
|
|
- 0, // [0:0] is the sub-list for extension type_name
|
|
|
- 0, // [0:0] is the sub-list for extension extendee
|
|
|
- 0, // [0:0] is the sub-list for field type_name
|
|
|
+ 2, // 0: pb.CommandResp.command_data:type_name -> google.protobuf.Struct
|
|
|
+ 1, // 1: pb.Rpcbff.connect:input_type -> pb.CommandReq
|
|
|
+ 1, // 2: pb.Rpcbff.disconnect:input_type -> pb.CommandReq
|
|
|
+ 0, // 3: pb.Rpcbff.connect:output_type -> pb.CommandResp
|
|
|
+ 0, // 4: pb.Rpcbff.disconnect:output_type -> pb.CommandResp
|
|
|
+ 3, // [3:5] is the sub-list for method output_type
|
|
|
+ 1, // [1:3] is the sub-list for method input_type
|
|
|
+ 1, // [1:1] is the sub-list for extension type_name
|
|
|
+ 1, // [1:1] is the sub-list for extension extendee
|
|
|
+ 0, // [0:1] is the sub-list for field type_name
|
|
|
}
|
|
|
|
|
|
func init() { file_pb_rpcbff_proto_init() }
|
|
@@ -174,7 +196,7 @@ func file_pb_rpcbff_proto_init() {
|
|
|
}
|
|
|
if !protoimpl.UnsafeEnabled {
|
|
|
file_pb_rpcbff_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
|
|
- switch v := v.(*ChatMsgReq); i {
|
|
|
+ switch v := v.(*CommandResp); i {
|
|
|
case 0:
|
|
|
return &v.state
|
|
|
case 1:
|
|
@@ -186,7 +208,7 @@ func file_pb_rpcbff_proto_init() {
|
|
|
}
|
|
|
}
|
|
|
file_pb_rpcbff_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
|
|
- switch v := v.(*ChatMsgReqResp); i {
|
|
|
+ switch v := v.(*CommandReq); i {
|
|
|
case 0:
|
|
|
return &v.state
|
|
|
case 1:
|