|
The Spring Framework | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.aop.support.AbstractExpressionPointcut
org.springframework.aop.aspectj.AspectJExpressionPointcut
public class AspectJExpressionPointcut
Spring pointcut implementation that uses the AspectJ weaver.
The pointcut expression value is an AspectJ string. This can reference other pointcuts and use composition and other operations.
Naturally, as this is to be processed by Spring AOP's proxy-based model, only method execution pointcuts are supported.
| Field Summary |
|---|
| Fields inherited from interface org.springframework.aop.ClassFilter |
|---|
TRUE |
| Fields inherited from interface org.springframework.aop.Pointcut |
|---|
TRUE |
| Constructor Summary | |
|---|---|
AspectJExpressionPointcut()
Create a new default AspectJExpressionPointcut. |
|
AspectJExpressionPointcut(Class declarationScope,
String[] paramNames,
Class[] paramTypes)
Create a new AspectJExpressionPointcut with the given settings. |
|
AspectJExpressionPointcut(Set supportedPrimitives)
Create a new AspectJExpressionPointcut with the given supported primitives. |
|
| Method Summary | |
|---|---|
boolean |
equals(Object other)
|
ClassFilter |
getClassFilter()
Return the ClassFilter for this pointcut. |
MethodMatcher |
getMethodMatcher()
Return the MethodMatcher for this pointcut. |
org.aspectj.weaver.tools.PointcutExpression |
getPointcutExpression()
|
int |
hashCode()
|
boolean |
isRuntime()
Is this MethodMatcher dynamic? |
boolean |
matches(Class targetClass)
Should the pointcut apply to the given interface or target class? |
boolean |
matches(Method method,
Class targetClass)
Perform static checking. |
boolean |
matches(Method method,
Class targetClass,
boolean beanHasIntroductions)
Perform static checking. |
boolean |
matches(Method method,
Class targetClass,
Object[] args)
Is there a runtime (dynamic) match for this method, which must have matched statically. |
void |
setParameterNames(String[] names)
|
void |
setParameterTypes(Class[] types)
|
void |
setPointcutDeclarationScope(Class pointcutDeclarationScope)
|
String |
toString()
|
| Methods inherited from class org.springframework.aop.support.AbstractExpressionPointcut |
|---|
getExpression, getLocation, onSetExpression, setExpression, setLocation |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AspectJExpressionPointcut()
public AspectJExpressionPointcut(Set supportedPrimitives)
supportedPrimitives - Set of PointcutPrimitive
instances
public AspectJExpressionPointcut(Class declarationScope,
String[] paramNames,
Class[] paramTypes)
| Method Detail |
|---|
public void setPointcutDeclarationScope(Class pointcutDeclarationScope)
public void setParameterNames(String[] names)
public void setParameterTypes(Class[] types)
public ClassFilter getClassFilter()
Pointcut
getClassFilter in interface Pointcutpublic MethodMatcher getMethodMatcher()
Pointcut
getMethodMatcher in interface Pointcutpublic org.aspectj.weaver.tools.PointcutExpression getPointcutExpression()
public boolean matches(Class targetClass)
ClassFilter
matches in interface ClassFiltertargetClass - candidate target class
public boolean matches(Method method,
Class targetClass)
MethodMatcher
matches in interface MethodMatchermethod - the candidate methodtargetClass - target class (may be null, in which case the candidate
class must be taken to be the method's declaring class)
public boolean isRuntime()
MethodMatcherNote: Could be pulled up into a Matcher super-interface to apply to fields also.
isRuntime in interface MethodMatcher
public boolean matches(Method method,
Class targetClass,
boolean beanHasIntroductions)
IntroductionAwareMethodMatcher
matches in interface IntroductionAwareMethodMatchermethod - the candidate methodtargetClass - target class (may be null, in which case the candidate
class must be taken to be the method's declaring class)beanHasIntroductions - true if the bean on whose behalf we are asking is the
subject on one or more introductions, and false otherwise
public boolean matches(Method method,
Class targetClass,
Object[] args)
MethodMatcher
matches in interface MethodMatchermethod - the candidate methodtargetClass - target classargs - arguments to the method
MethodMatcher.matches(Method, Class)public boolean equals(Object other)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic String toString()
toString in class Object
|
The Spring Framework | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||