public abstract class RouteStepProgress extends Object
The latest route step progress object can be obtained through either the ProgressChangeListener
or the MilestoneEventListener
callbacks.
Note that the route step progress object's immutable.
Constructor and Description |
---|
RouteStepProgress() |
Modifier and Type | Method and Description |
---|---|
static com.mapbox.services.android.navigation.v5.routeprogress.RouteStepProgress.Builder |
builder() |
abstract double |
distanceRemaining()
Total distance in meters from user to end of step.
|
abstract double |
distanceTraveled()
Returns distance user has traveled along current step in unit meters.
|
abstract double |
durationRemaining()
Provides the duration remaining in seconds till the user reaches the end of the current step.
|
abstract float |
fractionTraveled()
Get the fraction traveled along the current step, this is a float value between 0 and 1 and
isn't guaranteed to reach 1 before the user reaches the next step (if another step exist in route).
|
public static com.mapbox.services.android.navigation.v5.routeprogress.RouteStepProgress.Builder builder()
public abstract double distanceRemaining()
public abstract double distanceTraveled()
public abstract float fractionTraveled()
public abstract double durationRemaining()
long
value representing the duration remaining till end of step, in unit seconds.© 2019 Mapbox. All rights reserved.