Documentation ¶
Index ¶
- Variables
- func Delete(txn *rony.StoreTxn, alloc *tools.Allocator, keyParts ...interface{}) error
- func Exists(txn *rony.StoreTxn, alloc *tools.Allocator, keyParts ...interface{}) bool
- func ExistsByKey(txn *rony.StoreTxn, alloc *tools.Allocator, key []byte) bool
- func Get(txn *rony.StoreTxn, alloc *tools.Allocator, keyParts ...interface{}) ([]byte, error)
- func GetByKey(txn *rony.StoreTxn, alloc *tools.Allocator, key []byte) ([]byte, error)
- func Marshal(txn *rony.StoreTxn, alloc *tools.Allocator, m proto.Message, ...) error
- func Move(txn *rony.StoreTxn, oldKey, newKey []byte) error
- func Set(txn *rony.StoreTxn, alloc *tools.Allocator, val []byte, ...) error
- func SetByKey(txn *rony.StoreTxn, val, key []byte) error
- func Unmarshal(txn *rony.StoreTxn, alloc *tools.Allocator, m proto.Message, ...) error
- func UnmarshalMerge(txn *rony.StoreTxn, alloc *tools.Allocator, m proto.Message, ...) error
- type Config
- type Entry
- type Item
- type IterOption
- func (o *IterOption) Backward() bool
- func (o *IterOption) OffsetKey() []byte
- func (o *IterOption) OnClose(key []byte)
- func (o *IterOption) SetBackward() *IterOption
- func (o *IterOption) SetForward() *IterOption
- func (o *IterOption) SetOffsetKey(offset []byte) *IterOption
- func (o *IterOption) SetOnClose(f func(key []byte)) *IterOption
- type ListOption
- func (o *ListOption) Backward() bool
- func (o *ListOption) Limit() int32
- func (o *ListOption) SetBackward() *ListOption
- func (o *ListOption) SetForward() *ListOption
- func (o *ListOption) SetLimit(limit int32) *ListOption
- func (o *ListOption) SetSkip(skip int32) *ListOption
- func (o *ListOption) Skip() int32
- type LocalDB
- type Store
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrKeyNotFound = badger.ErrKeyNotFound DefaultIteratorOptions = badger.DefaultIteratorOptions )
View Source
var ( ErrAlreadyExists = fmt.Errorf("already exists") ErrEmptyObject = fmt.Errorf("empty object") )
Functions ¶
func ExistsByKey ¶ added in v0.12.0
Types ¶
type Config ¶
type Config struct { DirPath string ConflictRetries int ConflictMaxInterval time.Duration BatchWorkers int BatchSize int InMemory bool }
func DefaultConfig ¶
type IterOption ¶
type IterOption struct {
// contains filtered or unexported fields
}
func NewIterOption ¶
func NewIterOption() *IterOption
func (*IterOption) Backward ¶
func (o *IterOption) Backward() bool
func (*IterOption) OffsetKey ¶
func (o *IterOption) OffsetKey() []byte
func (*IterOption) OnClose ¶
func (o *IterOption) OnClose(key []byte)
func (*IterOption) SetBackward ¶
func (o *IterOption) SetBackward() *IterOption
func (*IterOption) SetForward ¶
func (o *IterOption) SetForward() *IterOption
func (*IterOption) SetOffsetKey ¶
func (o *IterOption) SetOffsetKey(offset []byte) *IterOption
func (*IterOption) SetOnClose ¶
func (o *IterOption) SetOnClose(f func(key []byte)) *IterOption
type ListOption ¶
type ListOption struct {
// contains filtered or unexported fields
}
func NewListOption ¶
func NewListOption() *ListOption
func (*ListOption) Backward ¶
func (o *ListOption) Backward() bool
func (*ListOption) Limit ¶
func (o *ListOption) Limit() int32
func (*ListOption) SetBackward ¶
func (o *ListOption) SetBackward() *ListOption
func (*ListOption) SetForward ¶
func (o *ListOption) SetForward() *ListOption
func (*ListOption) SetLimit ¶
func (o *ListOption) SetLimit(limit int32) *ListOption
func (*ListOption) SetSkip ¶
func (o *ListOption) SetSkip(skip int32) *ListOption
func (*ListOption) Skip ¶
func (o *ListOption) Skip() int32
Click to show internal directories.
Click to hide internal directories.