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|
|
|
|
|
|
CEKER,
|
|
|
|
|
|
SUSILICA,
|
|
|
|
|
|
PROZOR_BEZ_ROLETNE
|
2017-05-20 11:23:09 +03:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
public class Answer
|
|
|
|
|
|
{
|
|
|
|
|
|
public Answer(AnswerObjectModel model, string caption)
|
|
|
|
|
|
{
|
|
|
|
|
|
answerModel = model;
|
|
|
|
|
|
answerCaption = caption;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private AnswerObjectModel answerModel;
|
|
|
|
|
|
|
|
|
|
|
|
private string answerCaption;
|
|
|
|
|
|
|
|
|
|
|
|
public string getAnswerCaption()
|
|
|
|
|
|
{
|
|
|
|
|
|
return answerCaption;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public AnswerObjectModel getAnswerModel()
|
|
|
|
|
|
{
|
|
|
|
|
|
return answerModel;
|
|
|
|
|
|
}
|
|
|
|
|
|
};
|
2017-05-17 14:11:01 +02:00
|
|
|
|
|
|
|
|
|
|
public class Question
|
|
|
|
|
|
{
|
2017-05-20 16:43:03 +03:00
|
|
|
|
public Question(int [] correctAns, Answer[] possibleAns)
|
2017-05-20 11:23:09 +03:00
|
|
|
|
{
|
|
|
|
|
|
correctAnswers = correctAns;
|
2017-05-20 16:43:03 +03:00
|
|
|
|
possibleAnswers = possibleAns;
|
2017-05-20 11:23:09 +03:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Question(string question, int[] correctAns, Answer[] possibleAns)
|
2017-05-17 14:11:01 +02:00
|
|
|
|
{
|
|
|
|
|
|
questionText = question;
|
2017-05-20 11:23:09 +03:00
|
|
|
|
correctAnswers = correctAns;
|
|
|
|
|
|
possibleAnswers = possibleAns;
|
2017-05-17 14:11:01 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private int[] correctAnswers;
|
|
|
|
|
|
|
|
|
|
|
|
private string questionText;
|
|
|
|
|
|
|
2017-05-20 11:23:09 +03:00
|
|
|
|
private Answer[] possibleAnswers;
|
|
|
|
|
|
|
2017-05-17 14:11:01 +02:00
|
|
|
|
public int[] getCorrectAnswers()
|
|
|
|
|
|
{
|
|
|
|
|
|
return correctAnswers;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public string getQuestionText()
|
|
|
|
|
|
{
|
|
|
|
|
|
return questionText;
|
|
|
|
|
|
}
|
2017-05-20 11:23:09 +03:00
|
|
|
|
|
|
|
|
|
|
public Answer[] getPossibleAnswers()
|
|
|
|
|
|
{
|
|
|
|
|
|
return possibleAnswers;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2017-05-23 19:39:06 +03:00
|
|
|
|
public int getProfessorAtomIdx()
|
2017-05-20 11:23:09 +03:00
|
|
|
|
{
|
2017-05-23 19:39:06 +03:00
|
|
|
|
for(int i = 0; i < possibleAnswers.Length; ++i)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (possibleAnswers[i].getAnswerModel() == AnswerObjectModel.PROFESOR_ATOM_10)
|
|
|
|
|
|
return i + 1;
|
|
|
|
|
|
}
|
|
|
|
|
|
return -1;
|
|
|
|
|
|
}
|
2017-05-17 14:11:01 +02:00
|
|
|
|
}
|