MSFPolygon
Objective-C
@interface MSFPolygon : MSFVectorElement
Swift
class MSFPolygon : MSFVectorElement
A geometric polygon that can be displayed on the map. Polygons can be concave and have multiple overlapping holes.
-
Constructs a Polygon object from a geometry object and a style.
Declaration
Objective-C
- (id)initWithGeometry:(MSFPolygonGeometry *)geometry style:(MSFPolygonStyle *)style;Swift
init!(geometry: MSFPolygonGeometry!, style: MSFPolygonStyle!)Parameters
geometryThe geometry object that defines the location and holes of this polygon.
styleThe style that defines what this polygon looks like.
-
Constructs a Polygon object from a vector of map positions and a style.
Declaration
Objective-C
- (id)initWithPoses:(MSFMapPosVector *)poses style:(MSFPolygonStyle *)style;Swift
init!(poses: MSFMapPosVector!, style: MSFPolygonStyle!)Parameters
posesThe vector of map positions that defines the location of this polygon.
styleThe style that defines what this polygon looks like.
-
Constructs a Polygon object from a vector of map positions, a vector of holes and a style.
Declaration
Objective-C
- (id)initWithPoses:(MSFMapPosVector *)poses holes:(MSFMapPosVectorVector *)holes style:(MSFPolygonStyle *)style;Swift
init!(poses: MSFMapPosVector!, holes: MSFMapPosVectorVector!, style: MSFPolygonStyle!)Parameters
posesThe vector of map positions that defines the location of this polygon.
holesThe vector of holes that defines the locations of holes of this polygon.
styleThe style that defines what this polygon looks like.
-
Undocumented
Declaration
Objective-C
- (MSFPolygonGeometry *)getGeometry;Swift
func getGeometry() -> MSFPolygonGeometry! -
Sets the location for this polygon.
Declaration
Objective-C
- (void)setGeometry:(MSFPolygonGeometry *)geometry;Swift
func setGeometry(_ geometry: MSFPolygonGeometry!)Parameters
geometryThe new geometry object that defines the location and holes of this polygon.
-
Returns the vertices that define this polygon.
Return Value
The vector of map positions that define this polygon.
-
Sets the vertices that define this polygon. Note: holes are not affected by this call.
Declaration
Objective-C
- (void)setPoses:(MSFMapPosVector *)poses;Swift
func setPoses(_ poses: MSFMapPosVector!)Parameters
posesThe new vector of map positions that define this polygon.
-
Returns the holes of the polygon.
Declaration
Objective-C
- (MSFMapPosVectorVector *)getHoles;Swift
func getHoles() -> MSFMapPosVectorVector!Return Value
The list of holes of the polygon.
-
Sets the holes of the polygon.
Declaration
Objective-C
- (void)setHoles:(MSFMapPosVectorVector *)holes;Swift
func setHoles(_ holes: MSFMapPosVectorVector!)Parameters
holesThe list of holes of the polygon.
-
Returns the style of this polygon.
Return Value
The style that defines what this polygon looks like.
-
Sets the style for this polygon.
Declaration
Objective-C
- (void)setStyle:(MSFPolygonStyle *)style;Swift
func setStyle(_ style: MSFPolygonStyle!)Parameters
styleThe new style that defines what this polygon looks like.
-
Undocumented
Declaration
Objective-C
-(void)dealloc;Swift
func dealloc()