Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.saxon.om
Interface AxisIterator

All Superinterfaces:
  SequenceIterator

All Known Implementing Classes:
  ArrayIterator, AxisIteratorImpl, EmptyIterator, ListIterator, NamespaceIterator, PrependIterator, ReverseArrayIterator, SingletonIterator

public interface AxisIterator
extends SequenceIterator

A SequenceIterator is used to iterate over a sequence. An AxisIterator is a SequenceIterator that throws no exceptions. Despite its name, an AxisIterator is not invariably used to find nodes on an axis of a tree, though this is its most common use. For example, the class ArrayIterator is also defined as an AxisIterator.

Method Summary
`Item` | `current()` Get the current item in the sequence.
`SequenceIterator` | `getAnother()` Get another iterator over the same sequence of items, positioned at the start of the sequence
`Item` | `next()` Get the next item in the sequence.
`int` | `position()` Get the current position

Method Detail

### next

    public Item next()

  Get the next item in the sequence.

  Specified by:
    `next` in interface `SequenceIterator`
  Returns:
    the next Item. If there are no more nodes, return null.

### current

    public Item current()

  Get the current item in the sequence.

  Specified by:
    `current` in interface `SequenceIterator`
  Returns:
    the current item, that is, the item most recently returned by next()

### position

    public int position()

  Get the current position

  Specified by:
    `position` in interface `SequenceIterator`
  Returns:
    the position of the current item (the item most recently returned by next()), starting at 1 for the first node

### getAnother

    public SequenceIterator getAnother()

  Get another iterator over the same sequence of items, positioned at the start of the sequence

  Specified by:
    `getAnother` in interface `SequenceIterator`
  Returns:
    a new iterator over the same sequence

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD