Version: v0.1.0 Latest Latest

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

Go to latest
Published: Jun 30, 2020 License: Apache-2.0 Imports: 2 Imported by: 0




This section is empty.


This section is empty.


This section is empty.


type Backend

type Backend interface {
	// Read a buffer value stored against key k into buffer buf.
	// The return value will be false if the key could not be found in the map.
	Get(k uint64, buf []byte) bool

	// Update finds the buffer stored against key k and atomically updates it with
	// v using the function fn. It returns the error returned by fn, if any. The
	// function fn may be called multiple times during a single call to Update, or
	// not called at all.
	Update(k uint64, fn func(data []byte, init bool) error) error

type Store

type Store struct {
	Backend  Backend
	Collator collation.Collator

func (*Store) Read

func (*Store) Write

func (s *Store) Write(ctx context.Context, r collation.Row) error

type Transaction

type Transaction struct {
	Row collation.Row
	Fn  func(r collation.Row, data []byte, init bool) error

func (Transaction) Do

func (t Transaction) Do(data []byte, init bool) error

Source Files

Jump to

Keyboard shortcuts

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