|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.statcvs.util.FilePatternMatcher
public class FilePatternMatcher
Matches filenames against an Ant-style wildcard pattern list.
In short, ? matches one character, * matches zero or more characters but no directory changes (it doesn't match / or \), and ** matches zero or more directory levels. If the wildcard pattern ends in / or \, an implicit ** is added.
Several patterns can be specified, seperated by : or ;.
Everything is case sensitive. If you need case insensitive pattern matching, use String.toLower() on the pattern and on the candidate string.
Constructor Summary | |
---|---|
FilePatternMatcher(java.lang.String wildcardPattern)
Creates a matcher to match filenames against a specified wildcard pattern |
Method Summary | |
---|---|
boolean |
matches(java.lang.String filename)
Matches a filename against the wildcard pattern. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public FilePatternMatcher(java.lang.String wildcardPattern)
wildcardPattern
- an Ant-style wildcard patternMethod Detail |
---|
public boolean matches(java.lang.String filename)
filename
- a filename
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |