it.unimi.dsi.fastutil.ints
Class IntIterators.EmptyIterator
java.lang.Object
it.unimi.dsi.fastutil.ints.AbstractIntIterator
it.unimi.dsi.fastutil.ints.AbstractIntBidirectionalIterator
it.unimi.dsi.fastutil.ints.AbstractIntListIterator
it.unimi.dsi.fastutil.ints.IntIterators.EmptyIterator
- All Implemented Interfaces:
- BidirectionalIterator<Integer>, IntBidirectionalIterator, IntIterator, IntListIterator, ObjectBidirectionalIterator<Integer>, ObjectIterator<Integer>, Serializable, Cloneable, Iterator<Integer>, ListIterator<Integer>
- Enclosing class:
- IntIterators
public static class IntIterators.EmptyIterator
- extends AbstractIntListIterator
- implements Serializable, Cloneable
A class returning no elements and a type-specific iterator interface.
This class may be useful to implement your own in case you subclass
a type-specific iterator.
- See Also:
- Serialized Form
serialVersionUID
public static final long serialVersionUID
- See Also:
- Constant Field Values
IntIterators.EmptyIterator
protected IntIterators.EmptyIterator()
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interface Iterator<Integer>
- Specified by:
hasNext
in interface ListIterator<Integer>
hasPrevious
public boolean hasPrevious()
- Description copied from interface:
BidirectionalIterator
- Returns whether there is a previous element.
- Specified by:
hasPrevious
in interface BidirectionalIterator<Integer>
- Specified by:
hasPrevious
in interface ListIterator<Integer>
- Returns:
- whether there is a previous element.
- See Also:
ListIterator.hasPrevious()
nextInt
public int nextInt()
- Description copied from class:
AbstractIntIterator
- Delegates to the corresponding generic method.
- Specified by:
nextInt
in interface IntIterator
- Overrides:
nextInt
in class AbstractIntIterator
- Returns:
- the next element in the iteration.
- See Also:
Iterator.next()
previousInt
public int previousInt()
- Description copied from class:
AbstractIntBidirectionalIterator
- Delegates to the corresponding generic method.
- Specified by:
previousInt
in interface IntBidirectionalIterator
- Overrides:
previousInt
in class AbstractIntBidirectionalIterator
- Returns:
- the previous element in the iteration.
- See Also:
ListIterator.previous()
nextIndex
public int nextIndex()
- Specified by:
nextIndex
in interface ListIterator<Integer>
previousIndex
public int previousIndex()
- Specified by:
previousIndex
in interface ListIterator<Integer>
skip
public int skip(int n)
- Description copied from class:
AbstractIntIterator
- This method just iterates the type-specific version of
AbstractIntIterator.next()
for at most
n
times, stopping if Iterator.hasNext()
becomes false.
- Specified by:
skip
in interface IntIterator
- Specified by:
skip
in interface ObjectIterator<Integer>
- Overrides:
skip
in class AbstractIntIterator
- Parameters:
n
- the number of elements to skip.
- Returns:
- the number of elements actually skipped.
- See Also:
Iterator.next()
back
public int back(int n)
- Description copied from class:
AbstractIntBidirectionalIterator
- This method just iterates the type-specific version of
AbstractIntBidirectionalIterator.previous()
for
at most n
times, stopping if BidirectionalIterator.hasPrevious()
becomes false.
- Specified by:
back
in interface IntBidirectionalIterator
- Specified by:
back
in interface ObjectBidirectionalIterator<Integer>
- Overrides:
back
in class AbstractIntBidirectionalIterator
- Parameters:
n
- the number of elements to skip back.
- Returns:
- the number of elements actually skipped.
- See Also:
Iterator.next()
clone
public Object clone()
- Overrides:
clone
in class Object
Copyright © 2011. All Rights Reserved.