diff options
Diffstat (limited to 'platform/darwin/src/MGLPolygon.h')
-rw-r--r-- | platform/darwin/src/MGLPolygon.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/platform/darwin/src/MGLPolygon.h b/platform/darwin/src/MGLPolygon.h index 1a158874bb..a12e62b106 100644 --- a/platform/darwin/src/MGLPolygon.h +++ b/platform/darwin/src/MGLPolygon.h @@ -30,4 +30,28 @@ NS_ASSUME_NONNULL_BEGIN @end +/** + The `MGLMultiPolygon` class represents a shape consisting of one or more + polygons that do not overlap. For example, you would use an `MGLMultiPolygon` + object to represent an atoll together with an island in the atoll’s lagoon: + the atoll itself would be one `MGLPolygon` object, while the inner island would + be another. + */ +@interface MGLMultiPolygon : MGLShape <MGLOverlay> + +/** + An array of polygons forming the multipolygon. + */ +@property (nonatomic, copy, readonly) NS_ARRAY_OF(MGLPolygon *) *polygons; + +/** + Creates and returns a multipolygon object consisting of the given polygons. + + @param polygons The array of polygons defining the shape. + @return A new multipolygon object. + */ ++ (instancetype)multiPolygonWithPolygons:(NS_ARRAY_OF(MGLPolygon *) *)polygons; + +@end + NS_ASSUME_NONNULL_END |