public class FileFileFilter extends AbstractFileFilter implements Serializable
Files that are files (not directories).
For example, here is how to print out a list of the real files within the current directory:
File dir = new File(".");
String[] files = dir.list( FileFileFilter.FILE );
for ( int i = 0; i < files.length; i++ ) {
System.out.println(files[i]);
}
FileFilterUtils.fileFileFilter(),
Serialized Form| Modifier and Type | Field and Description |
|---|---|
static IOFileFilter |
FILE
Singleton instance of file filter
|
| Modifier | Constructor and Description |
|---|---|
protected |
FileFileFilter()
Restrictive consructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(File file)
Checks to see if the file is a file.
|
accept, toStringpublic static final IOFileFilter FILE
public boolean accept(File file)
accept in interface FileFilteraccept in interface IOFileFilteraccept in class AbstractFileFilterfile - the File to checkCopyright © 2002–2016 The Apache Software Foundation. All rights reserved.