Trait vrp_core::models::FeatureObjective

source ·
pub trait FeatureObjective: Send + Sync {
    // Required methods
    fn fitness(&self, solution: &InsertionContext) -> Cost;
    fn estimate(&self, move_ctx: &MoveContext<'_>) -> Cost;
}
Expand description

Defines feature’s objective function behavior.

Required Methods§

source

fn fitness(&self, solution: &InsertionContext) -> Cost

An objective fitness value for the given solution.

source

fn estimate(&self, move_ctx: &MoveContext<'_>) -> Cost

Estimates the cost of insertion.

Implementors§