diff options
Diffstat (limited to 'platform/darwin/src/MGLFeature.h')
-rw-r--r-- | platform/darwin/src/MGLFeature.h | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/platform/darwin/src/MGLFeature.h b/platform/darwin/src/MGLFeature.h index d187e9cf06..239a338f67 100644 --- a/platform/darwin/src/MGLFeature.h +++ b/platform/darwin/src/MGLFeature.h @@ -83,10 +83,6 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, copy, readonly) NS_DICTIONARY_OF(NSString *, id) *attributes; - - -- (NS_DICTIONARY_OF(NSString *, id) *)featureDictionary; - /** Returns the feature attribute for the given attribute name. @@ -95,6 +91,17 @@ NS_ASSUME_NONNULL_BEGIN */ - (nullable id)attributeForKey:(NSString *)key; +/** + Returns a dictionary that can be serialized as a GeoJSON Feature representation + of an instance of an `MGLFeature` subclass. + + The dictionary includes a `geometry` key corresponding to the receiver’s + underlying geometry data, a `properties` key corresponding to the receiver’s + `attributes` property, and an `id` key corresponding to the receiver’s + `identifier` property. + */ +- (NS_DICTIONARY_OF(NSString *, id) *)geoJSONDictionary; + @end /** |