CachePool
class CachePool extends CachePool (View source)
Extended PSR cache pool to include security context hash into cache key
Constants
PATTERN_ENTRYIDENTIFIER |
Pattern an entry identifier must match. |
Properties
protected BackendInterface | $backend | from CachePool | |
protected string | $identifier | An identifier for this cache, useful if you use several different caches. |
from CachePool |
protected array | $deferredItems | A list of items still to be persisted. |
from CachePool |
protected | $securityContext |
Methods
Returns a Cache Item representing the specified key.
Confirms if the cache contains specified cache item.
Removes the item from the pool.
Persists a cache item immediately.
Checks the validity of an entry identifier. Returns true if it's valid.
No description
Details
__construct(string $identifier, BackendInterface $backend)
Constructs the cache
CacheItemInterface
getItem(string $key)
Returns a Cache Item representing the specified key.
iterable
getItems(array $keys = [])
Returns a traversable set of cache items.
bool
hasItem(string $key)
Confirms if the cache contains specified cache item.
bool
clear()
Deletes all items in the pool.
bool
deleteItem(string $key)
Removes the item from the pool.
bool
deleteItems(array $keys)
Removes multiple items from the pool.
bool
save(CacheItemInterface $item)
Persists a cache item immediately.
bool
saveDeferred(CacheItemInterface $item)
Sets a cache item to be persisted later.
bool
commit()
Persists any deferred cache items.
bool
isValidEntryIdentifier(string $identifier)
Checks the validity of an entry identifier. Returns true if it's valid.
protected string
enrichCacheItemKey(string $key)
No description