public ChoiceQuestionAnswer(Question question, QuestionnaireAnswer questionAnswerSet) : base(question, questionAnswerSet) { choices = new List <QuestionAnswerChoice>(); foreach (Choice c in question.Choice.OrderBy(c => c.num)) { choices.Add(new QuestionAnswerChoice(this, c)); } }
public static BaseQuestionAnswer NewQuestionAnswer(Question question, QuestionnaireAnswer questionAnswerSet) { switch (question.type_cd) { case "O": return(new OnlyCommentQuestionAnswer(question, questionAnswerSet)); case "T": return(new StringQuestionAnswer(question, questionAnswerSet)); case "Y": return(new YesNoQuestionAnswer(question, questionAnswerSet)); case "C": return(new ChoiceQuestionAnswer(question, questionAnswerSet)); default: return(null); } }
public YesNoQuestionAnswer(Question question, QuestionnaireAnswer questionAnswerSet) : base(question, questionAnswerSet) { }
public StringQuestionAnswer(Question question, QuestionnaireAnswer questionAnswerSet) : base(question, questionAnswerSet) { }
public OnlyCommentQuestionAnswer(Question question, QuestionnaireAnswer questionAnswerSet) : base(question, questionAnswerSet) { }
public BaseQuestionAnswer(Question question, QuestionnaireAnswer questA) { q = question; questionAnswerSet = questA; }