Documentation
¶
Index ¶
- Variables
- type Bitmap
- func (l *Bitmap) Del(ctx context.Context) error
- func (l *Bitmap) FindBit(ctx context.Context, bit int8, start int64, end int64) (int64, error)
- func (l *Bitmap) Get(ctx context.Context) (*[]byte, error)
- func (l *Bitmap) GetBit(ctx context.Context, index int64) (int64, error)
- func (l *Bitmap) GetBool(ctx context.Context, index int64) (bool, error)
- func (l *Bitmap) GetRange(ctx context.Context, start int64, end int64) (*[]byte, error)
- func (l *Bitmap) LoopBits(ctx context.Context, bit int8, start int64, end int64) func() (int64, error)
- func (l *Bitmap) Set(ctx context.Context, data *[]byte) error
- func (l *Bitmap) SetBit(ctx context.Context, index int64, bit int64) error
- func (l *Bitmap) SetBool(ctx context.Context, index int64, value bool) error
- type HeartBeatLock
- type KeyResolver
- type LinoRedis
- func (l *LinoRedis) BitField(ctx context.Context, subPath string, args ...interface{}) ([]int64, error)
- func (l *LinoRedis) BitPos(ctx context.Context, subPath string, bit int64, args ...int64) (int64, error)
- func (l *LinoRedis) BitPosSpan(ctx context.Context, subPath string, bit int8, start int64, end int64, ...) (int64, error)
- func (l *LinoRedis) Close() error
- func (l *LinoRedis) Decr(ctx context.Context, subPath string) (int64, error)
- func (l *LinoRedis) DecrBy(ctx context.Context, subPath string, value int64) (int64, error)
- func (l *LinoRedis) Del(ctx context.Context, subPath string) error
- func (l *LinoRedis) Expire(ctx context.Context, subPath string, expiration time.Duration) (bool, error)
- func (l *LinoRedis) Fork(parts ...string) *LinoRedis
- func (l *LinoRedis) Forkf(format string, args ...interface{}) *LinoRedis
- func (l *LinoRedis) Get(ctx context.Context, subPath string) *redis.StringCmd
- func (l *LinoRedis) GetBit(ctx context.Context, subPath string, offset int64) (int64, error)
- func (l *LinoRedis) GetRange(ctx context.Context, subPath string, start int64, end int64) ([]byte, error)
- func (l *LinoRedis) GetResolver() func(parts ...string) string
- func (l *LinoRedis) HDel(ctx context.Context, subPath string, fields ...string) (int64, error)
- func (l *LinoRedis) HExists(ctx context.Context, subPath string, field string) (bool, error)
- func (l *LinoRedis) HGet(ctx context.Context, subPath string, field string) *redis.StringCmd
- func (l *LinoRedis) HGetAll(ctx context.Context, subPath string) (map[string]string, error)
- func (l *LinoRedis) HMGet(ctx context.Context, subPath string, fields ...string) ([]interface{}, error)
- func (l *LinoRedis) HMSet(ctx context.Context, subPath string, fields map[string]interface{}) error
- func (l *LinoRedis) HSet(ctx context.Context, subPath string, field string, value interface{}) (int64, error)
- func (l *LinoRedis) Incr(ctx context.Context, subPath string) (int64, error)
- func (l *LinoRedis) IncrBy(ctx context.Context, subPath string, value int64) (int64, error)
- func (l *LinoRedis) IncrByFloat(ctx context.Context, subPath string, value float64) (float64, error)
- func (l *LinoRedis) MGet(ctx context.Context, subPaths ...string) *redis.SliceCmd
- func (l *LinoRedis) MSet(ctx context.Context, values map[string]string) error
- func (l *LinoRedis) NewBitmap(basePath string) *Bitmap
- func (l *LinoRedis) NewHeartBeatLock(subPath string, heartBeatInterval time.Duration) *HeartBeatLock
- func (l *LinoRedis) NewPipeline(resolver *KeyResolver) *Pipeline
- func (l *LinoRedis) NewRLEBitfield(basePath string) *RLEBitfield
- func (l *LinoRedis) NewRedisItem(subPath string) *RedisItem
- func (l *LinoRedis) NewRedisItemf(format string, args ...interface{}) *RedisItem
- func (l *LinoRedis) NewRedisSet(subPath string) *RedisSet
- func (l *LinoRedis) NewScaner(subPath string, opts *ScanOptions) *Scaner
- func (l *LinoRedis) Ping(timeout time.Duration) bool
- func (l *LinoRedis) PrintKey()
- func (l *LinoRedis) SAdd(ctx context.Context, subPath string, members ...interface{}) (int64, error)
- func (l *LinoRedis) SCard(ctx context.Context, subPath string) (int64, error)
- func (l *LinoRedis) SIsMember(ctx context.Context, subPath string, member interface{}) (bool, error)
- func (l *LinoRedis) SMembers(ctx context.Context, subPath string) ([]string, error)
- func (l *LinoRedis) SPop(ctx context.Context, subPath string) (string, error)
- func (l *LinoRedis) SRem(ctx context.Context, subPath string, members ...interface{}) (int64, error)
- func (l *LinoRedis) Scan(ctx context.Context, cursor uint64, match string, count int64) *redis.ScanCmd
- func (l *LinoRedis) Set(ctx context.Context, subPath string, value interface{}, ...) (string, error)
- func (l *LinoRedis) SetBit(ctx context.Context, subPath string, offset int64, value int) (int64, error)
- func (l *LinoRedis) SetEX(ctx context.Context, subPath string, value interface{}, ...) (string, error)
- func (l *LinoRedis) SetNX(ctx context.Context, subPath string, value interface{}, ...) (bool, error)
- func (l *LinoRedis) TTL(ctx context.Context, subPath string) (time.Duration, error)
- type Pipeline
- type RLEBitfield
- func (l *RLEBitfield) Del(ctx context.Context) error
- func (l *RLEBitfield) Get(ctx context.Context) (*bitfield.BitField, error)
- func (l *RLEBitfield) Lock(ctx context.Context) error
- func (l *RLEBitfield) Set(ctx context.Context, bf *bitfield.BitField) error
- func (l *RLEBitfield) Unlock(ctx context.Context) error
- type RedisItem
- func (l *RedisItem) BitField(ctx context.Context, args ...interface{}) ([]int64, error)
- func (l *RedisItem) BitPos(ctx context.Context, bit int64, args ...int64) (int64, error)
- func (l *RedisItem) BitPosSpan(ctx context.Context, bit int8, start int64, end int64, span string) (int64, error)
- func (l *RedisItem) Decr(ctx context.Context) (int64, error)
- func (l *RedisItem) DecrBy(ctx context.Context, value int64) (int64, error)
- func (l *RedisItem) Del(ctx context.Context) error
- func (l *RedisItem) Expire(ctx context.Context, expiration time.Duration) (bool, error)
- func (l *RedisItem) Get(ctx context.Context) *redis.StringCmd
- func (l *RedisItem) GetBit(ctx context.Context, offset int64) (int64, error)
- func (l *RedisItem) GetRange(ctx context.Context, start int64, end int64) ([]byte, error)
- func (l *RedisItem) Incr(ctx context.Context) (int64, error)
- func (l *RedisItem) IncrBy(ctx context.Context, value int64) (int64, error)
- func (l *RedisItem) IncrByFloat(ctx context.Context, value float64) (float64, error)
- func (l *RedisItem) Set(ctx context.Context, value interface{}, expiration time.Duration) (string, error)
- func (l *RedisItem) SetBit(ctx context.Context, offset int64, value int) (int64, error)
- func (l *RedisItem) SetEX(ctx context.Context, value interface{}, expiration time.Duration) (string, error)
- func (l *RedisItem) SetNX(ctx context.Context, value interface{}, expiration time.Duration) (bool, error)
- func (l *RedisItem) TTL(ctx context.Context) (time.Duration, error)
- type RedisSet
- func (l *RedisSet) Add(ctx context.Context, members ...interface{}) (int64, error)
- func (l *RedisSet) Clear(ctx context.Context) error
- func (l *RedisSet) IsMember(ctx context.Context, member interface{}) (bool, error)
- func (l *RedisSet) Members(ctx context.Context) ([]string, error)
- func (l *RedisSet) Pop(ctx context.Context) (string, error)
- func (l *RedisSet) Remove(ctx context.Context, members ...interface{}) (int64, error)
- func (l *RedisSet) Size(ctx context.Context) (int64, error)
- type ScanOptions
- type Scaner
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrLockFailed = errors.New("lock failed") ErrChannelDone = errors.New("channel done") )
Functions ¶
This section is empty.
Types ¶
type Bitmap ¶
type Bitmap struct { HBLock *HeartBeatLock BitLockBaseKey *LinoRedis BitDataBaseKey *LinoRedis // contains filtered or unexported fields }
type HeartBeatLock ¶
type HeartBeatLock struct {
// contains filtered or unexported fields
}
type KeyResolver ¶ added in v0.0.7
type LinoRedis ¶
type LinoRedis struct {
// contains filtered or unexported fields
}
func LoadRedisWithPrefix ¶ added in v0.0.8
func MustLoadRedis ¶ added in v0.0.8
func MustLoadRedisWithPrefix ¶ added in v0.0.8
func NewLinoRedis ¶
func (*LinoRedis) BitField ¶ added in v0.0.3
func (l *LinoRedis) BitField(ctx context.Context, subPath string, args ...interface{}) ([]int64, error)
Bitfield
func (*LinoRedis) BitPosSpan ¶ added in v0.0.5
func (*LinoRedis) GetResolver ¶
func (*LinoRedis) IncrByFloat ¶ added in v0.0.11
func (*LinoRedis) NewHeartBeatLock ¶
func (l *LinoRedis) NewHeartBeatLock(subPath string, heartBeatInterval time.Duration) *HeartBeatLock
func (*LinoRedis) NewPipeline ¶ added in v0.0.7
func (l *LinoRedis) NewPipeline(resolver *KeyResolver) *Pipeline
func (*LinoRedis) NewRLEBitfield ¶ added in v0.0.7
func (l *LinoRedis) NewRLEBitfield(basePath string) *RLEBitfield
func (*LinoRedis) NewRedisItem ¶
func (*LinoRedis) NewRedisItemf ¶ added in v0.0.7
func (*LinoRedis) NewRedisSet ¶ added in v0.0.7
func (*LinoRedis) NewScaner ¶
func (l *LinoRedis) NewScaner(subPath string, opts *ScanOptions) *Scaner
func (*LinoRedis) SAdd ¶
func (l *LinoRedis) SAdd(ctx context.Context, subPath string, members ...interface{}) (int64, error)
Set
func (*LinoRedis) Scan ¶
func (l *LinoRedis) Scan(ctx context.Context, cursor uint64, match string, count int64) *redis.ScanCmd
Keys
type RLEBitfield ¶ added in v0.0.7
type RLEBitfield struct {
// contains filtered or unexported fields
}
func (*RLEBitfield) Get ¶ added in v0.0.7
func (l *RLEBitfield) Get(ctx context.Context) (*bitfield.BitField, error)
type RedisItem ¶
type RedisItem struct {
// contains filtered or unexported fields
}
func (*RedisItem) BitPosSpan ¶ added in v0.0.5
func (*RedisItem) IncrByFloat ¶ added in v0.0.11
type RedisSet ¶ added in v0.0.7
type RedisSet struct {
// contains filtered or unexported fields
}
type ScanOptions ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.