| Methods |
public
|
get(string $key): mixed
Retrieve an item from the cache by key.
Retrieve an item from the cache by key.
|
#
|
public
|
many(array $keys): array
Retrieve multiple items from the cache by key.
Retrieve multiple items from the cache by key.
Items not found in the cache will have a null value.
|
#
|
public
|
put(string $key, mixed $value, int $seconds): bool
Store an item in the cache for a given number of seconds.
Store an item in the cache for a given number of seconds.
|
#
|
public
|
putMany(array $values, int $seconds): bool
Store multiple items in the cache for a given number of seconds.
Store multiple items in the cache for a given number of seconds.
|
#
|
public
|
increment(string $key, mixed $value = 1): int|bool
Increment the value of an item in the cache.
Increment the value of an item in the cache.
|
#
|
public
|
decrement(string $key, mixed $value = 1): int|bool
Decrement the value of an item in the cache.
Decrement the value of an item in the cache.
|
#
|
public
|
forever(string $key, mixed $value): bool
Store an item in the cache indefinitely.
Store an item in the cache indefinitely.
|
#
|
public
|
forget(string $key): bool
Remove an item from the cache.
Remove an item from the cache.
|
#
|
public
|
flush(): bool
Remove all items from the cache.
Remove all items from the cache.
|
#
|
public
|
getPrefix(): string
Get the cache key prefix.
Get the cache key prefix.
|
#
|