|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--javax.swing.filechooser.FileFilter
|
+--com.monkeycoder.monkeynes.base.GenericFileFilter
This provides completely generic file filtering for Swing based FileChooser dialogs.
Originally part of the MonkeyNES project.
| Constructor Summary | |
GenericFileFilter()
Creates an empty GenericFileFilter with no extensions, no description, and not showing directories. |
|
GenericFileFilter(ArrayList inExtensions)
Creates a GenericFileFilter with the extensions provided, no description, and not showing directories. |
|
GenericFileFilter(ArrayList inExtensions,
boolean inShowDirs)
Creates a GenericFileFilter with the extensions provided, no description, and optionally showing directories. |
|
GenericFileFilter(ArrayList inExtensions,
String inDescription)
Creates a GenericFileFilter with the extensions and description provided, and not showing directories. |
|
GenericFileFilter(ArrayList inExtensions,
String inDescription,
boolean inShowDirs)
Creates a GenericFileFilter with the extensions and description provided, and optionally showing directories. |
|
GenericFileFilter(String inExtensions)
Creates a GenericFileFilter with the extensions provided, no description, and not showing directories. |
|
GenericFileFilter(String inExtensions,
boolean inShowDirs)
Creates a GenericFileFilter with the extensions provided, no description, and optionally showing directories. |
|
GenericFileFilter(String inExtensions,
String inDescription)
Creates a GenericFileFilter with the extensions and description provided, and not showing directories. |
|
GenericFileFilter(String inExtensions,
String inDescription,
boolean inShowDirs)
Creates a GenericFileFilter with the extensions and description provided, and optionally showing directories. |
|
| Method Summary | |
boolean |
accept(File inFile)
Returns whether or not the specified file is to be shown. |
void |
addExtension(String inExt)
Adds an extension to the list of extensions on which this GenericFileFilter filters. |
String |
getDescription()
Gets the description. |
void |
setDescription(String inDesc)
Sets the description. |
void |
setShowDirs(boolean inShowDirs)
Sets whether or not directories will be shown. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public GenericFileFilter()
public GenericFileFilter(ArrayList inExtensions)
inExtensions - An ArrayList containing the extensions.
public GenericFileFilter(ArrayList inExtensions,
boolean inShowDirs)
inExtensions - An ArrayList containing the extensions.inShowDirs - Whether or not to display directories with this filter.
public GenericFileFilter(ArrayList inExtensions,
String inDescription)
inExtensions - An ArrayList containing the extensions.inDescription - The description of this filter in the drop down list.
public GenericFileFilter(ArrayList inExtensions,
String inDescription,
boolean inShowDirs)
inExtensions - An ArrayList containing the extensions.inDescription - The description of this filter in the drop down list.inShowDirs - Whether or not to display directories with this filter.public GenericFileFilter(String inExtensions)
inExtensions - A pipe ('|') seperated string containing the extensions.
public GenericFileFilter(String inExtensions,
boolean inShowDirs)
inExtensions - A pipe ('|') seperated string containing the extensions.inShowDirs - Whether or not to display directories with this filter.
public GenericFileFilter(String inExtensions,
String inDescription)
inExtensions - A pipe ('|') seperated string containing the extensions.inDescription - The description of this filter in the drop down list.
public GenericFileFilter(String inExtensions,
String inDescription,
boolean inShowDirs)
inExtensions - A pipe ('|') seperated string containing the extensions.inDescription - The description of this filter in the drop down list.inShowDirs - Whether or not to display directories with this filter.| Method Detail |
public void addExtension(String inExt)
inExt - A string containing the extension to add.public void setDescription(String inDesc)
inDesc - The description of this filter in the drop down list.public String getDescription()
getDescription in class FileFilterpublic void setShowDirs(boolean inShowDirs)
inShowDirs - Whether or not to display directories with this filter.public boolean accept(File inFile)
accept in interface FileFilteraccept in class FileFilterinFile - The file being tested.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||