Documentation
¶
Index ¶
- func RegisterChatServiceServer(s *grpc.Server, srv ChatServiceServer)
- type ChatServiceClient
- type ChatServiceServer
- type ChatService_SubscribeClient
- type ChatService_SubscribeServer
- type Message
- func (*Message) Descriptor() ([]byte, []int)
- func (m *Message) GetSendId() string
- func (m *Message) GetSentAt() *timestamp.Timestamp
- func (m *Message) GetText() string
- func (*Message) ProtoMessage()
- func (m *Message) Reset()
- func (m *Message) String() string
- func (m *Message) XXX_DiscardUnknown()
- func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Message) XXX_Merge(src proto.Message)
- func (m *Message) XXX_Size() int
- func (m *Message) XXX_Unmarshal(b []byte) error
- type SendRequest
- func (*SendRequest) Descriptor() ([]byte, []int)
- func (m *SendRequest) GetMessage() *Message
- func (m *SendRequest) GetSubId() string
- func (*SendRequest) ProtoMessage()
- func (m *SendRequest) Reset()
- func (m *SendRequest) String() string
- func (m *SendRequest) XXX_DiscardUnknown()
- func (m *SendRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SendRequest) XXX_Merge(src proto.Message)
- func (m *SendRequest) XXX_Size() int
- func (m *SendRequest) XXX_Unmarshal(b []byte) error
- type SendResponse
- func (*SendResponse) Descriptor() ([]byte, []int)
- func (*SendResponse) ProtoMessage()
- func (m *SendResponse) Reset()
- func (m *SendResponse) String() string
- func (m *SendResponse) XXX_DiscardUnknown()
- func (m *SendResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SendResponse) XXX_Merge(src proto.Message)
- func (m *SendResponse) XXX_Size() int
- func (m *SendResponse) XXX_Unmarshal(b []byte) error
- type SubscribeRequest
- func (*SubscribeRequest) Descriptor() ([]byte, []int)
- func (m *SubscribeRequest) GetSubId() string
- func (*SubscribeRequest) ProtoMessage()
- func (m *SubscribeRequest) Reset()
- func (m *SubscribeRequest) String() string
- func (m *SubscribeRequest) XXX_DiscardUnknown()
- func (m *SubscribeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SubscribeRequest) XXX_Merge(src proto.Message)
- func (m *SubscribeRequest) XXX_Size() int
- func (m *SubscribeRequest) XXX_Unmarshal(b []byte) error
- type SubscribeResponse
- func (*SubscribeResponse) Descriptor() ([]byte, []int)
- func (m *SubscribeResponse) GetMessage() *Message
- func (*SubscribeResponse) ProtoMessage()
- func (m *SubscribeResponse) Reset()
- func (m *SubscribeResponse) String() string
- func (m *SubscribeResponse) XXX_DiscardUnknown()
- func (m *SubscribeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SubscribeResponse) XXX_Merge(src proto.Message)
- func (m *SubscribeResponse) XXX_Size() int
- func (m *SubscribeResponse) XXX_Unmarshal(b []byte) error
- type UnimplementedChatServiceServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterChatServiceServer ¶
func RegisterChatServiceServer(s *grpc.Server, srv ChatServiceServer)
Types ¶
type ChatServiceClient ¶
type ChatServiceClient interface { Send(ctx context.Context, in *SendRequest, opts ...grpc.CallOption) (*SendResponse, error) Subscribe(ctx context.Context, in *SubscribeRequest, opts ...grpc.CallOption) (ChatService_SubscribeClient, error) }
ChatServiceClient is the client API for ChatService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewChatServiceClient ¶
func NewChatServiceClient(cc *grpc.ClientConn) ChatServiceClient
type ChatServiceServer ¶
type ChatServiceServer interface { Send(context.Context, *SendRequest) (*SendResponse, error) Subscribe(*SubscribeRequest, ChatService_SubscribeServer) error }
ChatServiceServer is the server API for ChatService service.
type ChatService_SubscribeClient ¶
type ChatService_SubscribeClient interface { Recv() (*SubscribeResponse, error) grpc.ClientStream }
type ChatService_SubscribeServer ¶
type ChatService_SubscribeServer interface { Send(*SubscribeResponse) error grpc.ServerStream }
type Message ¶
type Message struct { SendId string `protobuf:"bytes,1,opt,name=send_id,json=sendId,proto3" json:"send_id,omitempty"` Text string `protobuf:"bytes,2,opt,name=text,proto3" json:"text,omitempty"` SentAt *timestamp.Timestamp `protobuf:"bytes,3,opt,name=sent_at,json=sentAt,proto3" json:"sent_at,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Message) Descriptor ¶
func (*Message) ProtoMessage ¶
func (*Message) ProtoMessage()
func (*Message) XXX_DiscardUnknown ¶
func (m *Message) XXX_DiscardUnknown()
func (*Message) XXX_Marshal ¶
func (*Message) XXX_Unmarshal ¶
type SendRequest ¶
type SendRequest struct { SubId string `protobuf:"bytes,1,opt,name=sub_id,json=subId,proto3" json:"sub_id,omitempty"` Message *Message `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SendRequest) Descriptor ¶
func (*SendRequest) Descriptor() ([]byte, []int)
func (*SendRequest) GetMessage ¶
func (m *SendRequest) GetMessage() *Message
func (*SendRequest) GetSubId ¶
func (m *SendRequest) GetSubId() string
func (*SendRequest) ProtoMessage ¶
func (*SendRequest) ProtoMessage()
func (*SendRequest) Reset ¶
func (m *SendRequest) Reset()
func (*SendRequest) String ¶
func (m *SendRequest) String() string
func (*SendRequest) XXX_DiscardUnknown ¶
func (m *SendRequest) XXX_DiscardUnknown()
func (*SendRequest) XXX_Marshal ¶
func (m *SendRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SendRequest) XXX_Merge ¶
func (m *SendRequest) XXX_Merge(src proto.Message)
func (*SendRequest) XXX_Size ¶
func (m *SendRequest) XXX_Size() int
func (*SendRequest) XXX_Unmarshal ¶
func (m *SendRequest) XXX_Unmarshal(b []byte) error
type SendResponse ¶
type SendResponse struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SendResponse) Descriptor ¶
func (*SendResponse) Descriptor() ([]byte, []int)
func (*SendResponse) ProtoMessage ¶
func (*SendResponse) ProtoMessage()
func (*SendResponse) Reset ¶
func (m *SendResponse) Reset()
func (*SendResponse) String ¶
func (m *SendResponse) String() string
func (*SendResponse) XXX_DiscardUnknown ¶
func (m *SendResponse) XXX_DiscardUnknown()
func (*SendResponse) XXX_Marshal ¶
func (m *SendResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SendResponse) XXX_Merge ¶
func (m *SendResponse) XXX_Merge(src proto.Message)
func (*SendResponse) XXX_Size ¶
func (m *SendResponse) XXX_Size() int
func (*SendResponse) XXX_Unmarshal ¶
func (m *SendResponse) XXX_Unmarshal(b []byte) error
type SubscribeRequest ¶
type SubscribeRequest struct { SubId string `protobuf:"bytes,1,opt,name=sub_id,json=subId,proto3" json:"sub_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SubscribeRequest) Descriptor ¶
func (*SubscribeRequest) Descriptor() ([]byte, []int)
func (*SubscribeRequest) GetSubId ¶
func (m *SubscribeRequest) GetSubId() string
func (*SubscribeRequest) ProtoMessage ¶
func (*SubscribeRequest) ProtoMessage()
func (*SubscribeRequest) Reset ¶
func (m *SubscribeRequest) Reset()
func (*SubscribeRequest) String ¶
func (m *SubscribeRequest) String() string
func (*SubscribeRequest) XXX_DiscardUnknown ¶
func (m *SubscribeRequest) XXX_DiscardUnknown()
func (*SubscribeRequest) XXX_Marshal ¶
func (m *SubscribeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SubscribeRequest) XXX_Merge ¶
func (m *SubscribeRequest) XXX_Merge(src proto.Message)
func (*SubscribeRequest) XXX_Size ¶
func (m *SubscribeRequest) XXX_Size() int
func (*SubscribeRequest) XXX_Unmarshal ¶
func (m *SubscribeRequest) XXX_Unmarshal(b []byte) error
type SubscribeResponse ¶
type SubscribeResponse struct { Message *Message `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SubscribeResponse) Descriptor ¶
func (*SubscribeResponse) Descriptor() ([]byte, []int)
func (*SubscribeResponse) GetMessage ¶
func (m *SubscribeResponse) GetMessage() *Message
func (*SubscribeResponse) ProtoMessage ¶
func (*SubscribeResponse) ProtoMessage()
func (*SubscribeResponse) Reset ¶
func (m *SubscribeResponse) Reset()
func (*SubscribeResponse) String ¶
func (m *SubscribeResponse) String() string
func (*SubscribeResponse) XXX_DiscardUnknown ¶
func (m *SubscribeResponse) XXX_DiscardUnknown()
func (*SubscribeResponse) XXX_Marshal ¶
func (m *SubscribeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SubscribeResponse) XXX_Merge ¶
func (m *SubscribeResponse) XXX_Merge(src proto.Message)
func (*SubscribeResponse) XXX_Size ¶
func (m *SubscribeResponse) XXX_Size() int
func (*SubscribeResponse) XXX_Unmarshal ¶
func (m *SubscribeResponse) XXX_Unmarshal(b []byte) error
type UnimplementedChatServiceServer ¶
type UnimplementedChatServiceServer struct { }
UnimplementedChatServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedChatServiceServer) Send ¶
func (*UnimplementedChatServiceServer) Send(ctx context.Context, req *SendRequest) (*SendResponse, error)
func (*UnimplementedChatServiceServer) Subscribe ¶
func (*UnimplementedChatServiceServer) Subscribe(req *SubscribeRequest, srv ChatService_SubscribeServer) error
Click to show internal directories.
Click to hide internal directories.