Documentation ¶
Index ¶
- type Account
- type Database
- func (db *Database) Close() error
- func (db *Database) DeleteAccount(keyUID string) error
- func (db *Database) GetAccounts() ([]Account, error)
- func (db *Database) SaveAccount(account Account) error
- func (db *Database) UpdateAccount(account Account) error
- func (db *Database) UpdateAccountTimestamp(keyUID string, loginTimestamp int64) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { Name string `json:"name"` Timestamp int64 `json:"timestamp"` PhotoPath string `json:"photo-path"` KeycardPairing string `json:"keycard-pairing"` KeyUID string `json:"key-uid"` }
Account stores public information about account.
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
func InitializeDB ¶
InitializeDB creates db file at a given path and applies migrations.
func (*Database) DeleteAccount ¶
func (*Database) GetAccounts ¶
func (*Database) SaveAccount ¶
func (*Database) UpdateAccount ¶
Click to show internal directories.
Click to hide internal directories.