Package opennlp.tools.ml.maxent.io
Class QNModelReader
java.lang.Object
opennlp.tools.ml.model.AbstractModelReader
opennlp.tools.ml.maxent.io.GISModelReader
opennlp.tools.ml.maxent.io.QNModelReader
- Direct Known Subclasses:
- BinaryQNModelReader
The base class for readers of 
QN models.- See Also:
- 
Constructor SummaryConstructorsConstructorDescriptionQNModelReader(File file) Initializes aQNModelReadervia aFile.QNModelReader(DataReader dataReader) Initializes aQNModelReadervia aDataReader.
- 
Method SummaryModifier and TypeMethodDescriptionvoidChecks the model type via the the underlyingDataReader.Retrieves a model from disk.Methods inherited from class opennlp.tools.ml.model.AbstractModelReadergetModel, readDouble, readInt, readUTF
- 
Constructor Details- 
QNModelReaderInitializes aQNModelReadervia aDataReader.- Parameters:
- dataReader- The- DataReaderthat references the model to be read.
 
- 
QNModelReaderInitializes aQNModelReadervia aFile.- Parameters:
- file- The- Filethat references the model to be read.
- Throws:
- IOException- Thrown if IO errors occurred.
 
 
- 
- 
Method Details- 
checkModelTypeDescription copied from class:AbstractModelReaderChecks the model type via the the underlyingDataReader.- Overrides:
- checkModelTypein class- GISModelReader
- Throws:
- IOException- Thrown if IO errors occurred checking the model type.
 
- 
constructModelRetrieves a model from disk.If you are creating a reader for a format which won't work with this (perhaps a database or xml file), override this method and ignore the other methods provided in this abstract class. - Overrides:
- constructModelin class- GISModelReader
- Returns:
- The QNModelstored in the format and location specified to thisQNModelReader(usually via its constructor).
- Throws:
- IOException- Thrown if IO errors occurred during (re-)construction.
 
 
-