kv

package
v0.0.0-...-83f9fa1 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cluster

type Cluster struct {
	Engine string
	Config interface{}
}

type KV

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

func New

func New(cfg interface{}) (*KV, error)

func (*KV) Allocate

func (e *KV) Allocate(name string, size int64, ndata int, nparity int) error

func (*KV) Exists

func (e *KV) Exists(s string, ndata int, nparity int) (bool, error)

func (*KV) ReadAt

func (e *KV) ReadAt(name string, buf []byte, offset int64, ndata int, nparity int) (int, error)

func (*KV) Remove

func (e *KV) Remove(name string, ndata int, nparity int) error

func (*KV) SetBackend

func (e *KV) SetBackend(b backend.Backend) error

func (*KV) SetCache

func (e *KV) SetCache(c cache.Cache)

func (*KV) SetCluster

func (e *KV) SetCluster(c cluster.Cluster) error

func (*KV) WriteAt

func (e *KV) WriteAt(name string, buf []byte, offset int64, ndata int, nparity int) (int, error)

type RW

type RW struct {
	Name    string
	KV      *KV
	Offset  int64
	Size    int64
	Ndata   int
	Nparity int
}

func (*RW) Read

func (e *RW) Read(buf []byte) (int, error)

func (*RW) ReaderFrom

func (e *RW) ReaderFrom(r io.Reader) (int64, error)

func (*RW) Seek

func (e *RW) Seek(offset int64, whence int) (int64, error)

func (*RW) Write

func (e *RW) Write(buf []byte) (int, error)

func (*RW) WriterTo

func (e *RW) WriterTo(w io.Writer) (int64, error)

type Store

type Store struct {
	Engine string
	Config interface{}
}

Jump to

Keyboard shortcuts

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