cache

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache interface {
	Add(key string, value interface{}) error
	AddExpire(key string, value interface{}, d time.Duration) error
	Set(key string, value interface{}) error
	SetExpire(key string, value interface{}, d time.Duration) error
	Get(key string) (interface{}, error)
	Delete(key string)
	Deletes(keys []string)
}

type ErrorCache

type ErrorCache struct {
}

type RedisCache

type RedisCache struct {
	// contains filtered or unexported fields
}

func GetRedisCache

func GetRedisCache() *RedisCache

func NewRedisCache

func NewRedisCache() *RedisCache

func (RedisCache) Add

func (p RedisCache) Add(key string, value interface{}) error

func (RedisCache) AddExpire

func (p RedisCache) AddExpire(key string, value interface{}, d time.Duration) error

func (RedisCache) Delete

func (p RedisCache) Delete(key string)

func (RedisCache) Deletes

func (p RedisCache) Deletes(keys []string)

func (RedisCache) Get

func (p RedisCache) Get(key string) (interface{}, error)

func (RedisCache) Set

func (p RedisCache) Set(key string, value interface{}) error

func (RedisCache) SetExpire

func (p RedisCache) SetExpire(key string, value interface{}, d time.Duration) error

Jump to

Keyboard shortcuts

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