FUIMKRoutingMapViewDataSource

public protocol FUIMKRoutingMapViewDataSource : FUIMKMapViewDataSource

A protocol adopted by an object that plays as the data model of FUIMKRoutingFloorplanViewController.

  • The number of routes in map view.

    Declaration

    Swift

    func numberOfRoutes(in mapView: MKMapView) -> Int

    Parameters

    mapView

    The map view object contains these routes.

    Return Value

    number of routes.

  • Ask the data source for a route object at specific index.

    Important: Make sure the types you use to represent route vertexes and segments conform to FUIAnnotation protocol.

    Declaration

    Swift

    func mapView(_ mapView: MKMapView, routeAt index: Int) -> FUIRoute<MKPolyline, MKPointAnnotation>

    Parameters

    mapView

    The map view object contains the route.

    index

    The index of the route.

    Return Value

    A route object.