org.springframework.aop.support
Class NameMatchMethodPointcutAdvisor
java.lang.Object
org.springframework.aop.support.AbstractPointcutAdvisor
org.springframework.aop.support.AbstractGenericPointcutAdvisor
org.springframework.aop.support.NameMatchMethodPointcutAdvisor
- All Implemented Interfaces:
- java.io.Serializable, Advisor, PointcutAdvisor, Ordered
public class NameMatchMethodPointcutAdvisor
- extends AbstractGenericPointcutAdvisor
Convenient class for name-match method pointcuts that hold an Advice,
making them an Advisor.
- Author:
- Juergen Hoeller, Rob Harrop
- See Also:
NameMatchMethodPointcut
,
Serialized Form
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
pointcut
private final NameMatchMethodPointcut pointcut
NameMatchMethodPointcutAdvisor
public NameMatchMethodPointcutAdvisor()
NameMatchMethodPointcutAdvisor
public NameMatchMethodPointcutAdvisor(Advice advice)
setClassFilter
public void setClassFilter(ClassFilter classFilter)
- Set the
ClassFilter
to use for this pointcut.
Default is ClassFilter.TRUE
.
- See Also:
StaticMethodMatcherPointcut.setClassFilter(org.springframework.aop.ClassFilter)
setMappedName
public void setMappedName(java.lang.String mappedName)
- Convenience method when we have only a single method name to match.
Use either this method or
setMappedNames
, not both.
- See Also:
setMappedNames(java.lang.String[])
,
NameMatchMethodPointcut.setMappedName(java.lang.String)
setMappedNames
public void setMappedNames(java.lang.String[] mappedNames)
- Set the method names defining methods to match.
Matching will be the union of all these; if any match,
the pointcut matches.
- See Also:
NameMatchMethodPointcut.setMappedNames(java.lang.String[])
addMethodName
public NameMatchMethodPointcut addMethodName(java.lang.String name)
- Add another eligible method name, in addition to those already named.
Like the set methods, this method is for use when configuring proxies,
before a proxy is used.
- Parameters:
name
- name of the additional method that will match
- Returns:
- this pointcut to allow for multiple additions in one line
- See Also:
NameMatchMethodPointcut.addMethodName(java.lang.String)
getPointcut
public Pointcut getPointcut()
- Description copied from interface:
PointcutAdvisor
- Get the Pointcut that drives this advisor.