public final class MeasurementUtils extends Object
Modifier and Type | Method and Description |
---|---|
static double |
userTrueDistanceFromStep(com.mapbox.geojson.Point usersRawLocation,
com.mapbox.api.directions.v5.models.LegStep step)
Calculates the distance between the users current raw
Location object
to the closest Point in the LegStep . |
public static double userTrueDistanceFromStep(com.mapbox.geojson.Point usersRawLocation, com.mapbox.api.directions.v5.models.LegStep step)
Location
object
to the closest Point
in the LegStep
.usersRawLocation
- Point
the raw location where the user is currently locatedstep
- LegStep
to calculate the closest point on the step to our
predicted location© 2019 Mapbox. All rights reserved.