Versions in this module Expand all Collapse all v0 v0.2.2 Apr 20, 2026 v0.2.1 Apr 20, 2026 v0.2.0 Apr 20, 2026 Changes in this version + func PlayedPairs(state *TournamentState, opts HistoryOptions) [][]string type ByeType + func ParseByeType(s string) (ByeType, error) type GameResult + func ParseGameResult(s string) (GameResult, error) + type HistoryOptions struct + IncludeForfeits bool type PairingSystem + func ParsePairingSystem(s string) (PairingSystem, error) type PlayerEntry + WithdrawnAfterRound *int type ResultContext + ByeType *ByeType type ScoringSystem + func ParseScoringSystem(s string) (ScoringSystem, error) type TournamentState + PreAssignedByes []ByeEntry + func (s *TournamentState) ActivePlayerIDs(round int) []string + func (s *TournamentState) IsActiveInRound(playerID string, round int) bool v0.1.3 Apr 17, 2026 v0.1.2 Apr 13, 2026 Changes in this version type PlayerEntry + JoinedRound int v0.1.1 Apr 12, 2026 v0.1.0 Apr 11, 2026 Changes in this version + func BoolPtr(v bool) *bool + func DefaultTiebreakers(system PairingSystem) []string + func Float64Ptr(v float64) *float64 + func GetBool(m map[string]any, key string) (bool, bool) + func GetFloat64(m map[string]any, key string) (float64, bool) + func GetInt(m map[string]any, key string) (int, bool) + func GetString(m map[string]any, key string) (string, bool) + func IntPtr(v int) *int + func StringPtr(v string) *string + type ByeEntry struct + PlayerID string + Type ByeType + type ByeType int + const ByeAbsent + const ByeClubCommitment + const ByeExcused + const ByeHalf + const ByePAB + const ByeZero + func (bt ByeType) IsValid() bool + func (bt ByeType) String() string + type GameData struct + BlackID string + IsForfeit bool + Result GameResult + WhiteID string + type GamePairing struct + BlackID string + Board int + WhiteID string + type GameResult string + const ResultBlackWins + const ResultDoubleForfeit + const ResultDraw + const ResultForfeitBlackWins + const ResultForfeitWhiteWins + const ResultPending + const ResultWhiteWins + func (gr GameResult) IsDoubleForfeit() bool + func (gr GameResult) IsForfeit() bool + func (gr GameResult) IsRecordable() bool + func (gr GameResult) IsValid() bool + type NamedValue struct + ID string + Name string + Value float64 + type Pairer interface + Pair func(ctx context.Context, state *TournamentState) (*PairingResult, error) + type PairingConfig struct + Options map[string]any + System PairingSystem + type PairingResult struct + Byes []ByeEntry + Notes []string + Pairings []GamePairing + type PairingSystem string + const PairingBurstein + const PairingDoubleSwiss + const PairingDubov + const PairingDutch + const PairingKeizer + const PairingLim + const PairingRoundRobin + const PairingTeam + func (p PairingSystem) IsValid() bool + type PlayerEntry struct + Active bool + BirthDate string + DisplayName string + Federation string + FideID string + ID string + Rating int + Sex string + Title string + type PlayerScore struct + PlayerID string + Rank int + Score float64 + type ResultContext struct + IsAbsent bool + IsBye bool + IsForfeit bool + OpponentRank int + OpponentValueNumber int + PlayerRank int + PlayerValueNumber int + type RoundData struct + Byes []ByeEntry + Games []GameData + Number int + type Scorer interface + PointsForResult func(result GameResult, rctx ResultContext) float64 + Score func(ctx context.Context, state *TournamentState) ([]PlayerScore, error) + type ScoringConfig struct + Options map[string]any + System ScoringSystem + Tiebreakers []string + type ScoringSystem string + const ScoringFootball + const ScoringKeizer + const ScoringStandard + func (s ScoringSystem) IsValid() bool + type Standing struct + DisplayName string + Draws int + GamesPlayed int + Losses int + PlayerID string + Rank int + Score float64 + TieBreakers []NamedValue + Wins int + type TieBreakValue struct + PlayerID string + Value float64 + type TieBreaker interface + Compute func(ctx context.Context, state *TournamentState, scores []PlayerScore) ([]TieBreakValue, error) + ID func() string + Name func() string + type TournamentInfo struct + ChiefArbiter string + City string + DeputyArbiter string + EndDate string + Federation string + Name string + RoundDates []string + StartDate string + TimeControl string + type TournamentState struct + CurrentRound int + Info TournamentInfo + PairingConfig PairingConfig + Players []PlayerEntry + Rounds []RoundData + ScoringConfig ScoringConfig + func (s *TournamentState) Validate() error