Interface CpeCasProcessors
-
- All Superinterfaces:
java.lang.Cloneable,MetaDataObject,java.io.Serializable,XMLizable
- All Known Implementing Classes:
CpeCasProcessorsImpl
public interface CpeCasProcessors extends MetaDataObject
An object that holds configuration that is part of the CPE descriptor. It provides the means of configuring the CPE Processing Pipeline and to tweak performance charactristics of the CPE. It contains a list of CasProcessors that will be strung together into a pipeline by the CPE.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddCpeCasProcessor(CpeCasProcessor aCasProcessor)Appends new CasProcessor to existing list of CasProcessorsvoidaddCpeCasProcessor(CpeCasProcessor aCasProcessor, int aInsertPosition)Inserts a new CasProcessor at an indicated position.CpeCasProcessor[]getAllCpeCasProcessors()Returns ALLCpeCasProcessorobjects in processing pipeline.intgetCasPoolSize()intgetConcurrentPUCount()Returns number of ProcessingUnits.CpeCasProcessorgetCpeCasProcessor(int aPosition)ReturnsCpeCasProcessorfound at given position.booleangetDropCasOnException()intgetInputQueueSize()Returns size of the InputQueue.intgetOutputQueueSize()Returns the size of the OutputQueue.voidremoveAllCpeCasProcessors()Removes ALLCpeCasProcessorobjects from processing pipeline.voidremoveCpeCasProcessor(int aPosition)RemovesCpeCasProcessorobject from processing pipeline from a given position.voidsetConcurrentPUCount(int aConcurrentPUCount)Sets ProcessingUnit replication.voidsetInputQueueSize(int aOutputQueueSize)Sets the size of the InputQueue.voidsetOutputQueueSize(int aOutputQueueSize)Sets the size of the OutputQueue.voidsetPoolSize(int aPoolSize)-
Methods inherited from interface org.apache.uima.resource.metadata.MetaDataObject
clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl
-
Methods inherited from interface org.apache.uima.util.XMLizable
buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML, toXML
-
-
-
-
Method Detail
-
setOutputQueueSize
void setOutputQueueSize(int aOutputQueueSize) throws CpeDescriptorExceptionSets the size of the OutputQueue. This queue is shared among Processing Units and CasConsumers and contains bundles of CAS. Processing Units add bundles to the queue while CasConsumers consume them. The best size for this queue is determined by overall performance of the ProcessingUnit ( how fast it deposits bundles onto the queue) and memory availability. The larger the queue the more bundles (hence memory) is used.- Parameters:
aOutputQueueSize- - Output queue size- Throws:
CpeDescriptorException- tbd
-
getOutputQueueSize
int getOutputQueueSize()
Returns the size of the OutputQueue. This queue is shared among Processing Units and CasConsumers and contains bundles of CAS. Processing Units add bundles to the queue while CasConsumers consume them. The best size for this queue is determined by overall performance of the ProcessingUnit ( how fast it deposits bundles onto the queue) and memory availability. The larger the queue the more bundles (hence memory) is used.- Returns:
- - output queue size
-
setInputQueueSize
void setInputQueueSize(int aOutputQueueSize) throws CpeDescriptorExceptionSets the size of the InputQueue. This queue is shared among CollectionReader and Processing Units and contains bundles of CAS. CollectionReader adds bundles to the queue while Processing Unit consume them. The best size for this queue is determined by overall performance of the ProcessingUnit ( how fast it takes bundles off the queue) and memory availability. The larger the queue the more bundles (hence memory) is used.- Parameters:
aOutputQueueSize- - queue size- Throws:
CpeDescriptorException- tbd
-
getInputQueueSize
int getInputQueueSize()
Returns size of the InputQueue. This queue is shared among CollectionReader and Processing Units and contains bundles of CAS. CollectionReader adds bundles to the queue while Processing Unit consume them. The best size for this queue is determined by overall performance of the ProcessingUnit ( how fast it takes bundles off the queue) and memory availability. The larger the queue the more bundles (hence memory) is used.- Returns:
- - queue size
-
setConcurrentPUCount
void setConcurrentPUCount(int aConcurrentPUCount) throws CpeDescriptorExceptionSets ProcessingUnit replication. Each ProcessingUnit contains the same sequence of CasProcessors and runs in a seperate thread. On platforms containing more than one CPU, replicating ProcessingUnit may result in better performance.- Parameters:
aConcurrentPUCount- - number of ProcessingUnits(processing threads)- Throws:
CpeDescriptorException- tbd
-
getConcurrentPUCount
int getConcurrentPUCount()
Returns number of ProcessingUnits. Each ProcessingUnit contains the same sequence of CasProcessors and runs in a seperate thread. On platforms containing more than one CPU, replicating ProcessingUnit may result in better performance.- Returns:
- - number of ProcessingUnits(processing threads)
-
addCpeCasProcessor
void addCpeCasProcessor(CpeCasProcessor aCasProcessor, int aInsertPosition) throws CpeDescriptorException
Inserts a new CasProcessor at an indicated position.- Parameters:
aCasProcessor- - CasProcessor to addaInsertPosition- - position where to insert the CasProcessor- Throws:
CpeDescriptorException- tbd
-
addCpeCasProcessor
void addCpeCasProcessor(CpeCasProcessor aCasProcessor) throws CpeDescriptorException
Appends new CasProcessor to existing list of CasProcessors- Parameters:
aCasProcessor- - CasProcessor to add- Throws:
CpeDescriptorException- tbd
-
getCpeCasProcessor
CpeCasProcessor getCpeCasProcessor(int aPosition) throws CpeDescriptorException
ReturnsCpeCasProcessorfound at given position.- Parameters:
aPosition- - position of the CasProcessor- Returns:
- -
CpeCasProcessor - Throws:
CpeDescriptorException- tbd
-
getAllCpeCasProcessors
CpeCasProcessor[] getAllCpeCasProcessors() throws CpeDescriptorException
Returns ALLCpeCasProcessorobjects in processing pipeline.- Returns:
- array of
CpeCasProcessor - Throws:
CpeDescriptorException- tbd
-
removeCpeCasProcessor
void removeCpeCasProcessor(int aPosition) throws CpeDescriptorExceptionRemovesCpeCasProcessorobject from processing pipeline from a given position.- Parameters:
aPosition- - position of the CasProcessor in the pipeline- Throws:
CpeDescriptorException- tbd
-
removeAllCpeCasProcessors
void removeAllCpeCasProcessors() throws CpeDescriptorExceptionRemoves ALLCpeCasProcessorobjects from processing pipeline.- Throws:
CpeDescriptorException- tbd
-
setPoolSize
void setPoolSize(int aPoolSize) throws CpeDescriptorException- Throws:
CpeDescriptorException
-
getCasPoolSize
int getCasPoolSize()
-
getDropCasOnException
boolean getDropCasOnException()
-
-