|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectFileFilter
GenericFileFilter
public class GenericFileFilter
A FileFilter
which can be customised with an
arbitrary file type and which generates a standard
description do appear in a JFileChooser.
JFileChooser
,
FileFilter
Constructor Summary | |
---|---|
GenericFileFilter(String extension,
String desc)
Create a GenericFileFilter accepting
the file type described. |
Method Summary | |
---|---|
boolean |
accept(File f)
|
int |
compareTo(Object o)
|
String |
getDescription()
Returns the description of this file filter, as displayed in the dropdown list. |
String |
getExtension()
Returns the filename extension associated with this file filter. |
String |
getName()
Returns the name of the file type (e.g., the codec name, not the extension) of this file filter. |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GenericFileFilter(String extension, String desc)
GenericFileFilter
accepting
the file type described.
extension
- the extension of the file typedesc
- a description of the file typeMethod Detail |
---|
public boolean accept(File f)
accept
in class FileFilter
public String getDescription()
getDescription
in class FileFilter
public String getName()
public String getExtension()
public int compareTo(Object o)
compareTo
in interface Comparable
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |