reduceAsync<S, T> function

Future<S> reduceAsync <S, T>(Iterable<T> iterable, S initialValue, AsyncCombiner<S, T> combine)

Reduces a collection to a single value by iteratively combining elements of the collection using the provided combine function. Similar to Iterable.reduce, except that combine is an async function that returns a Future.

Implementation

Future<S> reduceAsync<S, T>(
        Iterable<T> iterable, S initialValue, AsyncCombiner<S, T> combine) =>
    _reduceAsync(iterable.iterator, initialValue, combine);