Skip to main content

par_map

Function par_map 

Source
pub fn par_map<F, R>(packets: &[Packet], f: F) -> Vec<R>
where F: Fn(&Packet) -> R + Sync + Send, R: Send,
Expand description

Apply a function to each packet in parallel, collecting results.

Useful for extracting fields, computing summaries, or filtering.