ArcGISVectorTiledLayer QML Type

Displays data from an ArcGIS vector tiled data source. More...

Import Statement: import Esri.ArcGISRuntime 100.15
Since: Esri.ArcGISRuntime 100.0
Inherits:

Layer

Properties

Signals

Detailed Description

ArcGIS vector tiled layers are much like ArcGIS tiled layers. An ArcGIS vector tiled layer consumes vector tiles and an associated style for drawing them. The data source can be a service in ArcGIS Online or ArcGIS Enterprise portal, or local vector tiles in a package (.vtpk file). You can use one of the many styled vector tiled basemaps on ArcGIS Online or create your own with the online style editor. Your customized vector tiled layers can be saved to and read from ArcGIS Online.

The tile data format is optimized to reduce network bandwidth demand and reduce CPU load while rendering the tiles. Vector tiled layers are appropriate for basemap, reference and possibly operational layers. They do not contain any feature data, and do not support identify or search operations.

Vector tiles are an alternative to raster tile basemap layers. Instead of pixels, the cartography is delivered using 2-D points. The points describe lines, polygons or the locations of labels and marker symbols. The file format of tiles is binary and conforms to the Mapbox Vector Tile Specification. Because the vector tile file format requires much less space than raster tiles, they take up less disk space and draw more quickly than bitmap-based data. Thus, they also tend to be more suitable for low-bandwidth or offline environments.

Vector tiles are rendered on the device at runtime and so the differences between levels of detail appear more continuous and crisp regardless of screen size or resolution. Vector tiled layers do not support identify, query, selection, or time, and they cannot be displayed in scenes.

To create a vector tiled layer, the runtime client is given either a URL or a portal item. The URL can point to a vector tile source, a vector tile style sheet, or a local vector tile package file. The portal item will contain a URL to a vector tile style sheet, which describes the appearance of the geometry and must be in the Mapbox GL Style format. The style sheet also contains a URL to a vector tile source. The source must be in the Mapbox TileJSON format. The vector tile source info includes a URL to a default style sheet.

More than one vector tile style sheet can use the same source. Both the vector tile source info and the style sheet are persisted as human readable JSON files.

The vector tile package is a single file (.vptk) that contains all of the tile data files, the source information, a style sheet, and the font and symbol marker resources required to display the map.

Use ExportVectorTilesTask to generate and download a VectorTileCache (optionally including a custom style) directly to the device as a single-tile .vtpk file which can be used to instantiate the layer. You can use ArcGIS Pro to create a vector tile package and provision it to the device. The same task can also create an ItemResourceCache, which stores style resources of the vector tile package. Or, you can use ArcGIS Pro to create a mobile map package (.mmpk file) that contains a vector tile package and your custom style.

This QML type supports the following default properties. A default property may be declared inside another declared object without being assigned explicitly to a property.

TypeDefault Property
ArcGISItemitem
Credentialcredential
RequestConfigurationrequestConfiguration (since Esri.ArcGISRuntime 100.1)
VectorTileCachevectorTileCache (since Esri.ArcGISRuntime 100.2)
ItemResourceCacheitemResourceCache (since Esri.ArcGISRuntime 100.2)

Example:

Display the Navigation vector tile layer by using an online service:

// Create MapView that contains a Map
MapView {
    id: mapview
    anchors.fill: parent

    Component.onCompleted: {
        // Set the focus on MapView to initially enable keyboard navigation
        forceActiveFocus();
    }

    Map {
        id: map
        Basemap {
            // Nest an ArcGISVectorTiledLayer Layer in the Basemap
            ArcGISVectorTiledLayer {
                url: "https://www.arcgis.com/home/item.html?id=7675d44bb1e4428aa2c30a9b68f97822"
            }
        }
        initialViewpoint: ViewpointCenter {
            center: Point { x:-80.18; y: 25.778135; spatialReference: SpatialReference { wkid: 4326 } }
            targetScale: 150000
        }
    }
}

Alternatively, you can display vector tiles offline by setting the file path to a local vector tile package (*.vtpk):

// create a basemap from a local vector tile package
Basemap {
    ArcGISVectorTiledLayer {
        url: dataPath + "vtpk/LosAngeles.vtpk"
    }
}

See sample: Vector tiled layer (URL)

See also ApiKeyResource, Cancelable, LayerContent, Loadable, RemoteResource, Layer, LayerContent, Loadable, and RemoteResource.

Property Documentation

apiKey : string

Returns the API key.

This property was introduced in Esri.ArcGISRuntime 100.10.

See also ApiKeyResource.


[default] credential : Credential

The credential used to access the source of this layer.


[default] item : ArcGISItem

The item used to initialize the layer.

The item cannot be changed after the layer is loaded.


itemResourceCache : ItemResourceCache

The item resource cache containing style resources for this layer.

This property was introduced in Esri.ArcGISRuntime 100.2.


[default] requestConfiguration : RequestConfiguration

The configuration parameters used for network requests sent by this layer.

This property was introduced in Esri.ArcGISRuntime 100.1.


sourceInfo : VectorTileSourceInfo

Returns information about the vector tile layer's source (read-only).

The returned VectorTileSource includes name, extent, visible scale, and so on.


style : VectorTileStyle

Returns information about the style sheet used with this vector tiled layer (read-only).

The returned VectorTileStyle includes the style sheet's URL, version, and so on.


url : url

The URL to the source of this layer.


vectorTileCache : VectorTileCache

The vector tile cache of this layer.

This property was introduced in Esri.ArcGISRuntime 100.2.


Signal Documentation

apiKeyChanged()

Emitted when the apiKey property changes.

Note: The corresponding handler is onApiKeyChanged.

This signal was introduced in Esri.ArcGISRuntime 100.10.

See also ApiKeyResource.


credentialChanged()

Emitted when the credential property changes.

Note: The corresponding handler is onCredentialChanged.


itemResourceCacheChanged()

Emitted when the itemResourceCache property changes.

Note: The corresponding handler is onItemResourceCacheChanged.

This signal was introduced in Esri.ArcGISRuntime 100.2.


requestConfigurationChanged()

Emitted when the requestConfiguration property changes.

Note: The corresponding handler is onRequestConfigurationChanged.

This signal was introduced in Esri.ArcGISRuntime 100.1.


sourceInfoChanged()

Emitted when the sourceInfo property changes.

Note: The corresponding handler is onSourceInfoChanged.


styleChanged()

Emitted when the style property changes.

Note: The corresponding handler is onStyleChanged.


urlChanged()

Emitted when the url property changes.

Note: The corresponding handler is onUrlChanged.


vectorTileCacheChanged()

Emitted when the vectorTileCache property changes.

Note: The corresponding handler is onVectorTileCacheChanged.

This signal was introduced in Esri.ArcGISRuntime 100.2.


Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.