org.ozoneDB.collections
Class _BaseList_ListIteratorImpl

java.lang.Object
  extended byorg.ozoneDB.OzoneObject
      extended byorg.ozoneDB.collections._BaseList_ListIteratorImpl
All Implemented Interfaces:
java.util.Iterator, java.util.ListIterator, org.ozoneDB.OzoneCompatible, org.ozoneDB.OzoneCompatibleOrProxy, OzoneIterator, OzoneListIterator, org.ozoneDB.OzoneRemote, java.io.Serializable

public class _BaseList_ListIteratorImpl
extends org.ozoneDB.OzoneObject
implements OzoneListIterator

Author:
leo
See Also:
Serialized Form

Constructor Summary
_BaseList_ListIteratorImpl(BaseList owner, int index)
           
 
Method Summary
 void add(java.lang.Object o)
          Inserts the specified element into the list (optional operation).
 boolean hasNext()
           
 boolean hasPrevious()
           
 java.lang.Object next()
           
 int nextIndex()
           
 java.lang.Object previous()
          Returns the previous element in the list.
 int previousIndex()
           
 void remove()
           
 void set(java.lang.Object o)
           
 
Methods inherited from class org.ozoneDB.OzoneObject
container, database, deleteRecursive, equals, getHandle, getObjectID, handle, hashCode, onActivate, onCreate, onDelete, onPassivate, requireWriteLocking, self, setContainer, toString, toXML
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.ozoneDB.OzoneCompatibleOrProxy
getObjectID
 

Constructor Detail

_BaseList_ListIteratorImpl

public _BaseList_ListIteratorImpl(BaseList owner,
                                  int index)
Method Detail

hasNext

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

hasPrevious

public boolean hasPrevious()
Specified by:
hasPrevious in interface java.util.ListIterator

next

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

previous

public java.lang.Object previous()
Description copied from interface: OzoneListIterator
Returns the previous element in the list. This method may be called repeatedly to iterate through the list backwards, or intermixed with calls to next to go back and forth. (Note that alternating calls to next and previous will return the same element repeatedly.)

Specified by:
previous in interface OzoneListIterator
Returns:
the previous element in the list.

nextIndex

public int nextIndex()
Specified by:
nextIndex in interface java.util.ListIterator

previousIndex

public int previousIndex()
Specified by:
previousIndex in interface java.util.ListIterator

remove

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

set

public void set(java.lang.Object o)
Specified by:
set in interface java.util.ListIterator

add

public void add(java.lang.Object o)
Description copied from interface: OzoneListIterator
Inserts the specified element into the list (optional operation). The element is inserted immediately before the next element that would be returned by next, if any, and after the next element that would be returned by previous, if any. (If the list contains no elements, the new element becomes the sole element on the list.) The new element is inserted before the implicit cursor: a subsequent call to next would be unaffected, and a subsequent call to previous would return the new element. (This call increases by one the value that would be returned by a call to nextIndex or previousIndex.)

Specified by:
add in interface OzoneListIterator
Parameters:
o - the element to insert.


Copyright © 2004 The Ozone Database Project - www.ozone-db.org. All Rights Reserved.