diff options
author | Jason Wray <jason@mapbox.com> | 2018-04-12 18:59:09 -0400 |
---|---|---|
committer | Jason Wray <jason@mapbox.com> | 2018-04-16 18:42:34 -0400 |
commit | d4e597eb94a90a816fcc480fa7b6719430a20b84 (patch) | |
tree | ac098db0c1a3f35d883b8565c8bc598dc7647ad1 /platform/darwin/src/MGLAccountManager.h | |
parent | 0529c018f3ea76d2aa0405c88849fe319cc1da25 (diff) | |
download | qtlocation-mapboxgl-d4e597eb94a90a816fcc480fa7b6719430a20b84.tar.gz |
[ios, macos] Convert various class methods to class properties
This improves the Swift interface while having no effect on Obj-C usage.
Diffstat (limited to 'platform/darwin/src/MGLAccountManager.h')
-rw-r--r-- | platform/darwin/src/MGLAccountManager.h | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/platform/darwin/src/MGLAccountManager.h b/platform/darwin/src/MGLAccountManager.h index b691c4c906..436e45ca9b 100644 --- a/platform/darwin/src/MGLAccountManager.h +++ b/platform/darwin/src/MGLAccountManager.h @@ -5,7 +5,7 @@ NS_ASSUME_NONNULL_BEGIN /** - The MGLAccountManager object provides a global way to set a Mapbox API access + The `MGLAccountManager` object provides a global way to set a Mapbox API access token. */ MGL_EXPORT @@ -14,9 +14,9 @@ MGL_EXPORT #pragma mark Authorizing Access /** - Set the + The <a href="https://www.mapbox.com/help/define-access-token/">Mapbox access token</a> - to be used by all instances of MGLMapView in the current application. + used by all instances of `MGLMapView` in the current application. Mapbox-hosted vector tiles and styles require an API access token, which you can obtain from the @@ -25,24 +25,16 @@ MGL_EXPORT your Mapbox account. They also deter other developers from using your styles without your permission. - @param accessToken A Mapbox access token. Calling this method with a value of - `nil` has no effect. + Setting this property to a value of `nil` has no effect. @note You must set the access token before attempting to load any Mapbox-hosted style. Therefore, you should generally set it before creating an instance of - MGLMapView. The recommended way to set an access token is to add an entry to - your application’s Info.plist file with the key `MGLMapboxAccessToken` and - the type String. Alternatively, you may call this method from your + `MGLMapView`. The recommended way to set an access token is to add an entry + to your application’s Info.plist file with the key `MGLMapboxAccessToken` + and the type `String`. Alternatively, you may call this method from your application delegate’s `-applicationDidFinishLaunching:` method. */ -+ (void)setAccessToken:(nullable NSString *)accessToken; - -/** - Returns the - <a href="https://www.mapbox.com/help/define-access-token/">Mapbox access token</a> - in use by instances of MGLMapView in the current application. - */ -+ (nullable NSString *)accessToken; +@property (class, nullable) NSString *accessToken; + (BOOL)mapboxMetricsEnabledSettingShownInApp __attribute__((unavailable("Telemetry settings are now always shown in the ℹ️ menu."))); |