| 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectca.uhn.cache.util.MutableIterator
Default implementation of IMutableIterator. The default close() method does nothing, and should be overridden to perform any required cleanup. Note that this class is NOT thread-safe in the sense of supporting multiple iterating clients or competing threads calling add and freeze (although different threads may add and iterate concurrently). It is assumed that one thread is iterating. It is up to the caller to ensure that freeze() is not called until after add() has been called as for the last time.
| Constructor Summary | |
MutableIterator()
New instance.  | 
|
| Method Summary | |
 void | 
add(java.lang.Object theObject)
Adds a single item to the list which this iterator iterates through.  | 
 void | 
close()
Does nothing by default.  | 
 void | 
declareException(java.lang.Exception theException)
This indicates that an exception has been encountered while populating this iterator.  | 
 void | 
freeze()
Called after all add() and merge() calls.  | 
 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 | 
| Constructor Detail | 
public MutableIterator()
| Method Detail | 
public void add(java.lang.Object theObject)
IMutableIterator
add in interface IMutableIteratortheObject - IDataItem to addca.uhn.cache.IMutableIterator#add(java.lang.Object)public void freeze()
IMutableIterator
freeze in interface IMutableIteratorca.uhn.cache.IMutableIterator#freeze()
public boolean hasNext()
                throws MutableIteratorException
hasNext in interface java.util.IteratorMutableIteratorExceptionjava.util.Iterator.hasNext()
public java.lang.Object next()
                      throws MutableIteratorException,
                             java.util.NoSuchElementException
next in interface java.util.IteratorMutableIteratorException
java.util.NoSuchElementExceptionIterator.next()public void close()
close in interface IMutableIteratorca.uhn.cache.IMutableIterator#close()public void declareException(java.lang.Exception theException)
IMutableIterator
declareException in interface IMutableIteratortheException - exception to declareca.uhn.cache.IMutableIterator#declareException(java.lang.Exception)public void remove()
remove in interface java.util.IteratorIterator.remove()
  | 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||