public class NameSample
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEFAULT_TYPE
The a default type value when there is no type in training data.
|
Constructor and Description |
---|
NameSample(java.lang.String[] sentence,
Span[] names,
boolean clearAdaptiveData) |
NameSample(java.lang.String[] sentence,
Span[] names,
java.lang.String[][] additionalContext,
boolean clearAdaptiveData)
Initializes the current instance.
|
NameSample(java.lang.String id,
java.lang.String[] sentence,
Span[] names,
java.lang.String[][] additionalContext,
boolean clearAdaptiveData) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String[][] |
getAdditionalContext() |
java.lang.String |
getId() |
Span[] |
getNames() |
java.lang.String[] |
getSentence() |
boolean |
isClearAdaptiveDataSet() |
static NameSample |
parse(java.lang.String taggedTokens,
boolean isClearAdaptiveData) |
static NameSample |
parse(java.lang.String taggedTokens,
java.lang.String defaultType,
boolean isClearAdaptiveData) |
java.lang.String |
toString() |
public static final java.lang.String DEFAULT_TYPE
public NameSample(java.lang.String id, java.lang.String[] sentence, Span[] names, java.lang.String[][] additionalContext, boolean clearAdaptiveData)
public NameSample(java.lang.String[] sentence, Span[] names, java.lang.String[][] additionalContext, boolean clearAdaptiveData)
sentence
- training sentencenames
- additionalContext
- clearAdaptiveData
- if true the adaptive data of the
feature generators is clearedpublic NameSample(java.lang.String[] sentence, Span[] names, boolean clearAdaptiveData)
public java.lang.String getId()
public java.lang.String[] getSentence()
public Span[] getNames()
public java.lang.String[][] getAdditionalContext()
public boolean isClearAdaptiveDataSet()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public static NameSample parse(java.lang.String taggedTokens, boolean isClearAdaptiveData) throws java.io.IOException
java.io.IOException
public static NameSample parse(java.lang.String taggedTokens, java.lang.String defaultType, boolean isClearAdaptiveData) throws java.io.IOException
java.io.IOException
Copyright © 2010 - 2020 Adobe. All Rights Reserved