org.springframework.aop.support
Class Perl5RegexpMethodPointcut

java.lang.Object
  extended byorg.springframework.aop.support.StaticMethodMatcher
      extended byorg.springframework.aop.support.StaticMethodMatcherPointcut
          extended byorg.springframework.aop.support.AbstractRegexpMethodPointcut
              extended byorg.springframework.aop.support.Perl5RegexpMethodPointcut
All Implemented Interfaces:
ClassFilter, MethodMatcher, Pointcut, Serializable
Direct Known Subclasses:
RegexpMethodPointcut

public class Perl5RegexpMethodPointcut
extends AbstractRegexpMethodPointcut

Perl5 regular expression pointcut bean. JavaBean properties are:

Note: the regular expressions must be a match. For example, .*get.* will match com.mycom.Foo.getBar(). get.* will not.

Currently uses Jakarta ORO regular expression library. Does not require J2SE 1.4, although it runs under 1.4.

Since:
1.1
Author:
Rod Johnson
See Also:
AbstractRegexpMethodPointcut, Serialized Form

Field Summary
 
Fields inherited from class org.springframework.aop.support.AbstractRegexpMethodPointcut
logger
 
Fields inherited from interface org.springframework.aop.ClassFilter
TRUE
 
Fields inherited from interface org.springframework.aop.Pointcut
TRUE
 
Fields inherited from interface org.springframework.aop.MethodMatcher
TRUE
 
Constructor Summary
Perl5RegexpMethodPointcut()
           
 
Method Summary
protected  void initPatternRepresentation(String[] patterns)
          Initialize ORO fields from patterns String[].
protected  boolean matches(String pattern, int patternIndex)
          Does the pattern at the given index match this string?
 
Methods inherited from class org.springframework.aop.support.AbstractRegexpMethodPointcut
getClassFilter, getPatterns, matches, matches, setPattern, setPatterns
 
Methods inherited from class org.springframework.aop.support.StaticMethodMatcherPointcut
getMethodMatcher, setClassFilter
 
Methods inherited from class org.springframework.aop.support.StaticMethodMatcher
isRuntime, matches
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Perl5RegexpMethodPointcut

public Perl5RegexpMethodPointcut()
Method Detail

initPatternRepresentation

protected void initPatternRepresentation(String[] patterns)
                                  throws IllegalArgumentException
Initialize ORO fields from patterns String[].

Specified by:
initPatternRepresentation in class AbstractRegexpMethodPointcut
Parameters:
patterns - the patterns to initialize
Throws:
IllegalArgumentException - in case of an invalid pattern

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 match
patternIndex - index of pattern from 0
Returns:
whether there's a match


Copyright (C) 2003-2004 The Spring Framework Project.