showRouteWithLegIndexHighlighted
suspend fun MapboxRouteLineApi.showRouteWithLegIndexHighlighted(legIndex: Int): Expected<RouteLineError, RouteLineUpdateValue>
Content copied to clipboard
If successful this method returns a RouteLineUpdateValue that when rendered will display the route line with the route leg indicated by the provided leg index highlighted. All the other legs will only show a simple line with RouteLineColorResources.inActiveRouteLegsColor.
This is intended to be used with routes that have multiple waypoints. In addition, calling this method does not change the state of the route line.
This method can be useful for showing a route overview with a specific route leg highlighted.
Return
a RouteLineUpdateValue for rendering or an error
Parameters
legIndex
the route leg index that should appear most prominent.