pub trait Selection<G: Genome>: Send + Sync {
// Required method
fn select<'a, R: Rng>(
&self,
population: &'a Population<G>,
rng: &mut R,
) -> &'a Individual<G>;
}Expand description
Trait for selection operators.
Required Methods§
Sourcefn select<'a, R: Rng>(
&self,
population: &'a Population<G>,
rng: &mut R,
) -> &'a Individual<G>
fn select<'a, R: Rng>( &self, population: &'a Population<G>, rng: &mut R, ) -> &'a Individual<G>
Select one parent from the population.
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.