Interface: AsyncIterableIteratorToArray<V>
An interface that adds a toArray method to AsyncIterableIterator
.
Usage:
const keys: string[] = await rep.scan().keys().toArray();
Type parameters
Name |
---|
V |
Hierarchy
AsyncIterableIterator
<V
>↳
AsyncIterableIteratorToArray
Methods
[asyncIterator]
▸ [asyncIterator](): AsyncIterableIterator
<V
>
Returns
AsyncIterableIterator
<V
>
Inherited from
AsyncIterableIterator.[asyncIterator]
next
▸ next(...args
): Promise
<IteratorResult
<V
, any
>>
Parameters
Name | Type |
---|---|
...args | [] | [undefined ] |
Returns
Promise
<IteratorResult
<V
, any
>>
Inherited from
AsyncIterableIterator.next
return
▸ Optional
return(value?
): Promise
<IteratorResult
<V
, any
>>
Parameters
Name | Type |
---|---|
value? | any |
Returns
Promise
<IteratorResult
<V
, any
>>
Inherited from
AsyncIterableIterator.return
throw
▸ Optional
throw(e?
): Promise
<IteratorResult
<V
, any
>>
Parameters
Name | Type |
---|---|
e? | any |
Returns
Promise
<IteratorResult
<V
, any
>>
Inherited from
AsyncIterableIterator.throw
toArray
▸ toArray(): Promise
<V
[]>
Returns
Promise
<V
[]>