public class DiscourseEntity extends DiscourseElement
Constructor and Description |
---|
DiscourseEntity(MentionContext mention)
Creates a new entity based on the specified mention.
|
DiscourseEntity(MentionContext mention,
GenderEnum gender,
double genderProb,
NumberEnum number,
double numberProb)
Creates a new entity based on the specified mention and its specified gender and number properties.
|
Modifier and Type | Method and Description |
---|---|
String |
getCategory()
Returns the semantic category of this entity.
|
GenderEnum |
getGender()
Returns the gender associated with this entity.
|
double |
getGenderProbability()
Returns the probability for the gender associated with this entity.
|
NumberEnum |
getNumber()
Returns the number associated with this entity.
|
double |
getNumberProbability()
Returns the probability for the number associated with this entity.
|
void |
setCategory(String cat)
Specifies the semantic category of this entity.
|
void |
setGender(GenderEnum gender)
Specifies the gender of this entity.
|
void |
setGenderProbability(double p)
Specifies the probability of the gender of this entity.
|
void |
setNumber(NumberEnum number)
Specifies the number of this entity.
|
void |
setNumberProbability(double p)
Specifies the probability of the number of this entity.
|
addMention, getId, getLastExtent, getMentions, getNumMentions, getRecentMentions, setId, toString
public DiscourseEntity(MentionContext mention, GenderEnum gender, double genderProb, NumberEnum number, double numberProb)
mention
- The first mention of this entity.gender
- The gender of this entity.genderProb
- The probability that the specified gender is correct.number
- The number for this entity.numberProb
- The probability that the specified number is correct.public DiscourseEntity(MentionContext mention)
mention
- The first mention of this entity.public String getCategory()
public void setCategory(String cat)
cat
- The semantic category of the entity.public GenderEnum getGender()
public double getGenderProbability()
public NumberEnum getNumber()
public double getNumberProbability()
public void setGender(GenderEnum gender)
gender
- The gender.public void setGenderProbability(double p)
p
- the probability of the gender of this entity.public void setNumber(NumberEnum number)
number
- public void setNumberProbability(double p)
p
- the probability of the number of this entity.Copyright © 2016 The Apache Software Foundation. All rights reserved.