nutsdb

package
v1.2.4 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewSearchOption added in v1.1.5

func NewSearchOption(opts ...SearchOption) *searchOption

Types

type SearchOption added in v1.1.5

type SearchOption = func(opt *searchOption)

func WithEndKey added in v1.1.5

func WithEndKey(endKey []byte) SearchOption

func WithLimit added in v1.1.5

func WithLimit(limit int) SearchOption

func WithOffset added in v1.1.5

func WithOffset(offset int) SearchOption

func WithPrefix added in v1.1.5

func WithPrefix(prefix []byte) SearchOption

func WithReg added in v1.1.5

func WithReg(reg string) SearchOption

func WithStartKey added in v1.1.5

func WithStartKey(startKey []byte) SearchOption

type Table

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

func NewTable

func NewTable(db *nutsdb.DB, name string, ttl uint32) (*Table, error)

func (*Table) BatchSet added in v1.2.2

func (tb *Table) BatchSet(ctx context.Context, args ...[]byte) error

func (*Table) Delete

func (tb *Table) Delete(ctx context.Context, key []byte) error

func (*Table) Get

func (tb *Table) Get(ctx context.Context, key []byte, fn func(val []byte) error) error

func (*Table) GetTTL added in v1.1.8

func (tb *Table) GetTTL(ctx context.Context, key []byte) (int64, error)

func (*Table) Iterate added in v1.1.5

func (tb *Table) Iterate(ctx context.Context, opt *nutsdb.IteratorOptions, fn func(key []byte, val []byte) error) error

func (*Table) MGet

func (tb *Table) MGet(ctx context.Context, keys [][]byte, fn func(val []byte) error) error

func (*Table) MSet

func (tb *Table) MSet(ctx context.Context, args ...[]byte) error

func (Table) Name added in v1.1.3

func (tb Table) Name() string

func (*Table) Persist added in v1.1.7

func (tb *Table) Persist(ctx context.Context, key []byte, val []byte) error

func (*Table) Search added in v1.1.5

func (tb *Table) Search(ctx context.Context, cb func(key []byte, value []byte) error, opts ...SearchOption) error

func (*Table) Set

func (tb *Table) Set(ctx context.Context, key []byte, val []byte) error

func (Table) TTL added in v1.1.3

func (tb Table) TTL() uint32

Jump to

Keyboard shortcuts

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