Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterGatewayLoginManagerServer(s grpc.ServiceRegistrar, srv GatewayLoginManagerServer)
- type GatewayLoginManagerClient
- type GatewayLoginManagerServer
- type LoginResponse
- func (*LoginResponse) Descriptor() ([]byte, []int)deprecated
- func (x *LoginResponse) GetCode() int32
- func (x *LoginResponse) GetLoginStatus() bool
- func (x *LoginResponse) GetMessage() string
- func (*LoginResponse) ProtoMessage()
- func (x *LoginResponse) ProtoReflect() protoreflect.Message
- func (x *LoginResponse) Reset()
- func (x *LoginResponse) String() string
- type Token
- type UnimplementedGatewayLoginManagerServer
- type UnsafeGatewayLoginManagerServer
Constants ¶
const ( GatewayLoginManager_CheckGatewayLoginStatus_FullMethodName = "/pb.GatewayLoginManager/CheckGatewayLoginStatus" GatewayLoginManager_LoginServerByToken_FullMethodName = "/pb.GatewayLoginManager/LoginServerByToken" )
Variables ¶
var File_proto_gateway_gateway_proto protoreflect.FileDescriptor
var GatewayLoginManager_ServiceDesc = grpc.ServiceDesc{ ServiceName: "pb.GatewayLoginManager", HandlerType: (*GatewayLoginManagerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CheckGatewayLoginStatus", Handler: _GatewayLoginManager_CheckGatewayLoginStatus_Handler, }, { MethodName: "LoginServerByToken", Handler: _GatewayLoginManager_LoginServerByToken_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/gateway/gateway.proto", }
GatewayLoginManager_ServiceDesc is the grpc.ServiceDesc for GatewayLoginManager service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterGatewayLoginManagerServer ¶
func RegisterGatewayLoginManagerServer(s grpc.ServiceRegistrar, srv GatewayLoginManagerServer)
Types ¶
type GatewayLoginManagerClient ¶
type GatewayLoginManagerClient interface { CheckGatewayLoginStatus(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*LoginResponse, error) LoginServerByToken(ctx context.Context, in *Token, opts ...grpc.CallOption) (*LoginResponse, error) }
GatewayLoginManagerClient is the client API for GatewayLoginManager 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 NewGatewayLoginManagerClient ¶
func NewGatewayLoginManagerClient(cc grpc.ClientConnInterface) GatewayLoginManagerClient
type GatewayLoginManagerServer ¶
type GatewayLoginManagerServer interface { CheckGatewayLoginStatus(context.Context, *emptypb.Empty) (*LoginResponse, error) LoginServerByToken(context.Context, *Token) (*LoginResponse, error) // contains filtered or unexported methods }
GatewayLoginManagerServer is the server API for GatewayLoginManager service. All implementations must embed UnimplementedGatewayLoginManagerServer for forward compatibility.
服务的定义
type LoginResponse ¶
type LoginResponse struct { Code int32 `protobuf:"varint,1,opt,name=Code,proto3" json:"Code,omitempty"` Message string `protobuf:"bytes,2,opt,name=Message,proto3" json:"Message,omitempty"` LoginStatus bool `protobuf:"varint,3,opt,name=LoginStatus,proto3" json:"LoginStatus,omitempty"` // contains filtered or unexported fields }
func (*LoginResponse) Descriptor
deprecated
func (*LoginResponse) Descriptor() ([]byte, []int)
Deprecated: Use LoginResponse.ProtoReflect.Descriptor instead.
func (*LoginResponse) GetCode ¶
func (x *LoginResponse) GetCode() int32
func (*LoginResponse) GetLoginStatus ¶
func (x *LoginResponse) GetLoginStatus() bool
func (*LoginResponse) GetMessage ¶
func (x *LoginResponse) GetMessage() 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 Token ¶
type Token struct { Value string `protobuf:"bytes,1,opt,name=Value,proto3" json:"Value,omitempty"` // contains filtered or unexported fields }
func (*Token) Descriptor
deprecated
func (*Token) ProtoMessage ¶
func (*Token) ProtoMessage()
func (*Token) ProtoReflect ¶
func (x *Token) ProtoReflect() protoreflect.Message
type UnimplementedGatewayLoginManagerServer ¶
type UnimplementedGatewayLoginManagerServer struct{}
UnimplementedGatewayLoginManagerServer 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 (UnimplementedGatewayLoginManagerServer) CheckGatewayLoginStatus ¶
func (UnimplementedGatewayLoginManagerServer) CheckGatewayLoginStatus(context.Context, *emptypb.Empty) (*LoginResponse, error)
func (UnimplementedGatewayLoginManagerServer) LoginServerByToken ¶
func (UnimplementedGatewayLoginManagerServer) LoginServerByToken(context.Context, *Token) (*LoginResponse, error)
type UnsafeGatewayLoginManagerServer ¶
type UnsafeGatewayLoginManagerServer interface {
// contains filtered or unexported methods
}
UnsafeGatewayLoginManagerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to GatewayLoginManagerServer will result in compilation errors.