Class RepositoryDocumentFactory
- java.lang.Object
-
- org.apache.manifoldcf.agents.incrementalingest.RepositoryDocumentFactory
-
public class RepositoryDocumentFactory extends java.lang.Object
This class accepts a RepositoryDocument in its constructor, and then allows multiple copies to me made, as part of a split in the pipeline. It must be closed in order to release all temporary resources.
-
-
Field Summary
Fields Modifier and Type Field Description protected BinaryInput
binaryTracker
protected java.util.Map<java.lang.String,CharacterInput[]>
metadataReaders
protected RepositoryDocument
original
-
Constructor Summary
Constructors Constructor Description RepositoryDocumentFactory(RepositoryDocument document)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Close this object and release its resources.RepositoryDocument
createDocument()
Create a new RepositoryDocument object from the saved local resources.
-
-
-
Field Detail
-
original
protected final RepositoryDocument original
-
binaryTracker
protected BinaryInput binaryTracker
-
metadataReaders
protected final java.util.Map<java.lang.String,CharacterInput[]> metadataReaders
-
-
Constructor Detail
-
RepositoryDocumentFactory
public RepositoryDocumentFactory(RepositoryDocument document) throws ManifoldCFException, java.io.IOException
Constructor. Pass a RepositoryDocument. This constructor reads all streams and stores them in a temporary local location. If there is an error reading the streams, an IOException will be thrown. Otherwise, a ManifoldCFException will be thrown instead.- Parameters:
document
- is the repository document to read.- Throws:
ManifoldCFException
java.io.IOException
-
-
Method Detail
-
createDocument
public RepositoryDocument createDocument() throws ManifoldCFException
Create a new RepositoryDocument object from the saved local resources. As a side effect, this method also releases any resources held on behalf of the previously created RepositoryDocument.- Returns:
- a repository document object.
- Throws:
ManifoldCFException
-
close
public void close() throws ManifoldCFException
Close this object and release its resources.- Throws:
ManifoldCFException
-
-