RouteCoordinate

public struct RouteCoordinate

Important

This is a Public Preview API. It may be changed or removed at any time.

RouteCoordinate

  • Calculates the geographic distance from this coordinate to the coordinate given as an argument

    Declaration

    Swift

    public func distance(to otherCoordinate: CLLocationCoordinate2D) -> Measurement<UnitLength>

    Parameters

    otherCoordinate

    A coordinate for calculation

    Return Value

    Calculated distance in meters.

  • Calculates the angle (bearing) between this coordinate and the coordinate given as an argument.

    Declaration

    Swift

    public func angle(to otherCoordinate: CLLocationCoordinate2D) -> Double

    Parameters

    otherCoordinate

    A coordinate for calculation

    Return Value

    Calculated angle.