public abstract class BaseModel extends Object implements ArtifactProvider, Serializable
| Modifier and Type | Field and Description | 
|---|---|
static String | 
TRAINING_CUTOFF_PROPERTY  | 
static String | 
TRAINING_EVENTHASH_PROPERTY  | 
static String | 
TRAINING_ITERATIONS_PROPERTY  | 
| Modifier and Type | Method and Description | 
|---|---|
<T> T | 
getArtifact(String key)
Gets an artifact by name 
 | 
String | 
getLanguage()
Retrieves the language code of the material which
 was used to train the model or x-unspecified if
 non was set. 
 | 
String | 
getManifestProperty(String key)
Retrieves the value to the given key from the manifest.properties
 entry. 
 | 
Version | 
getVersion()
Retrieves the OpenNLP version which was used
 to create the model. 
 | 
boolean | 
isLoadedFromSerialized()
Indicates if this provider was loaded from serialized. 
 | 
void | 
serialize(OutputStream out)
Serializes the model to the given  
OutputStream. | 
public static final String TRAINING_CUTOFF_PROPERTY
public static final String TRAINING_ITERATIONS_PROPERTY
public static final String TRAINING_EVENTHASH_PROPERTY
public final String getManifestProperty(String key)
getManifestProperty in interface ArtifactProviderkey - public final String getLanguage()
getLanguage in interface ArtifactProviderpublic final Version getVersion()
public final void serialize(OutputStream out) throws IOException
OutputStream.out - stream to write the model toIOExceptionpublic <T> T getArtifact(String key)
ArtifactProvidergetArtifact in interface ArtifactProviderpublic boolean isLoadedFromSerialized()
ArtifactProviderisLoadedFromSerialized in interface ArtifactProviderCopyright © 2017 The Apache Software Foundation. All rights reserved.