dispose
Stops any ongoing operations (including location tracking or foreground service if active etc.), cleans up internal state and releasing resources. Call this when NavigationApi is no longer needed.
Before disposing, ensure all SDK related objects are destroyed (for example map view etc. and they are no longer used).
Throws
if the method is called in an invalid state, specifically if:
the
valueof sdkState is SdkState.Disposed or SdkState.Disposing.