类 AnnotationMatchingPointcut
- java.lang.Object
- org.springframework.aop.support.annotation.AnnotationMatchingPointcut
- 所有已实现的接口:
Pointcut
public class AnnotationMatchingPointcut extends Object implements Pointcut
- 从以下版本开始:
- 2.0
- 作者:
- Juergen Hoeller
- 另请参阅:
AnnotationClassFilter
,AnnotationMethodMatcher
构造器概要
构造器 构造器 说明 AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType)
Create a new AnnotationMatchingPointcut for the given annotation type.AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType, boolean checkInherited)
Create a new AnnotationMatchingPointcut for the given annotation type.AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType, Class<? extends Annotation> methodAnnotationType)
Create a new AnnotationMatchingPointcut for the given annotation types.
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 boolean
equals(Object other)
static AnnotationMatchingPointcut
forClassAnnotation(Class<? extends Annotation> annotationType)
Factory method for an AnnotationMatchingPointcut that matches for the specified annotation at the class level.static AnnotationMatchingPointcut
forMethodAnnotation(Class<? extends Annotation> annotationType)
Factory method for an AnnotationMatchingPointcut that matches for the specified annotation at the method level.ClassFilter
getClassFilter()
Return the ClassFilter for this pointcut.MethodMatcher
getMethodMatcher()
Return the MethodMatcher for this pointcut.int
hashCode()
String
toString()
构造器详细资料
AnnotationMatchingPointcut
public AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType)
Create a new AnnotationMatchingPointcut for the given annotation type.- 参数:
classAnnotationType
- the annotation type to look for at the class level
AnnotationMatchingPointcut
public AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType, boolean checkInherited)
Create a new AnnotationMatchingPointcut for the given annotation type.- 参数:
classAnnotationType
- the annotation type to look for at the class levelcheckInherited
- whether to also check the superclasses and interfaces as well as meta-annotations for the annotation type- 另请参阅:
AnnotationClassFilter(Class, boolean)
AnnotationMatchingPointcut
public AnnotationMatchingPointcut(Class<? extends Annotation> classAnnotationType, Class<? extends Annotation> methodAnnotationType)
Create a new AnnotationMatchingPointcut for the given annotation types.- 参数:
classAnnotationType
- the annotation type to look for at the class level (can benull
)methodAnnotationType
- the annotation type to look for at the method level (can benull
)
方法详细资料
getClassFilter
public ClassFilter getClassFilter()
从接口复制的说明:Pointcut
Return the ClassFilter for this pointcut.- 指定者:
getClassFilter
在接口中Pointcut
- 返回:
- the ClassFilter (never
null
)
getMethodMatcher
public MethodMatcher getMethodMatcher()
从接口复制的说明:Pointcut
Return the MethodMatcher for this pointcut.- 指定者:
getMethodMatcher
在接口中Pointcut
- 返回:
- the MethodMatcher (never
null
)
forClassAnnotation
public static AnnotationMatchingPointcut forClassAnnotation(Class<? extends Annotation> annotationType)
Factory method for an AnnotationMatchingPointcut that matches for the specified annotation at the class level.- 参数:
annotationType
- the annotation type to look for at the class level- 返回:
- the corresponding AnnotationMatchingPointcut
forMethodAnnotation
public static AnnotationMatchingPointcut forMethodAnnotation(Class<? extends Annotation> annotationType)
Factory method for an AnnotationMatchingPointcut that matches for the specified annotation at the method level.- 参数:
annotationType
- the annotation type to look for at the method level- 返回:
- the corresponding AnnotationMatchingPointcut