public class CpeDescriptionImpl extends MetaDataObject_impl implements CpeDescription
MetaDataObject_impl.MetaDataAttr, MetaDataObject_impl.SerialContext, MetaDataObject_impl.Serializer
serialContext
Constructor and Description |
---|
CpeDescriptionImpl() |
CpeDescriptionImpl(XMLInputSource aInput)
This is needed for XMLParser.parseCpeDesription() to work.
|
Modifier and Type | Method and Description |
---|---|
CpeCollectionReaderCasInitializer |
addCasInitializer(String aInitializerDescriptorPath)
Deprecated.
As of v2.0, CAS Initializers are deprecated.
|
void |
addCasProcessor(CpeCasProcessor aCasProcessor)
Appends a instance of
CpeCasProcessor to the end of
the list containing CPE CasProcessors. |
void |
addCasProcessor(int index,
CpeCasProcessor aCasProcessor)
Adds a instance of
CpeCasProcessor at a specified
location in the list of CPE CasProcessors. |
void |
addCollectionReader(CpeCollectionReader aCollectionReader) |
CpeCollectionReader |
addCollectionReader(String aCollectionReaderPath)
Adds a path to the descriptor file containing CollectionReader's configuration.
|
CpeCollectionReader[] |
getAllCollectionCollectionReaders()
Returns a list of
CpeCollectionReader instances
representing ALL defined CollectionReaders. |
CpeCasProcessors |
getCpeCasProcessors()
Returns a
CpeCasProcessors instance containing
processing pipeline spec. |
CpeConfiguration |
getCpeConfig() |
CpeConfiguration |
getCpeConfiguration()
Returns the CPE configuration that includes:
An ID of the entity to begin processing with (OPTIONAL)
Number of entities to process
Checkpoint definition (checkpoint file, frequency)
A name of the class implementing
UimaTimer interface. |
CpeResourceManagerConfiguration |
getCpeResourceManagerConfiguration() |
CpeResourceManagerConfiguration |
getResourceManagerConfiguration()
Returns ResourceManagerConfiguration instance.
|
protected XmlizationInfo |
getXmlizationInfo()
To be implemented by subclasses to return information describing how to represent this object
in XML.
|
protected void |
readUnknownPropertyValueFromXMLElement(Element aElement,
XMLParser aParser,
XMLParser.ParsingOptions aOptions,
List aKnownPropertyNames)
Utility method that attempts to read a property value from an XML element even though it is not
known to which property the value should be assigned.
|
void |
setAllCollectionCollectionReaders(CpeCollectionReader[] areaders) |
void |
setCheckpoint(String aCheckpointFile,
int aFrequency)
Add checkpoint file and frequency (in millis) of checkpoints
|
void |
setCpeCasProcessors(CpeCasProcessors aCasProcessors) |
void |
setCpeConfig(CpeConfiguration aConfiguration) |
void |
setCpeConfiguration(CpeConfiguration aConfiguration) |
void |
setCpeResourceManagerConfiguration(CpeResourceManagerConfiguration aResMgrConfPagth)
Defines the path to Resource Manager Configuration
|
void |
setDeployment(String aDeployMode)
Define startup mode for the CPE.
|
void |
setInputQueueSize(int aSize)
Deprecated.
|
void |
setNumToProcess(long aEntityCount)
Defines number of entities to process by the CPE.
|
void |
setOutputQueueSize(int aSize)
Deprecated.
|
void |
setProcessingUnitThreadCount(int aSize) |
void |
setResourceManagerConfiguration(String aResMgrConfPagth)
Defines the path to Resource Manager Configuration
|
void |
setStartingEntityId(String aStartEntityId)
Defines an id of the first entity to process.
|
void |
setTimer(String aTimerClass)
Add name of the class that implements (@link org.apache.uima.util.UimaTimer} interface.
|
buildFromXMLElement, buildFromXMLElement, clone, equals, getAdditionalAttributes, getAttributeClass, getAttributeValue, getInfoset, getMatchingNode, getPropertyDescriptors, getPropertyXmlInfo, getRelativePathBase, getSerialContext, getSourceUrl, getSourceUrlString, getWrapperClass, getXMLAttributes, hashCode, isModifiable, listAttributes, readArrayPropertyValueFromXMLElement, readMapPropertyFromXml, readPropertyValueFromXMLElement, resolveSettings, setAttributeValue, setInfoset, setSourceUrl, setSourceUrlIfNull, toString, toXML, toXML, toXML, toXML, valueIsNullOrEmptyArray, writeArrayPropertyAsElement, writeMapPropertyToXml, writePropertyAsElement
finalize, getClass, notify, notifyAll, wait, wait, wait
toXML
clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl
buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML
public CpeDescriptionImpl()
public CpeDescriptionImpl(XMLInputSource aInput) throws InvalidXMLException
InvalidXMLException
public void addCollectionReader(CpeCollectionReader aCollectionReader) throws CpeDescriptorException
addCollectionReader
in interface CpeDescription
CpeDescriptorException
public CpeCollectionReader addCollectionReader(String aCollectionReaderPath) throws CpeDescriptorException
CpeDescription
This method causes the CPE descriptor to use the older <include> syntax. To use the
<import> syntax, you must use CpeDescription.addCollectionReader(CpeCollectionReader)
instead.
addCollectionReader
in interface CpeDescription
aCollectionReaderPath
- -
path to the CollectionReader descriptor. A relative path is interpreted as
relative to the current working directory.CpeCollectionReader
CpeDescriptorException
- tbd@Deprecated public CpeCollectionReaderCasInitializer addCasInitializer(String aInitializerDescriptorPath) throws CpeDescriptorException
CpeDescription
addCasInitializer
in interface CpeDescription
aInitializerDescriptorPath
- -
path to the CasInitializer descriptorCpeCollectionReaderCasInitializer
CpeDescriptorException
- tbdpublic CpeCollectionReader[] getAllCollectionCollectionReaders() throws CpeDescriptorException
CpeDescription
CpeCollectionReader
instances
representing ALL defined CollectionReaders.getAllCollectionCollectionReaders
in interface CpeDescription
CpeCollectionReader
instances.CpeDescriptorException
- tbdpublic void setAllCollectionCollectionReaders(CpeCollectionReader[] areaders) throws CpeDescriptorException
setAllCollectionCollectionReaders
in interface CpeDescription
CpeDescriptorException
public void setResourceManagerConfiguration(String aResMgrConfPagth)
CpeDescription
setResourceManagerConfiguration
in interface CpeDescription
aResMgrConfPagth
- -
path to Resource Manager Configuration file.public void setCpeResourceManagerConfiguration(CpeResourceManagerConfiguration aResMgrConfPagth)
CpeDescription
setCpeResourceManagerConfiguration
in interface CpeDescription
aResMgrConfPagth
- -
path to Resource Manager Configuration file.public CpeResourceManagerConfiguration getCpeResourceManagerConfiguration()
@Deprecated public void setInputQueueSize(int aSize) throws CpeDescriptorException
CpeDescription
setInputQueueSize
in interface CpeDescription
aSize
- -
size of the queueCpeDescriptorException
- tbdpublic void setProcessingUnitThreadCount(int aSize) throws CpeDescriptorException
setProcessingUnitThreadCount
in interface CpeDescription
aSize
- the number of threadsCpeDescriptorException
- tbd@Deprecated public void setOutputQueueSize(int aSize) throws CpeDescriptorException
CpeDescription
setOutputQueueSize
in interface CpeDescription
aSize
- -
size of the queueCpeDescriptorException
- tbdpublic void setCpeCasProcessors(CpeCasProcessors aCasProcessors)
setCpeCasProcessors
in interface CpeDescription
public CpeCasProcessors getCpeCasProcessors() throws CpeDescriptorException
CpeDescription
CpeCasProcessors
instance containing
processing pipeline spec. This includes:
getCpeCasProcessors
in interface CpeDescription
CpeCasProcessors
CpeDescriptorException
- tbdpublic void addCasProcessor(CpeCasProcessor aCasProcessor) throws CpeDescriptorException
CpeDescription
CpeCasProcessor
to the end of
the list containing CPE CasProcessors.
A CasProcessor can either be:
addCasProcessor
in interface CpeDescription
aCasProcessor
- -
instance of CpeCasProcessor
to add.CpeDescriptorException
- tbdpublic void addCasProcessor(int index, CpeCasProcessor aCasProcessor) throws CpeDescriptorException
CpeDescription
CpeCasProcessor
at a specified
location in the list of CPE CasProcessors. If the index is greater than the list size, the new
CpeCasProcessor
instance is appended to the list.addCasProcessor
in interface CpeDescription
index
- -
insertion point for the CpeCasProcessor
aCasProcessor
- -
CasProcessor to addCpeDescriptorException
- tbdpublic void setCpeConfiguration(CpeConfiguration aConfiguration)
setCpeConfiguration
in interface CpeDescription
public CpeConfiguration getCpeConfiguration() throws CpeDescriptorException
CpeDescription
UimaTimer
interface.
Using an instance of CpeConfiguration
the client
may change behavior of the CPE and corresponding to each of the elements in the above list.
getCpeConfiguration
in interface CpeDescription
CpeConfiguration
CpeDescriptorException
- tbdpublic void setCpeConfig(CpeConfiguration aConfiguration)
public CpeConfiguration getCpeConfig() throws CpeDescriptorException
CpeDescriptorException
public void setCheckpoint(String aCheckpointFile, int aFrequency)
CpeDescription
setCheckpoint
in interface CpeDescription
aCheckpointFile
- -
path for the checkpoint fileaFrequency
- -
frequency in terms of mills for checkpointspublic void setDeployment(String aDeployMode)
CpeDescription
setDeployment
in interface CpeDescription
aDeployMode
- -
CPM deployment modepublic void setNumToProcess(long aEntityCount)
CpeDescription
setNumToProcess
in interface CpeDescription
aEntityCount
- -
entity countpublic void setStartingEntityId(String aStartEntityId)
CpeDescription
setStartingEntityId
in interface CpeDescription
aStartEntityId
- -
entity idpublic void setTimer(String aTimerClass)
CpeDescription
setTimer
in interface CpeDescription
aTimerClass
- -
name of the UimaTimer classpublic CpeResourceManagerConfiguration getResourceManagerConfiguration()
CpeDescription
getResourceManagerConfiguration
in interface CpeDescription
CpeResourceManagerConfiguration
protected void readUnknownPropertyValueFromXMLElement(Element aElement, XMLParser aParser, XMLParser.ParsingOptions aOptions, List aKnownPropertyNames) throws InvalidXMLException
MetaDataObject_impl
readUnknownPropertyValueFromXMLElement
in class MetaDataObject_impl
aElement
- DOM element to read fromaParser
- parser to use to construct complex valuesaOptions
- -aKnownPropertyNames
- List of propertiees that we've already values for (these values will not be
overwritten)InvalidXMLException
- if no acceptable object is described by aElementprotected XmlizationInfo getXmlizationInfo()
MetaDataObject_impl
getXmlizationInfo
in class MetaDataObject_impl
Copyright © 2017. All rights reserved.