summaryrefslogtreecommitdiff
path: root/platform/darwin/src/MGLVectorSource.h
diff options
context:
space:
mode:
Diffstat (limited to 'platform/darwin/src/MGLVectorSource.h')
-rw-r--r--platform/darwin/src/MGLVectorSource.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/platform/darwin/src/MGLVectorSource.h b/platform/darwin/src/MGLVectorSource.h
index ba8f075b5a..aa867adb6c 100644
--- a/platform/darwin/src/MGLVectorSource.h
+++ b/platform/darwin/src/MGLVectorSource.h
@@ -24,8 +24,19 @@ NS_ASSUME_NONNULL_BEGIN
(<var>extent</var>&nbsp;×&nbsp;2)&nbsp;−&nbsp;1, inclusive. Any vector style
layer initialized with a vector source must have a non-`nil` value in its
`sourceLayerIdentifier` property.
-
- <!--EXAMPLE: MGLVectorSource-->
+
+ ### Example
+
+ ```swift
+ let source = MGLVectorSource(identifier: "pois", tileURLTemplates: ["https://example.com/vector-tiles/{z}/{x}/{y}.mvt"], options: [
+ .minimumZoomLevel: 9,
+ .maximumZoomLevel: 16,
+ .attributionInfos: [
+ MGLAttributionInfo(title: NSAttributedString(string: "© Mapbox"), url: URL(string: "http://mapbox.com"))
+ ]
+ ])
+ mapView.style.addSource(source)
+ ```
*/
@interface MGLVectorSource : MGLTileSource