public CacheCollector::__construct($cid, CacheBackendInterface $cache, LockBackendInterface $lock, array $tags = array())
Constructs a CacheCollector object.
Parameters
string $cid: The cid for the array being cached.
\Drupal\Core\Cache\CacheBackendInterface $cache: The cache backend.
\Drupal\Core\Lock\LockBackendInterface $lock: The lock backend.
array $tags: (optional) The tags to specify for the cache item.
File
- core/lib/Drupal/Core/Cache/CacheCollector.php, line 113
Class
- CacheCollector
- Default implementation for CacheCollectorInterface.
Namespace
Drupal\Core\Cache
Code
public function __construct($cid, CacheBackendInterface $cache, LockBackendInterface $lock, array $tags = array()) { assert('\Drupal\Component\Assertion\Inspector::assertAllStrings($tags)', 'Cache tags must be strings.'); $this->cid = $cid; $this->cache = $cache; $this->tags = $tags; $this->lock = $lock; }
Please login to continue.