diff options
author | tobrun <tobrun.van.nuland@gmail.com> | 2019-06-04 10:10:50 +0200 |
---|---|---|
committer | Tobrun <tobrun.van.nuland@gmail.com> | 2019-06-05 09:38:20 +0200 |
commit | 36361192b1b55a272b6115876ffe18be55f6b964 (patch) | |
tree | c304dac2134c619de2556be7e48a74bb18f28327 /platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java | |
parent | a5f7f73dfefbcb92e44cd26bfeb894ca425c893a (diff) | |
download | qtlocation-mapboxgl-36361192b1b55a272b6115876ffe18be55f6b964.tar.gz |
[android] - rename style component URL api to URI
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java')
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java | 45 |
1 files changed, 39 insertions, 6 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java index 586234a0c2..e8e38c4f4e 100644 --- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java +++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshotter.java @@ -93,7 +93,7 @@ public class MapSnapshotter { private float pixelRatio = 1; private int width; private int height; - private String styleUrl = Style.MAPBOX_STREETS; + private String styleUri = Style.MAPBOX_STREETS; private String styleJson; private LatLngBounds region; private CameraPosition cameraPosition; @@ -114,12 +114,12 @@ public class MapSnapshotter { } /** - * @param url The style URL to use + * @param uri The style URI to use * @return the mutated {@link Options} */ @NonNull - public Options withStyle(String url) { - this.styleUrl = url; + public Options withStyle(String uri) { + this.styleUri = uri; return this; } @@ -198,7 +198,9 @@ public class MapSnapshotter { * * @param apiBaseUrl The base of our API endpoint * @return the mutated {@link Options} + * @deprecated use {@link #withApiBaseUri(String)} instead */ + @Deprecated @NonNull public Options withApiBaseUrl(String apiBaseUrl) { this.apiBaseUrl = apiBaseUrl; @@ -206,6 +208,18 @@ public class MapSnapshotter { } /** + * Specifies the URI used for API endpoint. + * + * @param apiBaseUri The base of our API endpoint + * @return the mutated {@link Options} + */ + @NonNull + public Options withApiBaseUri(String apiBaseUri) { + this.apiBaseUrl = apiBaseUrl; + return this; + } + + /** * @return the width of the image */ public int getWidth() { @@ -236,9 +250,18 @@ public class MapSnapshotter { /** * @return the style url + * @deprecated use {@link #getStyleUri()} instead */ + @Deprecated public String getStyleUrl() { - return styleUrl; + return styleUri; + } + + /** + * @return the style uri + */ + public String getStyleUri() { + return styleUri; } /** @@ -259,11 +282,21 @@ public class MapSnapshotter { /** * @return The base of our API endpoint + * @deprecated use {@link #getApiBaseUri()} instead */ @Nullable + @Deprecated public String getApiBaseUrl() { return apiBaseUrl; } + + /** + * @return The base of our API endpoint + */ + @Nullable + public String getApiBaseUri() { + return apiBaseUrl; + } } /** @@ -289,7 +322,7 @@ public class MapSnapshotter { String programCacheDir = FileSource.getInternalCachePath(context); nativeInitialize(this, fileSource, options.pixelRatio, options.width, - options.height, options.styleUrl, options.styleJson, options.region, options.cameraPosition, + options.height, options.styleUri, options.styleJson, options.region, options.cameraPosition, options.showLogo, programCacheDir, options.localIdeographFontFamily); } |