opennlp.tools.cmdline
Class ModelLoader<T>

java.lang.Object
  extended by opennlp.tools.cmdline.ModelLoader<T>
Type Parameters:
T -
Direct Known Subclasses:
ChunkerModelLoader, DoccatModelLoader, POSModelLoader

public abstract class ModelLoader<T>
extends Object

Loads a model and does all the error handling for the command line tools.

Note: Do not use this class, internal use only!


Constructor Summary
protected ModelLoader(String modelName)
           
 
Method Summary
 T load(File modelFile)
           
protected abstract  T loadModel(InputStream modelIn)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModelLoader

protected ModelLoader(String modelName)
Method Detail

loadModel

protected abstract T loadModel(InputStream modelIn)
                        throws IOException,
                               InvalidFormatException
Throws:
IOException
InvalidFormatException

load

public T load(File modelFile)


Copyright © 2010. All Rights Reserved.