AWFMKMultiShapeOverlay

Objective-C

@interface AWFMKMultiShapeOverlay
    : NSObject <MKOverlay, AWFStyledMapItem, AWFMultiShapeOverlay>

Swift

class AWFMKMultiShapeOverlay : NSObject

An AWFMKMultiShapeOverlay object is a data object that contains the information needed to render multiple polygons and polylines in an Apple MapKit map view’s area.

  • The group identifier for the map item. This controls which style is used when multiple styles are available for a single data layer type.

    Declaration

    Objective-C

    @property (nonatomic, copy, nullable) NSString *identifier;

    Swift

    var identifier: String? { get set }
  • The style associated with the overlay.

    Declaration

    Objective-C

    @property (nonatomic, strong, nullable) AWFMapItemStyle *style;

    Swift

    var style: AWFMapItemStyle? { get set }
  • The layer type this map item belongs to.

    Declaration

    Objective-C

    @property (nonatomic) AWFMapLayer _Nonnull layerType;

    Swift

    var layerType: AWFMapLayer { get set }
  • The complete list of polygons associated with the overlay.

    Declaration

    Objective-C

    @property (nonatomic, strong, nullable) NSArray<MKPolygon *> *polygons;

    Swift

    var polygons: [Any]? { get set }
  • The complete list of polylines associated with the overlay.

    Declaration

    Objective-C

    @property (nonatomic, strong, nullable) NSArray<MKPolyline *> *polylines;

    Swift

    var polylines: [Any]? { get set }
  • The approximate center point of the overlay area.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CLLocationCoordinate2D coordinate;

    Swift

    var coordinate: Int32 { get }
  • The projected rectangle that encompasses the overlay.

    Declaration

    Objective-C

    @property (nonatomic, readonly) MKMapRect boundingMapRect;

    Swift

    var boundingMapRect: Int32 { get }
  • Creates and returns an AWFMKMultiShapeOverlay from the specified polygons and polylines.

    Declaration

    Objective-C

    - (nonnull instancetype)
        initWithPolygons:(nullable NSArray<MKPolygon *> *)polygons
               polylines:(nullable NSArray<MKPolyline *> *)polylines;

    Swift

    init(polygons: [Any]?, polylines: [Any]?)

    Parameters

    polygons

    The array of polygons

    polylines

    The array of polylines

    Return Value

    A new overlay object

  • Updates the polygons and polylines associated with the overlay.

    Declaration

    Objective-C

    - (void)updatePolygons:(nullable NSArray<MKPolygon *> *)polygons
                 polylines:(nullable NSArray<MKPolyline *> *)polylines;

    Swift

    func updatePolygons(_ polygons: [Any]?, polylines: [Any]?)

    Parameters

    polygons

    The array of polygons

    polylines

    The array of polylines