public class FilenameExtensionFilter extends Object implements FilenameFilter
FilenameFilter
that allows to filter by an extension.Constructor and Description |
---|
FilenameExtensionFilter(String ext,
boolean ignoreCase)
Constructs a
FilenameExtensionFilter with the given extension and if the case should
be ignored. |
public FilenameExtensionFilter(String ext, boolean ignoreCase)
FilenameExtensionFilter
with the given extension and if the case should
be ignored.ext
- the extension that the files must have.ignoreCase
- if the case should be ignored.public boolean accept(File dir, String name)
accept
in interface FilenameFilter