pub(crate) trait Memory<'a> {
// Required method
fn for_each_segment<F>(&mut self, lanes: usize, f: F)
where F: Fn(SegmentView<'_>, usize, usize) + Sync + Send;
}Expand description
Extension trait for Argon2 memory blocks.
Required Methods§
Sourcefn for_each_segment<F>(&mut self, lanes: usize, f: F)
fn for_each_segment<F>(&mut self, lanes: usize, f: F)
Compute each Argon2 segment.
By default computation is single threaded. Parallel computation can be enabled with the
parallel feature, in which case [rayon] is used to compute as many lanes in parallel as
possible.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.