eZ\Publish\Core\Persistence\Cache\CacheServiceDecorator::getItem PHP Méthode

getItem() public méthode

{@see \Psr\Cache\CacheItemPoolInterface}
public getItem ( ) : Stash\Interfaces\ItemInterface
Résultat Stash\Interfaces\ItemInterface
    public function getItem()
    {
        $args = func_get_args();
        if (empty($args)) {
            return $this->cachePool->getItem(self::SPI_CACHE_KEY_PREFIX);
        }
        //  Upstream seems to no longer support array, so we flatten it
        if (!isset($args[1]) && is_array($args[0])) {
            $key = implode('/', array_map([$this, 'washKey'], $args[0]));
        } else {
            $key = '' . implode('/', array_map([$this, 'washKey'], $args));
        }
        $key = $key === '' ? self::SPI_CACHE_KEY_PREFIX : self::SPI_CACHE_KEY_PREFIX . '/' . $key;
        return $this->cachePool->getItem($key);
    }