Class Overview
Regular expression pointcut based on the java.util.regex
package.
Supports the following JavaBean properties:
- pattern: regular expression for the fully-qualified method names to match
- patterns: alternative property taking a String array of patterns. The result will
be the union of these patterns.
Note: the regular expressions must be a match. For example,
.*get.*
will match com.mycom.Foo.getBar().
get.*
will not.
Summary
Protected Methods |
void
|
initExcludedPatternRepresentation(String[] excludedPatterns)
Initialize exclusion Pattern Patterns from the supplied String[] .
|
void
|
initPatternRepresentation(String[] patterns)
Initialize Pattern Patterns from the supplied String[] .
|
boolean
|
matches(String pattern, int patternIndex)
Returns true if the Pattern at index patternIndex
matches the supplied candidate String .
|
boolean
|
matchesExclusion(String candidate, int patternIndex)
Returns true if the exclusion Pattern at index patternIndex
matches the supplied candidate String .
|
[Expand]
Inherited Methods |
From class
org.springframework.aop.support.AbstractRegexpMethodPointcut
|
From class
org.springframework.aop.support.StaticMethodMatcherPointcut
|
From class
org.springframework.aop.support.StaticMethodMatcher
final
boolean
|
isRuntime()
Is this MethodMatcher dynamic, that is, must a final call be made on the
matches(java.lang.reflect.Method, Class, Object[]) method at
runtime even if the 2-arg matches method returns true ?
Can be invoked when an AOP proxy is created, and need not be invoked
again before each method invocation,
|
final
boolean
|
matches(Method method, Class<?> targetClass, Object[] args)
Check whether there a runtime (dynamic) match for this method,
which must have matched statically.
|
|
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
|
From interface
org.springframework.aop.MethodMatcher
abstract
boolean
|
isRuntime()
Is this MethodMatcher dynamic, that is, must a final call be made on the
matches(java.lang.reflect.Method, Class, Object[]) method at
runtime even if the 2-arg matches method returns true ?
Can be invoked when an AOP proxy is created, and need not be invoked
again before each method invocation,
|
abstract
boolean
|
matches(Method method, Class<?> targetClass)
Perform static checking whether the given method matches.
|
abstract
boolean
|
matches(Method method, Class<?> targetClass, Object[] args)
Check whether there a runtime (dynamic) match for this method,
which must have matched statically.
|
|
From interface
org.springframework.aop.Pointcut
|
Public Constructors
public
JdkRegexpMethodPointcut
()
Protected Methods
protected
void
initExcludedPatternRepresentation
(String[] excludedPatterns)
Initialize exclusion Pattern Patterns from the supplied String[]
.
Parameters
excludedPatterns
| the patterns to initialize |
protected
void
initPatternRepresentation
(String[] patterns)
Initialize Pattern Patterns from the supplied String[]
.
Parameters
patterns
| the patterns to initialize |
protected
boolean
matches
(String pattern, int patternIndex)
Returns true
if the Pattern at index patternIndex
matches the supplied candidate String
.
Parameters
pattern
| String pattern to match |
patternIndex
| index of pattern from 0 |
Returns
true
if there is a match, else false
.
protected
boolean
matchesExclusion
(String candidate, int patternIndex)
Returns true
if the exclusion Pattern at index patternIndex
matches the supplied candidate String
.
Parameters
candidate
| String pattern to match. |
patternIndex
| index of pattern starting from 0. |
Returns
true
if there is a match, else false
.