A function that returns a boolean to indicate whether it was able to produce
the next value in the sequence. It should return true
when the sequence is done.
Rest
...args: anyOptional additional arguments that where passed to the iterator next
function.
false
if a new value was produced and assigned to the v
of the context, otherwise
true
to indicate that the sequence is done.
Optional
rOptional function that accepts zero or one argument. This function is called via the
iterator return
function when the iterator caller does not intend to make any more
next()
calls so the implementation and can perform any cleanup actions.
Optional
tA function that accepts zero or one argument. The function is called via the iterator
throw
function when that the iterator caller detects an error condition, and e is
typically an Error instance.
Optional
vThe current value to be assigned to the returned iterator result, the next n
function should assign this value to the context as part of incrementing to
the next value.
The context used to manage how the createIterator returns and moves to the next item, and provides to the current value
v
.Since
0.4.2