FUIMKMapViewDataSource
public protocol FUIMKMapViewDataSource : AnyObject
A protocol adopted by an object that plays as the data model of FUIMKMapView
.
-
The number of layers in map view.
Declaration
Swift
func numberOfLayers(in mapView: MKMapView) -> Int
Parameters
mapView
The map view object contains these layers.
Return Value
number of layers.
-
Ask the data source for
FUIGeometryLayer
object at specified index.Declaration
Swift
func mapView(_ mapView: MKMapView, layerAtIndex index: Int) -> FUIGeometryLayer
Parameters
mapView
The map view object contains the layer.
index
The index of layer.
Return Value
The
FUIGeometryLayer
object at specified index. -
Ask the data source for geometry objects at specified layer.
Declaration
Swift
func mapView(_ mapView: MKMapView, geometriesForLayer layer: FUIGeometryLayer) -> [MKAnnotation]
Parameters
mapView
The map view object contains the geometry objects.
layer
The layer contains these geometry objects.
Return Value
Geometry objects in the layer.