Neos\Cache\Backend\FileBackend::requireOnce PHP Метод

requireOnce() публичный Метод

Loads PHP code from the cache and require_onces it right away.
public requireOnce ( string $entryIdentifier ) : mixed
$entryIdentifier string An identifier which describes the cache entry to load
Результат mixed Potential return value from the include operation
    public function requireOnce($entryIdentifier)
    {
        if ($this->frozen === true) {
            if (isset($this->cacheEntryIdentifiers[$entryIdentifier])) {
                return require_once $this->cacheDirectory . $entryIdentifier . $this->cacheEntryFileExtension;
            } else {
                return false;
            }
        } else {
            $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);
            }
            return $this->isCacheFileExpired($pathAndFilename) ? false : (require_once $pathAndFilename);
        }
    }