kv

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseStore added in v1.0.0

type BaseStore struct {
	plugins.Config
	document.KeyCoder
}

BaseStore represents a base store.

func NewBaseStore added in v1.0.0

func NewBaseStore() *BaseStore

NewBaseStore returns a new base store instance.

func NewBaseStoreWith added in v1.0.0

func NewBaseStoreWith(coder document.KeyCoder) *BaseStore

NewBaseStore returns a new base store instance.

func (*BaseStore) DecodeKey added in v1.0.0

func (store *BaseStore) DecodeKey(b []byte) (document.Key, error)

DecodeKey returns the decoded key from the specified bytes if available, otherwise returns an error.

func (*BaseStore) EncodeKey added in v1.0.0

func (store *BaseStore) EncodeKey(key document.Key) ([]byte, error)

EncodeKey returns the encoded bytes from the specified key if available, otherwise returns an error.

func (*BaseStore) ServiceType added in v1.0.0

func (store *BaseStore) ServiceType() plugins.ServiceType

ServiceType returns the plug-in service type.

func (*BaseStore) SetKeyCoder added in v1.0.0

func (store *BaseStore) SetKeyCoder(coder document.KeyCoder)

SetKeyCoder sets the key coder.

type Service

type Service interface {
	kv.Store
	plugins.Service
}

Service represents a key-value store service.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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