Example #1
0
        public bool compare(Question question)
        {
            if (!question.questionsContent.Equals(questionsContent))
            {
                return(false);
            }
            if (!question.questionsType.getType().Equals(questionsType.getType()))
            {
                return(false);
            }
            for (int i = 0; i < unswers.Count; i++)
            {
                if (!unswers.ElementAt(i).compare(question.unswers.ElementAt(i)))
                {
                    return(false);
                }
            }

            return(true);
        }
 private string getSubQueryForGettingQuestionsTypeId(QuestionType type)
 {
     return("(SELECT id FROM Objects WHERE Type" +
            "=" + getSubQueryForGettingTypeId(DbTypes.questionT.getName()) +
            " AND name='" + type.getType() + "')");
 }