org.springframework.aop.support
Class JdkRegexpMethodPointcut
java.lang.Object
org.springframework.aop.support.StaticMethodMatcher
org.springframework.aop.support.StaticMethodMatcherPointcut
org.springframework.aop.support.AbstractRegexpMethodPointcut
org.springframework.aop.support.JdkRegexpMethodPointcut
- All Implemented Interfaces:
- ClassFilter, MethodMatcher, Pointcut, Serializable
- public class JdkRegexpMethodPointcut
- extends AbstractRegexpMethodPointcut
Java 1.4 regular expression pointcut bean. JavaBean properties are:
- pattern: Java 1.4 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.
Requires J2SE 1.4, as it builds on the java.util.regex
package.
- Since:
- 1.1
- Author:
- Dmitriy Kopylenko
- See Also:
AbstractRegexpMethodPointcut
,
Serialized Form
Fields inherited from interface org.springframework.aop.Pointcut |
TRUE |
Method Summary |
protected void |
initPatternRepresentation(String[] patterns)
Initialize Java 1.4 Patterns field from patterns String[]. |
protected boolean |
matches(String pattern,
int patternIndex)
Does the pattern at the given index match this string? |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JdkRegexpMethodPointcut
public JdkRegexpMethodPointcut()
initPatternRepresentation
protected void initPatternRepresentation(String[] patterns)
throws PatternSyntaxException
- Initialize Java 1.4 Patterns field from patterns String[].
- Specified by:
initPatternRepresentation
in class AbstractRegexpMethodPointcut
- Parameters:
patterns
- the patterns to initialize
- Throws:
PatternSyntaxException
matches
protected boolean matches(String pattern,
int patternIndex)
- Description copied from class:
AbstractRegexpMethodPointcut
- Does the pattern at the given index match this string?
- Specified by:
matches
in class AbstractRegexpMethodPointcut
- Parameters:
pattern
- string pattern to matchpatternIndex
- index of pattern from 0
- Returns:
- whether there's a match
Copyright (C) 2003-2004 The Spring Framework Project.