pmap 0.2.0
pmap: ^0.2.0 copied to clipboard
Parallel map funcion
pmap #
Description #
A parallel implementation of Iterable.map. This is a convenient function to
help parallelize expensive operations.
Example #
import 'package:pmap/pmap.dart';
int square(int x) => x * x;
void main() async {
List<int> list = [1, 2, 3, 4, 5];
Stream<int> results = pmap(list, square);
await for (int value in results) {
print(value);
}
}