opennlp.uima.tokenize
Class TokenizerTrainer
java.lang.Object
org.apache.uima.resource.Resource_ImplBase
org.apache.uima.resource.ConfigurableResource_ImplBase
org.apache.uima.collection.CasConsumer_ImplBase
opennlp.uima.tokenize.TokenizerTrainer
- All Implemented Interfaces:
- org.apache.uima.collection.base_cpm.CasObjectProcessor, org.apache.uima.collection.base_cpm.CasProcessor, org.apache.uima.collection.CasConsumer, org.apache.uima.resource.ConfigurableResource, org.apache.uima.resource.Resource
public final class TokenizerTrainer
- extends org.apache.uima.collection.CasConsumer_ImplBase
OpenNLP Tokenizer trainer.
Mandatory parameters
Type | Name | Description |
String | opennlp.uima.ModelName | The name of the model file |
String | opennlp.uima.SentenceType | The full name of the sentence type |
String | opennlp.uima.TokenType | The full name of the token type |
Optional parameters
Type | Name | Description |
Boolean | opennlp.uima.tokenizer.IsSkipAlphaNumerics |
Fields inherited from interface org.apache.uima.resource.Resource |
PARAM_AGGREGATE_SOFA_MAPPINGS, PARAM_CONFIG_PARAM_SETTINGS, PARAM_PERFORMANCE_TUNING_SETTINGS, PARAM_RESOURCE_MANAGER, PARAM_UIMA_CONTEXT |
Method Summary |
void |
collectionProcessComplete(org.apache.uima.util.ProcessTrace arg0)
Called if the processing is finished, this method
does the training. |
void |
destroy()
Releases allocated resources. |
void |
initialize()
Initializes the current instance. |
boolean |
isStateless()
The trainer is not stateless. |
void |
processCas(org.apache.uima.cas.CAS cas)
Process the given CAS object. |
void |
typeSystemInit(org.apache.uima.cas.TypeSystem typeSystem)
Initialize the current instance with the given type system. |
Methods inherited from class org.apache.uima.collection.CasConsumer_ImplBase |
batchProcessComplete, getProcessingResourceMetaData, initialize, isReadOnly, processCas, reconfigure |
Methods inherited from class org.apache.uima.resource.ConfigurableResource_ImplBase |
getConfigParameterValue, getConfigParameterValue, setConfigParameterValue, setConfigParameterValue |
Methods inherited from class org.apache.uima.resource.Resource_ImplBase |
getCasManager, getLogger, getMetaData, getResourceManager, getUimaContext, getUimaContextAdmin, setLogger |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.uima.resource.ConfigurableResource |
getConfigParameterValue, getConfigParameterValue, setConfigParameterValue, setConfigParameterValue |
Methods inherited from interface org.apache.uima.resource.Resource |
getLogger, getMetaData, getResourceManager, getUimaContext, getUimaContextAdmin, setLogger |
IS_ALPHA_NUMERIC_OPTIMIZATION
public static final java.lang.String IS_ALPHA_NUMERIC_OPTIMIZATION
- See Also:
- Constant Field Values
TokenizerTrainer
public TokenizerTrainer()
initialize
public void initialize()
throws org.apache.uima.resource.ResourceInitializationException
- Initializes the current instance.
- Overrides:
initialize
in class org.apache.uima.collection.CasConsumer_ImplBase
- Throws:
org.apache.uima.resource.ResourceInitializationException
typeSystemInit
public void typeSystemInit(org.apache.uima.cas.TypeSystem typeSystem)
throws org.apache.uima.resource.ResourceInitializationException
- Initialize the current instance with the given type system.
- Specified by:
typeSystemInit
in interface org.apache.uima.collection.base_cpm.CasObjectProcessor
- Overrides:
typeSystemInit
in class org.apache.uima.collection.CasConsumer_ImplBase
- Throws:
org.apache.uima.resource.ResourceInitializationException
processCas
public void processCas(org.apache.uima.cas.CAS cas)
- Process the given CAS object.
collectionProcessComplete
public void collectionProcessComplete(org.apache.uima.util.ProcessTrace arg0)
throws org.apache.uima.resource.ResourceProcessException,
java.io.IOException
- Called if the processing is finished, this method
does the training.
- Specified by:
collectionProcessComplete
in interface org.apache.uima.collection.base_cpm.CasProcessor
- Overrides:
collectionProcessComplete
in class org.apache.uima.collection.CasConsumer_ImplBase
- Throws:
org.apache.uima.resource.ResourceProcessException
java.io.IOException
isStateless
public boolean isStateless()
- The trainer is not stateless.
- Specified by:
isStateless
in interface org.apache.uima.collection.base_cpm.CasProcessor
- Overrides:
isStateless
in class org.apache.uima.collection.CasConsumer_ImplBase
destroy
public void destroy()
- Releases allocated resources.
- Specified by:
destroy
in interface org.apache.uima.resource.Resource
- Overrides:
destroy
in class org.apache.uima.collection.CasConsumer_ImplBase
Copyright © 2011 The Apache Software Foundation. All Rights Reserved.