|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.io.filefilter.AbstractFileFilter
org.apache.commons.io.filefilter.OrFileFilter
This filter produces a logical OR of the two filters specified.
Field Summary | |
private IOFileFilter |
filter1
The first filter |
private IOFileFilter |
filter2
The second filter |
Constructor Summary | |
OrFileFilter(IOFileFilter filter1,
IOFileFilter filter2)
Constructs a new file filter that ORs the result of two other filters. |
Method Summary | |
boolean |
accept(java.io.File file)
Checks to see if either filter is true. |
boolean |
accept(java.io.File file,
java.lang.String name)
Checks to see if either filter is true. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private IOFileFilter filter1
private IOFileFilter filter2
Constructor Detail |
public OrFileFilter(IOFileFilter filter1, IOFileFilter filter2)
filter1
- the first filter, must not be nullfilter2
- the second filter, must not be null
java.lang.IllegalArgumentException
- if either filter is nullMethod Detail |
public boolean accept(java.io.File file)
accept
in interface IOFileFilter
accept
in class AbstractFileFilter
file
- the File to check
public boolean accept(java.io.File file, java.lang.String name)
accept
in interface IOFileFilter
accept
in class AbstractFileFilter
file
- the File directoryname
- the filename
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |