bolt

package
v0.0.0-...-c688a7a Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bolt

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

Bolt is the Bolt database. It satisfies the Database interface.

func New

func New(ctx context.Context, directory string) (*Bolt, error)

New returns a new Bolt implementation.

func (*Bolt) Close

func (b *Bolt) Close(ctx context.Context)

Close closes the database. Make sure to close the database once used.

func (*Bolt) Create

func (b *Bolt) Create(ctx context.Context, user database.User) error

Create implements the Database interface.

func (*Bolt) Delete

func (b *Bolt) Delete(ctx context.Context, name string) error

Delete implements the Database interface.

func (*Bolt) Get

func (b *Bolt) Get(ctx context.Context, name string) (user *database.User)

Get implements the Database interface.

func (*Bolt) Update

func (b *Bolt) Update(ctx context.Context, user database.User) (*database.User, error)

Update implements the Database interface.

Jump to

Keyboard shortcuts

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