streamToIntList function

Future<List<int>> streamToIntList(
  1. Stream<List<int>> stream
)

Implementation

Future<List<int>> streamToIntList(Stream<List<int>> stream) async {
  return await stream.fold<List<int>>(<int>[],
          (List<int> previous, List<int> element) {
        previous.addAll(element);
        return previous;
      });
}