pub trait TransportFallback: Send + Sync {
    // Required methods
    fn duration(
        &self,
        profile: &Profile,
        from: Location,
        to: Location
    ) -> Duration;
    fn distance(
        &self,
        profile: &Profile,
        from: Location,
        to: Location
    ) -> Distance;
}
Expand description

A fallback for transport costs if from->to entry is not defined.

Required Methods§

source

fn duration(&self, profile: &Profile, from: Location, to: Location) -> Duration

Returns fallback duration.

source

fn distance(&self, profile: &Profile, from: Location, to: Location) -> Distance

Returns fallback distance.

Implementors§