/** * Get the next element in the direction of this iterator. * * @return the next element */ public E next() { if (! hasNext()) throw new NoSuchElementException(); return elements[descending ? -- idx : idx ++]; }
/** * Get the next element in the direction of this iterator. * * @return the next element */ public E next() { if (! hasNext()) throw new NoSuchElementException(); return elements[descending ? -- idx : idx ++]; }
/** * Get the next element in the direction of this iterator. * * @return the next element */ public E next() { if (! hasNext()) throw new NoSuchElementException(); return elements[descending ? -- idx : idx ++]; }
/** * Get the next element in the direction of this iterator. * * @return the next element */ public E next() { if (! hasNext()) throw new NoSuchElementException(); return elements[descending ? -- idx : idx ++]; }