public final class RouteRefresh extends Object
Constructor and Description |
---|
RouteRefresh(String accessToken,
RefreshCallback refreshCallback)
Creates a
RouteRefresh object which calls the RefreshCallback with updated
routes. |
Modifier and Type | Method and Description |
---|---|
void |
refresh(RouteProgress routeProgress)
Refreshes the
DirectionsRoute included in the RouteProgress and returns it
to the callback that was originally passed in. |
public RouteRefresh(String accessToken, RefreshCallback refreshCallback)
RouteRefresh
object which calls the RefreshCallback
with updated
routes.accessToken
- mapbox access tokenrefreshCallback
- to call with updated routespublic void refresh(RouteProgress routeProgress)
DirectionsRoute
included in the RouteProgress
and returns it
to the callback that was originally passed in. The client will then have to update their
DirectionsRoute
with the LegAnnotation
s
returned in this response. The leg annotations start at the current leg index of the
RouteProgress
routeProgress
- to refresh via the route and current leg index© 2019 Mapbox. All rights reserved.