parallelMapNotNullIndexed

suspend fun <T, S> Collection<T>.parallelMapNotNullIndexed(maxConcurrentRequests: Int? = null, mapper: suspend (index: Int, T) -> S?): List<S>

Maps every element of this collection using mapper in parallel and filters out null.

Parameters

maxConcurrentRequests

the maximum amount of concurrent coroutines (null means unlimited)

This in itself does not launch multiple threads, how many threads are launched is dependent on the used Dispatcher