Packagecom.yworks.support
Classpublic class CompositeIterator
InheritanceCompositeIterator Inheritance Object
Implements Iterator

A composite Iterator that iterates two given Iterators one after the other.



Public Methods
 MethodDefined By
  
Creates an instance that iterates over the two given Iterator
CompositeIterator
  
hasNext():Boolean
Tests whether the method next() will return a valid element.
CompositeIterator
  
next():Object
Gets the next element of the set of elements.
CompositeIterator
  
reset():void
Sets the Iterator's element cursor to the first element.
CompositeIterator
Constructor Detail
CompositeIterator()Constructor
public function CompositeIterator(first:Iterator, second:Iterator)

Creates an instance that iterates over the two given Iterator

Parameters
first:Iterator
 
second:Iterator
Method Detail
hasNext()method
public function hasNext():Boolean

Tests whether the method next() will return a valid element.

Returns
Booleantrue if next() will return a valid element.
next()method 
public function next():Object

Gets the next element of the set of elements.

Returns
Object — The next element in the set.
reset()method 
public function reset():void

Sets the Iterator's element cursor to the first element.