Documentation ¶
Index ¶
- Constants
- func NewPlayDataPlayerServiceHandler(svc PlayDataPlayerServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
- type PlayDataPlayerServiceClient
- type PlayDataPlayerServiceHandler
- type UnimplementedPlayDataPlayerServiceHandler
- func (UnimplementedPlayDataPlayerServiceHandler) Gain(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error)
- func (UnimplementedPlayDataPlayerServiceHandler) Join(context.Context, *connect.Request[v1.JoinPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error)
- func (UnimplementedPlayDataPlayerServiceHandler) Quit(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.DataPlayerResponse], error)
Constants ¶
const ( // PlayDataPlayerServiceJoinProcedure is the fully-qualified name of the PlayDataPlayerService's // Join RPC. PlayDataPlayerServiceJoinProcedure = "/linq.playdata.players.v1.PlayDataPlayerService/Join" // PlayDataPlayerServiceQuitProcedure is the fully-qualified name of the PlayDataPlayerService's // Quit RPC. PlayDataPlayerServiceQuitProcedure = "/linq.playdata.players.v1.PlayDataPlayerService/Quit" // PlayDataPlayerServiceGainProcedure is the fully-qualified name of the PlayDataPlayerService's // Gain RPC. PlayDataPlayerServiceGainProcedure = "/linq.playdata.players.v1.PlayDataPlayerService/Gain" )
These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.
Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.
const (
// PlayDataPlayerServiceName is the fully-qualified name of the PlayDataPlayerService service.
PlayDataPlayerServiceName = "linq.playdata.players.v1.PlayDataPlayerService"
)
Variables ¶
This section is empty.
Functions ¶
func NewPlayDataPlayerServiceHandler ¶
func NewPlayDataPlayerServiceHandler(svc PlayDataPlayerServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
NewPlayDataPlayerServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.
By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.
Types ¶
type PlayDataPlayerServiceClient ¶
type PlayDataPlayerServiceClient interface { // Attaches player to the session (tournament), including internal checks // and also automatically takes bets according with the tournament config Join(context.Context, *connect.Request[v1.JoinPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error) // Quiting player from the sessions (tournament), which means that player // finished his game and waiting for tournament finishing Quit(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.DataPlayerResponse], error) // Allow player gain his reward in case tournament has not automatic spreading Gain(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error) }
PlayDataPlayerServiceClient is a client for the linq.playdata.players.v1.PlayDataPlayerService service.
func NewPlayDataPlayerServiceClient ¶
func NewPlayDataPlayerServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) PlayDataPlayerServiceClient
NewPlayDataPlayerServiceClient constructs a client for the linq.playdata.players.v1.PlayDataPlayerService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.
The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).
type PlayDataPlayerServiceHandler ¶
type PlayDataPlayerServiceHandler interface { // Attaches player to the session (tournament), including internal checks // and also automatically takes bets according with the tournament config Join(context.Context, *connect.Request[v1.JoinPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error) // Quiting player from the sessions (tournament), which means that player // finished his game and waiting for tournament finishing Quit(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.DataPlayerResponse], error) // Allow player gain his reward in case tournament has not automatic spreading Gain(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error) }
PlayDataPlayerServiceHandler is an implementation of the linq.playdata.players.v1.PlayDataPlayerService service.
type UnimplementedPlayDataPlayerServiceHandler ¶
type UnimplementedPlayDataPlayerServiceHandler struct{}
UnimplementedPlayDataPlayerServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedPlayDataPlayerServiceHandler) Gain ¶
func (UnimplementedPlayDataPlayerServiceHandler) Gain(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error)
func (UnimplementedPlayDataPlayerServiceHandler) Join ¶
func (UnimplementedPlayDataPlayerServiceHandler) Join(context.Context, *connect.Request[v1.JoinPlayerRequest]) (*connect.Response[v1.AppliedPlayerOrder], error)
func (UnimplementedPlayDataPlayerServiceHandler) Quit ¶
func (UnimplementedPlayDataPlayerServiceHandler) Quit(context.Context, *connect.Request[v1.DataPlayerRequest]) (*connect.Response[v1.DataPlayerResponse], error)