Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileSystemStore ¶
type FileSystemStore struct {
// contains filtered or unexported fields
}
func FileSystemPlayerStoreFromFile ¶
func FileSystemPlayerStoreFromFile(path string) (*FileSystemStore, error)
func NewFileSystemStore ¶
func NewFileSystemStore(database *os.File) (*FileSystemStore, error)
func (*FileSystemStore) GetLeague ¶
func (f *FileSystemStore) GetLeague() League
func (*FileSystemStore) GetPlayerScore ¶
func (f *FileSystemStore) GetPlayerScore(name string) int
func (*FileSystemStore) RecordWin ¶
func (f *FileSystemStore) RecordWin(name string)
type InMemoryPlayerStore ¶
type InMemoryPlayerStore struct {
// contains filtered or unexported fields
}
func NewInMemoryPlayerStore ¶
func NewInMemoryPlayerStore() *InMemoryPlayerStore
func (*InMemoryPlayerStore) GetLeague ¶
func (i *InMemoryPlayerStore) GetLeague() League
func (*InMemoryPlayerStore) GetPlayerScore ¶
func (i *InMemoryPlayerStore) GetPlayerScore(name string) int
func (*InMemoryPlayerStore) RecordWin ¶
func (i *InMemoryPlayerStore) RecordWin(name string)
type PlayerServer ¶
func NewPlayerServer ¶
func NewPlayerServer(store PlayerStore) *PlayerServer
func (*PlayerServer) GetPlayerScore ¶
func (p *PlayerServer) GetPlayerScore(name string) int
Source Files ¶
Click to show internal directories.
Click to hide internal directories.