Skip To Content ArcGIS for Developers Sign In Dashboard

WmsLayer QML Type

Defines an Open Geospatial Consortium (OGC) Web Map Service (WMS) layer. More...

Import Statement: import Esri.ArcGISRuntime 100.9
Since: Esri.ArcGISRuntime 100.2
Inherits:

ImageAdjustmentLayer

Properties

Signals

Detailed Description

An instance of this class allows you to display data from a WMS service.

Web Map Service (WMS) is an Open Geospatial Consortium (OGC) standard for delivering map images from an online service. WmsLayer displays data from a web service that provides maps in the form of server-rendered images. ArcGIS Runtime supports WMS versions 1.1.0, 1.1.1, and 1.3.0. The service may be hosted in the cloud on ArcGIS Online, on a third party server, or on-premises with ArcGIS Server.

Functional characteristics

A WMS service can contain multiple layers in a hierarchy. WmsLayer can be constructed directly with a URL to a service and the uniquely identifying name of the desired layer. Alternatively, a WmsService can be used to programmatically explore the available layers and allow the user to choose layers at run time.

The maps provided by a WMS service use predefined symbology defined by the server. As a result, it is not possible to apply custom renderers or to visualize feature selection. A WmsLayer can have multiple style options. Your app can choose from the available styles.

Some layers can be marked as opaque, which means that they cover most of the map area and are good candidates for use as a basemap.

WmsLayer supports identify and time, but not selection or query. Note that due to the nature of WMS, it is not possible to retrieve feature geometry from WMS identify results. WmsLayer supports custom parameters, which can be specified for the service or an individual layer.

WmsLayer adopts the loadable pattern, and many of its properties are initialized asynchronously. The layer is loaded when displayed in a MapView or a SceneView. If using the layer without a MapView or a SceneView, call the Loadable::load method to load it before use. Use the Loadable::loadStatusChanged signal to determine when the layer is ready, and check the Enums.LoadStatus before using the layer.

Required propertiesurllayerNameslayerInfos
url and layerNamesrequiredrequiredunused
layerInfosunusedunusedrequired

Performance characteristics

WMS servers render map images on demand, which can require more server resources than a similar tiled service. WMS requires a service connection at all times.

Default properties

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.

See sample: WMS layer (URL)

See also Layer, WmsService, WmsServiceInfo, WmsLayerInfo, WmsSublayer, ImageAdjustmentLayer, Loadable, LayerContent, RemoteResource, and TimeAware.

Property Documentation

[default] credential : Credential

The credential used to access a secured WMS service.

The credential cannot be changed after the layer is loaded.


customParameters : jsobject

Returns key/value pairs representing the custom parameters that are applied to the WMS requests related to this layer.

The key and value for each key/value pair must be strings, where the key is the parameter's name and the value the parameter's value.

When making a WMS request, only parameters required by the service are included by default. Setting custom parameters will allow you to specify any additional parameters, such as API keys or user credentials, to the service. These parameters will be appended to GetMap and GetFeatureInfo requests.

When used together with a WmsService, if a parameter with the same name is defined in the service's custom parameters, then layer-specific values will take precedence over service-wide parameter values.

This property was introduced in Esri.ArcGISRuntime 100.3.


fullTimeExtent : TimeExtent

Returns the full time extent of the time aware layer (read-only).

Note: This property is only available after the time aware layer is loaded.

This property was introduced in Esri.ArcGISRuntime 100.3.

See also TimeExtent.


[default] item : ArcGISItem

The item used to initialize this WMSLayer.

The item cannot be changed after the layer is loaded.


layerInfos : list<WmsLayerInfo>

A list of WmsLayerInfo objects describing the selected WMS sublayers.


layerNames : list<string>

A list of names of visible WMS layers.


preferredImageFormat : Enums.MapServiceImageFormat

Returns the preferred image format of this WMS layer (read-only).

If a preferred format is not specified prior to loading, then Enums.MapServiceImageFormat.Png32 is used.

See also Enums.MapServiceImageFormat.


refreshInterval : int

The refresh interval used by the layer in milliseconds.

Layers request data from the service each time this interval elapses.

A value of 0 means to never refresh.

Note: The value is treated as unsigned and cannot be negative.


requestConfiguration : RequestConfiguration

Returns the RequestConfiguration in use by this layer.


sublayers : list<WmsSublayer>

Returns a list of WmsSublayer for this WMS Layer


supportsTimeFiltering : bool

Returns whether the time aware layer supports filtering its contents by time values (read-only).

This property was introduced in Esri.ArcGISRuntime 100.3.


timeFilteringEnabled : bool

Returns whether the time aware layer participates in filtering based on the time extent of its geo view.

This property was introduced in Esri.ArcGISRuntime 100.3.


timeInterval : TimeValue

Returns a time interval that represents the suggested step size for use when manipulating the time extent (read-only).

This information can be used to set the step size for a time slider control.

Note: This property is only available after the time aware layer is loaded.

This property was introduced in Esri.ArcGISRuntime 100.3.

See also TimeValue.


timeOffset : TimeValue

The time offset of the time aware layer.

The time offset is subtracted from the time extent set on the time aware layer's geo view. This can be used to overlay data from different periods of time for comparison.

Note: This property is only available after the layer is loaded.

This property was introduced in Esri.ArcGISRuntime 100.3.

See also TimeValue.


url : url

The URL of the WMS service.

/sa /l WmsService::url.


version : Enums.WmsVersion

The version of this WMS Layer.

ArcGIS Runtime supports WMS versions 1.3.0, 1.1.1, and 1.1.0. The latest supported WMS version is set as the default.

See also Enums.WmsVersion.


Signal Documentation

credentialChanged()

Emitted when the credential property changes.

Note: The corresponding handler is onCredentialChanged.


customParametersChanged()

Emitted when the customParameters property changes.

Note: The corresponding handler is onCustomParametersChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


fullTimeExtentChanged()

Emitted when the fullTimeExtent property of the time aware layer changes.

Note: The corresponding handler is onFullTimeExtentChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


layerInfosChanged()

Emitted when the layerInfos property changes.

Note: The corresponding handler is onLayerInfosChanged.


layerNamesChanged()

Emitted when the layerNames property changes.

Note: The corresponding handler is onLayerNamesChanged.


preferredImageFormatChanged()

Emitted when the preferredImageFormat property changes.

Note: The corresponding handler is onPreferredImageFormatChanged.


refreshIntervalChanged()

Emitted when the refreshInterval property changes.

Note: The corresponding handler is onRefreshIntervalChanged.


requestConfigurationChanged()

Emitted when the requestConfiguration property changes.

Note: The corresponding handler is onRequestConfigurationChanged.


sublayersChanged()

Emitted when the sublayers property changes.

Note: The corresponding handler is onSublayersChanged.


supportsTimeFilteringChanged()

Emitted when the supportsTimeFiltering property of the time aware layer changes.

Note: The corresponding handler is onSupportsTimeFilteringChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


timeFilteringEnabledChanged()

Emitted when the timeFilteringEnabled property of the time aware layer changes.

Note: The corresponding handler is onTimeFilteringEnabledChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


timeIntervalChanged()

Emitted when the timeInterval property of the time aware layer changes.

Note: The corresponding handler is onTimeIntervalChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


timeOffsetChanged()

Emitted when the timeOffset property of the time aware layer changes.

Note: The corresponding handler is onTimeOffsetChanged.

This signal was introduced in Esri.ArcGISRuntime 100.3.


urlChanged()

Emitted when the url property changes.

Note: The corresponding handler is onUrlChanged.


versionChanged()

Emitted when the version property changes.

Note: The corresponding handler is onVersionChanged.



Feedback on this topic?