cache

package
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 14, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClearAll

func ClearAll() error

func Decr

func Decr(key string) error

func Delete

func Delete(key string) error

func Get

func Get(key string, e interface{}) error

func Incr

func Incr(key string) error

func Init

func Init(c cache.Cache)

初始化缓存

func IsExist

func IsExist(key string) bool

func Put

func Put(key string, val interface{}, timeout time.Duration) error

func StartAndGC

func StartAndGC(config string) error

Types

type NullCache

type NullCache struct {
}

func (*NullCache) ClearAll

func (bm *NullCache) ClearAll() error

func (*NullCache) Decr

func (bm *NullCache) Decr(key string) error

func (*NullCache) Delete

func (bm *NullCache) Delete(key string) error

func (*NullCache) Get

func (bm *NullCache) Get(key string) interface{}

func (*NullCache) GetMulti

func (bm *NullCache) GetMulti(keys []string) []interface{}

func (*NullCache) Incr

func (bm *NullCache) Incr(key string) error

func (*NullCache) IsExist

func (bm *NullCache) IsExist(key string) bool

func (*NullCache) Put

func (bm *NullCache) Put(key string, val interface{}, timeout time.Duration) error

func (*NullCache) StartAndGC

func (bm *NullCache) StartAndGC(config string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL