PHP Class Go\Core\CachedAspectLoader

Inheritance: extends AspectLoader
Datei anzeigen Open project: goaop/framework

Protected Properties

Property Type Description
$cacheDir null | string Path to the cache directory
$cacheFileMode integer File mode for the cache files
$loaderId string Identifier of original loader

Public Methods

Method Description
__construct ( Go\Core\AspectContainer $container, string $loaderId, array $options = [] ) Cached loader constructor
__get ( $name )
load ( Go\Aop\Aspect $aspect )
registerLoaderExtension ( Go\Core\AspectLoaderExtension $loader )

Protected Methods

Method Description
loadFromCache ( string $fileName ) : array | Go\Aop\Pointcut[] | Go\Aop\Advisor[] Loads pointcuts and advisors from the file
saveToCache ( array | Go\Aop\Pointcut[] | Go\Aop\Advisor[] $items, string $fileName ) Save pointcuts and advisors to the file

Method Details

__construct() public method

Cached loader constructor
public __construct ( Go\Core\AspectContainer $container, string $loaderId, array $options = [] )
$container Go\Core\AspectContainer Instance of container
$loaderId string Original loader identifier
$options array List of kernel options

__get() public method

public __get ( $name )

load() public method

public load ( Go\Aop\Aspect $aspect )
$aspect Go\Aop\Aspect

loadFromCache() protected method

Loads pointcuts and advisors from the file
protected loadFromCache ( string $fileName ) : array | Go\Aop\Pointcut[] | Go\Aop\Advisor[]
$fileName string Name of the file with cache
return array | Go\Aop\Pointcut[] | Go\Aop\Advisor[]

registerLoaderExtension() public method

public registerLoaderExtension ( Go\Core\AspectLoaderExtension $loader )
$loader Go\Core\AspectLoaderExtension

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

Property Details

$cacheDir protected_oe property

Path to the cache directory
protected null|string $cacheDir
return null | string

$cacheFileMode protected_oe property

File mode for the cache files
protected int $cacheFileMode
return integer

$loaderId protected_oe property

Identifier of original loader
protected string $loaderId
return string