Struct xml_builder::XMLElement [−][src]
pub struct XMLElement { /* fields omitted */ }Expand description
Structure representing an XML element field.
Implementations
Instantiates a new XMLElement object.
Arguments
name- A string slice that holds the name of the XML element.
Enables attributes sorting.
Disables attributes sorting.
Adds the given name/value attribute to the XMLElement.
Arguments
name- A string slice that holds the name of the attributevalue- A string slice that holds the value of the attribute
Adds a new XMLElement child object to the references XMLElement.
Raises XMLError if trying to add a child to a text XMLElement.
Arguments
element- A XMLElement object to add as child
Adds text content to a XMLElement object.
Raises XMLError if trying to add text to a non-empty object.
Arguments
text- A string containing the text to add to the object