Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var File_users_proto protoreflect.FileDescriptor
var Users_ServiceDesc = grpc.ServiceDesc{ ServiceName: "Users", HandlerType: (*UsersServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetUser", Handler: _Users_GetUser_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "users.proto", }
Users_ServiceDesc is the grpc.ServiceDesc for Users service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterUsersServer ¶
func RegisterUsersServer(s grpc.ServiceRegistrar, srv UsersServer)
Types ¶
type UnimplementedUsersServer ¶
type UnimplementedUsersServer struct { }
UnimplementedUsersServer must be embedded to have forward compatible implementations.
func (UnimplementedUsersServer) GetUser ¶
func (UnimplementedUsersServer) GetUser(context.Context, *UserGetRequest) (*UserGetReply, error)
type UnsafeUsersServer ¶
type UnsafeUsersServer interface {
// contains filtered or unexported methods
}
UnsafeUsersServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to UsersServer will result in compilation errors.
type User ¶
type User struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*User) Descriptor
deprecated
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) ProtoReflect ¶
func (x *User) ProtoReflect() protoreflect.Message
type UserGetReply ¶
type UserGetReply struct { User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"` // contains filtered or unexported fields }
func (*UserGetReply) Descriptor
deprecated
func (*UserGetReply) Descriptor() ([]byte, []int)
Deprecated: Use UserGetReply.ProtoReflect.Descriptor instead.
func (*UserGetReply) GetUser ¶
func (x *UserGetReply) GetUser() *User
func (*UserGetReply) ProtoMessage ¶
func (*UserGetReply) ProtoMessage()
func (*UserGetReply) ProtoReflect ¶
func (x *UserGetReply) ProtoReflect() protoreflect.Message
func (*UserGetReply) Reset ¶
func (x *UserGetReply) Reset()
func (*UserGetReply) String ¶
func (x *UserGetReply) String() string
type UserGetRequest ¶
type UserGetRequest struct { Auth string `protobuf:"bytes,1,opt,name=auth,proto3" json:"auth,omitempty"` // contains filtered or unexported fields }
func (*UserGetRequest) Descriptor
deprecated
func (*UserGetRequest) Descriptor() ([]byte, []int)
Deprecated: Use UserGetRequest.ProtoReflect.Descriptor instead.
func (*UserGetRequest) GetAuth ¶
func (x *UserGetRequest) GetAuth() string
func (*UserGetRequest) ProtoMessage ¶
func (*UserGetRequest) ProtoMessage()
func (*UserGetRequest) ProtoReflect ¶
func (x *UserGetRequest) ProtoReflect() protoreflect.Message
func (*UserGetRequest) Reset ¶
func (x *UserGetRequest) Reset()
func (*UserGetRequest) String ¶
func (x *UserGetRequest) String() string
type UsersClient ¶
type UsersClient interface {
GetUser(ctx context.Context, in *UserGetRequest, opts ...grpc.CallOption) (*UserGetReply, error)
}
UsersClient is the client API for Users service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewUsersClient ¶
func NewUsersClient(cc grpc.ClientConnInterface) UsersClient
type UsersServer ¶
type UsersServer interface { GetUser(context.Context, *UserGetRequest) (*UserGetReply, error) // contains filtered or unexported methods }
UsersServer is the server API for Users service. All implementations must embed UnimplementedUsersServer for forward compatibility