Class goog.iter.Iterator
code »Class/interface for iterators. An iterator needs to implement a next
method and it needs to throw a goog.iter.StopIteration
when the
iteration passes beyond the end. Iterators have no hasNext
method.
It is recommended to always use the helper functions to iterate over the
iterator or in case you are only targeting JavaScript 1.7 for in loops.
Constructor
goog.iter.Iterator ( )
Show:
Instance Methods
code »__iterator__ ( opt_keys ) ⇒ !goog.iter.Iterator
Returns the Iterator
object itself. This is used to implement
the iterator protocol in JavaScript 1.7
!goog.iter.Iterator
Iterator
object itself. This is used to implement
the iterator protocol in JavaScript 1.7Parameters |
---|
|
Returns |
|