|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.filechooser.FileFilter
util.Filter
Defines a file filter that can be used when opening and saving files. The filter is used to specify what files to show in the file dialog.
Field Summary | |
private java.lang.String |
filter
|
Constructor Summary | |
Filter(java.lang.String filter)
Constructs the Filter. |
Method Summary | |
boolean |
accept(java.io.File f)
Checks if the specified file should be shown or not. |
java.lang.String |
getDescription()
The filter's description. |
java.lang.String |
getExtension(java.io.File f)
Get the extension (file ending) of a file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private java.lang.String filter
Constructor Detail |
public Filter(java.lang.String filter)
filter
- a string containing the file ending you want to filterMethod Detail |
public boolean accept(java.io.File f)
f
- the file to be checked
public java.lang.String getDescription()
public java.lang.String getExtension(java.io.File f)
f
- the file which filename we want
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |