ExportVectorTilesTask class final

A task to download vector tiles with their default style or with their associated custom style resources. Optionally, the task can download only the custom style resources.

Vector tiles are exported as a vector tile package (.vtpk) file, see VectorTileCache, from a vector tile service. The vector tile service must support the creation of an offline vector tile cache; specifically, it must enable the "exportTiles" operation.

Vector tiles contain vector representations of data that can be restyled for different purposes, such as day and night viewing. You can download default styling resources along with the vector tiles and custom style resources from ArcGIS Portal items that host vector tile layers. You can checked whether the vector tiles have custom styles using ExportVectorTilesTask.hasStyleResources. Custom styles are exported separately as an ItemResourceCache.

The export vector tiles task can be initialized with a URL using ExportVectorTilesTask.withUri. The URL can be to:

  • A vector tile server that ends in "VectorTileServer" and is the rest end-point used to export vector tile packages. The vector tile service must be enabled for export or the task will fail to load.
  • A portal item for a vector tile service or a vector tiled layer with a custom style applied.
  • A vector basemap layer created using a BasemapStyle.

Alternatively a PortalItem, referencing a vector tile service or a custom style for a vector tiled layer, can be used with ExportVectorTilesTask.withPortalItem.

When using Esri provided vector basemaps that do not support exporting tiles (such as the ArcGIS streets basemap - see BasemapStyle.arcGISStreets), an alternative service that supports exporting tiles will be used instead.

Implemented types
Mixed-in types

Constructors

ExportVectorTilesTask.withPortalItem(PortalItem portalItem)
Creates an export vector tiles task with a portal item of type PortalItemType.vectorTileService.
factory
ExportVectorTilesTask.withUri(Uri uri)
Creates an export vector tiles task with a URL to a vector tile service.
factory

Properties

apiKey String
The API key allows your app to access ArcGIS location services and private portal items.
getter/setter pairoverride
hashCode int
The hash code for this object.
no setterinherited
hasStyleResources bool
True if the task's portal item has any associated style resources that override the default style of the vector tile service, false otherwise.
no setter
loadError ArcGISException?
The load error.
no setterinherited
loadStatus LoadStatus
The load status.
no setterinherited
onLoadStatusChanged Stream<LoadStatus>
A stream that reports changes to the LoadStatus.
no setterinherited
portalItem PortalItem?
The task's portal item which must be of type PortalItemType.vectorTileService.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
uri Uri?
The URL for exporting vector tiles.
no setter
vectorTileSourceInfo VectorTileSourceInfo?
The task's VectorTileSourceInfo representing the source metadata for a vector tile service.
no setter

Methods

cancelLoad() → void
Cancels loading metadata for the object.
inherited
createDefaultExportVectorTilesParameters({required Geometry areaOfInterest, required double maxScale}) Future<ExportVectorTilesParameters>
Creates and returns the default parameters for the export vector tile task.
exportStyleResourceCache({required Uri itemResourceCacheUri}) ExportVectorTilesJob
Return a new export vector tiles job that will download a custom style from a portal item as an item resource cache.
exportVectorTiles({required ExportVectorTilesParameters parameters, required Uri downloadFileUri}) ExportVectorTilesJob
Returns a new export vector tiles job that can be used to generate and download a vector tile package containing the vector tiles specified by the parameters (ExportVectorTilesParameters).
exportVectorTilesWithItemResourceCache({required ExportVectorTilesParameters parameters, required Uri vectorTileCacheUri, required Uri itemResourceCacheUri}) ExportVectorTilesJob
Return a new export vector tiles job that can be used to generate and download a vector tile package and return a custom style as an item resource cache.
load() Future<void>
Loads the metadata for the object asynchronously.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
retryLoad() Future<void>
Loads or retries loading metadata for the object asynchronously.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited