Documentation
¶
Index ¶
- Variables
- func SetLogger(l Logger)
- type ContextLogger
- type DB
- func (d *DB) Close()
- func (d *DB) Collections(ctx context.Context, parent string) ([]*dstore.Collection, error)
- func (d *DB) Create(ctx context.Context, path string, values map[string]interface{}) error
- func (d *DB) Delete(ctx context.Context, path string) (bool, error)
- func (d *DB) DeleteAll(ctx context.Context, paths []string) error
- func (d *DB) DeleteCollection(ctx context.Context, parent string) error
- func (d *DB) DocumentIterator(ctx context.Context, parent string, opt ...dstore.Option) (dstore.Iterator, error)
- func (d *DB) Documents(ctx context.Context, parent string, opt ...dstore.Option) ([]*dstore.Document, error)
- func (d *DB) Exists(ctx context.Context, path string) (bool, error)
- func (d *DB) Get(ctx context.Context, path string) (*dstore.Document, error)
- func (d *DB) GetAll(ctx context.Context, paths []string) ([]*dstore.Document, error)
- func (d *DB) IsOpen() bool
- func (d *DB) Load(ctx context.Context, path string, v interface{}) (bool, error)
- func (d *DB) OpenAtPath(ctx context.Context, path string, key SecretKey) error
- func (d *DB) Set(ctx context.Context, path string, values map[string]interface{}, ...) error
- func (d *DB) SetClock(clock tsutil.Clock)
- func (d *DB) Spew(w io.Writer) error
- type LogLevel
- type Logger
- type SecretKey
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAlreadyOpen = errors.New("already open")
ErrAlreadyOpen if already open.
View Source
var ErrNotOpen = errors.New("not open")
ErrNotOpen if not open.
Functions ¶
Types ¶
type ContextLogger ¶
type ContextLogger interface { Debugf(ctx context.Context, format string, args ...interface{}) Infof(ctx context.Context, format string, args ...interface{}) Warningf(ctx context.Context, format string, args ...interface{}) Errorf(ctx context.Context, format string, args ...interface{}) }
ContextLogger interface used in this package with request context.
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB is sqlcipher implementation of dstore.Documents.
func (*DB) Collections ¶
Collections ...
func (*DB) DeleteCollection ¶
DeleteCollection to at paths at parent.
func (*DB) DocumentIterator ¶
func (d *DB) DocumentIterator(ctx context.Context, parent string, opt ...dstore.Option) (dstore.Iterator, error)
DocumentIterator ...
func (*DB) Documents ¶
func (d *DB) Documents(ctx context.Context, parent string, opt ...dstore.Option) ([]*dstore.Document, error)
Documents ...
func (*DB) OpenAtPath ¶
OpenAtPath opens db located at path.
Click to show internal directories.
Click to hide internal directories.