PHP Class Go\Core\AdviceMatcher

Datei anzeigen Open project: goaop/framework Class Usage Examples

Protected Properties

Property Type Description
$loader AspectLoader Loader of aspects

Public Methods

Method Description
__construct ( AspectLoader $loader, boolean $isInterceptFunctions = false ) Constructor
getAdvicesForClass ( ReflectionClas\ReflectionClass $class, array $advisors ) : array | Go\Aop\Advice[] Return list of advices for class
getAdvicesForFunctions ( Go\ParserReflection\ReflectionFileNamespace $namespace, array $advisors ) : array Returns list of function advices for namespace

Private Methods

Method Description
getAdvicesFromAdvisor ( ReflectionClas\ReflectionClass $class, Go\Aop\PointcutAdvisor $advisor, string $advisorId, Go\Aop\PointFilter $filter ) : array Returns list of advices from advisor and point filter
getFunctionAdvicesFromAdvisor ( Go\ParserReflection\ReflectionFileNamespace $namespace, Go\Aop\PointcutAdvisor $advisor, string $advisorId, Go\Aop\PointFilter $pointcut ) : array Returns list of function advices for specific namespace
getIntroductionFromAdvisor ( ReflectionClas\ReflectionClass $class, Go\Aop\IntroductionAdvisor $advisor, string $advisorId ) : array Returns list of introduction advices from advisor

Method Details

__construct() public method

Constructor
public __construct ( AspectLoader $loader, boolean $isInterceptFunctions = false )
$loader AspectLoader Instance of aspect loader
$isInterceptFunctions boolean Optional flag to enable function interception

getAdvicesForClass() public method

Return list of advices for class
public getAdvicesForClass ( ReflectionClas\ReflectionClass $class, array $advisors ) : array | Go\Aop\Advice[]
$class ReflectionClas\ReflectionClass Class to advise
$advisors array List of advisor to match
return array | Go\Aop\Advice[] List of advices for class

getAdvicesForFunctions() public method

Returns list of function advices for namespace
public getAdvicesForFunctions ( Go\ParserReflection\ReflectionFileNamespace $namespace, array $advisors ) : array
$namespace Go\ParserReflection\ReflectionFileNamespace
$advisors array List of advisor to match
return array

Property Details

$loader protected_oe property

Loader of aspects
protected AspectLoader,Go\Core $loader
return AspectLoader