Interface AsyncIterator<T, TReturn, TNext>
Type Parameters
-
T
-
TReturn = any
-
TNext = undefined
Methods
next
- next(...args: [] | [TNext]): Promise<IteratorResult<T, TReturn>>
-
Parameters
-
Rest
...args: [] | [TNext]
Returns Promise<IteratorResult<T, TReturn>>
Optional
return
- return(value?: TReturn | PromiseLike<TReturn>): Promise<IteratorResult<T, TReturn>>
-
Returns Promise<IteratorResult<T, TReturn>>
Optional
throw
- throw(e?: any): Promise<IteratorResult<T, TReturn>>
-
Returns Promise<IteratorResult<T, TReturn>>
NOTE: 'next' is defined using a tuple to ensure we report the correct assignability errors in all places.