示例#1
0
        /// <summary>Execute the command.</summary>
        public override void Execute()
        {
            ITemplateEditor templateEditor = HostWindow.ActiveChildForm as ITemplateEditor;

            if (templateEditor != null)
            {
                templateEditor.RunTemplate();
            }
        }
示例#2
0
        public Merger(KeyValuePairLoaderType keyValuePairLoaderType, TemplateEditorType templateEditorType, String templateRootDirectory)
        {
            switch (keyValuePairLoaderType)
            {
            case KeyValuePairLoaderType.SeperateFileBased:
                keyValueLoader = new SeperateFileBasedKeyValueLoader();
                break;

            default:
                throw new ArgumentException("Unknown KeyValuePairLoaderType");
            }

            switch (templateEditorType)
            {
            case TemplateEditorType.XceedSoftwareDocX:
                templateEditor = new DocXTemplateEditor();
                break;

            default:
                throw new ArgumentException("Unknown TemplateEditorType");
            }

            this.templateRootDirectory = templateRootDirectory;
        }
 public void Init(ITemplateEditor <TemplateType> editor) => Editor = editor;