parallel_map_collect

Function parallel_map_collect 

Source
pub fn parallel_map_collect<I, T, U, M>(items: I, mapper: M) -> Vec<U>
where I: IntoParallelIterator<Item = T>, T: Send, U: Send, M: Fn(T) -> U + Sync + Send,
Expand description

Parallel map-collect operation on a collection

This function maps over a collection in parallel and collects the results.

§Arguments

  • items - The items to process
  • mapper - Function that processes each item

§Returns

Vector of mapped results