Element.toString

string toString() const

Turns the whole element, including tag, attributes, and children, into a string which could be pasted into an XML file.