Exemplo n.º 1
0
        /// <summary>
        /// действия перед началом конвертации
        /// инициализация компонент
        /// </summary>
        protected override void DoBefore()
        {
            convertCurse = course.AsXMLForConvert();

            convertOperations = new List <IOperationModel>();

            IEnumerable <XElement> themes    = convertCurse.Descendants(NodeNames.THEME_ROOT);
            IOperationModel        themeConv = new ThemeXSLTHTML5(themes, convParams, this);

            convertOperations.Add(themeConv);

            IEnumerable <XElement> tests     = convertCurse.Descendants(NodeNames.TEST_ROOT);
            IOperationModel        testsConv = new TestXSLTConvertor(tests, convParams, this);

            convertOperations.Add(testsConv);

            IOperationModel themplate = new ThemeplateXSLTConvertor(convParams);

            convertOperations.Add(themplate);

            IOperationModel content = new ContentXSLTConvertor(convertCurse, convParams);

            convertOperations.Add(content);


            convertOperations.ForEach(x => x.Prepare());
        }
Exemplo n.º 2
0
        /// <summary>
        /// действия перед началом конвертации
        /// инициализация компонент
        /// </summary>       
        protected override void DoBefore()
        {
            convertCurse = course.AsXMLForConvert();

            convertOperations = new List<IOperationModel>();

            IEnumerable<XElement> themes = convertCurse.Descendants(NodeNames.THEME_ROOT);
            IOperationModel themeConv = new ThemeXSLTConvertor(themes, convParams,this);
            convertOperations.Add(themeConv);

            IEnumerable<XElement> tests = convertCurse.Descendants(NodeNames.TEST_ROOT);
            IOperationModel testsConv = new TestXSLTConvertor(tests, convParams, this);
            convertOperations.Add(testsConv);

            IOperationModel themplate = new ThemeplateXSLTConvertor(convParams);
            convertOperations.Add(themplate);

            IOperationModel content = new ContentXSLTConvertor(convertCurse,convParams);
            convertOperations.Add(content);

            convertOperations.ForEach(x => x.Prepare());
        }