public void SetAttributeTo(string name, string value, XMLElementUI <TAppData, TModuleData, TElementData> element)
        {
            var r = addAttributeHandler.AddAttribute(name, value, element);

            if (!r.ok)
            {
                throw new SetAttributeException(name, value, element.name, r.message);
            }
        }
        public IXMLElement AddElementTo(string name, XMLElementUI <TAppData, TModuleData, TElementData> previewElement)
        {
            var result = addElementHandler.AddElement(name, previewElement);
            var bomb   = result as BombElement;

            if (bomb != null)
            {
                bomb.Detonate();
            }
            return(result);
        }
 public XMLModule(XMLApplication <TAppData, TModuleData, TElementData> app, TElementData rootData, TModuleData data)
 {
     this.app         = app;
     this.data        = data;
     this.rootElement = new XMLElementUI <TAppData, TModuleData, TElementData>("root", rootData, this);
 }