public final class ExtensionListFilter
extends java.lang.Object
implements java.io.FilenameFilter
Modifier and Type | Field and Description |
---|---|
static boolean |
DEBUGGING
true if debugging.
|
(package private) boolean |
invert
do we return all directories but the ones in the list.
|
Constructor and Description |
---|
ExtensionListFilter(boolean invert,
java.lang.String... want)
constructor
|
ExtensionListFilter(java.lang.String... want)
constructor
|
public static final boolean DEBUGGING
final boolean invert
public ExtensionListFilter(java.lang.String... want)
want
- Array of simple file extension names, case insensitive, e.g. new String["html", "txt", "bat" ];public ExtensionListFilter(boolean invert, java.lang.String... want)
invert
- if true, selects files not in the list instead.want
- Array of simple file extension names, case insensitive, e.g. new String["html", "txt", "bat" ];public boolean accept(java.io.File dir, java.lang.String name)
accept
in interface java.io.FilenameFilter
dir
- the directory in which the file was found.name
- the name of the filepublic static void main(java.lang.String[] args)
args
- not used