|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.languagecomputer.api.text.DefaultText com.languagecomputer.api.text.DefaultQuestionAnswerPair
public class DefaultQuestionAnswerPair
Default implementation of an QuestionAnswerPair
.
DefaultText
Field Summary |
---|
Fields inherited from interface com.languagecomputer.api.text.QuestionAnswerPair |
---|
TYPE |
Constructor Summary | |
---|---|
DefaultQuestionAnswerPair()
Creates a new DefaultQuestionAnswerPair . |
Method Summary | |
---|---|
Text |
getAnswer()
Returns the answer Text for this QuestionAnswerPair . |
String |
getQuestion()
Returns the question for this QuestionAnswerPair . |
void |
setAnnotationType(AnnotationType annType)
Not necessary: defaults to QuestionAnswerPair.TYPE . |
void |
setAnswer(Text answer)
Sets the answer to use for this QuestionAnswerPair . |
void |
setQuestion(String question)
Sets the question to use for this QuestionAnswerPair . |
String |
toString()
Returns a String representation of a
DefaultQuestionAnswerPair . |
Methods inherited from class com.languagecomputer.api.text.DefaultText |
---|
getAnnotationType, getCongruentAnnotations, getDocument, getDocumentID, getEndCharOffset, getIntersectingAnnotations, getRawString, getStartCharOffset, getSubAnnotations, getSuperAnnotations, setDocument, setEndCharOffset, setRawString, setStartCharOffset |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.languagecomputer.api.text.Text |
---|
getAnnotationType, getCongruentAnnotations, getDocument, getDocumentID, getEndCharOffset, getIntersectingAnnotations, getRawString, getStartCharOffset, getSubAnnotations, getSuperAnnotations |
Constructor Detail |
---|
public DefaultQuestionAnswerPair()
DefaultQuestionAnswerPair
.
Method Detail |
---|
public void setAnnotationType(AnnotationType annType)
QuestionAnswerPair.TYPE
.
setAnnotationType
in class DefaultText
annType
- AnnotationType
to use for this
DefaultQuestionAnswerPair
.Text.getAnnotationType()
,
AnnotationType
public void setQuestion(String question)
QuestionAnswerPair
.
question
- The question for this QuestionAnswerPair
.getQuestion()
public String getQuestion()
QuestionAnswerPair
.
getQuestion
in interface QuestionAnswerPair
String
.public void setAnswer(Text answer)
QuestionAnswerPair
.
answer
- The answer Text
for this
QuestionAnswerPair
.getAnswer()
public Text getAnswer()
Text
for this QuestionAnswerPair
.
getAnswer
in interface QuestionAnswerPair
Text
.public String toString()
String
representation of a
DefaultQuestionAnswerPair
.
toString
in class DefaultText
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |