Esempio n. 1
0
        private QuestionResponse CreateQuestionResponse(string questionId)
        {
            QuestionResponse response;

            Question question = this.FindQuestion(questionId);

            if (question is MCQuestion ||
                question is MRQuestion ||
                question is MAQuestion ||
                question is TableQuestion ||
                question is TFQuestion)
            {
                response = new SelectableQuestionResponse(questionId);
            }
            else if (question is FIBQuestion)
            {
                response = new FIBQuestionResponse(questionId);
            }
            else if (question is ESQuestion)
            {
                response = new ESQuestionResponse(questionId);
            }
            else
            {
                response = new QuestionResponse(questionId);
            }

            return(response);
        }
Esempio n. 2
0
 /// <summary>
 /// 初始化Exercise类的新实例。
 /// </summary>
 public Exercise()
 {
     this.createTime = DateTime.Now.ToUniversalTime();
     this.response   = new ExerciseResponse(base.Id);
 }