Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetPut ¶
type GetPut interface { // Get looks up the value that corresponds to key and calls cb once if the key exists // if the key does not exist then a pacherr.ErrNotExist is returned Get(ctx context.Context, key []byte, cb ValueCallback) error // Put creates an entry mapping key to value, overwriting any previous mapping. Put(ctx context.Context, key, value []byte) error }
GetPut supports the basic Get and Put operations
type Store ¶
type Store interface { GetPut Delete(ctx context.Context, key []byte) error Exists(ctx context.Context, key []byte) (bool, error) Walk(ctx context.Context, prefix []byte, cb func(key []byte) error) error }
Store is a key-value store
func NewFromObjectClient ¶
NewFromObjectClient converts an object client into a key value store. This can provide more natural interface for small values, but it will read the entire object into memory
type ValueCallback ¶
ValueCallback is the type of functions used to access values
Click to show internal directories.
Click to hide internal directories.