RouteAlternativesOptions

class RouteAlternativesOptions

The options available for observing alternative routes. The RouteOptions used to set the current active route are updated according to the current route progress.

Register your RouteAlternativesObserver through MapboxNavigation, the onRouteAlternatives callback will be triggered every intervalMillis. There are multiple conditions that will disable alternative route requests:

  • There are no observers registered

  • There is not an active route

  • The trip session is not started

Parameters

intervalMillis

The interval in milliseconds, default is 5 min. Minimum is 30 seconds.

avoidManeuverSeconds

a radius in seconds around origin point where need to avoid any significant maneuvers. Unit is seconds, default is 8 second.

Types

Builder
Link copied to clipboard
class Builder

Functions

equals
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Regenerate whenever a change is made
hashCode
Link copied to clipboard
open override fun hashCode(): Int
Regenerate whenever a change is made
toBuilder
Link copied to clipboard
fun toBuilder(): RouteAlternativesOptions.Builder
toString
Link copied to clipboard
open override fun toString(): String
Returns a string representation of the object.

Properties

avoidManeuverSeconds
Link copied to clipboard
val avoidManeuverSeconds: Int
a radius in seconds around origin point where need to avoid any significant maneuvers.
intervalMillis
Link copied to clipboard
val intervalMillis: Long
The interval in milliseconds, default is 5 min.