Skip to main content

PlanningModelSupport

Trait PlanningModelSupport 

Source
pub trait PlanningModelSupport:
    PlanningSolution
    + Sized
    + 'static {
    // Required methods
    fn attach_descriptor_hooks(descriptor: &mut SolutionDescriptor);
    fn attach_runtime_scalar_hooks(
        slot: ScalarVariableSlot<Self>,
    ) -> ScalarVariableSlot<Self>;
    fn attach_coverage_groups(
        scalar_variables: &[ScalarVariableSlot<Self>],
    ) -> Vec<CoverageGroupBinding<Self>>;
    fn validate_model(descriptor: &SolutionDescriptor);
    fn update_entity_shadows(
        solution: &mut Self,
        descriptor_index: usize,
        entity_index: usize,
    ) -> bool;
    fn update_all_shadows(solution: &mut Self) -> bool;

    // Provided method
    fn attach_scalar_groups(
        _scalar_variables: &[ScalarVariableSlot<Self>],
    ) -> Vec<ScalarGroupBinding<Self>> { ... }
}

Required Methods§

Source

fn attach_descriptor_hooks(descriptor: &mut SolutionDescriptor)

Source

fn attach_runtime_scalar_hooks( slot: ScalarVariableSlot<Self>, ) -> ScalarVariableSlot<Self>

Source

fn attach_coverage_groups( scalar_variables: &[ScalarVariableSlot<Self>], ) -> Vec<CoverageGroupBinding<Self>>

Source

fn validate_model(descriptor: &SolutionDescriptor)

Source

fn update_entity_shadows( solution: &mut Self, descriptor_index: usize, entity_index: usize, ) -> bool

Source

fn update_all_shadows(solution: &mut Self) -> bool

Provided Methods§

Source

fn attach_scalar_groups( _scalar_variables: &[ScalarVariableSlot<Self>], ) -> Vec<ScalarGroupBinding<Self>>

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.

Implementors§