it.unimi.dsi.fastutil.shorts
Class AbstractShort2LongSortedMap.KeySetIterator

java.lang.Object
  extended by it.unimi.dsi.fastutil.shorts.AbstractShortIterator
      extended by it.unimi.dsi.fastutil.shorts.AbstractShortBidirectionalIterator
          extended by it.unimi.dsi.fastutil.shorts.AbstractShort2LongSortedMap.KeySetIterator
All Implemented Interfaces:
BidirectionalIterator<Short>, ObjectBidirectionalIterator<Short>, ObjectIterator<Short>, ShortBidirectionalIterator, ShortIterator, Iterator<Short>
Enclosing class:
AbstractShort2LongSortedMap

protected static class AbstractShort2LongSortedMap.KeySetIterator
extends AbstractShortBidirectionalIterator

A wrapper exhibiting a map iterator as an iterator on keys.

To provide an iterator on keys, just create an instance of this class using the corresponding iterator on entries.


Field Summary
protected  ObjectBidirectionalIterator<Map.Entry<Short,Long>> i
           
 
Constructor Summary
AbstractShort2LongSortedMap.KeySetIterator(ObjectBidirectionalIterator<Map.Entry<Short,Long>> i)
           
 
Method Summary
 boolean hasNext()
           
 boolean hasPrevious()
          Returns whether there is a previous element.
 short nextShort()
          Delegates to the corresponding generic method.
 short previousShort()
          Delegates to the corresponding generic method.
 
Methods inherited from class it.unimi.dsi.fastutil.shorts.AbstractShortBidirectionalIterator
back, previous
 
Methods inherited from class it.unimi.dsi.fastutil.shorts.AbstractShortIterator
next, remove, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface it.unimi.dsi.fastutil.shorts.ShortIterator
skip
 
Methods inherited from interface it.unimi.dsi.fastutil.objects.ObjectIterator
skip
 
Methods inherited from interface java.util.Iterator
next, remove
 

Field Detail

i

protected final ObjectBidirectionalIterator<Map.Entry<Short,Long>> i
Constructor Detail

AbstractShort2LongSortedMap.KeySetIterator

public AbstractShort2LongSortedMap.KeySetIterator(ObjectBidirectionalIterator<Map.Entry<Short,Long>> i)
Method Detail

nextShort

public short nextShort()
Description copied from class: AbstractShortIterator
Delegates to the corresponding generic method.

Specified by:
nextShort in interface ShortIterator
Overrides:
nextShort in class AbstractShortIterator
Returns:
the next element in the iteration.
See Also:
Iterator.next()

previousShort

public short previousShort()
Description copied from class: AbstractShortBidirectionalIterator
Delegates to the corresponding generic method.

Specified by:
previousShort in interface ShortBidirectionalIterator
Overrides:
previousShort in class AbstractShortBidirectionalIterator
Returns:
the previous element in the iteration.
See Also:
ListIterator.previous()

hasNext

public boolean hasNext()

hasPrevious

public boolean hasPrevious()
Description copied from interface: BidirectionalIterator
Returns whether there is a previous element.

Returns:
whether there is a previous element.
See Also:
ListIterator.hasPrevious()


Copyright © 2011. All Rights Reserved.