com.taco.data
Class SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator

java.lang.Object
  extended by com.taco.data.SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator
All Implemented Interfaces:
java.util.Iterator
Enclosing class:
SoftValueMap.SoftValueEntrySet

protected class SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator
extends java.lang.Object
implements java.util.Iterator

An iterator over the entry set. Iteration is guaranteed to yield sane results; no keys will be null due to cleared references.


Field Summary
protected  SoftValueMap.SoftValue _currentSoftValue
          The soft value of the entry returned by the last call to next().
protected  java.util.Iterator _innerIterator
          The iterator into the storage map's entry set that this iterator corresponds to.
protected  int[] _stride
          _stride[i] indicates the number of elements to skip in the iteration of the entry set of _innerIterator before getting to the ith entry with a non-cleared value.
protected  int _strideIndex
          The index into _stride to look at for the next call to next().
protected  java.util.LinkedList _values
          A list of values which provides the strong references needed to guarantee no references to values will be cleared.
 
Constructor Summary
SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator()
           
 
Method Summary
 boolean hasNext()
           
 java.lang.Object next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_values

protected java.util.LinkedList _values
A list of values which provides the strong references needed to guarantee no references to values will be cleared.


_innerIterator

protected java.util.Iterator _innerIterator
The iterator into the storage map's entry set that this iterator corresponds to.


_stride

protected int[] _stride
_stride[i] indicates the number of elements to skip in the iteration of the entry set of _innerIterator before getting to the ith entry with a non-cleared value.


_strideIndex

protected int _strideIndex
The index into _stride to look at for the next call to next(). Also indicates the number of elements iterated over.


_currentSoftValue

protected SoftValueMap.SoftValue _currentSoftValue
The soft value of the entry returned by the last call to next(). It must be invalidated if the entry is removed.

Constructor Detail

SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator

public SoftValueMap.SoftValueEntrySet.SoftValueEntryIterator()
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface java.util.Iterator

next

public java.lang.Object next()
Specified by:
next in interface java.util.Iterator

remove

public void remove()
Specified by:
remove in interface java.util.Iterator