PHP Class Neos\Flow\Aop\Pointcut\PointcutExpressionParser

Afficher le fichier Open project: neos/flow-development-collection Class Usage Examples

Protected Properties

Свойство Type Description
$objectManager Neos\Flow\ObjectManagement\ObjectManagerInterface
$proxyClassBuilder Neos\Flow\Aop\Builder\ProxyClassBuilder
$reflectionService Neos\Flow\Reflection\ReflectionService
$sourceHint string

Méthodes publiques

Méthode Description
injectObjectManager ( Neos\Flow\ObjectManagement\ObjectManagerInterface $objectManager ) : void
injectProxyClassBuilder ( ProxyClassBuilder $proxyClassBuilder ) : void
injectReflectionService ( ReflectionService $reflectionService ) : void
parse ( string $pointcutExpression, string $sourceHint ) : PointcutFilterComposite Parses a string pointcut expression and returns the pointcut objects accordingly

Méthodes protégées

Méthode Description
getArgumentConstraintsFromMethodArgumentsPattern ( string $methodArgumentsPattern ) : array Parses the method arguments pattern and returns the corresponding constraints array
getRuntimeEvaluationConditionsFromEvaluateString ( string $evaluateString ) : array Parses the evaluate string for runtime evaluations and returns the corresponding conditions array
getSubstringBetweenParentheses ( string $string ) : string Returns the substring of $string which is enclosed by parentheses of the first level.
getVisibilityFromSignaturePattern ( &$signaturePattern ) : string Parses the signature pattern and returns the visibility modifier if any. If a modifier was found, it will be removed from the $signaturePattern.
parseAnnotationPattern ( string &$annotationPattern, array &$annotationPropertyConstraints ) : void Parse an annotation pattern and adjust $annotationPattern and $annotationPropertyConstraints as needed.
parseDesignatorClass ( string $operator, string $classPattern, PointcutFilterComposite $pointcutFilterComposite ) : void Takes a class filter pattern and adds a so configured class filter to the filter composite object.
parseDesignatorClassAnnotatedWith ( string $operator, string $annotationPattern, PointcutFilterComposite $pointcutFilterComposite ) : void Takes a class annotation filter pattern and adds a so configured class annotation filter to the filter composite object.
parseDesignatorFilter ( string $operator, string $filterObjectName, PointcutFilterComposite $pointcutFilterComposite ) : void Adds a custom filter to the pointcut filter composite
parseDesignatorMethod ( string $operator, string $signaturePattern, PointcutFilterComposite $pointcutFilterComposite ) : void Splits the parameters of the pointcut designator "method" into a class and a method part and adds the appropriately configured filters to the filter composite object.
parseDesignatorMethodAnnotatedWith ( string $operator, string $annotationPattern, PointcutFilterComposite $pointcutFilterComposite ) : void Takes a method annotation filter pattern and adds a so configured method annotation filter to the filter composite object.
parseDesignatorPointcut ( string $operator, string $pointcutExpression, PointcutFilterComposite $pointcutFilterComposite ) : void Splits the value of the pointcut designator "pointcut" into an aspect class- and a pointcut method part and adds the appropriately configured filter to the composite object.
parseDesignatorSetting ( string $operator, string $configurationPath, PointcutFilterComposite $pointcutFilterComposite ) : void Adds a setting filter to the pointcut filter composite
parseDesignatorWithin ( string $operator, string $signaturePattern, PointcutFilterComposite $pointcutFilterComposite ) : void Adds a class type filter to the pointcut filter composite
parseRuntimeEvaluations ( string $operator, string $runtimeEvaluations, PointcutFilterComposite $pointcutFilterComposite ) : void Adds runtime evaluations to the pointcut filter composite

Method Details

getArgumentConstraintsFromMethodArgumentsPattern() protected méthode

Parses the method arguments pattern and returns the corresponding constraints array
protected getArgumentConstraintsFromMethodArgumentsPattern ( string $methodArgumentsPattern ) : array
$methodArgumentsPattern string The arguments pattern defined in the pointcut expression
Résultat array The corresponding constraints array

getRuntimeEvaluationConditionsFromEvaluateString() protected méthode

Parses the evaluate string for runtime evaluations and returns the corresponding conditions array
protected getRuntimeEvaluationConditionsFromEvaluateString ( string $evaluateString ) : array
$evaluateString string The evaluate string defined in the pointcut expression
Résultat array The corresponding constraints array

getSubstringBetweenParentheses() protected méthode

Returns the substring of $string which is enclosed by parentheses of the first level.
protected getSubstringBetweenParentheses ( string $string ) : string
$string string The string to parse
Résultat string The inner part between the first level of parentheses

getVisibilityFromSignaturePattern() protected méthode

Parses the signature pattern and returns the visibility modifier if any. If a modifier was found, it will be removed from the $signaturePattern.
protected getVisibilityFromSignaturePattern ( &$signaturePattern ) : string
Résultat string Visibility modifier or NULL of none was found

injectObjectManager() public méthode

public injectObjectManager ( Neos\Flow\ObjectManagement\ObjectManagerInterface $objectManager ) : void
$objectManager Neos\Flow\ObjectManagement\ObjectManagerInterface
Résultat void

injectProxyClassBuilder() public méthode

public injectProxyClassBuilder ( ProxyClassBuilder $proxyClassBuilder ) : void
$proxyClassBuilder Neos\Flow\Aop\Builder\ProxyClassBuilder
Résultat void

injectReflectionService() public méthode

public injectReflectionService ( ReflectionService $reflectionService ) : void
$reflectionService Neos\Flow\Reflection\ReflectionService
Résultat void

parse() public méthode

Parses a string pointcut expression and returns the pointcut objects accordingly
public parse ( string $pointcutExpression, string $sourceHint ) : PointcutFilterComposite
$pointcutExpression string The expression defining the pointcut
$sourceHint string A message giving a hint on where the expression was defined. This is used in error messages.
Résultat PointcutFilterComposite A composite of class-filters, method-filters and pointcuts

parseAnnotationPattern() protected méthode

Parse an annotation pattern and adjust $annotationPattern and $annotationPropertyConstraints as needed.
protected parseAnnotationPattern ( string &$annotationPattern, array &$annotationPropertyConstraints ) : void
$annotationPattern string
$annotationPropertyConstraints array
Résultat void

parseDesignatorClass() protected méthode

Takes a class filter pattern and adds a so configured class filter to the filter composite object.
protected parseDesignatorClass ( string $operator, string $classPattern, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$classPattern string The pattern expression as configuration for the class filter
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the class filter) will be added to this composite object.
Résultat void

parseDesignatorClassAnnotatedWith() protected méthode

Takes a class annotation filter pattern and adds a so configured class annotation filter to the filter composite object.
protected parseDesignatorClassAnnotatedWith ( string $operator, string $annotationPattern, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$annotationPattern string The pattern expression as configuration for the class annotation filter
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the class annotation filter) will be added to this composite object.
Résultat void

parseDesignatorFilter() protected méthode

Adds a custom filter to the pointcut filter composite
protected parseDesignatorFilter ( string $operator, string $filterObjectName, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$filterObjectName string Object Name of the custom filter (value of the designator)
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the custom filter) will be added to this composite object.
Résultat void

parseDesignatorMethod() protected méthode

Splits the parameters of the pointcut designator "method" into a class and a method part and adds the appropriately configured filters to the filter composite object.
protected parseDesignatorMethod ( string $operator, string $signaturePattern, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$signaturePattern string The pattern expression defining the class and method - the "signature"
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the class and method filter) will be added to this composite object.
Résultat void

parseDesignatorMethodAnnotatedWith() protected méthode

Takes a method annotation filter pattern and adds a so configured method annotation filter to the filter composite object.
protected parseDesignatorMethodAnnotatedWith ( string $operator, string $annotationPattern, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$annotationPattern string The pattern expression as configuration for the method annotation filter
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the method annotation filter) will be added to this composite object.
Résultat void

parseDesignatorPointcut() protected méthode

Splits the value of the pointcut designator "pointcut" into an aspect class- and a pointcut method part and adds the appropriately configured filter to the composite object.
protected parseDesignatorPointcut ( string $operator, string $pointcutExpression, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$pointcutExpression string The pointcut expression (value of the designator)
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the pointcut filter) will be added to this composite object.
Résultat void

parseDesignatorSetting() protected méthode

Adds a setting filter to the pointcut filter composite
protected parseDesignatorSetting ( string $operator, string $configurationPath, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$configurationPath string The path to the settings option, that should be used
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the custom filter) will be added to this composite object.
Résultat void

parseDesignatorWithin() protected méthode

Adds a class type filter to the pointcut filter composite
protected parseDesignatorWithin ( string $operator, string $signaturePattern, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string
$signaturePattern string The pattern expression defining the class type
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the class type filter) will be added to this composite object.
Résultat void

parseRuntimeEvaluations() protected méthode

Adds runtime evaluations to the pointcut filter composite
protected parseRuntimeEvaluations ( string $operator, string $runtimeEvaluations, PointcutFilterComposite $pointcutFilterComposite ) : void
$operator string The operator
$runtimeEvaluations string The runtime evaluations string
$pointcutFilterComposite PointcutFilterComposite An instance of the pointcut filter composite. The result (ie. the custom filter) will be added to this composite object.
Résultat void

Property Details

$objectManager protected_oe property

protected ObjectManagerInterface,Neos\Flow\ObjectManagement $objectManager
Résultat Neos\Flow\ObjectManagement\ObjectManagerInterface

$proxyClassBuilder protected_oe property

protected ProxyClassBuilder,Neos\Flow\Aop\Builder $proxyClassBuilder
Résultat Neos\Flow\Aop\Builder\ProxyClassBuilder

$reflectionService protected_oe property

protected ReflectionService,Neos\Flow\Reflection $reflectionService
Résultat Neos\Flow\Reflection\ReflectionService

$sourceHint protected_oe property

protected string $sourceHint
Résultat string