pub trait ParallelSchedule: Copy {
// Required method
fn dispatch<F>(&self, pool: &mut ThreadPool, tasks: usize, function: F)
where F: Fn(Prong) + Sync;
// Provided method
fn dispatch_slices<F>(
&self,
pool: &mut ThreadPool,
tasks: usize,
function: F,
)
where F: Fn(Prong, usize) + Sync { ... }
}Required Methods§
fn dispatch<F>(&self, pool: &mut ThreadPool, tasks: usize, function: F)
Provided Methods§
fn dispatch_slices<F>(&self, pool: &mut ThreadPool, tasks: usize, function: F)
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.