|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.aop.support.MethodMatchers
public abstract class MethodMatchers
Static utility methods for composing
MethodMatchers
.
A MethodMatcher may be evaluated statically (based on method and target class) or need further evaluation dynamically (based on arguments at the time of method invocation).
ClassFilters
,
Pointcuts
Nested Class Summary | |
---|---|
private static class |
MethodMatchers.ClassFilterAwareUnionMethodMatcher
MethodMatcher implementation for a union of two given MethodMatchers, supporting an associated ClassFilter per MethodMatcher. |
private static class |
MethodMatchers.IntersectionMethodMatcher
MethodMatcher implementation for an intersection of two given MethodMatchers. |
private static class |
MethodMatchers.UnionMethodMatcher
MethodMatcher implementation for a union of two given MethodMatchers. |
Constructor Summary | |
---|---|
MethodMatchers()
|
Method Summary | |
---|---|
static MethodMatcher |
intersection(MethodMatcher mm1,
MethodMatcher mm2)
Match all methods that both of the given MethodMatchers match. |
static boolean |
matches(MethodMatcher mm,
java.lang.reflect.Method method,
java.lang.Class targetClass,
boolean hasIntroductions)
Apply the given MethodMatcher to the given Method, supporting an IntroductionAwareMethodMatcher
(if applicable). |
(package private) static MethodMatcher |
union(MethodMatcher mm1,
ClassFilter cf1,
MethodMatcher mm2,
ClassFilter cf2)
Match all methods that either (or both) of the given MethodMatchers matches. |
static MethodMatcher |
union(MethodMatcher mm1,
MethodMatcher mm2)
Match all methods that either (or both) of the given MethodMatchers matches. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MethodMatchers()
Method Detail |
---|
public static MethodMatcher union(MethodMatcher mm1, MethodMatcher mm2)
mm1
- the first MethodMatchermm2
- the second MethodMatcher
static MethodMatcher union(MethodMatcher mm1, ClassFilter cf1, MethodMatcher mm2, ClassFilter cf2)
mm1
- the first MethodMatchercf1
- the corresponding ClassFilter for the first MethodMatchermm2
- the second MethodMatchercf2
- the corresponding ClassFilter for the second MethodMatcher
public static MethodMatcher intersection(MethodMatcher mm1, MethodMatcher mm2)
mm1
- the first MethodMatchermm2
- the second MethodMatcher
public static boolean matches(MethodMatcher mm, java.lang.reflect.Method method, java.lang.Class targetClass, boolean hasIntroductions)
IntroductionAwareMethodMatcher
(if applicable).
mm
- the MethodMatcher to apply (may be an IntroductionAwareMethodMatcher)method
- the candidate methodtargetClass
- the target class (may be null
, in which case
the candidate class must be taken to be the method's declaring class)hasIntroductions
- true
if the object on whose behalf we are
asking is the subject on one or more introductions; false
otherwise
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |