Documentation ¶
Index ¶
- Variables
- func RegisterOrderServer(s *grpc.Server, srv OrderServer)
- func RegisterUserServer(s *grpc.Server, srv UserServer)
- type DeleteReq
- type DeleteRes
- type InsertReq
- type InsertRes
- type OrderClient
- type OrderServer
- type QueryReq
- type QueryRes
- type UnimplementedOrderServer
- type UnimplementedUserServer
- type UserClient
- type UserServer
Constants ¶
This section is empty.
Variables ¶
View Source
var File_order_proto protoreflect.FileDescriptor
View Source
var File_user_proto protoreflect.FileDescriptor
Functions ¶
func RegisterOrderServer ¶
func RegisterOrderServer(s *grpc.Server, srv OrderServer)
func RegisterUserServer ¶
func RegisterUserServer(s *grpc.Server, srv UserServer)
Types ¶
type DeleteReq ¶
type DeleteReq struct { Id int32 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // contains filtered or unexported fields }
func (*DeleteReq) Descriptor
deprecated
func (*DeleteReq) ProtoMessage ¶
func (*DeleteReq) ProtoMessage()
func (*DeleteReq) ProtoReflect ¶
func (x *DeleteReq) ProtoReflect() protoreflect.Message
type DeleteRes ¶
type DeleteRes struct {
// contains filtered or unexported fields
}
func (*DeleteRes) Descriptor
deprecated
func (*DeleteRes) ProtoMessage ¶
func (*DeleteRes) ProtoMessage()
func (*DeleteRes) ProtoReflect ¶
func (x *DeleteRes) ProtoReflect() protoreflect.Message
type InsertReq ¶
type InsertReq struct { Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` // contains filtered or unexported fields }
func (*InsertReq) Descriptor
deprecated
func (*InsertReq) ProtoMessage ¶
func (*InsertReq) ProtoMessage()
func (*InsertReq) ProtoReflect ¶
func (x *InsertReq) ProtoReflect() protoreflect.Message
type InsertRes ¶
type InsertRes struct { Id int32 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // contains filtered or unexported fields }
func (*InsertRes) Descriptor
deprecated
func (*InsertRes) ProtoMessage ¶
func (*InsertRes) ProtoMessage()
func (*InsertRes) ProtoReflect ¶
func (x *InsertRes) ProtoReflect() protoreflect.Message
type OrderClient ¶
type OrderClient interface { Insert(ctx context.Context, in *InsertReq, opts ...grpc.CallOption) (*InsertRes, error) Query(ctx context.Context, in *QueryReq, opts ...grpc.CallOption) (*QueryRes, error) Delete(ctx context.Context, in *DeleteReq, opts ...grpc.CallOption) (*DeleteRes, error) }
OrderClient is the client API for Order service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewOrderClient ¶
func NewOrderClient(cc grpc.ClientConnInterface) OrderClient
type OrderServer ¶
type OrderServer interface { Insert(context.Context, *InsertReq) (*InsertRes, error) Query(context.Context, *QueryReq) (*QueryRes, error) Delete(context.Context, *DeleteReq) (*DeleteRes, error) }
OrderServer is the server API for Order service.
type QueryReq ¶
type QueryReq struct { Id int32 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` // contains filtered or unexported fields }
func (*QueryReq) Descriptor
deprecated
func (*QueryReq) ProtoMessage ¶
func (*QueryReq) ProtoMessage()
func (*QueryReq) ProtoReflect ¶
func (x *QueryReq) ProtoReflect() protoreflect.Message
type QueryRes ¶
type QueryRes struct { Id int32 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` Name string `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"` // contains filtered or unexported fields }
func (*QueryRes) Descriptor
deprecated
func (*QueryRes) ProtoMessage ¶
func (*QueryRes) ProtoMessage()
func (*QueryRes) ProtoReflect ¶
func (x *QueryRes) ProtoReflect() protoreflect.Message
type UnimplementedOrderServer ¶
type UnimplementedOrderServer struct { }
UnimplementedOrderServer can be embedded to have forward compatible implementations.
type UnimplementedUserServer ¶
type UnimplementedUserServer struct { }
UnimplementedUserServer can be embedded to have forward compatible implementations.
type UserClient ¶
type UserClient interface { Insert(ctx context.Context, in *InsertReq, opts ...grpc.CallOption) (*InsertRes, error) Query(ctx context.Context, in *QueryReq, opts ...grpc.CallOption) (*QueryRes, error) Delete(ctx context.Context, in *DeleteReq, opts ...grpc.CallOption) (*DeleteRes, error) }
UserClient is the client API for User service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewUserClient ¶
func NewUserClient(cc grpc.ClientConnInterface) UserClient
Click to show internal directories.
Click to hide internal directories.