|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.neurowork.mobile.android.fw.levels.impl.Results
public class Results
Class for save and show quiz results.
Constructor Summary | |
---|---|
Results()
Constructor for default penalty Results objects |
|
Results(double penalty)
Constructor |
Method Summary | |
---|---|
float[] |
getResults()
Return results of your quiz. |
float |
getScore()
Return the final score based on the correct or incorrect questions and their weight and penalties. |
int |
getTotalQuestions()
Return how many questions the Results class have. |
int |
getTotalWeight()
Return the total weight of all quiz questions. |
void |
setAnswer(int weight,
boolean correct)
Set the result of a quiz answer |
void |
setTotalWeight(int totalWeight)
Set the total weight of your quiz for calculate the correct results. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Results()
public Results(double penalty)
penalty
- Penalty percentage. From 0 to 1. Default value = 0.25Method Detail |
---|
public void setAnswer(int weight, boolean correct)
weight
- Weight of the quiz answercorrect
- If the answer was correct or incorrectpublic int getTotalQuestions()
public void setTotalWeight(int totalWeight)
totalQuestions
- public float[] getResults()
public int getTotalWeight()
public float getScore()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |