Skip to main content

PillarSelector

Trait PillarSelector 

Source
pub trait PillarSelector<S: PlanningSolution>: Send + Debug {
    // Required methods
    fn iter<'a, D: Director<S>>(
        &'a self,
        score_director: &D,
    ) -> impl Iterator<Item = Pillar> + 'a;
    fn size<D: Director<S>>(&self, score_director: &D) -> usize;
    fn descriptor_index(&self) -> usize;

    // Provided method
    fn is_never_ending(&self) -> bool { ... }
}
Expand description

Trait for selecting pillars of entities.

A pillar selector groups entities by their variable values and returns groups (pillars) that can be moved together.

§Type Parameters

  • S - The planning solution type

Required Methods§

Source

fn iter<'a, D: Director<S>>( &'a self, score_director: &D, ) -> impl Iterator<Item = Pillar> + 'a

Source

fn size<D: Director<S>>(&self, score_director: &D) -> usize

Source

fn descriptor_index(&self) -> usize

Provided Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<S, V, ES, E> PillarSelector<S> for DefaultPillarSelector<S, V, ES, E>
where S: PlanningSolution, V: Clone + Eq + Hash + Send + Sync + 'static, ES: EntitySelector<S>, E: Fn(&dyn Director<S>, usize, usize) -> Option<V> + Send + Sync,