public void SaveElementNodeTemplateFile(ElementNodeTemplate elementNodeTemplate, string filePath) { filePath = _GetRootedPath(filePath, ElementNodeTemplate.Directory); filePath = Path.ChangeExtension(filePath, ElementNodeTemplate.Extension); IObjectPersistor <ElementNodeTemplate> persistor = PersistorFactory.Instance.CreateElementNodeTemplatePersistor(); persistor.SaveToFile(elementNodeTemplate, filePath); }
public ElementNode ImportTemplateOnce(string templateFileName, ElementNode parentNode) { ElementNodeTemplate elementNodeTemplate = FileService.Instance.LoadElementNodeTemplateFile(templateFileName); if (elementNodeTemplate == null) { return(null); } VixenSystem.Nodes.AddChildToParent(elementNodeTemplate.ElementNode, parentNode); return(elementNodeTemplate.ElementNode); }
public XmlElementNodeTemplateFilePolicy(ElementNodeTemplate template, XElement content) { _template = template; _content = content; }