storeonedrive

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 (
	ErrClosed = store.ErrClosed
)
View Source
var ErrExisted = errors.New("existed")
View Source
var ErrNotFound = errors.New("not found")

Functions

func TestKV

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

Types

type Def

type Def struct{}

func (Def) New

func (Def) New() New

type New

type New func(
	ctx context.Context,
	client *http.Client,
	drivePath string,
	dir string,
) (*Store, error)

type Store

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

func (*Store) CostInfo

func (s *Store) CostInfo() storekv.CostInfo

func (*Store) KeyDelete

func (s *Store) KeyDelete(keys ...string) (err error)

func (*Store) KeyExists

func (s *Store) KeyExists(key string) (ok bool, err error)

func (*Store) KeyGet

func (s *Store) KeyGet(key string, fn func(io.Reader) error) (err error)

func (*Store) KeyIter

func (s *Store) KeyIter(prefix string, fn func(string) error) (err error)

func (*Store) KeyPut

func (s *Store) KeyPut(key string, r io.Reader) (err error)

func (*Store) Name

func (s *Store) Name() string

func (*Store) StoreID

func (s *Store) StoreID() string

Jump to

Keyboard shortcuts

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