com.filenet.api.util
Class ParallelContentStream
- java.lang.Object
-
- com.filenet.api.util.ParallelContentStream
-
public class ParallelContentStream extends java.lang.ObjectA parallel content stream delivers document content sequentially but uses multuple threads executing in parallel in the client application to gather the content from the server. This can provide a performance benefit in some circumstances, although at cost of additional memory and resource usage in both the server and client.
-
-
Constructor Summary
Constructors Constructor and Description ParallelContentStream()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static java.io.InputStreamgetParallelContentStream(Document doc, int elementIndex, int threadCount, int blockSize)Creates a parallel stream returning the content of a specified element of a Document's content elements.
-
-
-
Method Detail
-
getParallelContentStream
public static java.io.InputStream getParallelContentStream(Document doc, int elementIndex, int threadCount, int blockSize)
Creates a parallel stream returning the content of a specified element of a Document's content elements. The stream returned can only be read sequencially and cannot be cast tocom.filenet.api.util.ExtendedInputStream. The caller is responsible for closing the returned stream when finished.- Parameters:
doc- The document object from which to retrieve content.elementIndex- The zero-based index in the content element list of the element for which content should be returned.threadCount- The number of parallel threads to use for retrieval.blockSize- The size of each block of content that is fetched by a parallel thread.- Returns:
- The
java.io.InputStreamproviding sequential read access to the requested content.
-
-