Documentation
¶
Index ¶
- Constants
- func AddConnections(config *RedisConfig) error
- func ChangeConnection(hval string, conf *RedisConfig) error
- func DoOperation(values url.Values) (bool, interface{})
- func GetRedis(hval string) *redisConnection
- func GetRedisInConnections(hval string) *redisConnection
- func RemoveConnections(hval string) error
- type Geo
- type GeoValue
- type Hash
- type HostConfig
- type KeyInfo
- func (info *KeyInfo) GetDb() int
- func (info *KeyInfo) GetKeyName() string
- func (info *KeyInfo) GetTtl() int64
- func (info *KeyInfo) GetType() uint8
- func (info *KeyInfo) GetTypeString() string
- func (info *KeyInfo) SetTtlWithTime(t time.Duration)
- func (info *KeyInfo) SetTypeWithString(t string)
- func (info *KeyInfo) String() string
- type KeyMap
- type KeyValues
- type List
- type Message
- type RedisConfig
- type RedisVhosts
- func (hosts RedisVhosts) Add(RConf *RedisConfig) error
- func (hosts RedisVhosts) Edit(hval string, New *RedisConfig) error
- func (hosts RedisVhosts) GetConfig(Hval string) (*RedisConfig, error)
- func (hosts RedisVhosts) GetConfigByName(name string) (*RedisConfig, error)
- func (hosts RedisVhosts) GetName(Hval string) (string, error)
- func (hosts RedisVhosts) Remove(hval string) error
- type Render
- type Set
- type String
- type ValueOf
- type Zset
Constants ¶
View Source
const AddListValue = "add_list_value"
set use it
View Source
const ChangeConfig = "change_config"
View Source
const DelConfig = "del_config"
View Source
const DelHashField = "del_hash_field"
View Source
const DelKey = "del_key"
View Source
const DelListValue = "del_list_value"
View Source
const DelZsetField = "del_zset_field"
View Source
const GetKey = "get_key"
key
View Source
const Info = "get_server_info"
server
View Source
const RedisGeo = 6
View Source
const RedisHash = 5
View Source
const RedisList = 2
View Source
const RedisNone = 0
redis type
View Source
const RedisSet = 3
View Source
const RedisString = 1
View Source
const RedisUnknow = 9
View Source
const RedisZset = 4
View Source
const SetConfig = "set_config"
config
View Source
const SetHashField = "set_hash_field"
View Source
const SetTtl = "set_ttl"
View Source
const SetValue = "set_value"
string
View Source
const SetZsetField = "set_zset_field"
Variables ¶
This section is empty.
Functions ¶
func AddConnections ¶
func AddConnections(config *RedisConfig) error
func ChangeConnection ¶
func ChangeConnection(hval string, conf *RedisConfig) error
func DoOperation ¶
func GetRedisInConnections ¶
func GetRedisInConnections(hval string) *redisConnection
func RemoveConnections ¶
Types ¶
type HostConfig ¶
type KeyInfo ¶
type KeyInfo struct {
Db int `json:"db"` //which db
KeyName string `json:"key_name"` //keyname
Type uint8 `json:"type"` //key type
TTl int64 `json:"ttl"`
// contains filtered or unexported fields
}
key
func GetKeyInfo ¶
func GetKeyInfo() *KeyInfo
func GetKeyInfoWithBasic ¶
func (*KeyInfo) GetKeyName ¶
func (*KeyInfo) GetTypeString ¶
func (*KeyInfo) SetTtlWithTime ¶
func (*KeyInfo) SetTypeWithString ¶
type KeyValues ¶
type KeyValues struct {
*KeyInfo `json:"key_info"`
Value interface{} `json:"value"`
}
func KeyOperation ¶
type Message ¶
type RedisConfig ¶
type RedisConfig struct {
Name string `json:"name,omitempty"`
Host string `json:"host,omitempty"`
Db int `json:"db,omitempty"`
Pw string `json:"pw,omitempty"`
Hval string `json:"hval"`
}
func InitConfig ¶
func InitConfig(host, name, pw string) *RedisConfig
func (*RedisConfig) GetHval ¶
func (RConf *RedisConfig) GetHval() string
func (*RedisConfig) GetName ¶
func (RConf *RedisConfig) GetName() string
type RedisVhosts ¶
type RedisVhosts map[string]*RedisConfig
var RedisHosts RedisVhosts
func (RedisVhosts) Add ¶
func (hosts RedisVhosts) Add(RConf *RedisConfig) error
func (RedisVhosts) Edit ¶
func (hosts RedisVhosts) Edit(hval string, New *RedisConfig) error
func (RedisVhosts) GetConfig ¶
func (hosts RedisVhosts) GetConfig(Hval string) (*RedisConfig, error)
func (RedisVhosts) GetConfigByName ¶
func (hosts RedisVhosts) GetConfigByName(name string) (*RedisConfig, error)
func (RedisVhosts) Remove ¶
func (hosts RedisVhosts) Remove(hval string) error
Click to show internal directories.
Click to hide internal directories.