pub struct XPathComparer;Expand description
A comparer that sorts XPath nodes in document order.
This comparer implements the XPath document order comparison for nodes. It is used to sort node sequences returned by XPath operations like union, intersect, and except.
§Panics
Panics if either item is not a node (i.e., is an atomic value).
Implementations§
Source§impl XPathComparer
impl XPathComparer
Sourcepub fn try_compare<N: DomNavigator>(
&self,
x: &XmlItem<N>,
y: &XmlItem<N>,
) -> Result<Ordering, XPathError>
pub fn try_compare<N: DomNavigator>( &self, x: &XmlItem<N>, y: &XmlItem<N>, ) -> Result<Ordering, XPathError>
Fallible comparison of two XmlItems in document order.
Returns an error if either item is not a node.
Trait Implementations§
Source§impl Clone for XPathComparer
impl Clone for XPathComparer
Source§fn clone(&self) -> XPathComparer
fn clone(&self) -> XPathComparer
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for XPathComparer
Source§impl Debug for XPathComparer
impl Debug for XPathComparer
Source§impl Default for XPathComparer
impl Default for XPathComparer
Source§fn default() -> XPathComparer
fn default() -> XPathComparer
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for XPathComparer
impl RefUnwindSafe for XPathComparer
impl Send for XPathComparer
impl Sync for XPathComparer
impl Unpin for XPathComparer
impl UnsafeUnpin for XPathComparer
impl UnwindSafe for XPathComparer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more