Packageorg.servebox.commons.collection
Interfacepublic interface IListIterator extends IIterator

An iterator for lists that allows to go through the list forward or backward, modify the list during the iteration, and obtain the iterator's current position in the list.



Public Methods
 MethodDefined by
  
add(o:IBasicObject):void
Inserts the element into the list.
IListIterator
 Inherited
hasNext():Boolean
Indicates whether the iterator has more elements when iterate the list in the forward direction.
IIterator
  
hasPrevious():Boolean
Indicates whether the iterator has more elements when iterate the list in the backward direction.
IListIterator
 Inherited
Retrieves the next element in the underlying list.
IIterator
  
nextIndex():int
Retrieves the index of the element that would be returned by a subsequent call to next.
IListIterator
  
Retrieves the previous element in the underlying list, if available.
IListIterator
  
Retrieves the index of the element that would be returned by a subsequent call to previous.
IListIterator
 Inherited
remove():void
Removes the current element.
IIterator
  
set(o:IBasicObject):void
Replaces the current element.
IListIterator
Method detail
add()method
public function add(o:IBasicObject):void

Inserts the element into the list.

Parameters
o:IBasicObject
hasPrevious()method 
public function hasPrevious():Boolean

Indicates whether the iterator has more elements when iterate the list in the backward direction.

Returns
Boolean
nextIndex()method 
public function nextIndex():int

Retrieves the index of the element that would be returned by a subsequent call to next.

Returns
int
previous()method 
public function previous():IBasicObject

Retrieves the previous element in the underlying list, if available.

Returns
IBasicObject
previousIndex()method 
public function previousIndex():int

Retrieves the index of the element that would be returned by a subsequent call to previous.

Returns
int
set()method 
public function set(o:IBasicObject):void

Replaces the current element. The current element is the last that was read using next or previous.

Parameters
o:IBasicObject