ArcGISTiledLayer.withUri constructor
- Uri uri
Creates an ArcGIS tiled layer from the specified URI.
If the specified URI is a map service URL, the MapServer must have "Single Fused Map Cache" set to true in its ArcGIS REST Services Directory. If the specified URI is a portal item URL, the underlying PortalItem is created and can be accessed through Layer.item. See PortalItem.withUri for the supported URL formats.
Parameters:
uri
— The URL to the REST endpoint of an ArcGIS map service or ArcGIS map service portal item, or the path to a local tile package(.tpk/.tpkx).
Implementation
factory ArcGISTiledLayer.withUri(
Uri uri,
) {
_initializeArcGISEnvironmentIfNeeded();
final coreURI = _CString(uri.toString());
final handle = _withThrowingErrorHandler((errorHandler) {
return runtimecore.RT_ArcGISTiledLayer_createWithURI(
coreURI.bytes,
errorHandler,
);
});
return Layer._instanceCache.instanceWith(handle);
}