Class CpeDescriptorFactory
- java.lang.Object
-
- org.apache.uima.collection.impl.metadata.cpe.CpeDescriptorFactory
-
public class CpeDescriptorFactory extends java.lang.ObjectFactory class for creating CpeDescriptors and their constituent objects.
-
-
Constructor Summary
Constructors Constructor Description CpeDescriptorFactory()Instantiates a new cpe descriptor factory.
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static CpeIntegratedCasProcessorproduceCasProcessor(java.lang.String aName)Produce cas processor.static CasProcessorConfigurationParameterSettingsproduceCasProcessorConfigurationParameterSettings()Produce cas processor configuration parameter settings.static CasProcessorDeploymentParamsproduceCasProcessorDeploymentParams()Produce cas processor deployment params.static CasProcessorErrorHandlingproduceCasProcessorErrorHandling()Produce cas processor error handling.static CasProcessorErrorRateThresholdproduceCasProcessorErrorRateThreshold()Produce cas processor error rate threshold.static CasProcessorExecArgproduceCasProcessorExecArg()Produce cas processor exec arg.static CasProcessorExecutableproduceCasProcessorExecutable()Produce cas processor executable.static CasProcessorFilterproduceCasProcessorFilter(java.lang.String aFilter)Produce cas processor filter.static CasProcessorMaxRestartsproduceCasProcessorMaxRestarts()Produce cas processor max restarts.static CpeCasProcessorsproduceCasProcessors()Produce cas processors.static CpeCasProcessorsproduceCasProcessors(int aInputQSize, int aOutputQSize, int aPuCount, CpeDescription aDescriptor)Produce cas processors.static CpeCasProcessorsproduceCasProcessors(CpeDescription aDescriptor)Produce cas processors.static CasProcessorTimeoutproduceCasProcessorTimeout()Produce cas processor timeout.static CpeCollectionReaderproduceCollectionReader()Produce collection reader.static CpeCollectionReaderproduceCollectionReader(java.lang.String aCollectionReaderDescriptorPath)Produce collection reader.static CpeCollectionReaderproduceCollectionReader(java.lang.String aCollectionReaderDescriptorPath, CpeDescription aDescriptor)Produce collection reader.protected static CpeCollectionReaderCasInitializerproduceCollectionReaderCasInitializer(java.lang.String aInitializerDescriptorPath)Deprecated.As of v2.0, CAS Initializers are deprecated.static CpeCollectionReaderCasInitializerproduceCollectionReaderCasInitializer(java.lang.String aPath, CpeDescription aDescriptor)Deprecated.As of v2.0, CAS Initializers are deprecated.static CpeCollectionReaderIteratorproduceCollectionReaderIterator(java.lang.String aPath)Produce collection reader iterator.static CpeComponentDescriptorproduceComponentDescriptor(java.lang.String aPath)Produce component descriptor.static CpeIncludeproduceComponentDescriptorInclude()Produce component descriptor include.static CpeCheckpointproduceCpeCheckpoint()Produce cpe checkpoint.static CpeConfigurationproduceCpeConfiguration()Produce cpe configuration.static CpeConfigurationproduceCpeConfiguration(CpeDescription aDescriptor)Produce cpe configuration.static CpeTimerproduceCpeTimer(java.lang.String aTimerClass)Produce cpe timer.static CasProcessorDeploymentParamproduceDeployParam()Produce deploy param.static CasProcessorDeploymentParamsproduceDeployParams()Produce deploy params.static CpeDescriptionproduceDescriptor()Produce a new CpeDescription from scratch.static CpeDescriptionproduceDescriptor(java.io.InputStream aInput)Parse a CpeDescription from a given input stream.static CpeDescriptionproduceDescriptor(XMLInputSource aInput)Parse a CpeDescription from a descriptor file.static CpeLocalCasProcessorproduceLocalCasProcessor(java.lang.String aName, java.lang.String aSoFa)Produce local cas processor.static NameValuePairproduceNameValuePair()Produce name value pair.static CpeRemoteCasProcessorproduceRemoteCasProcessor(java.lang.String aName)Produce remote cas processor.static CpeResourceManagerConfigurationproduceResourceManagerConfiguration(java.lang.String aResourceMgrConfigurationPath)Produce resource manager configuration.static CpeResourceManagerConfigurationproduceResourceManagerConfiguration(java.lang.String aResourceMgrConfigurationPath, CpeDescription aDescriptor)Produce resource manager configuration.static CasProcessorRunInSeperateProcessproduceRunInSeperateProcess()Produce run in seperate process.static CasProcessorRuntimeEnvParamproduceRuntimeEnvParam()Produce runtime env param.static CpeSofaMappingproduceSofaMapping()Produce sofa mapping.static CpeSofaMappingsproduceSofaMappings()Produce sofa mappings.
-
-
-
Method Detail
-
produceDescriptor
public static CpeDescription produceDescriptor()
Produce a new CpeDescription from scratch. This CpeDescription will contain no components and will have default settings.- Returns:
- An empty CpeDescription object with default settings
-
produceDescriptor
public static CpeDescription produceDescriptor(XMLInputSource aInput) throws InvalidXMLException
Parse a CpeDescription from a descriptor file.- Parameters:
aInput- identifies the input file- Returns:
- The CpeDescription object parsed from the input
- Throws:
InvalidXMLException- if the descriptor is invalid
-
produceDescriptor
public static CpeDescription produceDescriptor(java.io.InputStream aInput) throws InvalidXMLException
Parse a CpeDescription from a given input stream.- Parameters:
aInput- identifies the input stream- Returns:
- The CpeDescription object parsed from the input
- Throws:
InvalidXMLException- if the descriptor is invalid
-
produceCollectionReader
public static CpeCollectionReader produceCollectionReader(java.lang.String aCollectionReaderDescriptorPath, CpeDescription aDescriptor) throws CpeDescriptorException
Produce collection reader.- Parameters:
aCollectionReaderDescriptorPath- a path to the collection reader descriptoraDescriptor- the descriptor to associate the collection reader with- Returns:
- the CPE Collection Reader
- Throws:
CpeDescriptorException- if there is a failure
-
produceCollectionReader
public static CpeCollectionReader produceCollectionReader(java.lang.String aCollectionReaderDescriptorPath) throws CpeDescriptorException
Produce collection reader.- Parameters:
aCollectionReaderDescriptorPath- the a collection reader descriptor path- Returns:
- the cpe collection reader
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceCollectionReader
public static CpeCollectionReader produceCollectionReader() throws CpeDescriptorException
Produce collection reader.- Returns:
- the cpe collection reader
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceCollectionReaderIterator
public static CpeCollectionReaderIterator produceCollectionReaderIterator(java.lang.String aPath) throws CpeDescriptorException
Produce collection reader iterator.- Parameters:
aPath- the a path- Returns:
- the cpe collection reader iterator
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceCollectionReaderCasInitializer
@Deprecated public static CpeCollectionReaderCasInitializer produceCollectionReaderCasInitializer(java.lang.String aPath, CpeDescription aDescriptor) throws CpeDescriptorException
Deprecated.As of v2.0, CAS Initializers are deprecated.Produce collection reader cas initializer.- Parameters:
aPath- don't useaDescriptor- don't use- Returns:
- a CPE Collection Reader CAS Initializer
- Throws:
CpeDescriptorException- passed thru
-
produceCollectionReaderCasInitializer
@Deprecated protected static CpeCollectionReaderCasInitializer produceCollectionReaderCasInitializer(java.lang.String aInitializerDescriptorPath)
Deprecated.As of v2.0, CAS Initializers are deprecated.Produce collection reader cas initializer.- Parameters:
aInitializerDescriptorPath- path to the initializer descriptor- Returns:
- CPE Collection Reader CAS Initializer
-
produceComponentDescriptor
public static CpeComponentDescriptor produceComponentDescriptor(java.lang.String aPath)
Produce component descriptor.- Parameters:
aPath- The path to the the CPE component Descriptor- Returns:
- the CPE Component Description
-
produceCpeConfiguration
public static CpeConfiguration produceCpeConfiguration(CpeDescription aDescriptor) throws CpeDescriptorException
Produce cpe configuration.- Parameters:
aDescriptor- CPE descriptor to use- Returns:
- the Cpe Configuration
- Throws:
CpeDescriptorException- if it fails
-
produceCpeConfiguration
public static CpeConfiguration produceCpeConfiguration() throws CpeDescriptorException
Produce cpe configuration.- Returns:
- the cpe configuration
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceRuntimeEnvParam
public static CasProcessorRuntimeEnvParam produceRuntimeEnvParam()
Produce runtime env param.- Returns:
- the cas processor runtime env param
-
produceDeployParams
public static CasProcessorDeploymentParams produceDeployParams()
Produce deploy params.- Returns:
- the cas processor deployment params
-
produceDeployParam
public static CasProcessorDeploymentParam produceDeployParam()
Produce deploy param.- Returns:
- the cas processor deployment param
-
produceComponentDescriptorInclude
public static CpeInclude produceComponentDescriptorInclude()
Produce component descriptor include.- Returns:
- the cpe include
-
produceCasProcessors
public static CpeCasProcessors produceCasProcessors(CpeDescription aDescriptor) throws CpeDescriptorException
Produce cas processors.- Parameters:
aDescriptor- to use to produce the CPE CAS Processors- Returns:
- Cpe CAS Processors
- Throws:
CpeDescriptorException- if an error occurs
-
produceCasProcessors
public static CpeCasProcessors produceCasProcessors() throws CpeDescriptorException
Produce cas processors.- Returns:
- the cpe cas processors
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceCasProcessors
public static CpeCasProcessors produceCasProcessors(int aInputQSize, int aOutputQSize, int aPuCount, CpeDescription aDescriptor) throws CpeDescriptorException
Produce cas processors.- Parameters:
aInputQSize- the input queue sizeaOutputQSize- the output queue sizeaPuCount- the number of processing unitsaDescriptor- the CPE descriptor- Returns:
- CPE CAS Processors
- Throws:
CpeDescriptorException- if an error occurs
-
produceCasProcessor
public static CpeIntegratedCasProcessor produceCasProcessor(java.lang.String aName)
Produce cas processor.- Parameters:
aName- the a name- Returns:
- the cpe integrated cas processor
-
produceLocalCasProcessor
public static CpeLocalCasProcessor produceLocalCasProcessor(java.lang.String aName, java.lang.String aSoFa) throws CpeDescriptorException
Produce local cas processor.- Parameters:
aName- the processor nameaSoFa- the processor SofA- Returns:
- CPE Local CAS Processor
- Throws:
CpeDescriptorException- if an error occurs
-
produceRemoteCasProcessor
public static CpeRemoteCasProcessor produceRemoteCasProcessor(java.lang.String aName) throws CpeDescriptorException
Produce remote cas processor.- Parameters:
aName- the processor name- Returns:
- CPE Remote CAS Processor
- Throws:
CpeDescriptorException- if an error occurs
-
produceCpeTimer
public static CpeTimer produceCpeTimer(java.lang.String aTimerClass)
Produce cpe timer.- Parameters:
aTimerClass- the a timer class- Returns:
- the cpe timer
-
produceResourceManagerConfiguration
public static CpeResourceManagerConfiguration produceResourceManagerConfiguration(java.lang.String aResourceMgrConfigurationPath, CpeDescription aDescriptor) throws CpeDescriptorException
Produce resource manager configuration.- Parameters:
aResourceMgrConfigurationPath- the a resource mgr configuration pathaDescriptor- the a descriptor- Returns:
- the cpe resource manager configuration
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceResourceManagerConfiguration
public static CpeResourceManagerConfiguration produceResourceManagerConfiguration(java.lang.String aResourceMgrConfigurationPath) throws CpeDescriptorException
Produce resource manager configuration.- Parameters:
aResourceMgrConfigurationPath- the a resource mgr configuration path- Returns:
- the cpe resource manager configuration
- Throws:
CpeDescriptorException- the cpe descriptor exception
-
produceCasProcessorTimeout
public static CasProcessorTimeout produceCasProcessorTimeout()
Produce cas processor timeout.- Returns:
- the cas processor timeout
-
produceCasProcessorMaxRestarts
public static CasProcessorMaxRestarts produceCasProcessorMaxRestarts()
Produce cas processor max restarts.- Returns:
- the cas processor max restarts
-
produceCasProcessorErrorRateThreshold
public static CasProcessorErrorRateThreshold produceCasProcessorErrorRateThreshold()
Produce cas processor error rate threshold.- Returns:
- the cas processor error rate threshold
-
produceCasProcessorFilter
public static CasProcessorFilter produceCasProcessorFilter(java.lang.String aFilter)
Produce cas processor filter.- Parameters:
aFilter- the filter string- Returns:
- a CAS Processor Filter
-
produceCasProcessorErrorHandling
public static CasProcessorErrorHandling produceCasProcessorErrorHandling()
Produce cas processor error handling.- Returns:
- the cas processor error handling
-
produceCpeCheckpoint
public static CpeCheckpoint produceCpeCheckpoint()
Produce cpe checkpoint.- Returns:
- the cpe checkpoint
-
produceCasProcessorDeploymentParams
public static CasProcessorDeploymentParams produceCasProcessorDeploymentParams()
Produce cas processor deployment params.- Returns:
- the cas processor deployment params
-
produceCasProcessorExecArg
public static CasProcessorExecArg produceCasProcessorExecArg()
Produce cas processor exec arg.- Returns:
- the cas processor exec arg
-
produceCasProcessorExecutable
public static CasProcessorExecutable produceCasProcessorExecutable()
Produce cas processor executable.- Returns:
- the cas processor executable
-
produceRunInSeperateProcess
public static CasProcessorRunInSeperateProcess produceRunInSeperateProcess()
Produce run in seperate process.- Returns:
- the cas processor run in seperate process
-
produceCasProcessorConfigurationParameterSettings
public static CasProcessorConfigurationParameterSettings produceCasProcessorConfigurationParameterSettings()
Produce cas processor configuration parameter settings.- Returns:
- the cas processor configuration parameter settings
-
produceNameValuePair
public static NameValuePair produceNameValuePair()
Produce name value pair.- Returns:
- the name value pair
-
produceSofaMapping
public static CpeSofaMapping produceSofaMapping()
Produce sofa mapping.- Returns:
- the cpe sofa mapping
-
produceSofaMappings
public static CpeSofaMappings produceSofaMappings()
Produce sofa mappings.- Returns:
- the cpe sofa mappings
-
-