datastore

package
v0.0.0-...-9358e86 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2016 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewState

func NewState(db *sqlx.DB, state State) (string, error)

Types

type State

type State struct {
	StateID  string    `db:"state_id"`
	Word     string    `db:"word"`
	Guess    string    `db:"guess"`
	Current  string    `db:"current"`
	Mode     string    `db:"mode"`
	UserID   string    `db:"user_id"`
	ParentID string    `db:"parent_state_id"`
	Created  time.Time `db:"created_at"`
}

func GetNewState

func GetNewState(userID string) State

func GetState

func GetState(db *sqlx.DB, id string) (State, error)

func GetUserLastState

func GetUserLastState(db *sqlx.DB, id string) (State, error)

func (State) String

func (s State) String() string

Jump to

Keyboard shortcuts

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