stores3

package
v0.0.0-...-7899014 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Break = store.Break

	ErrKeyNotFound = store.ErrKeyNotFound
	ErrClosed      = store.ErrClosed
)

Functions

func TestKV

func TestKV(
	t *testing.T,
	testKV storekv.TestKV,
	newKV New,
	wg *pr2.WaitGroup,
)

Types

type Def

type Def struct{}

func (Def) New

func (Def) New(
	timeout Timeout,
) New

func (Def) Timeout

func (Def) Timeout() Timeout

type KV

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

func (*KV) CostInfo

func (kv *KV) CostInfo() storekv.CostInfo

func (*KV) KeyDelete

func (k *KV) KeyDelete(keys ...string) (err error)

func (*KV) KeyExists

func (k *KV) KeyExists(key string) (_ bool, err error)

func (*KV) KeyGet

func (k *KV) KeyGet(key string, fn func(io.Reader) error) (err error)

func (*KV) KeyIter

func (k *KV) KeyIter(prefix string, fn func(string) error) (err error)

func (*KV) KeyPut

func (k *KV) KeyPut(key string, r io.Reader) (err error)

func (*KV) Name

func (k *KV) Name() string

func (*KV) StoreID

func (k *KV) StoreID() string

type New

type New func(
	ctx context.Context,
	endpoint string,
	key string,
	secret string,
	useSSL bool,
	bucket string,
	options ...NewOption,
) (*KV, error)

type NewOption

type NewOption interface {
	IsNewOption()
}

type Scope

type Scope = dscope.Scope

type Timeout

type Timeout time.Duration

Jump to

Keyboard shortcuts

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