public interface IQuestion extends IQuestionnaireBase
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
getAnswer()
Returns answer of the question.
|
IUser |
getAnsweredBy()
Returns the user who last answered
|
java.util.Date |
getAnsweredOnDate()
Returns the timestamp when the answer was persisted
|
AnswerType |
getAnswerType()
Returns answer type
|
java.lang.Float |
getMaxRiskScore()
Returns maximum risk score of the question.
|
java.util.List<IQuestionOption> |
getOptions()
Returns list of
IQuestionOption for a selection question. |
java.util.List<java.lang.String> |
getRequires()
Returns the list of evidence types required by this question for the
question to be considered complete.
|
java.lang.Float |
getScore()
Returns score of the question.
|
QuestionStatus |
getStatus()
Returns the status of the question
|
java.util.List<IQuestionTableColumn> |
getTableColumns()
Returns list of
IQuestionTableColumn for a selection question. |
IQuestionDependency |
getVisibilityDependency()
Returns a question dependency object that represents visibility dependency.
|
int |
getWeight()
Returns weight of the question.
|
boolean |
hasRequiredEvidences()
Returns a flag to indicate if the question meets all the required evidences.
|
boolean |
isHidden()
Returns a flag to indicate if the question is hidden because of the visibility dependency condition.
|
boolean |
isShowAttachmentTab()
Returns a flag to indicate if need to show the question attachment tab.
|
boolean |
isShowCommentTab()
Returns a flag to indicate if need to show the question comment tab.
|
void |
setAnswer(java.lang.Object answer)
Sets answer of the question.
|
void |
setAnswerType(AnswerType aType)
Sets answer type of the question
|
void |
setOptions(java.util.List<IQuestionOption> options)
Sets options for selection question.
|
void |
setRequires(java.util.List<java.lang.String> requires)
Sets the list of evidence types required by this question for the
question to be considered complete.
|
void |
setShowAttachmentTab(boolean showAttachmentTab)
Sets if need to show the question attachment tab
|
void |
setShowCommentTab(boolean showCommentTab)
Sets if need to show the question comment tab
|
void |
setStatus(QuestionStatus status)
Sets the status of the question
|
void |
setTableColumns(java.util.List<IQuestionTableColumn> columns)
Sets table columns for selection question.
|
void |
setVisibilityDependency(IQuestionDependency questiondependency)
Sets a question dependency object.
|
void |
setWeight(int weight)
Sets weight of the question.
|
getDescription, getId, getOrder, getParentId, getRationale, getReference, getReportID, getTitle, setDescription, setOrder, setRationale, setReference, setTitleAnswerType getAnswerType()
void setAnswerType(AnswerType aType)
aType - answer type enumjava.util.List<IQuestionOption> getOptions()
IQuestionOption for a selection question.
Options are only applicable to AnswerType.RADIO and AnswerType.MULTI_CHECK.IQuestionOptionvoid setOptions(java.util.List<IQuestionOption> options)
options - list of IQuestionOptionvoid setTableColumns(java.util.List<IQuestionTableColumn> columns)
columns - list of IQuestionTableColumnjava.util.List<IQuestionTableColumn> getTableColumns()
IQuestionTableColumn for a selection question.
Options are only applicable to AnswerType.TABLE_ANSWER.IQuestionTableColumnIQuestionDependency getVisibilityDependency()
IQuestionDependencyvoid setVisibilityDependency(IQuestionDependency questiondependency)
questiondependency - IQuestionDependencyvoid setWeight(int weight)
weight - int getWeight()
java.lang.Float getScore()
java.lang.Float getMaxRiskScore()
boolean isHidden()
boolean hasRequiredEvidences()
java.lang.Object getAnswer()
AnswerType.
AnswerType.RADIO : The answer type is Integer which corresponds to IQuestionOption.getValue()
AnswerType.MULTI_CHECK : The answer type is List of Integer which corresponds to IQuestionOption.getValue()
AnswerType.TEXT, AnswerType.TEXT_AREA : The answer type is String
AnswerType.TABLE_ANSWER : The answer type is List of List of String which are cell values of a table answer
void setAnswer(java.lang.Object answer)
getAnswer() for the acceptable object type. Otherwise, this call throws an IllegalArgumentException.
The answer can be null when it is unanswered.answer - java.util.List<java.lang.String> getRequires()
void setRequires(java.util.List<java.lang.String> requires)
requires - List of strings (e.g., ["comment", "attachment"] )java.util.Date getAnsweredOnDate()
QuestionStatus getStatus()
QuestionStatusvoid setStatus(QuestionStatus status)
status - QuestionStatusboolean isShowCommentTab()
void setShowCommentTab(boolean showCommentTab)
showCommentTab - boolean isShowAttachmentTab()
void setShowAttachmentTab(boolean showAttachmentTab)
showAttachmentTab -
Licensed Materials - Property of IBM
OpenPages with Watson (PID: 5725-D51)
© Copyright IBM Corporation 2013, 2020. All Rights Reserved.
US Government Users Restricted Rights -
Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.