Documentation ¶
Index ¶
- Constants
- type RedisCache
- func (r *RedisCache) Decr(key string) (int64, error)
- func (r *RedisCache) Delete(key string) (err error)
- func (r *RedisCache) Flush() (err error)
- func (r *RedisCache) Get(key string, _val interface{}) error
- func (r *RedisCache) Incr(key string) (int64, error)
- func (r *RedisCache) IsExist(key string) bool
- func (r *RedisCache) Set(key string, val interface{}, timeout int64) (err error)
- func (r *RedisCache) StartAndGC(opt cache.Options) error
- func (r *RedisCache) Touch(key string, expire int64) (err error)
- type RedisConfig
Constants ¶
View Source
const GC_HASH_KEY = "TagCache:CacheGCKeys"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisCache ¶
type RedisCache struct {
// contains filtered or unexported fields
}
func (*RedisCache) Decr ¶
func (r *RedisCache) Decr(key string) (int64, error)
Decr decreases cached int-type value by given key as a counter.
func (*RedisCache) Delete ¶
func (r *RedisCache) Delete(key string) (err error)
Delete deletes cached value by given key.
func (*RedisCache) Get ¶
func (r *RedisCache) Get(key string, _val interface{}) error
func (*RedisCache) Incr ¶
func (r *RedisCache) Incr(key string) (int64, error)
Incr increases cached int-type value by given key as a counter.
func (*RedisCache) IsExist ¶
func (r *RedisCache) IsExist(key string) bool
IsExist returns true if cached value exists.
func (*RedisCache) Set ¶
func (r *RedisCache) Set(key string, val interface{}, timeout int64) (err error)
func (*RedisCache) StartAndGC ¶
func (r *RedisCache) StartAndGC(opt cache.Options) error
StartAndGC starts GC routine based on config string settings.
Click to show internal directories.
Click to hide internal directories.