Подключение файлового кеширования конфигураций.
@param string $cacheDirectory
359415
public function enableFileCaching($cacheDirectory)
    {
        $this->cacheStack[] = ['name' => 'files', 'class' => new FileCache($cacheDirectory)];
        $this->cacheDepth = count($this->cacheStack);
    }
359718
private function generateTemplateMapper($cacheDir)
    {
        $files = $this->templateUtil->getAllTemplates();

        if (empty($files)) {
            return;
        }

        $this->filesystem->dumpFile(
            $cacheDir.'/contao/config/twig-templates.php',
            sprintf("<?php\n\nreturn %s;\n", var_export($files, true))
        );
    }
77975
public function setCacheDir($dir)
    {
        $this->cacheDir = rtrim($dir, '/\\') . DIRECTORY_SEPARATOR;
        if (!file_exists($this->cacheDir)) {
            mkdir($this->cacheDir, 0777, true);
        }
        if (is_writable($this->cacheDir) === false) {
            throw new Exception('The cache directory must be writable, chmod "' . $this->cacheDir . '" to make it writable');
        }
    }
621161
public function clear($commandKey, $cacheKey)
    {
        if ($this->exists($commandKey, $cacheKey)) {
            unset($this->cachedResults[$commandKey][$cacheKey]);
        }
    }
327300
public function warmUp($cacheDir)
    {
        if (null === $this->finder) {
            return;
        }

        $twig = $this->container->get('twig');

        $templates = $this->finder->findAllTemplates();

        foreach ($this->paths as $path => $namespace) {
            $templates = array_merge($templates, $this->findTemplatesInFolder($namespace, $path));
        }

        foreach ($templates as $template) {
            try {
                $twig->loadTemplate($template);
            } catch (Error $e) {
                // problem during compilation, give up
            }
        }
    }
517527
public function addCache(CacheInterface $cache)
    {
        $this->cacheMap[$cache->getName()] = $cache;
        $this->cacheNames[]                = $cache->getName();
    }
1198875
public function storeCache(array $cache)
    {
        if ($this->store === null) {
            register_shutdown_function([$this, 'saveCacheFile']);
        }

        $this->store = $cache;
    }
1099323
public function generateAllCacheTree($cacheDir)
    {
        $this->cacheDir = $cacheDir;

        $tables = $this->database->listTables();

        foreach ($tables as $table) {
            // trigger loadDataContainer TL_HOOK
            System::getContainer()->get('huh.utils.dca')->loadDc($table);
        }
    }
721553
public function setDirectory(Directory $directory)
    {
        $this->directory = $directory;
        $this->iterator = new \ArrayIterator($directory->children());
    }
831006
protected function deleteCacheEntries() {

		if(($cachePath = $this->folder->getCachePath(TRUE))) {

			$di	= new \DirectoryIterator($cachePath);

			foreach($di as $fileinfo) {
				if(	$fileinfo->isDot() ||
					!$fileinfo->isFile() ||
					strpos($fileinfo->getFilename(), $this->filename) !== 0
				) {
					continue;
				}

				unlink($fileinfo->getRealPath());
			}
		}
	}
1334215
public function warmUp($cacheDir)
    {
        if (false === is_dir($this->assetsDir)) {
            return;
        }

        $finder = new Finder();
        $finder->files()->in($this->assetsDir);

        $result = [];

        /** @var SplFileInfo $file */
        foreach ($finder as $file) {
            $cannonicalName = $file->getRelativePathname();

            $result[$cannonicalName] = $this->versioningScheme->getVersion('/' . $cannonicalName);
        }

        $cacheDir = sprintf($cacheDir . '/' . $this->cacheName);
        $this->writeCacheFile($cacheDir, sprintf('<?php return %s;', var_export($result, true)));

    }
745311
public function setCachePath($cachePath='')
    {
        if ($this->cache) {
            if (empty($cachePath)) {
                $this->cachePath = $this->templatesPath.'cache/';
            } else {
                $this->cachePath = $cachePath;
            }
            if (!is_readable($this->cachePath) || !is_writeable($this->cachePath)) {
                $this->error("Template Cache Path ({$this->cachePath}) does not exist or is not readable & writeable.");
            }
        } else {
            $this->cachePath = null;
        }
    }
973751
def cache(cache_directory_path):
    """"""
    if not cache_directory_path:
        click.secho(dtool_config.utils.get_cache(
            CONFIG_PATH,
        ))
    else:
        click.secho(dtool_config.utils.set_cache(
            CONFIG_PATH,
            cache_directory_path
        ))
729067
function resetCache()
    {
        if ( $this->CacheFile && file_exists( $this->CacheFile ) )
            unlink( $this->CacheFile );
        if ( $this->PlacementCacheFile && file_exists( $this->PlacementCacheFile ) )
            unlink( $this->PlacementCacheFile );
    }
128958
protected function setManifestDirectory(string $manifestDirectory)
    {
        $this->manifest->directory = $manifestDirectory;
        $this->hotModuleReplacement->directory = $manifestDirectory;    
    }
1187565
public function flushCache()
    {
        $iterator = new \DirectoryIterator($this->getConfig('cache_folder'));

        foreach ($iterator as $file) {
            if (! $file->isDot()) {
                unlink($file->getPathname());
            }
        }
    }
1264418
private function getDirectoryAndFilenameFromKey($cacheKey) {

        if (!is_array($cacheKey)) {
            $cacheKey = array($cacheKey);
        }

        $filename = array_pop($cacheKey);
        $dir = $this->cacheBaseDir . "/" . join("/", $cacheKey);


        // Return dir and filename
        return array($dir, $filename);

    }