Documentation ¶
Overview ¶
Package pb is a generated protocol buffer package.
It is generated from these files:
sprints.proto
It has these top-level messages:
Empty AbortMessage Race DefinedRace Results Result Tournaments TournamentNames TournamentSpec DefinedPlayer ResultSpec Player Starter Racer Tournament VisConfiguration
Index ¶
- Variables
- func RegisterSprintsServer(s *grpc.Server, srv SprintsServer)
- func RegisterVisualServer(s *grpc.Server, srv VisualServer)
- type AbortMessage
- type DefinedPlayer
- func (*DefinedPlayer) Descriptor() ([]byte, []int)
- func (m *DefinedPlayer) GetColor() string
- func (m *DefinedPlayer) GetOtherContenders() []*DefinedPlayer
- func (m *DefinedPlayer) GetRacesRemaining() uint32
- func (*DefinedPlayer) ProtoMessage()
- func (m *DefinedPlayer) Reset()
- func (m *DefinedPlayer) String() string
- type DefinedRace
- type Empty
- type Gender
- type Player
- type Race
- type Racer
- type Result
- type ResultSpec
- type Results
- type SprintsClient
- type SprintsServer
- type Sprints_GetResultsClient
- type Sprints_GetResultsServer
- type Starter
- type Tournament
- func (*Tournament) Descriptor() ([]byte, []int)
- func (m *Tournament) GetColor() []string
- func (m *Tournament) GetDestValue() uint32
- func (m *Tournament) GetMode() Tournament_TournamentMode
- func (m *Tournament) GetName() string
- func (m *Tournament) GetPlayerCount() uint32
- func (m *Tournament) GetResult() []*Result
- func (*Tournament) ProtoMessage()
- func (m *Tournament) Reset()
- func (m *Tournament) String() string
- type TournamentNames
- type TournamentSpec
- type Tournament_TournamentMode
- type Tournaments
- type VisConfiguration
- func (*VisConfiguration) Descriptor() ([]byte, []int)
- func (m *VisConfiguration) GetDistFactor() uint32
- func (m *VisConfiguration) GetFullscreen() bool
- func (m *VisConfiguration) GetHostName() string
- func (m *VisConfiguration) GetMovingUnit() uint32
- func (m *VisConfiguration) GetResolutionHeight() uint32
- func (m *VisConfiguration) GetResolutionWidth() uint32
- func (m *VisConfiguration) GetVisName() string
- func (*VisConfiguration) ProtoMessage()
- func (m *VisConfiguration) Reset()
- func (m *VisConfiguration) String() string
- type VisualClient
- type VisualServer
- type Visual_UpdateRaceClient
- type Visual_UpdateRaceServer
Constants ¶
This section is empty.
Variables ¶
View Source
var Gender_name = map[int32]string{
0: "MALE",
1: "FEMALE",
2: "OTHER",
}
View Source
var Gender_value = map[string]int32{
"MALE": 0,
"FEMALE": 1,
"OTHER": 2,
}
View Source
var Tournament_TournamentMode_name = map[int32]string{
0: "DISTANCE",
1: "TIME",
}
View Source
var Tournament_TournamentMode_value = map[string]int32{
"DISTANCE": 0,
"TIME": 1,
}
Functions ¶
func RegisterSprintsServer ¶
func RegisterSprintsServer(s *grpc.Server, srv SprintsServer)
func RegisterVisualServer ¶
func RegisterVisualServer(s *grpc.Server, srv VisualServer)
Types ¶
type AbortMessage ¶
type AbortMessage struct {
Message string `protobuf:"bytes,1,opt,name=message" json:"message,omitempty"`
}
func (*AbortMessage) Descriptor ¶
func (*AbortMessage) Descriptor() ([]byte, []int)
func (*AbortMessage) GetMessage ¶
func (m *AbortMessage) GetMessage() string
func (*AbortMessage) ProtoMessage ¶
func (*AbortMessage) ProtoMessage()
func (*AbortMessage) Reset ¶
func (m *AbortMessage) Reset()
func (*AbortMessage) String ¶
func (m *AbortMessage) String() string
type DefinedPlayer ¶
type DefinedPlayer struct { Color string `protobuf:"bytes,1,opt,name=color" json:"color,omitempty"` RacesRemaining uint32 `protobuf:"varint,2,opt,name=racesRemaining" json:"racesRemaining,omitempty"` OtherContenders []*DefinedPlayer `protobuf:"bytes,3,rep,name=otherContenders" json:"otherContenders,omitempty"` }
func (*DefinedPlayer) Descriptor ¶
func (*DefinedPlayer) Descriptor() ([]byte, []int)
func (*DefinedPlayer) GetColor ¶
func (m *DefinedPlayer) GetColor() string
func (*DefinedPlayer) GetOtherContenders ¶
func (m *DefinedPlayer) GetOtherContenders() []*DefinedPlayer
func (*DefinedPlayer) GetRacesRemaining ¶
func (m *DefinedPlayer) GetRacesRemaining() uint32
func (*DefinedPlayer) ProtoMessage ¶
func (*DefinedPlayer) ProtoMessage()
func (*DefinedPlayer) Reset ¶
func (m *DefinedPlayer) Reset()
func (*DefinedPlayer) String ¶
func (m *DefinedPlayer) String() string
type DefinedRace ¶
type DefinedRace struct { // how many races are remaining before this one will take place RacesRemaining uint32 `protobuf:"varint,1,opt,name=racesRemaining" json:"racesRemaining,omitempty"` Player []*DefinedPlayer `protobuf:"bytes,2,rep,name=player" json:"player,omitempty"` }
func (*DefinedRace) Descriptor ¶
func (*DefinedRace) Descriptor() ([]byte, []int)
func (*DefinedRace) GetPlayer ¶
func (m *DefinedRace) GetPlayer() []*DefinedPlayer
func (*DefinedRace) GetRacesRemaining ¶
func (m *DefinedRace) GetRacesRemaining() uint32
func (*DefinedRace) ProtoMessage ¶
func (*DefinedRace) ProtoMessage()
func (*DefinedRace) Reset ¶
func (m *DefinedRace) Reset()
func (*DefinedRace) String ¶
func (m *DefinedRace) String() string
type Empty ¶
type Empty struct { }
func (*Empty) Descriptor ¶
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
type Player ¶
type Player struct { Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` Gender Gender `protobuf:"varint,2,opt,name=gender,enum=pb.Gender" json:"gender,omitempty"` }
func (*Player) Descriptor ¶
func (*Player) ProtoMessage ¶
func (*Player) ProtoMessage()
type Race ¶
type Race struct { Players []*Player `protobuf:"bytes,1,rep,name=players" json:"players,omitempty"` DestValue uint32 `protobuf:"varint,2,opt,name=destValue" json:"destValue,omitempty"` }
func (*Race) Descriptor ¶
func (*Race) GetDestValue ¶
func (*Race) GetPlayers ¶
func (*Race) ProtoMessage ¶
func (*Race) ProtoMessage()
type Racer ¶
type Racer struct { PlayerNum uint32 `protobuf:"varint,1,opt,name=playerNum" json:"playerNum,omitempty"` Distance uint32 `protobuf:"varint,2,opt,name=distance" json:"distance,omitempty"` }
func (*Racer) Descriptor ¶
func (*Racer) GetDistance ¶
func (*Racer) GetPlayerNum ¶
func (*Racer) ProtoMessage ¶
func (*Racer) ProtoMessage()
type Result ¶
type Result struct { Player *Player `protobuf:"bytes,1,opt,name=player" json:"player,omitempty"` Result float32 `protobuf:"fixed32,2,opt,name=result" json:"result,omitempty"` DestValue uint32 `protobuf:"varint,3,opt,name=destValue" json:"destValue,omitempty"` }
func (*Result) Descriptor ¶
func (*Result) GetDestValue ¶
func (*Result) ProtoMessage ¶
func (*Result) ProtoMessage()
type ResultSpec ¶
type ResultSpec struct { Gender Gender `protobuf:"varint,1,opt,name=gender,enum=pb.Gender" json:"gender,omitempty"` Last uint32 `protobuf:"varint,2,opt,name=last" json:"last,omitempty"` TournamentName string `protobuf:"bytes,3,opt,name=tournamentName" json:"tournamentName,omitempty"` }
func (*ResultSpec) Descriptor ¶
func (*ResultSpec) Descriptor() ([]byte, []int)
func (*ResultSpec) GetGender ¶
func (m *ResultSpec) GetGender() Gender
func (*ResultSpec) GetLast ¶
func (m *ResultSpec) GetLast() uint32
func (*ResultSpec) GetTournamentName ¶
func (m *ResultSpec) GetTournamentName() string
func (*ResultSpec) ProtoMessage ¶
func (*ResultSpec) ProtoMessage()
func (*ResultSpec) Reset ¶
func (m *ResultSpec) Reset()
func (*ResultSpec) String ¶
func (m *ResultSpec) String() string
type Results ¶
type Results struct {
Result []*Result `protobuf:"bytes,1,rep,name=result" json:"result,omitempty"`
}
func (*Results) Descriptor ¶
func (*Results) ProtoMessage ¶
func (*Results) ProtoMessage()
type SprintsClient ¶
type SprintsClient interface { NewTournament(ctx context.Context, in *Tournament, opts ...grpc.CallOption) (*Tournament, error) NewRace(ctx context.Context, in *Race, opts ...grpc.CallOption) (*Empty, error) StartRace(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Player, error) AbortRace(ctx context.Context, in *AbortMessage, opts ...grpc.CallOption) (*Empty, error) ConfigureVis(ctx context.Context, in *VisConfiguration, opts ...grpc.CallOption) (*Empty, error) GetResults(ctx context.Context, in *ResultSpec, opts ...grpc.CallOption) (Sprints_GetResultsClient, error) GetTournamentNames(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*TournamentNames, error) GetCurrentTournament(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Tournament, error) LoadTournament(ctx context.Context, in *TournamentSpec, opts ...grpc.CallOption) (*Tournament, error) ShowResults(ctx context.Context, in *ResultSpec, opts ...grpc.CallOption) (*Empty, error) }
func NewSprintsClient ¶
func NewSprintsClient(cc *grpc.ClientConn) SprintsClient
type SprintsServer ¶
type SprintsServer interface { NewTournament(context.Context, *Tournament) (*Tournament, error) NewRace(context.Context, *Race) (*Empty, error) StartRace(context.Context, *Empty) (*Player, error) AbortRace(context.Context, *AbortMessage) (*Empty, error) ConfigureVis(context.Context, *VisConfiguration) (*Empty, error) GetResults(*ResultSpec, Sprints_GetResultsServer) error GetTournamentNames(context.Context, *Empty) (*TournamentNames, error) GetCurrentTournament(context.Context, *Empty) (*Tournament, error) LoadTournament(context.Context, *TournamentSpec) (*Tournament, error) ShowResults(context.Context, *ResultSpec) (*Empty, error) }
type Sprints_GetResultsClient ¶
type Sprints_GetResultsClient interface { Recv() (*Result, error) grpc.ClientStream }
type Sprints_GetResultsServer ¶
type Sprints_GetResultsServer interface { Send(*Result) error grpc.ServerStream }
type Starter ¶
type Starter struct {
CountdownTime uint32 `protobuf:"varint,1,opt,name=countdownTime" json:"countdownTime,omitempty"`
}
func (*Starter) Descriptor ¶
func (*Starter) GetCountdownTime ¶
func (*Starter) ProtoMessage ¶
func (*Starter) ProtoMessage()
type Tournament ¶
type Tournament struct { Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` DestValue uint32 `protobuf:"varint,3,opt,name=destValue" json:"destValue,omitempty"` Mode Tournament_TournamentMode `protobuf:"varint,4,opt,name=mode,enum=pb.Tournament_TournamentMode" json:"mode,omitempty"` PlayerCount uint32 `protobuf:"varint,5,opt,name=playerCount" json:"playerCount,omitempty"` Color []string `protobuf:"bytes,6,rep,name=color" json:"color,omitempty"` Result []*Result `protobuf:"bytes,7,rep,name=result" json:"result,omitempty"` }
func (*Tournament) Descriptor ¶
func (*Tournament) Descriptor() ([]byte, []int)
func (*Tournament) GetColor ¶
func (m *Tournament) GetColor() []string
func (*Tournament) GetDestValue ¶
func (m *Tournament) GetDestValue() uint32
func (*Tournament) GetMode ¶
func (m *Tournament) GetMode() Tournament_TournamentMode
func (*Tournament) GetName ¶
func (m *Tournament) GetName() string
func (*Tournament) GetPlayerCount ¶
func (m *Tournament) GetPlayerCount() uint32
func (*Tournament) GetResult ¶
func (m *Tournament) GetResult() []*Result
func (*Tournament) ProtoMessage ¶
func (*Tournament) ProtoMessage()
func (*Tournament) Reset ¶
func (m *Tournament) Reset()
func (*Tournament) String ¶
func (m *Tournament) String() string
type TournamentNames ¶
type TournamentNames struct {
Name []string `protobuf:"bytes,1,rep,name=name" json:"name,omitempty"`
}
func (*TournamentNames) Descriptor ¶
func (*TournamentNames) Descriptor() ([]byte, []int)
func (*TournamentNames) GetName ¶
func (m *TournamentNames) GetName() []string
func (*TournamentNames) ProtoMessage ¶
func (*TournamentNames) ProtoMessage()
func (*TournamentNames) Reset ¶
func (m *TournamentNames) Reset()
func (*TournamentNames) String ¶
func (m *TournamentNames) String() string
type TournamentSpec ¶
type TournamentSpec struct {
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}
func (*TournamentSpec) Descriptor ¶
func (*TournamentSpec) Descriptor() ([]byte, []int)
func (*TournamentSpec) GetName ¶
func (m *TournamentSpec) GetName() string
func (*TournamentSpec) ProtoMessage ¶
func (*TournamentSpec) ProtoMessage()
func (*TournamentSpec) Reset ¶
func (m *TournamentSpec) Reset()
func (*TournamentSpec) String ¶
func (m *TournamentSpec) String() string
type Tournament_TournamentMode ¶
type Tournament_TournamentMode int32
const ( Tournament_DISTANCE Tournament_TournamentMode = 0 Tournament_TIME Tournament_TournamentMode = 1 )
func (Tournament_TournamentMode) EnumDescriptor ¶
func (Tournament_TournamentMode) EnumDescriptor() ([]byte, []int)
func (Tournament_TournamentMode) String ¶
func (x Tournament_TournamentMode) String() string
type Tournaments ¶
type Tournaments struct {
Tournament []*Tournament `protobuf:"bytes,1,rep,name=tournament" json:"tournament,omitempty"`
}
func (*Tournaments) Descriptor ¶
func (*Tournaments) Descriptor() ([]byte, []int)
func (*Tournaments) GetTournament ¶
func (m *Tournaments) GetTournament() []*Tournament
func (*Tournaments) ProtoMessage ¶
func (*Tournaments) ProtoMessage()
func (*Tournaments) Reset ¶
func (m *Tournaments) Reset()
func (*Tournaments) String ¶
func (m *Tournaments) String() string
type VisConfiguration ¶
type VisConfiguration struct { HostName string `protobuf:"bytes,1,opt,name=hostName" json:"hostName,omitempty"` VisName string `protobuf:"bytes,2,opt,name=visName" json:"visName,omitempty"` Fullscreen bool `protobuf:"varint,3,opt,name=fullscreen" json:"fullscreen,omitempty"` ResolutionWidth uint32 `protobuf:"varint,4,opt,name=resolutionWidth" json:"resolutionWidth,omitempty"` ResolutionHeight uint32 `protobuf:"varint,5,opt,name=resolutionHeight" json:"resolutionHeight,omitempty"` MovingUnit uint32 `protobuf:"varint,6,opt,name=movingUnit" json:"movingUnit,omitempty"` DistFactor uint32 `protobuf:"varint,7,opt,name=distFactor" json:"distFactor,omitempty"` }
func (*VisConfiguration) Descriptor ¶
func (*VisConfiguration) Descriptor() ([]byte, []int)
func (*VisConfiguration) GetDistFactor ¶
func (m *VisConfiguration) GetDistFactor() uint32
func (*VisConfiguration) GetFullscreen ¶
func (m *VisConfiguration) GetFullscreen() bool
func (*VisConfiguration) GetHostName ¶
func (m *VisConfiguration) GetHostName() string
func (*VisConfiguration) GetMovingUnit ¶
func (m *VisConfiguration) GetMovingUnit() uint32
func (*VisConfiguration) GetResolutionHeight ¶
func (m *VisConfiguration) GetResolutionHeight() uint32
func (*VisConfiguration) GetResolutionWidth ¶
func (m *VisConfiguration) GetResolutionWidth() uint32
func (*VisConfiguration) GetVisName ¶
func (m *VisConfiguration) GetVisName() string
func (*VisConfiguration) ProtoMessage ¶
func (*VisConfiguration) ProtoMessage()
func (*VisConfiguration) Reset ¶
func (m *VisConfiguration) Reset()
func (*VisConfiguration) String ¶
func (m *VisConfiguration) String() string
type VisualClient ¶
type VisualClient interface { NewTournament(ctx context.Context, in *Tournament, opts ...grpc.CallOption) (*Empty, error) NewRace(ctx context.Context, in *Race, opts ...grpc.CallOption) (*Empty, error) StartRace(ctx context.Context, in *Starter, opts ...grpc.CallOption) (*Empty, error) AbortRace(ctx context.Context, in *AbortMessage, opts ...grpc.CallOption) (*Empty, error) UpdateRace(ctx context.Context, opts ...grpc.CallOption) (Visual_UpdateRaceClient, error) FinishRace(ctx context.Context, in *Results, opts ...grpc.CallOption) (*Empty, error) ShowResults(ctx context.Context, in *Results, opts ...grpc.CallOption) (*Empty, error) ConfigureVis(ctx context.Context, in *VisConfiguration, opts ...grpc.CallOption) (*Empty, error) StopVis(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) }
func NewVisualClient ¶
func NewVisualClient(cc *grpc.ClientConn) VisualClient
type VisualServer ¶
type VisualServer interface { NewTournament(context.Context, *Tournament) (*Empty, error) NewRace(context.Context, *Race) (*Empty, error) StartRace(context.Context, *Starter) (*Empty, error) AbortRace(context.Context, *AbortMessage) (*Empty, error) UpdateRace(Visual_UpdateRaceServer) error FinishRace(context.Context, *Results) (*Empty, error) ShowResults(context.Context, *Results) (*Empty, error) ConfigureVis(context.Context, *VisConfiguration) (*Empty, error) StopVis(context.Context, *Empty) (*Empty, error) }
type Visual_UpdateRaceClient ¶
type Visual_UpdateRaceServer ¶
Click to show internal directories.
Click to hide internal directories.