Class ReverseListIterator

  • All Implemented Interfaces:
    Closeable, AutoCloseable,, net.sf.saxon.tree.iter.AxisIterator

    public class ReverseListIterator
    extends Object
    implements net.sf.saxon.tree.iter.AxisIterator
    Iterates list in backward direction.
    • Field Detail

      • items

        private final List<? extends> items
        List of nodes.
      • index

        private int index
        Current index.
    • Constructor Detail

      • ReverseListIterator

        public ReverseListIterator​(Collection<? extends> items)
        Constructor for ReverseListIterator class.
        items - the collection of nodes.
    • Method Detail

      • next

        public next()
        Get the next item in the sequence.
        Specified by:
        next in interface net.sf.saxon.tree.iter.AxisIterator
        Specified by:
        next in interface
        the next Item. If there are no more nodes, return null.