Trait openrailwaymap_exporter::algorithms::Distance  
source · pub trait Distance {
    // Required method
    fn distance(&self, other: &Self) -> Length;
}Expand description
A trait that defines a method for calculating the distance between two points
of the same type. Implementations are provided for Coord<f64> and Point<f64>.
Required Methods§
Implementations on Foreign Types§
source§impl Distance for Point<f64>
 
impl Distance for Point<f64>
Implementation of Distance for Point<f64>. The distance is calculated
using the Euclidean formula.
source§impl Distance for Coord<f64>
 
impl Distance for Coord<f64>
Implementation of Distance for Coord<f64>. The distance is calculated
using the Haversine formula.