|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdk.netarkivet.common.utils.arc.BatchFilter
public abstract class BatchFilter
A filter class for batch entries. Allows testing whether or not to process an entry without loading the entry data first. accept() is given an ARCRecord rather than a ShareableARCRecord to avoid unnecessary reading and copying of data of records not accepted by filter.
Field Summary | |
---|---|
static BatchFilter |
EXCLUDE_FILE_HEADERS
A default filter: Accepts all but the first file |
static BatchFilter |
NO_FILTER
A default filter: Accepts everything |
static BatchFilter |
ONLY_HTTP_ENTRIES
|
Constructor Summary | |
---|---|
protected |
BatchFilter(java.lang.String name)
Create a new filter with the given name |
Method Summary | |
---|---|
abstract boolean |
accept(org.archive.io.arc.ARCRecord record)
|
static BatchFilter |
getMimetypeBatchFilter(java.lang.String mimetype)
|
static boolean |
mimetypeIsOk(java.lang.String mimetype)
Check, if a certain mimetype is valid |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final BatchFilter NO_FILTER
public static final BatchFilter EXCLUDE_FILE_HEADERS
public static final BatchFilter ONLY_HTTP_ENTRIES
Constructor Detail |
---|
protected BatchFilter(java.lang.String name)
name
- The name of this filter, for debugging mostly.Method Detail |
---|
public static BatchFilter getMimetypeBatchFilter(java.lang.String mimetype) throws java.awt.datatransfer.MimeTypeParseException
mimetype
- String denoting the mimetype this filter represents
java.awt.datatransfer.MimeTypeParseException
- (if mimetype is invalid)public static boolean mimetypeIsOk(java.lang.String mimetype)
mimetype
-
public abstract boolean accept(org.archive.io.arc.ARCRecord record)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |