Versions in this module Expand all Collapse all v0 v0.0.1 Jun 7, 2023 Changes in this version + type Cache interface + Store func(name string) Driver + type Driver interface + Add func(key string, value any, t time.Duration) bool + Decrement func(key string, value ...int) (int, error) + Flush func() bool + Forever func(key string, value any) bool + Forget func(key string) bool + Get func(key string, def ...any) any + GetBool func(key string, def ...bool) bool + GetInt func(key string, def ...int) int + GetInt64 func(key string, def ...int64) int64 + GetString func(key string, def ...string) string + Has func(key string) bool + Increment func(key string, value ...int) (int, error) + Lock func(key string, t ...time.Duration) Lock + Pull func(key string, def ...any) any + Put func(key string, value any, t time.Duration) error + Remember func(key string, ttl time.Duration, callback func() any) (any, error) + RememberForever func(key string, callback func() any) (any, error) + WithContext func(ctx context.Context) Driver + type Lock interface + Block func(t time.Duration, callback ...func()) bool + ForceRelease func() bool + Get func(callback ...func()) bool + Release func() bool