Documentation ¶
Index ¶
- Variables
- func RegisterSessionServer(s grpc.ServiceRegistrar, srv SessionServer)
- type Response
- type SessionClient
- type SessionId
- type SessionInfo
- type SessionServer
- type SessionUpdate
- func (*SessionUpdate) Descriptor() ([]byte, []int)deprecated
- func (x *SessionUpdate) GetId() uint64
- func (x *SessionUpdate) GetInfo() map[string]string
- func (*SessionUpdate) ProtoMessage()
- func (x *SessionUpdate) ProtoReflect() protoreflect.Message
- func (x *SessionUpdate) Reset()
- func (x *SessionUpdate) String() string
- type UnimplementedSessionServer
- type UnsafeSessionServer
Constants ¶
This section is empty.
Variables ¶
var File_session_proto protoreflect.FileDescriptor
var Session_ServiceDesc = grpc.ServiceDesc{ ServiceName: "puzzlesessionservice.Session", HandlerType: (*SessionServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Generate", Handler: _Session_Generate_Handler, }, { MethodName: "GetSessionInfo", Handler: _Session_GetSessionInfo_Handler, }, { MethodName: "UpdateSessionInfo", Handler: _Session_UpdateSessionInfo_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "session.proto", }
Session_ServiceDesc is the grpc.ServiceDesc for Session service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterSessionServer ¶
func RegisterSessionServer(s grpc.ServiceRegistrar, srv SessionServer)
Types ¶
type Response ¶ added in v1.2.0
type Response struct { Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` // contains filtered or unexported fields }
func (*Response) Descriptor
deprecated
added in
v1.2.0
func (*Response) GetSuccess ¶ added in v1.2.0
func (*Response) ProtoMessage ¶ added in v1.2.0
func (*Response) ProtoMessage()
func (*Response) ProtoReflect ¶ added in v1.2.0
func (x *Response) ProtoReflect() protoreflect.Message
type SessionClient ¶
type SessionClient interface { // generate sessionId Generate(ctx context.Context, in *SessionInfo, opts ...grpc.CallOption) (*SessionId, error) GetSessionInfo(ctx context.Context, in *SessionId, opts ...grpc.CallOption) (*SessionInfo, error) UpdateSessionInfo(ctx context.Context, in *SessionUpdate, opts ...grpc.CallOption) (*Response, error) }
SessionClient is the client API for Session 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 NewSessionClient ¶
func NewSessionClient(cc grpc.ClientConnInterface) SessionClient
type SessionId ¶
type SessionId struct { Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*SessionId) Descriptor
deprecated
func (*SessionId) ProtoMessage ¶
func (*SessionId) ProtoMessage()
func (*SessionId) ProtoReflect ¶
func (x *SessionId) ProtoReflect() protoreflect.Message
type SessionInfo ¶
type SessionInfo struct { Info map[string]string `` /* 149-byte string literal not displayed */ // contains filtered or unexported fields }
func (*SessionInfo) Descriptor
deprecated
func (*SessionInfo) Descriptor() ([]byte, []int)
Deprecated: Use SessionInfo.ProtoReflect.Descriptor instead.
func (*SessionInfo) GetInfo ¶
func (x *SessionInfo) GetInfo() map[string]string
func (*SessionInfo) ProtoMessage ¶
func (*SessionInfo) ProtoMessage()
func (*SessionInfo) ProtoReflect ¶
func (x *SessionInfo) ProtoReflect() protoreflect.Message
func (*SessionInfo) Reset ¶
func (x *SessionInfo) Reset()
func (*SessionInfo) String ¶
func (x *SessionInfo) String() string
type SessionServer ¶
type SessionServer interface { // generate sessionId Generate(context.Context, *SessionInfo) (*SessionId, error) GetSessionInfo(context.Context, *SessionId) (*SessionInfo, error) UpdateSessionInfo(context.Context, *SessionUpdate) (*Response, error) // contains filtered or unexported methods }
SessionServer is the server API for Session service. All implementations must embed UnimplementedSessionServer for forward compatibility
type SessionUpdate ¶
type SessionUpdate struct { Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` Info map[string]string `` /* 149-byte string literal not displayed */ // contains filtered or unexported fields }
func (*SessionUpdate) Descriptor
deprecated
func (*SessionUpdate) Descriptor() ([]byte, []int)
Deprecated: Use SessionUpdate.ProtoReflect.Descriptor instead.
func (*SessionUpdate) GetId ¶
func (x *SessionUpdate) GetId() uint64
func (*SessionUpdate) GetInfo ¶
func (x *SessionUpdate) GetInfo() map[string]string
func (*SessionUpdate) ProtoMessage ¶
func (*SessionUpdate) ProtoMessage()
func (*SessionUpdate) ProtoReflect ¶
func (x *SessionUpdate) ProtoReflect() protoreflect.Message
func (*SessionUpdate) Reset ¶
func (x *SessionUpdate) Reset()
func (*SessionUpdate) String ¶
func (x *SessionUpdate) String() string
type UnimplementedSessionServer ¶
type UnimplementedSessionServer struct { }
UnimplementedSessionServer must be embedded to have forward compatible implementations.
func (UnimplementedSessionServer) Generate ¶
func (UnimplementedSessionServer) Generate(context.Context, *SessionInfo) (*SessionId, error)
func (UnimplementedSessionServer) GetSessionInfo ¶
func (UnimplementedSessionServer) GetSessionInfo(context.Context, *SessionId) (*SessionInfo, error)
func (UnimplementedSessionServer) UpdateSessionInfo ¶
func (UnimplementedSessionServer) UpdateSessionInfo(context.Context, *SessionUpdate) (*Response, error)
type UnsafeSessionServer ¶
type UnsafeSessionServer interface {
// contains filtered or unexported methods
}
UnsafeSessionServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to SessionServer will result in compilation errors.