Versions in this module Expand all Collapse all v0 v0.1.1 Mar 28, 2024 v0.1.0 Mar 28, 2024 Changes in this version + type Database struct + Q *Queries + func NewDatabase(path string, timeout time.Duration) *Database + func (d *Database) Close() error + func (d *Database) InitSchema() error + type DbCommon interface + ExecContext func(context.Context, string, ...interface{}) (sql.Result, error) + PrepareContext func(context.Context, string) (*sql.Stmt, error) + QueryContext func(context.Context, string, ...interface{}) (*sql.Rows, error) + QueryRowContext func(context.Context, string, ...interface{}) *sql.Row + type Password struct + Key string + Value string + type Queries struct + func (q *Queries) BatchInsertPassword(ctx context.Context, passwords []*Password, batchSize int) error + func (q *Queries) GetAllPasswords(ctx context.Context) ([]*Password, error) + func (q *Queries) GetPasswordByKey(ctx context.Context, key string) (*Password, error) + func (q *Queries) InsertPassword(ctx context.Context, password *Password) error + type Store interface + BatchInsertPassword func(ctx context.Context, passwords []*Password, batchSize int) error + GetAllPasswords func(ctx context.Context) ([]*Password, error) + GetPasswordByKey func(ctx context.Context, key string) (*Password, error) + InsertPassword func(ctx context.Context, password *Password) error