Why is CreateElement() a member function of XmlDocument class?




XmlDocument xmlDoc = new XmlDocument();
XmlElement elem = xmlDoc.CreateElement("Elem");
xmlDoc.AppendChild(elem);


AppendChild() is doing some changes to the object referred by xmldoc.... it makes sense it is a member function


CreateElement() which looks more like a common function to all the objects.... why is it a member function() ?


No comments:

Post a Comment