GPKGPolygonPoints

Objective-C

@interface GPKGPolygonPoints
    : NSObject <GPKGShapePoints, GPKGShapeWithChildrenPoints>

Swift

class GPKGPolygonPoints : NSObject, GPKGShapePoints, GPKGShapeWithChildrenPoints

Polygon points shape

  • Backing polygon

    Declaration

    Objective-C

    @property (nonatomic, strong) GPKGPolygon *polygon;

    Swift

    var polygon: GPKGPolygon! { get set }
  • Polygon points

    Declaration

    Objective-C

    @property (nonatomic, strong) NSMutableArray *points;

    Swift

    var points: NSMutableArray! { get set }
  • Polygon holes

    Declaration

    Objective-C

    @property (nonatomic, strong) NSMutableArray *holes;

    Swift

    var holes: NSMutableArray! { get set }
  • Initialize

    Declaration

    Objective-C

    - (instancetype)init;

    Swift

    init!()

    Return Value

    new polygon points

  • Add a point

    Declaration

    Objective-C

    - (void)addPoint:(GPKGMapPoint *)point;

    Swift

    func addPoint(_ point: GPKGMapPoint!)

    Parameters

    point

    point

  • Add a hole

    Declaration

    Objective-C

    - (void)addHole:(GPKGPolygonHolePoints *)hole;

    Swift

    func addHole(_ hole: GPKGPolygonHolePoints!)

    Parameters

    hole

    polygon hole points

  • Update the polygon points with the map view

    Declaration

    Objective-C

    - (void)updateWithMapView:(MKMapView *)mapView;

    Swift

    func update(with mapView: MKMapView!)

    Parameters

    mapView

    map view

  • Remove the polygon points from the map view

    Declaration

    Objective-C

    - (void)removeFromMapView:(MKMapView *)mapView;

    Swift

    func remove(from mapView: MKMapView!)

    Parameters

    mapView

    map view

  • Determine if the polygon points is valid

    Declaration

    Objective-C

    - (BOOL)isValid;

    Swift

    func isValid() -> Bool

    Return Value

    true if valid

  • Determine if the polygon points has been deleted

    Declaration

    Objective-C

    - (BOOL)isDeleted;

    Swift

    func isDeleted() -> Bool

    Return Value

    true if deleted