Go\Core\CachedAspectLoader::saveToCache PHP Method

saveToCache() protected method

Save pointcuts and advisors to the file
protected saveToCache ( array | Go\Aop\Pointcut[] | Go\Aop\Advisor[] $items, string $fileName )
$items array | Go\Aop\Pointcut[] | Go\Aop\Advisor[] List of items to store
$fileName string Name of the file with cache
    protected function saveToCache($items, $fileName)
    {
        $content = serialize($items);
        $directoryName = dirname($fileName);
        if (!is_dir($directoryName)) {
            mkdir($directoryName, $this->cacheFileMode, true);
        }
        file_put_contents($fileName, $content, LOCK_EX);
        // For cache files we don't want executable bits by default
        chmod($fileName, $this->cacheFileMode & ~0111);
    }