Documentation ¶
Index ¶
- func NewBatch() *batch
- type DB
- func (s *DB) Close() error
- func (s *DB) Destroy() error
- func (s *DB) DestroyClosed() error
- func (s *DB) Get(key []byte) ([]byte, error)
- func (s *DB) Has(key []byte) error
- func (s *DB) Init() error
- func (s *DB) IsInterfaceNil() bool
- func (s *DB) Put(key, val []byte) error
- func (bldb DB) RangeKeys(handler func(key []byte, value []byte) bool)
- func (s *DB) Remove(key []byte) error
- type SerialDB
- func (s *SerialDB) Close() error
- func (s *SerialDB) Destroy() error
- func (s *SerialDB) DestroyClosed() error
- func (s *SerialDB) Get(key []byte) ([]byte, error)
- func (s *SerialDB) Has(key []byte) error
- func (s *SerialDB) Init() error
- func (s *SerialDB) IsInterfaceNil() bool
- func (s *SerialDB) Put(key, val []byte) error
- func (bldb SerialDB) RangeKeys(handler func(key []byte, value []byte) bool)
- func (s *SerialDB) Remove(key []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB holds a pointer to the leveldb database and the path to where it is stored.
func NewDB ¶
func NewDB(path string, batchDelaySeconds int, maxBatchSize int, maxOpenFiles int) (s *DB, err error)
NewDB is a constructor for the leveldb persister It creates the files in the location given as parameter
func (*DB) DestroyClosed ¶
DestroyClosed removes the already closed storage medium stored data
func (*DB) IsInterfaceNil ¶
IsInterfaceNil returns true if there is no value under the interface
type SerialDB ¶
type SerialDB struct {
// contains filtered or unexported fields
}
SerialDB holds a pointer to the leveldb database and the path to where it is stored.
func NewSerialDB ¶
func NewSerialDB(path string, batchDelaySeconds int, maxBatchSize int, maxOpenFiles int) (s *SerialDB, err error)
NewSerialDB is a constructor for the leveldb persister It creates the files in the location given as parameter
func (*SerialDB) DestroyClosed ¶
DestroyClosed removes the already closed storage medium stored data
func (*SerialDB) IsInterfaceNil ¶
IsInterfaceNil returns true if there is no value under the interface