NavigationViewController

open class NavigationViewController : UIViewController, NavigationStatusPresenter, NavigationViewData, BuildingHighlighting
extension NavigationViewController: NavigationServiceDelegate
extension NavigationViewController: StyleManagerDelegate
extension NavigationViewController: TopBannerViewControllerDelegate
extension NavigationViewController: BottomBannerViewControllerDelegate
extension NavigationViewController: CarPlayConnectionObserver
extension NavigationViewController: NavigationMapViewDelegate

NavigationViewController is a fully-featured user interface for turn-by-turn navigation. Do not confuse it with the NavigationController class in UIKit.

You initialize a navigation view controller based on a predefined RouteResponse and NavigationOptions. As the user progresses along the route, the navigation view controller shows their surroundings and the route line on a map. Banners above and below the map display key information pertaining to the route. A list of steps and a feedback mechanism are accessible via the navigation view controller.

Route initialization should be configured before view controller’s view is loaded. Usually, that is automatically done during any of the inits, but you may also change this settings via prepareViewLoading(routeResponse:, routeIndex:, routeOptions:, navigationOptions:) methods. For example that could be handy while configuring a ViewController for a UIStoryboardSegue.

To be informed of significant events and decision points as the user progresses along the route, set the NavigationService.delegate property of the NavigationService that you provide when creating the navigation options.

CarPlayNavigationViewController manages the corresponding user interface on a CarPlay screen.

Important

Creating an instance of this type with parameters that uses RouteController with will start an Active Guidance session. The trip session is stopped when the instance is deallocated. For more info read the Pricing Guide.