channelshim

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2019 License: GPL-3.0 Imports: 6 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrDatastoreClosed = errors.New("datastore: this instance was closed")

Functions

This section is empty.

Types

type ChanneledDatastore

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

ChanneledDatastore makes datastore thread-safe

func NewChanneledDatastore

func NewChanneledDatastore(ds datastore.Datastore) *ChanneledDatastore

NewChanneledDatastore constructs a datastore accessed through channels.

func (*ChanneledDatastore) Batch

func (cds *ChanneledDatastore) Batch() (datastore.Batch, error)

Query implements Datastore.Batch

func (*ChanneledDatastore) Children

func (cds *ChanneledDatastore) Children() []datastore.Datastore

Children implements Shim

func (*ChanneledDatastore) Close

func (cds *ChanneledDatastore) Close() error

Query closed child Datastore and this Shim

func (*ChanneledDatastore) Delete

func (cds *ChanneledDatastore) Delete(key datastore.Key) error

Delete implements Datastore.Delete

func (*ChanneledDatastore) Get

func (cds *ChanneledDatastore) Get(key datastore.Key) (value interface{}, err error)

Get implements Datastore.Get

func (*ChanneledDatastore) Has

func (cds *ChanneledDatastore) Has(key datastore.Key) (exists bool, err error)

Has implements Datastore.Has

func (*ChanneledDatastore) IsThreadSafe

func (cds *ChanneledDatastore) IsThreadSafe()

func (*ChanneledDatastore) Put

func (cds *ChanneledDatastore) Put(key datastore.Key, value interface{}) error

Put implements Datastore.Put

func (*ChanneledDatastore) Query

func (cds *ChanneledDatastore) Query(q dsq.Query) (dsq.Results, error)

Query implements Datastore.Query

func (*ChanneledDatastore) SetChild

func (cds *ChanneledDatastore) SetChild(ds datastore.Datastore) error

SetChild sets the child of the datastore, if not yet set

type VBatchErr

type VBatchErr struct {
	Batch datastore.Batch
	Err   error
}

type VExistsErr

type VExistsErr struct {
	Exists bool
	Err    error
}

type VKeyValue

type VKeyValue struct {
	Key   datastore.Key
	Value interface{}
}

type VResultsErr

type VResultsErr struct {
	Results dsq.Results
	Err     error
}

type VValueErr

type VValueErr struct {
	Value interface{}
	Err   error
}

Jump to

Keyboard shortcuts

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