class RegexFilter extends Object implements FileFilter
getRelativePathFilterForBase(RelativePathBase)
.| Constructor and Description |
|---|
RegexFilter(String namePattern,
boolean ignoreCase)
Constructor with pattern and ignore-case flag.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(File file)
Filter if name only is matched, NOT THE WHOLE PATH.
|
FileFilter |
getRelativePathFilterForBase(RelativePathBase relativePathBase)
Returns a file filter that matches the whole (relative) path of the file
instead of just the file name.
|
public RegexFilter(String namePattern, boolean ignoreCase)
namePattern - the regex patternignoreCase - true if matching should be case insensitivepublic boolean accept(File file)
getRelativePathFilterForBase(RelativePathBase)).accept in interface FileFilterpublic FileFilter getRelativePathFilterForBase(RelativePathBase relativePathBase)
relativePathBase - basis for relative pathsCopyright © 2025. All rights reserved.