Exemple #1
0
        public static ExamTemplateCollection GetExamTemplates()
        {
            XmlElement templates = QueryTemplate.GetAbstractList();

            ExamTemplateCollection objTemplates = new ExamTemplateCollection();

            foreach (XmlElement each in templates.SelectNodes("ExamTemplate"))
            {
                ExamTemplate template = new ExamTemplate(each);
                objTemplates.Add(template.Identity, template);
            }

            return(objTemplates);
        }
Exemple #2
0
        public TemplateLookup()
        {
            _lookup_table = new Dictionary <string, string>();

            XmlElement xmlRecords = QueryTemplate.GetAbstractList();

            foreach (XmlElement each in xmlRecords.SelectNodes("ExamTemplate"))
            {
                string name = each.SelectSingleNode("TemplateName").InnerText;
                string id   = each.GetAttribute("ID");

                _lookup_table.Add(name, id);
            }
        }