Documentation
¶
Index ¶
Constants ¶
View Source
const EmptyName = ""
Variables ¶
This section is empty.
Functions ¶
func NewLocation ¶
func NewLocation(name string) *location
Types ¶
type ICache ¶
type ICache interface {
// Add 写入不存在的项目
Add(key string, val any, d time.Duration) bool
// Put 存储到缓存中
Put(key string, val any, d time.Duration)
// Has 判断项目是否存在
Has(key string) bool
// Get 获取项目
Get(key string, defaultValue any) any
// Forever 永久写入项目
Forever(key string, val any)
}
ICache 定义缓存接口
Click to show internal directories.
Click to hide internal directories.