public function MemoryCacheFactory::get in Apigee Edge 8
Gets a memory cache backend class for a given cache bin.
Parameters
string $bin: The cache bin for which a cache backend object should be returned.
Return value
\Drupal\Core\Cache\MemoryCache\MemoryCacheInterface The memory cache backend object associated with the specified bin.
Overrides MemoryCacheFactoryInterface::get
File
- src/
MemoryCacheFactory.php, line 65
Class
- MemoryCacheFactory
- Definition of the Apigee Edge memory cache factory service.
Namespace
Drupal\apigee_edgeCode
public function get($bin) : MemoryCacheInterface {
$bin = "{$this->prefix}_{$bin}";
if (!isset($this->bins[$bin])) {
$this->bins[$bin] = new MemoryCache();
}
return $this->bins[$bin];
}