TomTomNavigation

The TomTomNavigation interface serves as the primary interface for controlling the navigation process. It provides a comprehensive set of functionalities for managing and customizing a navigation session.

To manage the lifecycle of a navigation session, the interface offers methods to start and stop navigation. It also provides functionality to set and select active routes.

The interface also includes a range of listeners that allow developers to receive updates on various aspects of the navigation.

In addition to the listeners, the interface enables customization of the navigation experience. Note that by changing these properties in runtime, the navigation initialization configuration is overridden. Users can configure the betterProposalAcceptanceMode, which determines how to handle better route proposals. They can also choose the deviationReplanningMode, which defines whether the navigation automatically replans the route. The unitSystem and preferredLanguage can be customized to provide guidance instructions and announcements in the desired format and language.

Threading: This API isn't thread-safe and it's recommended to make API calls always on the same thread.

Properties

Link copied to clipboard

Controls how the route deviations are handled. When the deviation is detected the RouteTrackingStateUpdatedListener provides a RouteTrackingState with a RouteTrackingState.hasDeviated property set to true.

Link copied to clipboard
abstract val language: Locale

The current language used within TomTomNavigation in guidance instructions and announcement language.

Link copied to clipboard

The LocationProvider used by the TomTomNavigation for providing location updates to the navigation.

Link copied to clipboard

Provides access to current registered engines and allows updating them.

Link copied to clipboard

The current NavigationSnapshot. Can be null when navigation is not yet started or already stopped.

Link copied to clipboard
Link copied to clipboard

The preferred language to be used within TomTomNavigation in guidance instructions and announcement language.

Link copied to clipboard

UnitSystem to be used within TomTomNavigation.

Link copied to clipboard

The VehicleProvider used by the TomTomNavigation for providing vehicle updates to the navigation. Information from VehicleProvider.vehicle is leveraged by the HorizonEngine to provide the relevant virtual horizon. Additionally, it is used as a request parameter for route replannings during the navigation session. Notably, it supersedes any vehicle information specified in the RoutePlan.routePlanningOptions whether at the navigation start, or during any subsequent automatic or manual route replanning events.

Functions

Link copied to clipboard

Adds an ActiveRouteChangedListener. The listener is notified of changes to the active route whenever a new active route has been set.

Link copied to clipboard

Adds a DestinationArrivalListener. The listener is notified of arrival to the destination whenever ArrivalDetectionEngine successfully detects it.

Link copied to clipboard

Adds a GuidanceUpdatedListener. The listener is notified of new Guidance instances, whenever there is a change in location and the GuidanceEngine successfully generates it.

Link copied to clipboard

Adds a HorizonUpdatedListener for a specific set of horizon options. The listener is notified of updates to the horizon snapshot and the horizon position that are generated for these options.

Link copied to clipboard

Adds a LaneGuidanceUpdatedListener. The listener is notified of new LaneGuidance instances whenever there is a change in location and the GuidanceEngine successfully generates it.

Link copied to clipboard

Adds a LanguageChangedListener. The listener is notified of changes to the navigation language.

Link copied to clipboard

Adds a LocationContextUpdatedListener. The listener is notified of updates to the location context data.

Link copied to clipboard

Adds a LocationMapMatchedListener. The listener is notified of new MapMatchingResult each time a location change occurs and the MapMatchingEngine successfully matches it.

Link copied to clipboard

Adds a NavigationStateChangedListener. The listener is notified of changes to the NavigationState.

Link copied to clipboard

Adds a ProgressUpdatedListener. The listener is notified of new RouteProgress along the active route each time a location update occurs and the RouteProgressEngine successfully calculates it.

Link copied to clipboard

Adds a RouteAddedListener. The listener is notified of a new Route whenever it is added to the navigation session.

Link copied to clipboard

Adds a RouteRemovedListener. The listener is notified of a removed Route whenever it is removed from the navigation session.

Link copied to clipboard
Link copied to clipboard

Adds a RouteUpdatedListener. The listener is notified of successful updates to the Route.

Link copied to clipboard

Adds a WaypointArrivalListener. The listener is notified of waypoint arrival or departure whenever ArrivalDetectionEngine successfully detects it.

Link copied to clipboard
abstract fun departFromWaypoint(waypoint: RouteStop)

Marks a departure from the given waypoint independently from ArrivalDetectionEngine.hasArrivedAtWaypoint.

Link copied to clipboard

Retrieves a NavigationResumeSnapshot for the ongoing navigation session. This can be persisted to support resuming the navigation session when the application is restarted.

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

Removes a previously added GuidanceUpdatedListener.

Link copied to clipboard

Removes a previously added HorizonUpdatedListener.

Link copied to clipboard
Link copied to clipboard

Removes a previously added LanguageChangedListener.

Link copied to clipboard
Link copied to clipboard

Removes a previously added ProgressUpdatedListener.

Link copied to clipboard

Removes a previously added RouteAddedListener.

Link copied to clipboard

Removes a previously added RouteRemovedListener.

Link copied to clipboard

Removes a previously added RouteUpdatedListener.

Link copied to clipboard

Removes a previously added WaypointArrivalListener.

Link copied to clipboard
abstract fun resume(navigationResumeSnapshot: NavigationResumeSnapshot)

Restores the navigation session with a given NavigationResumeSnapshot.

Link copied to clipboard
abstract fun selectActiveRoute(routeId: RouteId)

Selects the Route with provided RouteId as active.

Link copied to clipboard
abstract fun setActiveRoutePlan(routePlan: RoutePlan)

Sets a provided routePlan as active.

Link copied to clipboard
abstract fun start()

Starts navigation without specifying a Route.

abstract fun start(navigationOptions: NavigationOptions)

Starts navigation with provided NavigationOptions.

Link copied to clipboard
abstract fun stop()

Stops current navigation session and clears data related to it.

Inherited functions

Link copied to clipboard
abstract fun close()