|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdk.netarkivet.common.utils.batch.FileBatchJob
dk.netarkivet.common.utils.archive.ArchiveBatchJobBase
public abstract class ArchiveBatchJobBase
Nested Class Summary |
---|
Nested classes/interfaces inherited from class dk.netarkivet.common.utils.batch.FileBatchJob |
---|
FileBatchJob.ExceptionOccurrence |
Field Summary | |
---|---|
protected int |
noOfRecordsProcessed
The total number of records processed. |
Fields inherited from class dk.netarkivet.common.utils.batch.FileBatchJob |
---|
batchJobTimeout, exceptions, filesFailed, noOfFilesProcessed |
Constructor Summary | |
---|---|
ArchiveBatchJobBase()
|
Method Summary | |
---|---|
abstract void |
finish(java.io.OutputStream os)
Finish up the job. |
java.lang.Exception[] |
getExceptionArray()
Returns a representation of the list of Exceptions recorded for this archive batch job. |
void |
handleException(java.lang.Exception e,
java.io.File archiveFile,
long index)
When the org.archive.io.arc classes throw IOExceptions while reading, this is where they go. |
protected void |
handleOurException(NetarkivetException e,
java.io.File archiveFile,
long index)
Private method that handles our exception. |
abstract void |
initialize(java.io.OutputStream os)
Initialize the job before running. |
int |
noOfRecordsProcessed()
Returns the number of records processed. |
Methods inherited from class dk.netarkivet.common.utils.batch.FileBatchJob |
---|
addException, addFinishException, addInitializeException, getBatchJobTimeout, getExceptions, getFilenamePattern, getFilesFailed, getNoOfFilesProcessed, maxExceptionsReached, postProcess, processFile, processOnlyFileNamed, processOnlyFilesMatching, processOnlyFilesMatching, processOnlyFilesNamed, setBatchJobTimeout |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int noOfRecordsProcessed
Constructor Detail |
---|
public ArchiveBatchJobBase()
Method Detail |
---|
public abstract void initialize(java.io.OutputStream os)
initialize
in class FileBatchJob
os
- The OutputStream to which output data is writtenpublic abstract void finish(java.io.OutputStream os)
finish
in class FileBatchJob
os
- The OutputStream to which output data is writtenprotected void handleOurException(NetarkivetException e, java.io.File archiveFile, long index)
e
- the given exceptionarchiveFile
- The archive file where the exception occurred.index
- The offset in the archive file where the exception occurred.public void handleException(java.lang.Exception e, java.io.File archiveFile, long index) throws ArgumentNotValid
e
- An Exception thrown by the org.archive.io.arc classes.archiveFile
- The archive file that was processed while the Exception was thrownindex
- The index (in the archive file) at which the Exception was thrown
ArgumentNotValid
- if e is nullpublic java.lang.Exception[] getExceptionArray()
public int noOfRecordsProcessed()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |