UseCacheBackendTrait
trait UseCacheBackendTrait (View source)
Provides methods to use a cache backend while respecting a 'use caches' flag.
Properties
| protected CacheBackendInterface | $cacheBackend | Cache backend instance. |
|
| protected bool | $useCaches | Flag whether caches should be used or skipped. |
Methods
object|false
cacheGet(string $cid)
Fetches from the cache backend, respecting the use caches flag.
cacheSet(string $cid, mixed $data, int $expire = Cache::PERMANENT, array $tags = [])
Stores data in the persistent cache, respecting the use caches flag.
Details
protected object|false
cacheGet(string $cid)
Fetches from the cache backend, respecting the use caches flag.
protected
cacheSet(string $cid, mixed $data, int $expire = Cache::PERMANENT, array $tags = [])
Stores data in the persistent cache, respecting the use caches flag.