opennlp.tools.namefind
Class TokenNameFinderModel
java.lang.Object
opennlp.tools.util.model.BaseModel
opennlp.tools.namefind.TokenNameFinderModel
public class TokenNameFinderModel
- extends BaseModel
The TokenNameFinderModel is the model used
by a learnable TokenNameFinder.
- See Also:
NameFinderME
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TokenNameFinderModel
public TokenNameFinderModel(String languageCode,
opennlp.model.AbstractModel nameFinderModel,
Map<String,Object> resources,
Map<String,String> manifestInfoEntries)
TokenNameFinderModel
public TokenNameFinderModel(InputStream in)
throws IOException,
InvalidFormatException
- Throws:
IOException
InvalidFormatException
getNameFinderModel
public opennlp.model.AbstractModel getNameFinderModel()
- Retrieves the
TokenNameFinder model.
- Returns:
isModelValid
public static boolean isModelValid(opennlp.model.MaxentModel model)
createArtifactSerializers
protected void createArtifactSerializers(Map<String,ArtifactSerializer> serializers)
- Description copied from class:
BaseModel
- Registers all
ArtifactSerializer for their artifact file name extensions.
The registered ArtifactSerializer are used to create and serialize
resources in the model package.
Override this method to register custom ArtifactSerializers.
Note:
Subclasses should generally invoke super.createArtifactSerializers at the beginning
of this method.
This method is called during construction.
- Overrides:
createArtifactSerializers in class BaseModel
- Parameters:
serializers - the key of the map is the file extension used to lookup
the ArtifactSerializer.
validateArtifactMap
protected void validateArtifactMap()
throws InvalidFormatException
- Description copied from class:
BaseModel
- Validates the parsed artifacts. If something is not
valid subclasses should throw an
InvalidFormatException.
Note:
Subclasses should generally invoke super.validateArtifactMap at the beginning
of this method.
- Overrides:
validateArtifactMap in class BaseModel
- Throws:
InvalidFormatException
Copyright © 2010. All Rights Reserved.