Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
- type AuthClient
- type AuthServer
- type LoginRequest
- func (*LoginRequest) Descriptor() ([]byte, []int)deprecated
- func (x *LoginRequest) GetPassword() string
- func (x *LoginRequest) GetUsername() string
- func (*LoginRequest) ProtoMessage()
- func (x *LoginRequest) ProtoReflect() protoreflect.Message
- func (x *LoginRequest) Reset()
- func (x *LoginRequest) String() string
- type LoginResponse
- type SignupRequest
- func (*SignupRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SignupRequest) GetPassword() string
- func (x *SignupRequest) GetUsername() string
- func (*SignupRequest) ProtoMessage()
- func (x *SignupRequest) ProtoReflect() protoreflect.Message
- func (x *SignupRequest) Reset()
- func (x *SignupRequest) String() string
- type SignupResponse
- type UnimplementedAuthServer
- func (UnimplementedAuthServer) Login(context.Context, *LoginRequest) (*LoginResponse, error)
- func (UnimplementedAuthServer) Signup(context.Context, *SignupRequest) (*SignupResponse, error)
- func (UnimplementedAuthServer) UpdatePassword(context.Context, *UpdatePasswordRequest) (*UpdatePasswordResponse, error)
- type UnsafeAuthServer
- type UpdatePasswordRequest
- func (*UpdatePasswordRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdatePasswordRequest) GetNewPassword() string
- func (*UpdatePasswordRequest) ProtoMessage()
- func (x *UpdatePasswordRequest) ProtoReflect() protoreflect.Message
- func (x *UpdatePasswordRequest) Reset()
- func (x *UpdatePasswordRequest) String() string
- type UpdatePasswordResponse
Constants ¶
const ( Auth_Login_FullMethodName = "/auth.Auth/Login" Auth_Signup_FullMethodName = "/auth.Auth/Signup" Auth_UpdatePassword_FullMethodName = "/auth.Auth/UpdatePassword" )
Variables ¶
var Auth_ServiceDesc = grpc.ServiceDesc{ ServiceName: "auth.Auth", HandlerType: (*AuthServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Login", Handler: _Auth_Login_Handler, }, { MethodName: "Signup", Handler: _Auth_Signup_Handler, }, { MethodName: "UpdatePassword", Handler: _Auth_UpdatePassword_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "auth/auth.proto", }
Auth_ServiceDesc is the grpc.ServiceDesc for Auth service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_auth_auth_proto protoreflect.FileDescriptor
Functions ¶
func RegisterAuthServer ¶
func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
Types ¶
type AuthClient ¶
type AuthClient interface { Login(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error) Signup(ctx context.Context, in *SignupRequest, opts ...grpc.CallOption) (*SignupResponse, error) UpdatePassword(ctx context.Context, in *UpdatePasswordRequest, opts ...grpc.CallOption) (*UpdatePasswordResponse, error) }
AuthClient is the client API for Auth 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 NewAuthClient ¶
func NewAuthClient(cc grpc.ClientConnInterface) AuthClient
type AuthServer ¶
type AuthServer interface { Login(context.Context, *LoginRequest) (*LoginResponse, error) Signup(context.Context, *SignupRequest) (*SignupResponse, error) UpdatePassword(context.Context, *UpdatePasswordRequest) (*UpdatePasswordResponse, error) // contains filtered or unexported methods }
AuthServer is the server API for Auth service. All implementations must embed UnimplementedAuthServer for forward compatibility.
type LoginRequest ¶
type LoginRequest struct { Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
func (*LoginRequest) Descriptor
deprecated
func (*LoginRequest) Descriptor() ([]byte, []int)
Deprecated: Use LoginRequest.ProtoReflect.Descriptor instead.
func (*LoginRequest) GetPassword ¶
func (x *LoginRequest) GetPassword() string
func (*LoginRequest) GetUsername ¶
func (x *LoginRequest) GetUsername() string
func (*LoginRequest) ProtoMessage ¶
func (*LoginRequest) ProtoMessage()
func (*LoginRequest) ProtoReflect ¶
func (x *LoginRequest) ProtoReflect() protoreflect.Message
func (*LoginRequest) Reset ¶
func (x *LoginRequest) Reset()
func (*LoginRequest) String ¶
func (x *LoginRequest) String() string
type LoginResponse ¶
type LoginResponse struct { Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"` // contains filtered or unexported fields }
func (*LoginResponse) Descriptor
deprecated
func (*LoginResponse) Descriptor() ([]byte, []int)
Deprecated: Use LoginResponse.ProtoReflect.Descriptor instead.
func (*LoginResponse) GetToken ¶
func (x *LoginResponse) GetToken() string
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 SignupRequest ¶
type SignupRequest struct { Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
func (*SignupRequest) Descriptor
deprecated
func (*SignupRequest) Descriptor() ([]byte, []int)
Deprecated: Use SignupRequest.ProtoReflect.Descriptor instead.
func (*SignupRequest) GetPassword ¶
func (x *SignupRequest) GetPassword() string
func (*SignupRequest) GetUsername ¶
func (x *SignupRequest) GetUsername() string
func (*SignupRequest) ProtoMessage ¶
func (*SignupRequest) ProtoMessage()
func (*SignupRequest) ProtoReflect ¶
func (x *SignupRequest) ProtoReflect() protoreflect.Message
func (*SignupRequest) Reset ¶
func (x *SignupRequest) Reset()
func (*SignupRequest) String ¶
func (x *SignupRequest) String() string
type SignupResponse ¶
type SignupResponse struct {
// contains filtered or unexported fields
}
func (*SignupResponse) Descriptor
deprecated
func (*SignupResponse) Descriptor() ([]byte, []int)
Deprecated: Use SignupResponse.ProtoReflect.Descriptor instead.
func (*SignupResponse) ProtoMessage ¶
func (*SignupResponse) ProtoMessage()
func (*SignupResponse) ProtoReflect ¶
func (x *SignupResponse) ProtoReflect() protoreflect.Message
func (*SignupResponse) Reset ¶
func (x *SignupResponse) Reset()
func (*SignupResponse) String ¶
func (x *SignupResponse) String() string
type UnimplementedAuthServer ¶
type UnimplementedAuthServer struct{}
UnimplementedAuthServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedAuthServer) Login ¶
func (UnimplementedAuthServer) Login(context.Context, *LoginRequest) (*LoginResponse, error)
func (UnimplementedAuthServer) Signup ¶
func (UnimplementedAuthServer) Signup(context.Context, *SignupRequest) (*SignupResponse, error)
func (UnimplementedAuthServer) UpdatePassword ¶ added in v0.0.3
func (UnimplementedAuthServer) UpdatePassword(context.Context, *UpdatePasswordRequest) (*UpdatePasswordResponse, error)
type UnsafeAuthServer ¶
type UnsafeAuthServer interface {
// contains filtered or unexported methods
}
UnsafeAuthServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AuthServer will result in compilation errors.
type UpdatePasswordRequest ¶ added in v0.0.3
type UpdatePasswordRequest struct { NewPassword string `protobuf:"bytes,1,opt,name=newPassword,proto3" json:"newPassword,omitempty"` // contains filtered or unexported fields }
func (*UpdatePasswordRequest) Descriptor
deprecated
added in
v0.0.3
func (*UpdatePasswordRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdatePasswordRequest.ProtoReflect.Descriptor instead.
func (*UpdatePasswordRequest) GetNewPassword ¶ added in v0.0.3
func (x *UpdatePasswordRequest) GetNewPassword() string
func (*UpdatePasswordRequest) ProtoMessage ¶ added in v0.0.3
func (*UpdatePasswordRequest) ProtoMessage()
func (*UpdatePasswordRequest) ProtoReflect ¶ added in v0.0.3
func (x *UpdatePasswordRequest) ProtoReflect() protoreflect.Message
func (*UpdatePasswordRequest) Reset ¶ added in v0.0.3
func (x *UpdatePasswordRequest) Reset()
func (*UpdatePasswordRequest) String ¶ added in v0.0.3
func (x *UpdatePasswordRequest) String() string
type UpdatePasswordResponse ¶ added in v0.0.3
type UpdatePasswordResponse struct {
// contains filtered or unexported fields
}
func (*UpdatePasswordResponse) Descriptor
deprecated
added in
v0.0.3
func (*UpdatePasswordResponse) Descriptor() ([]byte, []int)
Deprecated: Use UpdatePasswordResponse.ProtoReflect.Descriptor instead.
func (*UpdatePasswordResponse) ProtoMessage ¶ added in v0.0.3
func (*UpdatePasswordResponse) ProtoMessage()
func (*UpdatePasswordResponse) ProtoReflect ¶ added in v0.0.3
func (x *UpdatePasswordResponse) ProtoReflect() protoreflect.Message
func (*UpdatePasswordResponse) Reset ¶ added in v0.0.3
func (x *UpdatePasswordResponse) Reset()
func (*UpdatePasswordResponse) String ¶ added in v0.0.3
func (x *UpdatePasswordResponse) String() string