Documentation ¶
Index ¶
- type Cache
- func (c *Cache) Clear() error
- func (c *Cache) Do(key string, do func() (string, error), ttl time.Duration) (string, error)
- func (c *Cache) GetOrDo(key string, do func() (string, error), ttl time.Duration) (string, error)
- func (c *Cache) Put(key string, value string, ttl time.Duration) (string, error)
- type CacheEntry
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
Root string
}
func DefaultCache ¶
func DefaultCache() *Cache
type CacheEntry ¶
Click to show internal directories.
Click to hide internal directories.