pub fn parse(xml: &[u8]) -> Result<Document, RedispatchXmlError>Expand description
Deserialise a Redispatch 2.0 XML document into the appropriate Document
variant.
The document type is detected automatically from the root element.
ยงErrors
RedispatchXmlError::UnknownDocumentTypeโ unrecognised root element.RedispatchXmlError::Deserializeโ XML deserialization failure.RedispatchXmlError::NamespaceMismatchโ wrong or missing namespace.