TaggedCache
class TaggedCache extends Repository (View source)
Traits
Methods
Dynamically handle calls to the class.
Dynamically handle calls to the class.
Retrieve an item from the cache by key.
Retrieve an item from the cache and delete it.
Store multiple items in the cache for a given number of minutes.
Store an item in the cache if the key does not exist.
Get an item from the cache, or store the default value.
Get an item from the cache, or store the default value forever.
Get an item from the cache, or store the default value forever.
Begin executing a new tags operation if the store supports it.
Store an item in the cache for the default time.
Increment the value of an item in the cache.
Increment the value of an item in the cache.
Remove all items from the cache.
Get a fully qualified key for a tagged item.
Details
static
mixed
__callStatic(
string $method,
array $parameters)
Dynamically handle calls to the class.
in Repository at line line 59
void
setEventDispatcher(
Dispatcher $events)
Set the event dispatcher instance.
in Repository at line line 123
mixed
get(
string $key,
mixed $default = null)
Retrieve an item from the cache by key.
in RetrievesMultipleKeys at line line 15
array
many(
array $keys)
Retrieve multiple items from the cache by key.
Items not found in the cache will have a null value.
in Repository at line line 180
mixed
pull(
string $key,
mixed $default = null)
Retrieve an item from the cache and delete it.
in Repository at line line 197
void
put(
string $key,
mixed $value,
DateTime|int $minutes = null)
Store an item in the cache.
in RetrievesMultipleKeys at line line 33
void
putMany(
array $values,
int $minutes)
Store multiple items in the cache for a given number of minutes.
in Repository at line line 240
bool
add(
string $key,
mixed $value,
DateTime|int $minutes)
Store an item in the cache if the key does not exist.
in Repository at line line 268
void
forever(
string $key,
mixed $value)
Store an item in the cache indefinitely.
in Repository at line line 283
mixed
remember(
string $key,
DateTime|int $minutes,
Closure $callback)
Get an item from the cache, or store the default value.
in Repository at line line 304
mixed
sear(
string $key,
Closure $callback)
Get an item from the cache, or store the default value forever.
in Repository at line line 316
mixed
rememberForever(
string $key,
Closure $callback)
Get an item from the cache, or store the default value forever.
in Repository at line line 353
TaggedCache
tags(
array|mixed $names)
Begin executing a new tags operation if the store supports it.
in Repository at line line 397
void
setDefaultCacheTime(
int $minutes)
Set the default cache time in minutes.
in Repository at line line 429
mixed
offsetGet(
string $key)
Retrieve an item from the cache by key.
in Repository at line line 441
void
offsetSet(
string $key,
mixed $value)
Store an item in the cache for the default time.
at line line 49
void
increment(
string $key,
mixed $value = 1)
Increment the value of an item in the cache.
at line line 61
void
decrement(
string $key,
mixed $value = 1)
Increment the value of an item in the cache.