CacheStorage
class CacheStorage implements StorageContract
Constants
| private KEY_PREFIX |
Prefix that keeps blacklist keys apart from other cache keys. |
Properties
| protected string | $tag | ||
| protected bool | $writesThroughTags | Whether writes go through the blacklist tag so it can be flushed. |
|
| protected bool | $readsThroughTags | Whether reads and deletes go through the blacklist tag. |
Methods
Add a new item into storage.
Add a new item into storage forever.
Get an item from storage.
Remove an item from storage.
Remove all items associated with the tag.
Get the cache that blacklist writes go through.
Get the cache that blacklist reads and deletes go through.
Get the cache key for a logical blacklist key.
Details
at line 37
__construct(Repository $cache)
Create a new cache storage instance.
at line 51
bool
add(string $key, mixed $value, int $minutes)
Add a new item into storage.
at line 59
bool
forever(string $key, mixed $value)
Add a new item into storage forever.
at line 67
mixed
get(string $key)
Get an item from storage.
at line 75
bool
destroy(string $key)
Remove an item from storage.
at line 86
bool
flush()
Remove all items associated with the tag.
Only a store with tag support can clear the blacklist without removing other cache entries, so on any other store the cache's tags() call throws.
at line 95
protected Repository
writeCache()
Get the cache that blacklist writes go through.
at line 104
protected Repository
readCache()
Get the cache that blacklist reads and deletes go through.
at line 113
protected string
storageKey(string $key)
Get the cache key for a logical blacklist key.