Other Type Aliases

The following type aliases are available globally.

  • A closure to call when the NavigationDirections router has been configured completely.

    Declaration

    Swift

    public typealias NavigationDirectionsCompletionHandler = (_ numberOfTiles: UInt64) -> Void
  • A closure to call when an unpacking operation has made some progress.

    Declaration

    Swift

    public typealias UnpackProgressHandler = (_ totalBytes: UInt64, _ remainingBytes: UInt64) -> ()

    Parameters

    totalBytes

    The total size of tile pack in bytes.

    remainingBytes

    The remaining number of bytes left to download.

  • A closure to call once an unpacking operation has completed.

    Declaration

    Swift

    public typealias UnpackCompletionHandler = (_ numberOfTiles: UInt64, _ error: Error?) -> ()

    Parameters

    numberOfTiles

    The number of tiles that were unpacked.

    error

    Potential error that occured when trying to unpack.

  • A closure (block) to be called when a directions request is complete.

    If the request was canceled or there was an error obtaining the routes, this argument may be nil.

    If the request was canceled or there was an error obtaining the routes, this argument is nil. This is not to be confused with the situation in which no results were found, in which case the array is present but empty.

    Declaration

    Swift

    public typealias OfflineRouteCompletionHandler = (_ session: Directions.Session, _ result: Result<RouteResponse, OfflineRoutingError>) -> Void

    Parameters

    waypoints

    An array of Waypoint objects. Each waypoint object corresponds to a Waypoint object in the original RouteOptions object. The locations and names of these waypoints are the result of conflating the original waypoints to known roads. The waypoints may include additional information that was not specified in the original waypoints.

    routes

    An array of Route objects. The preferred route is first; any alternative routes come next if the RouteOptions object’s includesAlternativeRoutes property was set to true. The preferred route depends on the route options object’s profileIdentifier property.

    error

    The error that occurred, or nil if the placemarks were obtained successfully.

  • A container view controller is a view controller that behaves as a navigation component; that is, it responds as the user progresses along a route according to the NavigationServiceDelegate protocol.

    Declaration

    Swift

    public typealias ContainerViewController = UIViewController & NavigationComponent