Documentation
¶
Index ¶
- Constants
- type DistLock
- type Redis
- func (red *Redis) Close() error
- func (red *Redis) CreateListByInt64Slice(key string, data []int64) error
- func (red *Redis) DeleteKey(key string) error
- func (red *Redis) Do(commandName string, args ...interface{}) (reply interface{}, err error)
- func (red *Redis) Err() error
- func (red *Redis) Flush() error
- func (red *Redis) GetInt64SliceList(key string) ([]int64, error)
- func (red *Redis) GetListLen(key string) (int, error)
- func (red *Redis) GetListValueByIndex(key string, index int) (int64, error)
- func (red *Redis) Hget(key, field string) (string, error)
- func (red *Redis) Hgetall(key string) (map[string]string, error)
- func (red *Redis) Hmget(key string, fields []string) ([]string, error)
- func (red *Redis) Hmset(key string, m map[string]interface{}) error
- func (red *Redis) Hset(key, field, value string) error
- func (red *Redis) HyperLogLogAdd(key, value string) error
- func (red *Redis) HyperLogLogLen(key string) (int64, error)
- func (red *Redis) IsKeyExist(key string) bool
- func (red *Redis) ListPop(key string) (string, error)
- func (red *Redis) ListPush(key, value string) error
- func (red *Redis) Lock(key, value string, timeout int64) error
- func (red *Redis) Publish(channel, msg string) error
- func (red *Redis) Receive() (reply interface{}, err error)
- func (red *Redis) Send(commandName string, args ...interface{}) error
- func (red *Redis) SetAdd(key, value string) error
- func (red *Redis) SetLen(key string) (int64, error)
- func (red *Redis) SetListValueByIndex(key string, index int, value int64) error
- func (red *Redis) SetMembers(key string) ([]string, error)
- func (red *Redis) Unlock(key, value string) error
- func (red *Redis) ZsetAdd(key, value string, score int64) error
- func (red *Redis) ZsetLen(key string) (int64, error)
- func (red *Redis) ZsetLenBetweenScores(key string, min, max int64) (int64, error)
- func (red *Redis) ZsetMembers(key string) (map[string]int64, error)
- type RedisPool
Constants ¶
View Source
const ( MAX_POOL_SIZE = 20 MAX_IDLE_NUM = 2 MAX_ACTIVE_NUM = 20 REDIS_ADDR = "localhost:6379" REDISPASSWORD = "180498" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Redis ¶
type Redis struct {
// contains filtered or unexported fields
}
func (*Redis) CreateListByInt64Slice ¶
func (*Redis) GetListValueByIndex ¶
func (*Redis) HyperLogLogAdd ¶
func (*Redis) IsKeyExist ¶
func (*Redis) SetListValueByIndex ¶
func (*Redis) ZsetLenBetweenScores ¶
Click to show internal directories.
Click to hide internal directories.