ldbstorage

package
v0.0.0-...-ebe581b Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LevelDBStorage

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

func New

func New(root string) (*LevelDBStorage, error)

New creat a levelDB to save challenge material

func (*LevelDBStorage) Close

func (s *LevelDBStorage) Close()

func (*LevelDBStorage) Load

func (s *LevelDBStorage) Load(key []byte) (types.Material, error)

Load get a challenge material from levelDB

func (*LevelDBStorage) NewIterator

func (s *LevelDBStorage) NewIterator(prefix []byte) ([][]byte, error)

func (*LevelDBStorage) Save

func (s *LevelDBStorage) Save(cms []types.Material) error

Save save a challenge material to levelDB

func (*LevelDBStorage) Update

func (s *LevelDBStorage) Update(m types.Material, key []byte) error

Update update challenge material by key

Jump to

Keyboard shortcuts

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