getManeuvers

fun getManeuvers(route: DirectionsRoute, routeLegIndex: Int? = null): Expected<ManeuverError, List<Maneuver>>

Returns a list of Maneuvers which are wrappers on top of BannerInstructions that are in the provided route.

If a RouteLeg param is provided, the returned list will only contain Maneuvers for the RouteLeg provided as param, otherwise, the returned list will only contain Maneuvers for the first RouteLeg in a DirectionsRoute.

Return

Expected with Maneuvers if success and an error if failure.

See also

Parameters

route

route for which to generate maneuver objects

routeLegIndex

specify to inform the API of the index of RouteLeg you wish to get the list of Maneuver. By default the API returns the list of maneuvers for the first RouteLeg in a DirectionsRoute.

fun getManeuvers(routeProgress: RouteProgress): Expected<ManeuverError, List<Maneuver>>

Returns a list of Maneuvers which are wrappers on top of BannerInstructions that are in the provided route.

Given RouteProgress the function prepares a list of remaining Maneuvers on the currently active route leg (RouteLegProgress).

The first upcoming Maneuver object will also contain an up-to-date distance remaining from the current user location to the maneuver point, based on RouteProgress.

Return

Expected with Maneuvers if success and an error if failure.

See also

Parameters

routeProgress

current route progress