|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.aop.aspectj.annotation.AbstractAspectJAdvisorFactory
public abstract class AbstractAspectJAdvisorFactory
Abstract base class for factories that can create Spring AOP Advisors given AspectJ classes from classes honoring the AspectJ 5 annotation syntax.
This class handles annotation parsing and validation functionality. It does not actually generate Spring AOP Advisors, which is deferred to subclasses.
Nested Class Summary | |
---|---|
protected static class |
AbstractAspectJAdvisorFactory.AspectJAnnotation<A extends Annotation>
Class modelling an AspectJ annotation, exposing its type enumeration and pointcut String. |
protected static class |
AbstractAspectJAdvisorFactory.AspectJAnnotationType
|
Field Summary | |
---|---|
protected static ParameterNameDiscoverer |
ASPECTJ_ANNOTATION_PARAMETER_NAME_DISCOVERER
|
protected Log |
logger
Logger available to subclasses |
protected ParameterNameDiscoverer |
parameterNameDiscoverer
|
Constructor Summary | |
---|---|
protected |
AbstractAspectJAdvisorFactory()
|
Method Summary | |
---|---|
protected AspectJExpressionPointcut |
createPointcutExpression(Method annotatedMethod,
Class declarationScope,
String[] pointcutParameterNames)
The pointcut and advice annotations both have an "argNames" member which contains a comma-separated list of the argument names. |
protected static AbstractAspectJAdvisorFactory.AspectJAnnotation |
findAspectJAnnotationOnMethod(Method aMethod)
Find and return the first AspectJ annotation on the given method (there should only be one anyway...) |
boolean |
isAspect(Class<?> clazz)
Return whether or not the given class is an aspect, as reported by AspectJ's AJTypeSystem. |
void |
validate(Class<?> aspectClass)
Is the given class a valid aspect class? |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.springframework.aop.aspectj.annotation.AspectJAdvisorFactory |
---|
getAdvice, getAdvisor, getAdvisors |
Field Detail |
---|
protected static final ParameterNameDiscoverer ASPECTJ_ANNOTATION_PARAMETER_NAME_DISCOVERER
protected final Log logger
protected final ParameterNameDiscoverer parameterNameDiscoverer
Constructor Detail |
---|
protected AbstractAspectJAdvisorFactory()
Method Detail |
---|
protected static AbstractAspectJAdvisorFactory.AspectJAnnotation findAspectJAnnotationOnMethod(Method aMethod)
public boolean isAspect(Class<?> clazz)
AspectJAdvisorFactory
isAspect
in interface AspectJAdvisorFactory
clazz
- supposed annotation-style AspectJ class
public void validate(Class<?> aspectClass) throws AopConfigException
AspectJAdvisorFactory
validate
in interface AspectJAdvisorFactory
aspectClass
- supposed AspectJ annotation-style class
to validate
AopConfigException
- if the class is an invalid aspect
(which can never be legal)
NotAnAtAspectException
- if the class is not an aspect at all
(which may or may be legal, depending on the context)protected AspectJExpressionPointcut createPointcutExpression(Method annotatedMethod, Class declarationScope, String[] pointcutParameterNames)
|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |