Documentation ¶
Index ¶
- type DB
- func (db *DB) Close() error
- func (db *DB) CmpAndSwap(bucket, key, oldValue, newValue []byte) ([]byte, bool, error)
- func (db *DB) CreateTable(bucket []byte) error
- func (db *DB) Del(bucket, key []byte) error
- func (db *DB) DeleteTable(bucket []byte) error
- func (db *DB) Get(bucket, key []byte) ([]byte, error)
- func (db *DB) List(bucket []byte) ([]*database.Entry, error)
- func (db *DB) Open(dataSourceName string, opt ...database.Option) error
- func (db *DB) Set(bucket, key, value []byte) error
- func (db *DB) Update(tx *database.Tx) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB is a wrapper over *sql.DB,
func (*DB) CmpAndSwap ¶
CmpAndSwap modifies the value at the given bucket and key (to newValue) only if the existing (current) value matches oldValue.
func (*DB) CreateTable ¶
CreateTable creates a table in the database.
func (*DB) DeleteTable ¶
DeleteTable deletes a table in the database.
func (*DB) Open ¶
Open creates a Driver and connects to the database with the given address and access details.
Click to show internal directories.
Click to hide internal directories.