[][src]Trait vrp_core::refinement::objectives::ObjectiveCost

pub trait ObjectiveCost {
    fn value(&self) -> Cost;
fn cmp_relaxed(
        &self,
        other: &Box<dyn ObjectiveCost + Send + Sync>
    ) -> (Ordering, Ordering);
fn clone_box(&self) -> Box<dyn ObjectiveCost + Send + Sync>;
fn as_any(&self) -> &dyn Any; }

Specifies objective cost type.

Required methods

fn value(&self) -> Cost

Returns absolute value of objective.

fn cmp_relaxed(
    &self,
    other: &Box<dyn ObjectiveCost + Send + Sync>
) -> (Ordering, Ordering)

Compares objectives costs together, returns (actual, relaxed) ordering.

fn clone_box(&self) -> Box<dyn ObjectiveCost + Send + Sync>

Clones objective cost.

fn as_any(&self) -> &dyn Any

Returns objective cost as Any.

Loading content...

Implementors

impl ObjectiveCost for MeasurableObjectiveCost[src]

impl ObjectiveCost for MultiObjectiveCost[src]

Loading content...