|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.myfaces.trinidaddemo.survey.CheckboxQuestionBean
public class CheckboxQuestionBean
class CheckboxQuestionBean This bean represents a single multiple-answer checkbox style question. It has fields for the question prompt, a list of choices, and all the correct checkboxes in the answer. [Note: Due to a lack of support for dynamically iterating through data in early releases of Trinidad, this bean contains special get methods that help iterate through the list of choices for printing out on the screen.]
| Constructor Summary | |
|---|---|
CheckboxQuestionBean()
Class constructor (no arguments). |
|
CheckboxQuestionBean(String prompt,
ArrayList<String> choices,
int correctAnswer,
boolean checkbox0,
boolean checkbox1,
boolean checkbox2,
boolean checkbox3)
Class constructor. |
|
| Method Summary | |
|---|---|
boolean |
getCheckbox0()
IDE generated accessors |
boolean |
getCheckbox1()
|
boolean |
getCheckbox2()
|
boolean |
getCheckbox3()
|
int |
getCorrectAnswer()
|
String |
getCorrectAnswerMessage()
returns a message describing the correct answer choices. |
String |
getCorrectAnswerMessage(int checkboxNum)
Returns a message describing the correct answer for a particular checkbox. |
String |
getPrompt()
returns the question prompt. |
String |
getText1()
|
String |
getText2()
|
String |
getText3()
|
String |
getText4()
|
String |
toString()
typical toString method |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public CheckboxQuestionBean()
public CheckboxQuestionBean(String prompt,
ArrayList<String> choices,
int correctAnswer,
boolean checkbox0,
boolean checkbox1,
boolean checkbox2,
boolean checkbox3)
| Method Detail |
|---|
public String getPrompt()
getPrompt in interface QuestionBeanpublic String getText1()
public String getText2()
public String getText3()
public String getText4()
public String toString()
toString in class Objectpublic String getCorrectAnswerMessage()
getCorrectAnswerMessage in interface QuestionBeanpublic String getCorrectAnswerMessage(int checkboxNum)
checkboxNum - the index of the checkbox
public boolean getCheckbox0()
public boolean getCheckbox1()
public boolean getCheckbox2()
public boolean getCheckbox3()
public int getCorrectAnswer()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||