Documentation ¶
Index ¶
- Constants
- Variables
- type Lock
- type Redis
- func (r *Redis) Add(key string, value any, t time.Duration) bool
- func (r *Redis) Decrement(key string, value ...int) (int, error)
- func (r *Redis) Flush() bool
- func (r *Redis) Forever(key string, value any) bool
- func (r *Redis) Forget(key string) bool
- func (r *Redis) Get(key string, def ...any) any
- func (r *Redis) GetBool(key string, def ...bool) bool
- func (r *Redis) GetInt(key string, def ...int) int
- func (r *Redis) GetInt64(key string, def ...int64) int64
- func (r *Redis) GetString(key string, def ...string) string
- func (r *Redis) Has(key string) bool
- func (r *Redis) Increment(key string, value ...int) (int, error)
- func (r *Redis) Lock(key string, t ...time.Duration) cache.Lock
- func (r *Redis) Pull(key string, def ...any) any
- func (r *Redis) Put(key string, value any, t time.Duration) error
- func (r *Redis) Remember(key string, seconds time.Duration, callback func() (any, error)) (any, error)
- func (r *Redis) RememberForever(key string, callback func() (any, error)) (any, error)
- func (r *Redis) WithContext(ctx context.Context) cache.Driver
- type ServiceProvider
Constants ¶
View Source
const Binding = "goravel.redis"
View Source
const NoExpiration time.Duration = 0
Variables ¶
View Source
var App foundation.Application
Functions ¶
This section is empty.
Types ¶
type Lock ¶
type Lock struct {
// contains filtered or unexported fields
}
func (*Lock) ForceRelease ¶
type Redis ¶
type Redis struct {
// contains filtered or unexported fields
}
func (*Redis) Remember ¶
func (r *Redis) Remember(key string, seconds time.Duration, callback func() (any, error)) (any, error)
Remember Get an item from the cache, or execute the given Closure and store the result.
func (*Redis) RememberForever ¶
RememberForever Get an item from the cache, or execute the given Closure and store the result forever.
type ServiceProvider ¶
type ServiceProvider struct { }
func (*ServiceProvider) Boot ¶
func (receiver *ServiceProvider) Boot(app foundation.Application)
func (*ServiceProvider) Register ¶
func (receiver *ServiceProvider) Register(app foundation.Application)
Click to show internal directories.
Click to hide internal directories.