RouteRemovedListener

fun interface RouteRemovedListener

Informs the caller that the active or proposed route has been removed from the navigation session.

The active route is removed from the session when:

The proposed route is removed from the session when:

To listen to the route being removed from the session, first implement this interface to create a listener, for example:

val routeRemovedListener = RouteRemovedListener { route, reason ->
// add code here that handles the route being removed from the session
}

Then add this listener using TomTomNavigation.addRouteRemovedListener. To stop listening to the route being removed from the session, remove the listener using TomTomNavigation.removeRouteRemovedListener.

The complementary listener that provides updates on the addition of routes to the session is RouteAddedListener. Note, during navigation in the turn by turn mode there will always be one active route. Therefore, any removal of the current active route will always be preceded by an ActiveRouteChangedListener call, with details of the new active route.

Functions

Link copied to clipboard
abstract fun onRouteRemoved(route: Route, reason: RouteRemovedReason)

Called when a route has been removed from the navigation session.