Documentation
¶
Index ¶
- Variables
- func RegisterUserServiceServer(s grpc.ServiceRegistrar, srv UserServiceServer)
- type GetUserFromJWTInput
- func (*GetUserFromJWTInput) Descriptor() ([]byte, []int)deprecated
- func (x *GetUserFromJWTInput) GetJwtToken() string
- func (*GetUserFromJWTInput) ProtoMessage()
- func (x *GetUserFromJWTInput) ProtoReflect() protoreflect.Message
- func (x *GetUserFromJWTInput) Reset()
- func (x *GetUserFromJWTInput) String() string
- type GetUserFromJWTResponse
- func (*GetUserFromJWTResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetUserFromJWTResponse) GetUser() *User
- func (*GetUserFromJWTResponse) ProtoMessage()
- func (x *GetUserFromJWTResponse) ProtoReflect() protoreflect.Message
- func (x *GetUserFromJWTResponse) Reset()
- func (x *GetUserFromJWTResponse) String() string
- type GetUsersFilter
- func (*GetUsersFilter) Descriptor() ([]byte, []int)deprecated
- func (x *GetUsersFilter) GetAfterId() string
- func (x *GetUsersFilter) GetLimit() int32
- func (*GetUsersFilter) ProtoMessage()
- func (x *GetUsersFilter) ProtoReflect() protoreflect.Message
- func (x *GetUsersFilter) Reset()
- func (x *GetUsersFilter) String() string
- type GetUsersResponse
- type LoginInput
- type LoginResponse
- func (*LoginResponse) Descriptor() ([]byte, []int)deprecated
- func (x *LoginResponse) GetJwtToken() string
- func (x *LoginResponse) GetUser() *User
- func (*LoginResponse) ProtoMessage()
- func (x *LoginResponse) ProtoReflect() protoreflect.Message
- func (x *LoginResponse) Reset()
- func (x *LoginResponse) String() string
- type NewUser
- func (*NewUser) Descriptor() ([]byte, []int)deprecated
- func (x *NewUser) GetCountry() string
- func (x *NewUser) GetEmail() string
- func (x *NewUser) GetFullName() string
- func (x *NewUser) GetPassword() string
- func (*NewUser) ProtoMessage()
- func (x *NewUser) ProtoReflect() protoreflect.Message
- func (x *NewUser) Reset()
- func (x *NewUser) String() string
- type UnimplementedUserServiceServer
- func (UnimplementedUserServiceServer) CreateUser(context.Context, *NewUser) (*User, error)
- func (UnimplementedUserServiceServer) GetUserFromJWT(context.Context, *GetUserFromJWTInput) (*GetUserFromJWTResponse, error)
- func (UnimplementedUserServiceServer) GetUsers(context.Context, *GetUsersFilter) (*GetUsersResponse, error)
- func (UnimplementedUserServiceServer) LoginUser(context.Context, *LoginInput) (*LoginResponse, error)
- type UnsafeUserServiceServer
- type User
- func (*User) Descriptor() ([]byte, []int)deprecated
- func (x *User) GetCountry() string
- func (x *User) GetEmail() string
- func (x *User) GetFullName() string
- func (x *User) GetId() string
- func (*User) ProtoMessage()
- func (x *User) ProtoReflect() protoreflect.Message
- func (x *User) Reset()
- func (x *User) String() string
- type UserServiceClient
- type UserServiceServer
Constants ¶
This section is empty.
Variables ¶
var File_user_proto protoreflect.FileDescriptor
var UserService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "UserService", HandlerType: (*UserServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateUser", Handler: _UserService_CreateUser_Handler, }, { MethodName: "GetUsers", Handler: _UserService_GetUsers_Handler, }, { MethodName: "LoginUser", Handler: _UserService_LoginUser_Handler, }, { MethodName: "GetUserFromJWT", Handler: _UserService_GetUserFromJWT_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "user.proto", }
UserService_ServiceDesc is the grpc.ServiceDesc for UserService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterUserServiceServer ¶
func RegisterUserServiceServer(s grpc.ServiceRegistrar, srv UserServiceServer)
Types ¶
type GetUserFromJWTInput ¶
type GetUserFromJWTInput struct { JwtToken string `protobuf:"bytes,1,opt,name=jwtToken,proto3" json:"jwtToken,omitempty"` // contains filtered or unexported fields }
func (*GetUserFromJWTInput) Descriptor
deprecated
func (*GetUserFromJWTInput) Descriptor() ([]byte, []int)
Deprecated: Use GetUserFromJWTInput.ProtoReflect.Descriptor instead.
func (*GetUserFromJWTInput) GetJwtToken ¶
func (x *GetUserFromJWTInput) GetJwtToken() string
func (*GetUserFromJWTInput) ProtoMessage ¶
func (*GetUserFromJWTInput) ProtoMessage()
func (*GetUserFromJWTInput) ProtoReflect ¶
func (x *GetUserFromJWTInput) ProtoReflect() protoreflect.Message
func (*GetUserFromJWTInput) Reset ¶
func (x *GetUserFromJWTInput) Reset()
func (*GetUserFromJWTInput) String ¶
func (x *GetUserFromJWTInput) String() string
type GetUserFromJWTResponse ¶
type GetUserFromJWTResponse struct { User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"` // contains filtered or unexported fields }
func (*GetUserFromJWTResponse) Descriptor
deprecated
func (*GetUserFromJWTResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetUserFromJWTResponse.ProtoReflect.Descriptor instead.
func (*GetUserFromJWTResponse) GetUser ¶
func (x *GetUserFromJWTResponse) GetUser() *User
func (*GetUserFromJWTResponse) ProtoMessage ¶
func (*GetUserFromJWTResponse) ProtoMessage()
func (*GetUserFromJWTResponse) ProtoReflect ¶
func (x *GetUserFromJWTResponse) ProtoReflect() protoreflect.Message
func (*GetUserFromJWTResponse) Reset ¶
func (x *GetUserFromJWTResponse) Reset()
func (*GetUserFromJWTResponse) String ¶
func (x *GetUserFromJWTResponse) String() string
type GetUsersFilter ¶
type GetUsersFilter struct { AfterId string `protobuf:"bytes,1,opt,name=afterId,proto3" json:"afterId,omitempty"` Limit int32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` // contains filtered or unexported fields }
func (*GetUsersFilter) Descriptor
deprecated
func (*GetUsersFilter) Descriptor() ([]byte, []int)
Deprecated: Use GetUsersFilter.ProtoReflect.Descriptor instead.
func (*GetUsersFilter) GetAfterId ¶
func (x *GetUsersFilter) GetAfterId() string
func (*GetUsersFilter) GetLimit ¶
func (x *GetUsersFilter) GetLimit() int32
func (*GetUsersFilter) ProtoMessage ¶
func (*GetUsersFilter) ProtoMessage()
func (*GetUsersFilter) ProtoReflect ¶
func (x *GetUsersFilter) ProtoReflect() protoreflect.Message
func (*GetUsersFilter) Reset ¶
func (x *GetUsersFilter) Reset()
func (*GetUsersFilter) String ¶
func (x *GetUsersFilter) String() string
type GetUsersResponse ¶
type GetUsersResponse struct { Users []*User `protobuf:"bytes,1,rep,name=users,proto3" json:"users,omitempty"` // contains filtered or unexported fields }
func (*GetUsersResponse) Descriptor
deprecated
func (*GetUsersResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetUsersResponse.ProtoReflect.Descriptor instead.
func (*GetUsersResponse) GetUsers ¶
func (x *GetUsersResponse) GetUsers() []*User
func (*GetUsersResponse) ProtoMessage ¶
func (*GetUsersResponse) ProtoMessage()
func (*GetUsersResponse) ProtoReflect ¶
func (x *GetUsersResponse) ProtoReflect() protoreflect.Message
func (*GetUsersResponse) Reset ¶
func (x *GetUsersResponse) Reset()
func (*GetUsersResponse) String ¶
func (x *GetUsersResponse) String() string
type LoginInput ¶
type LoginInput struct { Email string `protobuf:"bytes,1,opt,name=email,proto3" json:"email,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
func (*LoginInput) Descriptor
deprecated
func (*LoginInput) Descriptor() ([]byte, []int)
Deprecated: Use LoginInput.ProtoReflect.Descriptor instead.
func (*LoginInput) GetEmail ¶
func (x *LoginInput) GetEmail() string
func (*LoginInput) GetPassword ¶
func (x *LoginInput) GetPassword() string
func (*LoginInput) ProtoMessage ¶
func (*LoginInput) ProtoMessage()
func (*LoginInput) ProtoReflect ¶
func (x *LoginInput) ProtoReflect() protoreflect.Message
func (*LoginInput) Reset ¶
func (x *LoginInput) Reset()
func (*LoginInput) String ¶
func (x *LoginInput) String() string
type LoginResponse ¶
type LoginResponse struct { User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"` JwtToken string `protobuf:"bytes,2,opt,name=jwtToken,proto3" json:"jwtToken,omitempty"` // contains filtered or unexported fields }
func (*LoginResponse) Descriptor
deprecated
func (*LoginResponse) Descriptor() ([]byte, []int)
Deprecated: Use LoginResponse.ProtoReflect.Descriptor instead.
func (*LoginResponse) GetJwtToken ¶
func (x *LoginResponse) GetJwtToken() string
func (*LoginResponse) GetUser ¶
func (x *LoginResponse) GetUser() *User
func (*LoginResponse) ProtoMessage ¶
func (*LoginResponse) ProtoMessage()
func (*LoginResponse) ProtoReflect ¶
func (x *LoginResponse) ProtoReflect() protoreflect.Message
func (*LoginResponse) Reset ¶
func (x *LoginResponse) Reset()
func (*LoginResponse) String ¶
func (x *LoginResponse) String() string
type NewUser ¶
type NewUser struct { FullName string `protobuf:"bytes,1,opt,name=fullName,proto3" json:"fullName,omitempty"` Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"` Password string `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"` Country string `protobuf:"bytes,4,opt,name=country,proto3" json:"country,omitempty"` // contains filtered or unexported fields }
func (*NewUser) Descriptor
deprecated
func (*NewUser) GetCountry ¶
func (*NewUser) GetFullName ¶
func (*NewUser) GetPassword ¶
func (*NewUser) ProtoMessage ¶
func (*NewUser) ProtoMessage()
func (*NewUser) ProtoReflect ¶
func (x *NewUser) ProtoReflect() protoreflect.Message
type UnimplementedUserServiceServer ¶
type UnimplementedUserServiceServer struct { }
UnimplementedUserServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedUserServiceServer) CreateUser ¶
func (UnimplementedUserServiceServer) GetUserFromJWT ¶
func (UnimplementedUserServiceServer) GetUserFromJWT(context.Context, *GetUserFromJWTInput) (*GetUserFromJWTResponse, error)
func (UnimplementedUserServiceServer) GetUsers ¶
func (UnimplementedUserServiceServer) GetUsers(context.Context, *GetUsersFilter) (*GetUsersResponse, error)
func (UnimplementedUserServiceServer) LoginUser ¶
func (UnimplementedUserServiceServer) LoginUser(context.Context, *LoginInput) (*LoginResponse, error)
type UnsafeUserServiceServer ¶
type UnsafeUserServiceServer interface {
// contains filtered or unexported methods
}
UnsafeUserServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to UserServiceServer will result in compilation errors.
type User ¶
type User struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` FullName string `protobuf:"bytes,2,opt,name=fullName,proto3" json:"fullName,omitempty"` Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"` Country string `protobuf:"bytes,4,opt,name=country,proto3" json:"country,omitempty"` // contains filtered or unexported fields }
func (*User) Descriptor
deprecated
func (*User) GetCountry ¶
func (*User) GetFullName ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) ProtoReflect ¶
func (x *User) ProtoReflect() protoreflect.Message
type UserServiceClient ¶
type UserServiceClient interface { CreateUser(ctx context.Context, in *NewUser, opts ...grpc.CallOption) (*User, error) GetUsers(ctx context.Context, in *GetUsersFilter, opts ...grpc.CallOption) (*GetUsersResponse, error) LoginUser(ctx context.Context, in *LoginInput, opts ...grpc.CallOption) (*LoginResponse, error) GetUserFromJWT(ctx context.Context, in *GetUserFromJWTInput, opts ...grpc.CallOption) (*GetUserFromJWTResponse, error) }
UserServiceClient is the client API for UserService 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 NewUserServiceClient ¶
func NewUserServiceClient(cc grpc.ClientConnInterface) UserServiceClient
type UserServiceServer ¶
type UserServiceServer interface { CreateUser(context.Context, *NewUser) (*User, error) GetUsers(context.Context, *GetUsersFilter) (*GetUsersResponse, error) LoginUser(context.Context, *LoginInput) (*LoginResponse, error) GetUserFromJWT(context.Context, *GetUserFromJWTInput) (*GetUserFromJWTResponse, error) // contains filtered or unexported methods }
UserServiceServer is the server API for UserService service. All implementations must embed UnimplementedUserServiceServer for forward compatibility