Packagecom.yworks.bridge.util
Interfacepublic interface ListIterator extends Iterator

An ListIterator is used to sequence over a List of objects. ListIterator can move backwards or forwards through the List.



Public Methods
 MethodDefined By
 Inherited
hasNext():Boolean
Answers if there are more elements to iterate.
Iterator
  
hasPrevious():Boolean
Answers if there are previous elements to iterate.
ListIterator
  
nextIndex():int
Answers the index of the next object in the iteration.
ListIterator
 Inherited
nextItem():Object
Answers the next object in the iteration.
Iterator
  
Answers the index of the previous object in the iteration.
ListIterator
  
previousItem():Object
Answers the previous object in the iteration.
ListIterator
 Inherited
removeItem():void
Removes the last object returned by next from the collection.
Iterator
Method Detail
hasPrevious()method
public function hasPrevious():Boolean

Answers if there are previous elements to iterate.

Returns
Boolean — true if there are previous elements, false otherwise

See also

nextIndex()method 
public function nextIndex():int

Answers the index of the next object in the iteration.

Returns
int — the index of the next object

Throws
Error — when there are no more elements

See also

previousIndex()method 
public function previousIndex():int

Answers the index of the previous object in the iteration.

Returns
int — the index of the previous object

Throws
Error — when there are no previous elements

See also

previousItem()method 
public function previousItem():Object

Answers the previous object in the iteration.

Returns
Object — the previous object

Throws
Error — when there are no previous elements

See also