Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache interface {
// Get an item from the cache. Returns the item or nil, and a bool indicating whether the key was found
Get(key string) (interface{}, bool)
// Add an item to the cache, replacing any existing item, using the default expiration
Set(key string, value interface{})
}
Cache represents a simple data cache
func NewCache ¶
func NewCache(config config.CacheConfig) *Cache
NewCache creates a new caching.Cache
Click to show internal directories.
Click to hide internal directories.