mocks

package
v0.0.0-...-8833268 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 25, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Password = "pa$$word"
View Source
var Username = "alice@example.com"

Functions

This section is empty.

Types

type AdminConsole

type AdminConsole struct {
	// contains filtered or unexported fields
}

func (*AdminConsole) Close

func (c *AdminConsole) Close() error

func (*AdminConsole) IsOnline

func (c *AdminConsole) IsOnline(context.Context) (bool, error)

func (*AdminConsole) Restart

func (c *AdminConsole) Restart(context.Context) error

func (*AdminConsole) Start

func (c *AdminConsole) Start(context.Context) error

func (*AdminConsole) Stop

func (c *AdminConsole) Stop(context.Context) error

type LogsSocket

type LogsSocket struct {
	// contains filtered or unexported fields
}

func OpenLogsSocket

func OpenLogsSocket() LogsSocket

func (*LogsSocket) AddClient

func (s *LogsSocket) AddClient(id string) (<-chan string, error)

func (*LogsSocket) RemoveClient

func (s *LogsSocket) RemoveClient(id string) error

type NonAdminConsole

type NonAdminConsole struct{}

func (NonAdminConsole) Broadcast

func (c NonAdminConsole) Broadcast(msg string) error

func (NonAdminConsole) Message

func (c NonAdminConsole) Message(user string, msg string) error

func (NonAdminConsole) Players

func (c NonAdminConsole) Players() ([]string, error)

func (NonAdminConsole) Seed

func (c NonAdminConsole) Seed() (string, error)

type UserModel

type UserModel struct{}

func (*UserModel) Authenticate

func (m *UserModel) Authenticate(username, password string) (int, error)

func (*UserModel) Exists

func (m *UserModel) Exists(id int) (bool, error)

func (*UserModel) Insert

func (m *UserModel) Insert(username, password string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL