Skip to main content

compare_document_order

Function compare_document_order 

Source
pub fn compare_document_order<N: DomNavigator>(a: &N, b: &N) -> Ordering
Expand description

Compare two nodes by document order.

ยงReturns

  • std::cmp::Ordering::Less if a precedes b
  • std::cmp::Ordering::Equal if they are the same node
  • std::cmp::Ordering::Greater if a follows b