Documentation ¶
Index ¶
- func RegisterStreamServiceServer(s *grpc.Server, srv StreamServiceServer)
- func RegisterStudentProtoServiceServer(s *grpc.Server, srv StudentProtoServiceServer)
- type MyRequest
- func (*MyRequest) Descriptor() ([]byte, []int)
- func (m *MyRequest) GetName() string
- func (*MyRequest) ProtoMessage()
- func (m *MyRequest) Reset()
- func (m *MyRequest) String() string
- func (m *MyRequest) XXX_DiscardUnknown()
- func (m *MyRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MyRequest) XXX_Merge(src proto.Message)
- func (m *MyRequest) XXX_Size() int
- func (m *MyRequest) XXX_Unmarshal(b []byte) error
- type MyResponse
- func (*MyResponse) Descriptor() ([]byte, []int)
- func (m *MyResponse) GetRealname() string
- func (*MyResponse) ProtoMessage()
- func (m *MyResponse) Reset()
- func (m *MyResponse) String() string
- func (m *MyResponse) XXX_DiscardUnknown()
- func (m *MyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MyResponse) XXX_Merge(src proto.Message)
- func (m *MyResponse) XXX_Size() int
- func (m *MyResponse) XXX_Unmarshal(b []byte) error
- type StreamPoint
- func (*StreamPoint) Descriptor() ([]byte, []int)
- func (m *StreamPoint) GetName() string
- func (m *StreamPoint) GetValue() int32
- func (*StreamPoint) ProtoMessage()
- func (m *StreamPoint) Reset()
- func (m *StreamPoint) String() string
- func (m *StreamPoint) XXX_DiscardUnknown()
- func (m *StreamPoint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *StreamPoint) XXX_Merge(src proto.Message)
- func (m *StreamPoint) XXX_Size() int
- func (m *StreamPoint) XXX_Unmarshal(b []byte) error
- type StreamRequest
- func (*StreamRequest) Descriptor() ([]byte, []int)
- func (m *StreamRequest) GetPt() *StreamPoint
- func (*StreamRequest) ProtoMessage()
- func (m *StreamRequest) Reset()
- func (m *StreamRequest) String() string
- func (m *StreamRequest) XXX_DiscardUnknown()
- func (m *StreamRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *StreamRequest) XXX_Merge(src proto.Message)
- func (m *StreamRequest) XXX_Size() int
- func (m *StreamRequest) XXX_Unmarshal(b []byte) error
- type StreamResponse
- func (*StreamResponse) Descriptor() ([]byte, []int)
- func (m *StreamResponse) GetPt() *StreamPoint
- func (*StreamResponse) ProtoMessage()
- func (m *StreamResponse) Reset()
- func (m *StreamResponse) String() string
- func (m *StreamResponse) XXX_DiscardUnknown()
- func (m *StreamResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *StreamResponse) XXX_Merge(src proto.Message)
- func (m *StreamResponse) XXX_Size() int
- func (m *StreamResponse) XXX_Unmarshal(b []byte) error
- type StreamServiceClient
- type StreamServiceServer
- type StreamService_ListClient
- type StreamService_ListServer
- type StreamService_RecordClient
- type StreamService_RecordServer
- type StreamService_RouteClient
- type StreamService_RouteServer
- type StudentProtoServiceClient
- type StudentProtoServiceServer
- type UnimplementedStreamServiceServer
- type UnimplementedStudentProtoServiceServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterStreamServiceServer ¶
func RegisterStreamServiceServer(s *grpc.Server, srv StreamServiceServer)
func RegisterStudentProtoServiceServer ¶
func RegisterStudentProtoServiceServer(s *grpc.Server, srv StudentProtoServiceServer)
Types ¶
type MyRequest ¶
type MyRequest struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*MyRequest) Descriptor ¶
func (*MyRequest) ProtoMessage ¶
func (*MyRequest) ProtoMessage()
func (*MyRequest) XXX_DiscardUnknown ¶
func (m *MyRequest) XXX_DiscardUnknown()
func (*MyRequest) XXX_Marshal ¶
func (*MyRequest) XXX_Unmarshal ¶
type MyResponse ¶
type MyResponse struct { Realname string `protobuf:"bytes,2,opt,name=realname,proto3" json:"realname,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*MyResponse) Descriptor ¶
func (*MyResponse) Descriptor() ([]byte, []int)
func (*MyResponse) GetRealname ¶
func (m *MyResponse) GetRealname() string
func (*MyResponse) ProtoMessage ¶
func (*MyResponse) ProtoMessage()
func (*MyResponse) Reset ¶
func (m *MyResponse) Reset()
func (*MyResponse) String ¶
func (m *MyResponse) String() string
func (*MyResponse) XXX_DiscardUnknown ¶
func (m *MyResponse) XXX_DiscardUnknown()
func (*MyResponse) XXX_Marshal ¶
func (m *MyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MyResponse) XXX_Merge ¶
func (m *MyResponse) XXX_Merge(src proto.Message)
func (*MyResponse) XXX_Size ¶
func (m *MyResponse) XXX_Size() int
func (*MyResponse) XXX_Unmarshal ¶
func (m *MyResponse) XXX_Unmarshal(b []byte) error
type StreamPoint ¶
type StreamPoint struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Value int32 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*StreamPoint) Descriptor ¶
func (*StreamPoint) Descriptor() ([]byte, []int)
func (*StreamPoint) GetName ¶
func (m *StreamPoint) GetName() string
func (*StreamPoint) GetValue ¶
func (m *StreamPoint) GetValue() int32
func (*StreamPoint) ProtoMessage ¶
func (*StreamPoint) ProtoMessage()
func (*StreamPoint) Reset ¶
func (m *StreamPoint) Reset()
func (*StreamPoint) String ¶
func (m *StreamPoint) String() string
func (*StreamPoint) XXX_DiscardUnknown ¶
func (m *StreamPoint) XXX_DiscardUnknown()
func (*StreamPoint) XXX_Marshal ¶
func (m *StreamPoint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*StreamPoint) XXX_Merge ¶
func (m *StreamPoint) XXX_Merge(src proto.Message)
func (*StreamPoint) XXX_Size ¶
func (m *StreamPoint) XXX_Size() int
func (*StreamPoint) XXX_Unmarshal ¶
func (m *StreamPoint) XXX_Unmarshal(b []byte) error
type StreamRequest ¶
type StreamRequest struct { Pt *StreamPoint `protobuf:"bytes,1,opt,name=pt,proto3" json:"pt,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*StreamRequest) Descriptor ¶
func (*StreamRequest) Descriptor() ([]byte, []int)
func (*StreamRequest) GetPt ¶
func (m *StreamRequest) GetPt() *StreamPoint
func (*StreamRequest) ProtoMessage ¶
func (*StreamRequest) ProtoMessage()
func (*StreamRequest) Reset ¶
func (m *StreamRequest) Reset()
func (*StreamRequest) String ¶
func (m *StreamRequest) String() string
func (*StreamRequest) XXX_DiscardUnknown ¶
func (m *StreamRequest) XXX_DiscardUnknown()
func (*StreamRequest) XXX_Marshal ¶
func (m *StreamRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*StreamRequest) XXX_Merge ¶
func (m *StreamRequest) XXX_Merge(src proto.Message)
func (*StreamRequest) XXX_Size ¶
func (m *StreamRequest) XXX_Size() int
func (*StreamRequest) XXX_Unmarshal ¶
func (m *StreamRequest) XXX_Unmarshal(b []byte) error
type StreamResponse ¶
type StreamResponse struct { Pt *StreamPoint `protobuf:"bytes,1,opt,name=pt,proto3" json:"pt,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*StreamResponse) Descriptor ¶
func (*StreamResponse) Descriptor() ([]byte, []int)
func (*StreamResponse) GetPt ¶
func (m *StreamResponse) GetPt() *StreamPoint
func (*StreamResponse) ProtoMessage ¶
func (*StreamResponse) ProtoMessage()
func (*StreamResponse) Reset ¶
func (m *StreamResponse) Reset()
func (*StreamResponse) String ¶
func (m *StreamResponse) String() string
func (*StreamResponse) XXX_DiscardUnknown ¶
func (m *StreamResponse) XXX_DiscardUnknown()
func (*StreamResponse) XXX_Marshal ¶
func (m *StreamResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*StreamResponse) XXX_Merge ¶
func (m *StreamResponse) XXX_Merge(src proto.Message)
func (*StreamResponse) XXX_Size ¶
func (m *StreamResponse) XXX_Size() int
func (*StreamResponse) XXX_Unmarshal ¶
func (m *StreamResponse) XXX_Unmarshal(b []byte) error
type StreamServiceClient ¶
type StreamServiceClient interface { // 服务器端流式 RPC List(ctx context.Context, in *StreamRequest, opts ...grpc.CallOption) (StreamService_ListClient, error) // 客户端流式 RPC Record(ctx context.Context, opts ...grpc.CallOption) (StreamService_RecordClient, error) // 双向流式 RPC Route(ctx context.Context, opts ...grpc.CallOption) (StreamService_RouteClient, error) }
StreamServiceClient is the client API for StreamService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewStreamServiceClient ¶
func NewStreamServiceClient(cc *grpc.ClientConn) StreamServiceClient
type StreamServiceServer ¶
type StreamServiceServer interface { // 服务器端流式 RPC List(*StreamRequest, StreamService_ListServer) error // 客户端流式 RPC Record(StreamService_RecordServer) error // 双向流式 RPC Route(StreamService_RouteServer) error }
StreamServiceServer is the server API for StreamService service.
type StreamService_ListClient ¶
type StreamService_ListClient interface { Recv() (*StreamResponse, error) grpc.ClientStream }
type StreamService_ListServer ¶
type StreamService_ListServer interface { Send(*StreamResponse) error grpc.ServerStream }
type StreamService_RecordClient ¶
type StreamService_RecordClient interface { Send(*StreamRequest) error CloseAndRecv() (*StreamResponse, error) grpc.ClientStream }
type StreamService_RecordServer ¶
type StreamService_RecordServer interface { SendAndClose(*StreamResponse) error Recv() (*StreamRequest, error) grpc.ServerStream }
type StreamService_RouteClient ¶
type StreamService_RouteClient interface { Send(*StreamRequest) error Recv() (*StreamResponse, error) grpc.ClientStream }
type StreamService_RouteServer ¶
type StreamService_RouteServer interface { Send(*StreamResponse) error Recv() (*StreamRequest, error) grpc.ServerStream }
type StudentProtoServiceClient ¶
type StudentProtoServiceClient interface {
GetName(ctx context.Context, in *MyRequest, opts ...grpc.CallOption) (*MyResponse, error)
}
StudentProtoServiceClient is the client API for StudentProtoService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewStudentProtoServiceClient ¶
func NewStudentProtoServiceClient(cc *grpc.ClientConn) StudentProtoServiceClient
type StudentProtoServiceServer ¶
type StudentProtoServiceServer interface {
GetName(context.Context, *MyRequest) (*MyResponse, error)
}
StudentProtoServiceServer is the server API for StudentProtoService service.
type UnimplementedStreamServiceServer ¶
type UnimplementedStreamServiceServer struct { }
UnimplementedStreamServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedStreamServiceServer) List ¶
func (*UnimplementedStreamServiceServer) List(req *StreamRequest, srv StreamService_ListServer) error
func (*UnimplementedStreamServiceServer) Record ¶
func (*UnimplementedStreamServiceServer) Record(srv StreamService_RecordServer) error
func (*UnimplementedStreamServiceServer) Route ¶
func (*UnimplementedStreamServiceServer) Route(srv StreamService_RouteServer) error
type UnimplementedStudentProtoServiceServer ¶
type UnimplementedStudentProtoServiceServer struct { }
UnimplementedStudentProtoServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedStudentProtoServiceServer) GetName ¶
func (*UnimplementedStudentProtoServiceServer) GetName(ctx context.Context, req *MyRequest) (*MyResponse, error)