org.apache.ctakes.chunker.ae
Class Chunker

java.lang.Object
  extended by org.apache.uima.analysis_component.AnalysisComponent_ImplBase
      extended by org.apache.uima.analysis_component.Annotator_ImplBase
          extended by org.apache.uima.analysis_component.JCasAnnotator_ImplBase
              extended by org.apache.ctakes.chunker.ae.Chunker
All Implemented Interfaces:
org.apache.uima.analysis_component.AnalysisComponent

public class Chunker
extends org.apache.uima.analysis_component.JCasAnnotator_ImplBase

This class provides a UIMA wrapper for the OpenNLP opennlp.tools.chunker.Chunker class. This wrapper can generate chunks of any kind as specified by the chunker model and the chunk creator.


Field Summary
static java.lang.String CHUNKER_CREATOR_CLASS_PARAM
          "ChunkCreatorClass" is a required, single, string parameter that specifies the chunker creator class to instantiate.
static java.lang.String CHUNKER_MODEL_FILE_PARAM
          "ChunkerModel" is a required, single, string parameter that contains the file name of the chunker model.
(package private)  ChunkCreator chunkerCreator
           
 
Constructor Summary
Chunker()
           
 
Method Summary
 void initialize(org.apache.uima.UimaContext uimaContext)
           
 void process(org.apache.uima.jcas.JCas jCas)
           
 
Methods inherited from class org.apache.uima.analysis_component.JCasAnnotator_ImplBase
getRequiredCasInterface, process
 
Methods inherited from class org.apache.uima.analysis_component.Annotator_ImplBase
getCasInstancesRequired, hasNext, next
 
Methods inherited from class org.apache.uima.analysis_component.AnalysisComponent_ImplBase
batchProcessComplete, collectionProcessComplete, destroy, getContext, getResultSpecification, reconfigure, setResultSpecification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CHUNKER_MODEL_FILE_PARAM

public static final java.lang.String CHUNKER_MODEL_FILE_PARAM
"ChunkerModel" is a required, single, string parameter that contains the file name of the chunker model. The model file name should end with ".bin.gz" or ".txt". If this is not the case, then please see resources/models/README.

See Also:
Constant Field Values

CHUNKER_CREATOR_CLASS_PARAM

public static final java.lang.String CHUNKER_CREATOR_CLASS_PARAM
"ChunkCreatorClass" is a required, single, string parameter that specifies the chunker creator class to instantiate. A chunker creator determines how chunk annotations are created.

See Also:
ChunkCreator, DefaultChunkCreator, PhraseTypeChunkCreator, Constant Field Values

chunkerCreator

ChunkCreator chunkerCreator
Constructor Detail

Chunker

public Chunker()
Method Detail

initialize

public void initialize(org.apache.uima.UimaContext uimaContext)
                throws org.apache.uima.resource.ResourceInitializationException
Specified by:
initialize in interface org.apache.uima.analysis_component.AnalysisComponent
Overrides:
initialize in class org.apache.uima.analysis_component.AnalysisComponent_ImplBase
Throws:
org.apache.uima.resource.ResourceInitializationException

process

public void process(org.apache.uima.jcas.JCas jCas)
             throws org.apache.uima.analysis_engine.AnalysisEngineProcessException
Specified by:
process in class org.apache.uima.analysis_component.JCasAnnotator_ImplBase
Throws:
org.apache.uima.analysis_engine.AnalysisEngineProcessException