src/Functions/AbstractFunctions.php
protected function setLocalCache(FilesystemInterface $filesystem, string $absoluteFilePath, $content): FunctionsInterface
    {
        $this->set(
            'localCacheFilePath',
            $this->get('localCacheDirectory').'/'.
            sha1(Config::APPLICATION_KEY).'/'.
            sha1($absoluteFilePath).'.'.
            $this->getFileExtension($absoluteFilePath)
        );

        $filesystem->write($this->get('localCacheFilePath'), (string) $content);

        return $this;
    }
protected function setLocalCache(FilesystemInterface $filesystem, string $absoluteFilePath, $content): FunctionsInterface
    {
        $this->set(
            'localCacheFilePath',
            $this->get('localCacheDirectory').'/'.
            sha1(Config::APPLICATION_KEY).'/'.
            sha1($absoluteFilePath).'.'.
            $this->getFileExtension($absoluteFilePath)
        );

        $filesystem->write($this->get('localCacheFilePath'), (string) $content);

        return $this;
    }
protected function setLocalCache ( FilesystemInterface $ filesystem , string $ absoluteFilePath , $ content ) : FunctionsInterface { $ this -> set ( 'localCacheFilePath' , $ this -> get ( 'localCacheDirectory' ) . '/' . sha1 ( Config :: APPLICATION_KEY ) . '/' . sha1 ( $ absoluteFilePath ) . '.' . $ this -> getFileExtension ( $ absoluteFilePath ) ) ; $ filesystem -> write ( $ this -> get ( 'localCacheFilePath' ) , ( string ) $ content ) ; return $ this ; }
Cache a local file to disk.

@param FilesystemInterface             $filesystem       The FilesystemInterface
@param string                          $absoluteFilePath The absolute file path (e.g., the full unique filename)
@param TemplateFactoryInterface|string $content          The TemplateFactory Interface or a string-type

@return FunctionsInterface

@api
Cache a local file to disk .