PHP Class Fenos\Notifynder\Translator\Compiler

Cache compiler for translations I got part of the code from the view compiler of laravel :)
Datei anzeigen Open project: fenos/notifynder Class Usage Examples

Protected Properties

Property Type Description
$files Illuminate\Filesystem\Filesystem The Filesystem instance.

Public Methods

Method Description
__construct ( Illuminate\Contracts\Filesystem\Filesystem $files ) Create a new compiler instance.
cacheFile ( array $contents ) : boolean | integer Cache the file in json format.
getCompiledPath ( string $filename ) : string Get the path to the compiled version of a view.
getFilePath ( ) : string Get cached file.
isExpired ( ) : boolean Determine if the view at the given path is expired.

Protected Methods

Method Description
cachePath ( ) : string Get cache path.

Method Details

__construct() public method

Create a new compiler instance.
public __construct ( Illuminate\Contracts\Filesystem\Filesystem $files )
$files Illuminate\Contracts\Filesystem\Filesystem

cacheFile() public method

Cache the file in json format.
public cacheFile ( array $contents ) : boolean | integer
$contents array
return boolean | integer

cachePath() protected method

Get cache path.
protected cachePath ( ) : string
return string

getCompiledPath() public method

Get the path to the compiled version of a view.
public getCompiledPath ( string $filename ) : string
$filename string
return string

getFilePath() public method

Get cached file.
public getFilePath ( ) : string
return string

isExpired() public method

Determine if the view at the given path is expired.
public isExpired ( ) : boolean
return boolean

Property Details

$files protected_oe property

The Filesystem instance.
protected Filesystem,Illuminate\Filesystem $files
return Illuminate\Filesystem\Filesystem