@InterfaceAudience.Public @InterfaceStability.Evolving public class GlobFilter extends Object implements PathFilter
Constructor and Description |
---|
GlobFilter(String filePattern)
Creates a glob filter with the specified file pattern.
|
GlobFilter(String filePattern,
PathFilter filter)
Creates a glob filter with the specified file pattern and an user filter.
|
public GlobFilter(String filePattern) throws IOException
filePattern
- the file pattern.IOException
- thrown if the file pattern is incorrect.public GlobFilter(String filePattern, PathFilter filter) throws IOException
filePattern
- the file pattern.filter
- user filter in addition to the glob pattern.IOException
- thrown if the file pattern is incorrect.public boolean accept(Path path)
PathFilter
accept
in interface PathFilter
path
- The abstract pathname to be testedtrue
if and only if pathname
should be includedCopyright © 2015 Apache Software Foundation. All Rights Reserved.