public class ExtensionFileFilter extends FileFilter implements FileFilter, Comparable
Constructor and Description |
---|
ExtensionFileFilter(String[] extensions,
String description)
Constructs a new filter that accepts the given extensions.
|
ExtensionFileFilter(String extension,
String description)
Constructs a new filter that accepts the given extension.
|
Modifier and Type | Method and Description |
---|---|
boolean |
accept(File f)
Accepts files with the proper extensions.
|
int |
compareTo(Object o)
Compares two FileFilter objects alphanumerically.
|
String |
getDescription()
Gets the filter's description.
|
String |
getExtension()
Gets the filter's first valid extension.
|
String[] |
getExtensions()
Gets the filter's valid extensions.
|
String |
toString()
Gets a string representation of this file filter.
|
public ExtensionFileFilter(String extension, String description)
public String getExtension()
public String[] getExtensions()
public boolean accept(File f)
accept
in interface FileFilter
accept
in class FileFilter
public String getDescription()
getDescription
in class FileFilter
public String toString()
public int compareTo(Object o)
compareTo
in interface Comparable
Copyright © 1996–2023 The SSEC Visualization Project. All rights reserved.