public class LabeledScoredConstituent extends LabeledConstituent
LabeledScoredConstituent
object defines an edge in a graph
with a label and a score.Constructor and Description |
---|
LabeledScoredConstituent()
Create an empty
LabeledScoredConstituent object. |
LabeledScoredConstituent(int start,
int end)
Create a
LabeledScoredConstituent object with given
values. |
LabeledScoredConstituent(int start,
int end,
Label label,
double score)
Create a
LabeledScoredConstituent object with given
values. |
Modifier and Type | Method and Description |
---|---|
ConstituentFactory |
constituentFactory()
Return a factory for this kind of constituent.
|
static ConstituentFactory |
factory()
Return a factory for this kind of constituent.
|
LabelFactory |
labelFactory()
Return a factory for this kind of label.
|
double |
score()
Returns the score associated with the current node, or Nan
if there is no score
|
void |
setScore(double score)
Sets the score associated with the current node, if there is one
|
label, setFromString, setLabel
end, setEnd, setStart, start
public LabeledScoredConstituent()
LabeledScoredConstituent
object.public LabeledScoredConstituent(int start, int end)
LabeledScoredConstituent
object with given
values.start
- start node of edgeend
- end node of edgepublic LabeledScoredConstituent(int start, int end, Label label, double score)
LabeledScoredConstituent
object with given
values.start
- start node of edgeend
- end node of edgepublic double score()
score
in interface Scored
score
in class Constituent
public void setScore(double score)
setScore
in class Constituent
public LabelFactory labelFactory()
labelFactory
in interface Label
labelFactory
in class LabeledConstituent
public ConstituentFactory constituentFactory()
constituentFactory
in class LabeledConstituent
public static ConstituentFactory factory()