Function
| Static Public Summary | ||
| public |
next(iterator: Iterator, dflt: any): any Returns the next value of the input iterator. |
|
| Static Private Summary | ||
| private |
Returns the next event of the input iterator. |
|
Static Public
public next(iterator: Iterator, dflt: any): any source
import next from '@iterable-iterator/next/src/next.js'Returns the next value of the input iterator. If the iterator is exhausted,
throws a StopIteration, unless a dflt argument has been
specified, in which case the dflt argument is returned.
Params:
| Name | Type | Attribute | Description |
| iterator | Iterator | The input iterator. |
|
| dflt | any |
|
The default value to return in the case that the input iterator is exhausted. |
Return:
| any | The next value of the input iterator. |
Static Private
private _next(iterator: Iterator): {value: any, done?: boolean} source
import _next from '@iterable-iterator/next/src/_next.js'Returns the next event of the input iterator.
Params:
| Name | Type | Attribute | Description |
| iterator | Iterator | The input iterator. |
