|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object opennlp.tools.coref.DiscourseElement
public abstract class DiscourseElement
Represents an item in which can be put into the discourse model. Object which are to be placed in the discourse model should extend this class.
DiscourseModel
Constructor Summary | |
---|---|
DiscourseElement(MentionContext mention)
Creates a new discourse element which contains the specified mention. |
Method Summary | |
---|---|
void |
addMention(MentionContext mention)
Adds the specified mention to this discourse element. |
int |
getId()
Returns the id associated with this element. |
MentionContext |
getLastExtent()
Returns the last mention for this element. |
Iterator<MentionContext> |
getMentions()
Returns an iterator over the mentions which iterates through them based on their occurrence in the document. |
int |
getNumMentions()
Returns the number of mentions in this element. |
Iterator<MentionContext> |
getRecentMentions()
Returns an iterator over the mentions which iterates through them based on which were most recently mentioned. |
void |
setId(int id)
Associates an id with this element. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DiscourseElement(MentionContext mention)
mention
- The mention which begins this discourse element.Method Detail |
---|
public Iterator<MentionContext> getRecentMentions()
Iterator
.public Iterator<MentionContext> getMentions()
Iterator
public int getNumMentions()
public void addMention(MentionContext mention)
mention
- The mention to be added.public MentionContext getLastExtent()
public void setId(int id)
id
- The id.public int getId()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |