Documentation ¶
Index ¶
- func B2ds(v []byte) string
- func B2i(v []byte) uint64
- func B2s(b []byte) string
- func Bconcat(slices ...[]byte) []byte
- func DS2b(v string) []byte
- func DS2i(v string) uint64
- func I2b(v uint64) []byte
- func S2b(s string) (b []byte)
- type BS
- type DB
- func (db *DB) Close() error
- func (db *DB) Hdel(name string, key []byte) error
- func (db *DB) HdelBucket(name string) error
- func (db *DB) Hget(name string, key []byte) *Reply
- func (db *DB) HgetInt(name string, key []byte) uint64
- func (db *DB) HhasKey(name string, key []byte) bool
- func (db *DB) Hincr(name string, key []byte, step int64) (newNum uint64, err error)
- func (db *DB) Hmdel(name string, keys [][]byte) error
- func (db *DB) Hmget(name string, keys [][]byte) *Reply
- func (db *DB) Hmset(name string, kvs ...[]byte) error
- func (db *DB) Hprefix(name string, prefix []byte, limit int) *Reply
- func (db *DB) Hrscan(name string, keyStart []byte, limit int) *Reply
- func (db *DB) Hscan(name string, keyStart []byte, limit int) *Reply
- func (db *DB) Hset(name string, key, val []byte) error
- func (db *DB) Zdel(name string, key []byte) error
- func (db *DB) ZdelBucket(name string) error
- func (db *DB) Zget(name string, key []byte) uint64
- func (db *DB) ZhasKey(name string, key []byte) bool
- func (db *DB) Zincr(name string, key []byte, step int64) (uint64, error)
- func (db *DB) Zmdel(name string, keys [][]byte) error
- func (db *DB) Zmget(name string, keys [][]byte) *Reply
- func (db *DB) Zmset(name string, kvs [][]byte) error
- func (db *DB) Zrscan(name string, keyStart, scoreStart []byte, limit int) *Reply
- func (db *DB) Zscan(name string, keyStart, scoreStart []byte, limit int) *Reply
- func (db *DB) Zset(name string, key []byte, val uint64) error
- type Entry
- type Reply
- func (r *Reply) Bytes() []byte
- func (r *Reply) Dict() map[string][]byte
- func (r *Reply) Int() int
- func (r *Reply) Int64() int64
- func (r *Reply) KvEach(fn func(key, value BS)) int
- func (r *Reply) KvLen() int
- func (r *Reply) List() []Entry
- func (r *Reply) NotFound() bool
- func (r *Reply) OK() bool
- func (r *Reply) String() string
- func (r *Reply) Uint() uint
- func (r *Reply) Uint64() uint64
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DS2b ¶
DS2b returns an 8-byte big endian representation of Digit string v ("123456") -> uint64(123456) -> 8-byte big endian.
Types ¶
type BS ¶
type BS []byte
type DB ¶
DB embeds a leveldb.DB.
func (*DB) HdelBucket ¶
HdelBucket delete all keys in a hashmap.
func (*DB) Hrscan ¶
Hrscan list key-value pairs of a hashmap with keys in range (key_start, key_end], in reverse order.
func (*DB) ZdelBucket ¶
ZdelBucket delete all keys in a zset.
type Reply ¶
Reply a holder for a Entry list of a hashmap.
Click to show internal directories.
Click to hide internal directories.