Documentation ¶
Overview ¶
Package internal defines common functions used by both rock paper scissors clients and servers.
Index ¶
- func CreateName(ctx *context.T) string
- func FindJudge(ctx *context.T, prefix string) (string, error)
- func FindPlayer(ctx *context.T, prefix string) (string, error)
- func FindScoreKeepers(ctx *context.T, prefix string) ([]string, error)
- func FormatScoreCard(score rps.ScoreCard) string
- func NewAuthorizer(fname string) security.Authorizer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateName ¶
CreateName creates a name using the username and hostname.
func FindPlayer ¶
FindPlayer returns a random rock-paper-scissors player from the mount table.
func FindScoreKeepers ¶
FindScoreKeepers returns all the rock-paper-scissors score keepers from the mount table.
func FormatScoreCard ¶
FormatScoreCard returns a string representation of a score card.
func NewAuthorizer ¶
func NewAuthorizer(fname string) security.Authorizer
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.