XmlNode newNode = document.ImportNode (data, true);
xel.AppendChild (newNode);
}
- document.AppendChild (xel); // FIXME: it should not be appended
-
- element = document.DocumentElement;
+ element = xel;
}
// why is data a XmlNodeList instead of a XmlElement ?
throw new ArgumentNullException ("value");
XmlDocument doc = new XmlDocument ();
XmlElement el = (XmlElement) doc.ImportNode (element, true);
- doc.AppendChild (el); // FIXME: it should not be appended
- el.RemoveAll ();
+ while (el.LastChild != null)
+ el.RemoveChild (el.LastChild);
foreach (XmlNode n in value)
el.AppendChild (doc.ImportNode (n, true));
element = el;
else {
XmlDocument document = new XmlDocument ();
XmlElement el = document.ImportNode (element, true) as XmlElement;
- el.Attributes.RemoveAll ();
- document.AppendChild (el); // FIXME: it should not be appended
el.SetAttribute (attribute, value);
element = el;
propertyModified = true;
XmlElement oldElement = element;
XmlDocument doc = new XmlDocument ();
element = doc.CreateElement (XmlSignature.ElementNames.Object, XmlSignature.NamespaceURI);
- doc.AppendChild (element); // FIXME: it should not be appended
foreach (XmlAttribute attribute in oldElement.Attributes) {
switch (attribute.Name) {
case XmlSignature.AttributeNames.Id: