NavigationSessionState

sealed class NavigationSessionState

Contains the various states that can occur during a navigation.

The MapboxNavigation implementation can enter into the following session states:

The SDK starts off in an Idle state. Whenever the MapboxNavigation.startTripSession is called, the SDK will enter the FreeDrive state. If the session is stopped, the SDK will enter the Idle state. If the SDK is in an Idle state, it stays in this same state even when a primary route is available. If the SDK is already in the FreeDrive mode or entering it whenever a primary route is available, the SDK will enter the ActiveGuidance mode instead. When the routes are manually cleared, the SDK automatically fall back to either Idle or FreeDrive state. When transitioning across states of a trip session the sessionId will change (empty when Idle).

Types

Link copied to clipboard
data class ActiveGuidance : NavigationSessionState

Active Guidance state

Link copied to clipboard
data class FreeDrive : NavigationSessionState

Free Drive state

Link copied to clipboard
object Idle : NavigationSessionState

Idle state

Properties

Link copied to clipboard
abstract val sessionId: String

Random session UUID. This is generated internally based on the current state within a trip session. I.e. will change when transitioning across states of a trip session. Empty when Idle.

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard