pub fn evaluate_xpath(
xml: &str,
xpath_expr: &str,
mode: QueryMode,
namespaces: &[(&str, &str)],
) -> Result<QueryResult, Error>Expand description
Evaluate an XPath 3.1 expression against an XML string.
Namespace prefixes are discovered automatically from the XML document’s
root element. Additional namespaces bindings are merged on top
(overriding any conflicting prefix from the document).
§Errors
Returns an error if the XML cannot be parsed, the XPath cannot be compiled,
or execution fails.