Wms Layer
A layer that can visualize data from a WMS service. Web Map Service (WMS) is an Open Geospatial Consortium (OGC) standard for delivering map images from an online service. WMS layer displays data from a web service that provides maps in the form of server-rendered images. The service may be hosted in ArcGIS Enterprise or in a third party server. This API supports WMS versions 1.1.0, 1.1.1, and 1.3.0.
Functional characteristics
A WMS service can contain multiple layers in a hierarchy. A WMS layer 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. WMS layers 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.
WMS layers support identify and time. They do not support selection or query. Note that due to the nature of WMS, it is not possible to retrieve feature geometry from WMS identify results. WMS layers support custom parameters, which can be specified for the service or an individual layer.
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.
Since
200.1.0
See also
Constructors
Creates a WMS layer from a portal item.
Creates a WmsLayer from the specified WmsLayerInfo objects.
Creates a WmsLayer with the specified URL and layer names. To specify a preferred WMS version, set the 'VERSION' parameter in the 'GetCapabilities' URL for the service.
Properties
The dictionary of custom parameters to be sent with WMS requests issued by this layer. These parameters are appended to GetMap and GetFeatureInfo requests. If a parameter with the same name is defined in WmsService.customParameters, then layer-specific values take precedence over service-wide values.
The WMS Layer's set of WmsLayerInfo objects. WmsLayerInfo objects describe the layers (as provided by the service). Multiple layers from a WmsService may be included in a single WmsLayer.
A collection of the names of the visible WMS layers.
The preferred image format of this WmsLayer. If a preferred format is not specified prior to loading, then MapServiceImageFormat.Png is used.
The collection of the sublayers in this WMS layer. This is a flat, ordered list of named sublayers.
The version of the WMS specification used by this WmsLayer. This API supports the following WMS versions: 1.3.0, 1.1.1, and 1.1.0. By default this value is the latest supported WMS version.
Inherited properties
The attribution text for the layer.
The brightness of the layer.
A flag indicating whether the layer content's visibility can be changed. A flag indicating whether the layer content visibility can be changed. Will return false if an error occurs.
The description for the layer.
The full extent of this layer, which is the extent where all layer data is contained. You can use this to zoom to all of the data contained in this layer. For feature layers, the extent is retrieved from its FeatureTable.extent.
The full time extent of the layer. If the layer, such as an ArcGISMapImageLayer, has sublayers with different time extents, fullTimeExtent is a union of its sublayer's time extents.
The unique identifying string for the layer, as specified in a map or scene. The id is used by other parts of this API to refer to a specific Layer, such as in a set of FeatureFenceParameters or a FacilityLayerDefinition. If not supplied, all layers will be assigned a unique id when created.
True if the layer supports identify, false otherwise. The value of this property may not be correct until the layer is in a fully loaded state.
True if the layer filters data based on its GeoView.timeExtent, false otherwise. This is only applicable if the layer's TimeAware.supportsTimeFiltering value is true. If the GeoView.timeExtent value is null, no time filtering is applied and all content is rendered.
The load status.
The maximum scale for the layer. The maximum scale at which this layer is visible. If the map or scene is zoomed in beyond this scale, the layer will not be visible. A value of 0 means there is no maximum scale threshold and the layer will be visible at the smallest scale available for the map or scene. If the value is nil, there is no maximum scale. All of the connected map and scene views will be updated.
The minimum scale for the layer. The minimum scale at which this layer is visible. If the map or scene is zoomed out beyond this scale, the layer will not be visible. A value of 0 means there is no minimum scale threshold and the layer will be visible at the largest scale available for the map or scene. If the value is nil, there is no minimum scale. All of the connected map and scene views will be updated.
The objects refresh interval. The refresh interval, in milliseconds. A refresh interval of null means never refresh.
A flag indicating whether the layer content participates in the legend. A flag indicating whether the layer content is shown in the legend.
The spatial reference of the layer.
The sub layer contents of a layer content.
True if the layer supports filtering data based on its time values, false otherwise.
The suggested time slider step size for this time aware layer. You can use this information to set the step size for a time slider control. The value is null if no time interval is suggested. The author of the layer's data typically configures this property if the data has been collected on a regular basis. For example, the daily position of a hurricane.
The amount of time by which the temporal values of this layer's data points are offset when displaying it in a GeoView. The time offset is subtracted from the time extent set on the layer's GeoView. This is useful if you want to overlay data in multiple layers that lies within different temporal extents. For example, if you want to compare data in one layer for a certain year with data in the same layer from the subsequent year, you can create two layers that reference the same data's service endpoint but set the TimeValue in one of the layers to be one year.
Callback invoked when the visibility of the layer changes.
Inherited functions
Cancels loading metadata for the Loadable object.
Fetches the list of legend info.
Returns the layer content's effective visibility at the specified scale. Returns the effective layer content visibility. This effective visibility takes care of the effective visibility of the parents at the specified scale. Will return false if an error occurs.