resumeNavigation

Loads the previously saved navigation resume snapshot and restores the navigation session by calling com.tomtom.sdk.navigation.TomTomNavigation.resume method.

To automatically resume a previously saved navigation session, you can use the following snippet:

val navigationResumeSnapshotRenewer = NavigationResumeSnapshotRenewerFactory.create(
context = context,
options = NavigationResumeSnapshotRenewerOptions(),
tomTomNavigation = tomTomNavigation
)
navigationResumeSnapshotRenewer.resumeNavigation(
callback = object :
Callback<NavigationResumeSnapshot, NavigationResumeSnapshotRenewerFailure> {
override fun onSuccess(result: NavigationResumeSnapshot) {
/* YOUR CODE GOES HERE */
}

override fun onFailure(failure: NavigationResumeSnapshotRenewerFailure) {
/* YOUR CODE GOES HERE */
}
}
)

Return

A Cancellable object that can be used to cancel the operation if necessary.

Parameters

callback

The callback to be invoked with the loaded navigation snapshot or in case of failure during the restoration process. The callback will be executed in the main thread.

Throws

if the navigation session is already started.