Loads data from the cache.

@param string $entryIdentifier An identifier which describes the cache entry to load
@return mixed The cache entry's content as a string or false if the cache entry could not be loaded
@api
555468
public function get(string $entryIdentifier)
    {
        return $this->uncompress($this->redis->get($this->buildKey('entry:' . $entryIdentifier)));
    }
906177
public function isLoaded($identifier)
    {
        $user = $this->getObject('user');

        // Find the user id
        if (!is_numeric($identifier))
        {
            if(!$identifier = JUserHelper::getUserId($identifier)) {
                $identifier = 0;
            }
        }

        if($identifier == 0 || $user->getId() != $identifier) {
            $result = isset($this->_users[$identifier]);
        } else {
            $result = true;
        }

        return $result;
    }
1168325
public function remove(string $entryIdentifier): bool
    {
        if (!isset($this->entries[$entryIdentifier])) {
            return false;
        }
        unset($this->entries[$entryIdentifier]);
        foreach (array_keys($this->tagsAndEntries) as $tag) {
            if (isset($this->tagsAndEntries[$tag][$entryIdentifier])) {
                unset($this->tagsAndEntries[$tag][$entryIdentifier]);
            }
        }
        return true;
    }
965124
public function getClassTemplates(ObjectIdentifier $identifier)
    {
        $templates = array();

        //Identifier
        $component = $this->getObject('object.bootstrapper')
            ->getComponentIdentifier($identifier->package, $identifier->domain);

        //Fallback
        if($namespaces = $this->getIdentifierNamespaces($component))
        {
            foreach($namespaces as $namespace)
            {
                //Handle class prefix vs class namespace
                if(strpos($namespace, '\\')) {
                    $namespace .= '\\';
                }

                $templates[] = $namespace.'<Class>';
                $templates[] = $namespace.'<Package><Path><File>';
            }
        }

        $templates = array_merge($templates, parent::getClassTemplates($identifier));

        return $templates;
    }
208337
public function requireOnce(string $entryIdentifier)
    {
        $pathAndFilename = $this->cacheDirectory . $entryIdentifier . $this->cacheEntryFileExtension;
        if ($entryIdentifier !== basename($entryIdentifier)) {
            throw new \InvalidArgumentException('The specified entry identifier (' . $entryIdentifier . ') must not contain a path segment.', 1282073036);
        }

        if (is_file($pathAndFilename)) {
            return include_once($pathAndFilename);
        }
        return false;
    }
191824
public function fetch($identifier, $lazyload = false)
    {
        $identifiers = array_merge((array) $identifier, $this->_fetch);

        //Only fetch identifiers that haven't been loaded yet.
        foreach($identifiers as $key => $value)
        {
            if($this->isLoaded($value)) {
                unset($identifiers[$key]);
            }
        }

        if(!empty($identifiers))
        {
            if (!$lazyload)
            {
                if (!is_numeric($identifiers[0])) {
                    $users = $this->getModel()->email($identifiers)->fetch();
                } else {
                    $users = $this->getModel()->id($identifiers)->fetch();
                }

                if(count($users))
                {
                    foreach($users as $user) {
                        $this->setUser($user);
                    }

                    return true;
                }
            }
            else $this->_fetch = $identifiers;
        }

        return false;
    }
762479
public function has(string $entryIdentifier): bool
    {
        $this->connect();

        $statementHandle = $this->databaseHandle->prepare('SELECT COUNT("identifier") FROM "' . $this->cacheTableName . '" WHERE "identifier"=? AND "context"=? AND "cache"=?' . $this->getNotExpiredStatement());
        $statementHandle->execute([$entryIdentifier, $this->context(), $this->cacheIdentifier]);
        return ($statementHandle->fetchColumn() > 0);
    }
638253
protected function cacheViaTrait(string $entryIdentifier, callable $callback, string $cacheIdentifier, int $lifetime = 0, array $tags = [])
    {
        try {
            /** @var AbstractFrontend $cache */
            $cache = GeneralUtility::makeInstance(CacheManager::class)->getCache($cacheIdentifier);
        } catch (\Exception $ex) {
            $logger = GeneralUtility::makeInstance(LogManager::class)->getLogger(__CLASS__);
            $logger->error($ex->getMessage(), ['entryIdentifier' => $entryIdentifier, 'cacheIdentifier' => $cacheIdentifier]);

            return \call_user_func_array($callback, []);
        }

        // Do not use "has" because the cache is a shared resource
        $result = $cache->get($entryIdentifier);
        if (false !== $result) {
            return $result;
        }
        $result = \call_user_func_array($callback, []);
        $cache->set($entryIdentifier, $result, $tags, 0 === $lifetime ? null : $lifetime);

        return $result;
    }
1077009
public function has(string $entryIdentifier): bool
    {
        return $this->memcache->get($this->identifierPrefix . $entryIdentifier) !== false;
    }
1096632
public function parsePageAsync( PageIdentifier $pageIdentifier ) {
		$params = [];
		if ( $pageIdentifier->getId() !== null ) {
			$params['pageid'] = $pageIdentifier->getId();
		} elseif ( $pageIdentifier->getTitle() !== null ) {
			$params['page'] = $pageIdentifier->getTitle()->getText();
		} else {
			throw new \RuntimeException( 'No way to identify page' );
		}

		$promise = $this->api->getRequestAsync( new SimpleRequest( 'parse', $params ) );

		return $promise->then( function ( $result ) {
			return $result['parse'];
		} );
	}
125518
protected function addIdentifierToTags(string $entryIdentifier, array $tags)
    {
        foreach ($tags as $tag) {
            // Update tag-to-identifier index
            $identifiers = $this->findIdentifiersByTag($tag);
            if (array_search($entryIdentifier, $identifiers) === false) {
                $identifiers[] = $entryIdentifier;
                $this->memcache->set($this->identifierPrefix . 'tag_' . $tag, $identifiers);
            }

            // Update identifier-to-tag index
            $existingTags = $this->findTagsByIdentifier($entryIdentifier);
            if (array_search($tag, $existingTags) === false) {
                $this->memcache->set($this->identifierPrefix . 'ident_' . $entryIdentifier, array_merge($existingTags, $tags));
            }
        }
    }
961722
public function loadSectionDataByIdentifier($identifier)
    {
        try {
            return $this->innerGateway->loadSectionDataByIdentifier($identifier);
        } catch (DBALException $e) {
            throw new RuntimeException('Database error', 0, $e);
        } catch (PDOException $e) {
            throw new RuntimeException('Database error', 0, $e);
        }
    }
485231
public function getByIdentifier(Identifier $identifier)
    {
        $className = $identifier->class->getName();
        $mapId     = $identifier->getSerialized();

        return $this->identityMap[$className][$mapId];
    }
876824
public function get(string $entryIdentifier)
    {
        $value = $this->memcache->get($this->identifierPrefix . $entryIdentifier);
        if (substr($value, 0, 13) === 'Flow*chunked:') {
            list(, $chunkCount) = explode(':', $value);
            $value = '';
            for ($chunkNumber = 1; $chunkNumber < $chunkCount; $chunkNumber++) {
                $value .= $this->memcache->get($this->identifierPrefix . $entryIdentifier . '_chunk_' . $chunkNumber);
            }
        }
        return $value;
    }
365568
public function has(string $entryIdentifier): bool
    {
        if ($entryIdentifier !== basename($entryIdentifier)) {
            throw new \InvalidArgumentException('The specified entry identifier must not contain a path segment.', 1334756878);
        }
        return file_exists($this->cacheDirectory . $entryIdentifier . $this->cacheEntryFileExtension);
    }
1158630
public function loadGroupDataByIdentifier($identifier)
    {
        $q = $this->createGroupLoadQuery();
        $q->where(
            $q->expr->eq(
                $this->dbHandler->quoteColumn('name'),
                $q->bindValue($identifier, null, \PDO::PARAM_STR)
            )
        );
        $stmt = $q->prepare();
        $stmt->execute();

        return $stmt->fetchAll(\PDO::FETCH_ASSOC);
    }
289606
public function parseIdentifier(ObjectIdentifier $identifier)
    {
        $info = parent::parseIdentifier($identifier);

        $path  = $identifier->path;

        //Allow locating default classes if $path is empty.
        if(empty($path))
        {
            $info['path']    = $info['file'];
            $info['file']    = '';
            $info['package'] = '';
        }
        else
        {
            $package = array_shift($path);

            $info['path']    = StringInflector::implode($path);
            $info['package'] = ucfirst($package);
        }

        //Make an exception for 'view' and 'module' types
        if(in_array($info['package'], array('View','Module')) && !in_array('behavior', $path)) {
            $info['path'] = '';
        }

        return $info;
    }