Struct vrp_core::construction::constraints::FleetUsageConstraintModule [−][src]
pub struct FleetUsageConstraintModule { /* fields omitted */ }Expand description
A module which controls fleet size usage.
Implementations
Creates FleetUsageConstraintModule to minimize used fleet size.
Creates FleetUsageConstraintModule to maximize used fleet size.
Creates FleetUsageConstraintModule with custom extra cost.
Trait Implementations
fn accept_insertion(
&self,
_solution_ctx: &mut SolutionContext,
_route_index: usize,
_job: &Job
)
fn accept_insertion(
&self,
_solution_ctx: &mut SolutionContext,
_route_index: usize,
_job: &Job
)
Accept insertion of specific job into the route.
Called once job has been inserted into solution represented via solution_ctx.
Target route is defined by route_index which refers to routes collection in solution context.
Inserted job is job.
This method should call accept_route_state internally.
This method should NOT modify amount of job activities in the tour. Read more
Accept route and updates its state to allow more efficient constraint checks. This method should NOT modify amount of job activities in the tour. Read more
Accepts insertion solution context allowing to update job insertion data. This method called twice: before insertion of all jobs starts and when it ends. Please note, that it is important to update only stale routes as this allows to avoid updating non changed route states. Read more
Returns unique constraint state keys. Used to avoid state key interference. Read more
Returns list of constraints to be used.