reversed method

DomTreeIterator reversed({
  1. dynamic wraps,
})

Returns another iterator, starting from the current element and heading reverse order. Scope is retained, while wrapping may be overriden if wraps is true or inherited from current as true, new wraps will start from current position.

Implementation

DomTreeIterator reversed({wraps}) {
  return DomTreeIterator(_element,
      reverse: !_reverse, scope: _scope, wraps: wraps ?? _wraps);
}