|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.swing.filechooser.FileFilter
org.montsuqi.util.ExtensionFileFilter
public class ExtensionFileFilter
A FileFilter that filters by file name extension.
This filter accepts files whose names end with the specified extension. All directories (with any name) are also accepted.
| Constructor Summary | |
|---|---|
ExtensionFileFilter(java.lang.String extension,
java.lang.String description)
Constructs a ExtensionFileFilter that filters by given extension. |
|
| Method Summary | |
|---|---|
boolean |
accept(java.io.File f)
Returns true when the given file is a directory or its name ends with the extension. |
java.lang.String |
getDescription()
Returns textual description of this filter. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ExtensionFileFilter(java.lang.String extension,
java.lang.String description)
Constructs a ExtensionFileFilter that filters by given extension.
extension - extension which is accepted.description - descriptive text that explains this filter.| Method Detail |
|---|
public boolean accept(java.io.File f)
Returns true when the given file is a directory or its name ends with the extension. False otherwise.
accept in class javax.swing.filechooser.FileFilterf - a File to test.
public java.lang.String getDescription()
Returns textual description of this filter.
getDescription in class javax.swing.filechooser.FileFilter
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||