|
ABLE 2.0.0 07/02/2003 10:25:01 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.able.conversation.FilterByExtension
The FilterByExtension class accepts files with extensions that match a given string.
The user specifies the extension to be accepted (in all lower case), and optionally, whether to accept directories (the default is to do so).
Constructor Summary | |
---|---|
FilterByExtension(java.lang.String extension)
Constructs a FilterByExtension object. |
Method Summary | |
---|---|
boolean |
accept(java.io.File arg0)
|
java.lang.String |
getAcceptedExtension()
Returns the extension used in accepting files. |
static java.lang.String |
getExtension(java.io.File file)
Returns the extension of the given file. |
boolean |
isDirectoriesAccepted()
Indicates whether directories are accepted by this filter. |
void |
setAcceptedExtension(java.lang.String extension)
Sets the extension to use in accepting files. |
void |
setDirectoriesAccepted(boolean directoriesAccepted)
Sets the flag that indicates whether directories are accepted by this filter. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public FilterByExtension(java.lang.String extension)
extension
- The extension to filter on. (Automatically mapped to lower case.)Method Detail |
public java.lang.String getAcceptedExtension()
public void setAcceptedExtension(java.lang.String extension)
The given string is mapped to lower case.
extension
- The extension to use in accepting files.public boolean isDirectoriesAccepted()
true
.
public void setDirectoriesAccepted(boolean directoriesAccepted)
directoriesAccepted
- The flag.public static java.lang.String getExtension(java.io.File file)
file
- the File object representing the filepublic boolean accept(java.io.File arg0)
accept
in interface java.io.FileFilter
|
ABLE 2.0.0 07/02/2003 10:25:01 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |