WmsSublayer Class

  • WmsSublayer
  • class Esri::ArcGISRuntime::WmsSublayer

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

    Header: #include <WmsSublayer.h>
    Since: Esri::ArcGISRuntime 100.2
    Inherits: Esri::ArcGISRuntime::LayerContent

    Public Functions

    virtual ~WmsSublayer() override
    Esri::ArcGISRuntime::WmsSublayer *clone(QObject *parent = nullptr) const
    QString currentStyle() const
    void setCurrentStyle(const QString &currentStyle)
    Esri::ArcGISRuntime::WmsLayerInfo sublayerInfo() const
    bool operator!=(const Esri::ArcGISRuntime::WmsSublayer &other) const
    bool operator==(const Esri::ArcGISRuntime::WmsSublayer &other) const

    Reimplemented Public Functions

    virtual bool canChangeVisibility() const override
    virtual bool isAutoFetchLegendInfos() const override
    virtual bool isShowInLegend() const override
    virtual bool isVisible() const override
    virtual bool isVisibleAtScale(double scale) const override
    virtual Esri::ArcGISRuntime::LegendInfoListModel *legendInfos() const override
    virtual QString name() const override
    virtual void setAutoFetchLegendInfos(bool autoFetchLegendInfos) override
    virtual void setShowInLegend(bool showInLegend) override
    virtual void setVisible(bool visible) override
    virtual QList<Esri::ArcGISRuntime::LayerContent *> subLayerContents() const override

    Detailed Description

    Some layer types contain sublayers. WmsSublayer provides data necessary for building a Table of Contents. Only named WMS sublayers have an associated WmsSublayer. This list can be obtained from WmsLayer::Sublayers() property of a loaded layer.

    You can get the QList of WmsSublayer from WmsLayer.

    Member Function Documentation

    [override virtual] WmsSublayer::~WmsSublayer()

    Destructor.

    [override virtual] bool WmsSublayer::canChangeVisibility() const

    Reimplements: LayerContent::canChangeVisibility() const.

    Returns 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.

    [since Esri::ArcGISRuntime 200.1] Esri::ArcGISRuntime::WmsSublayer *WmsSublayer::clone(QObject *parent = nullptr) const

    Clones the WmsSublayer to a new instance with an optional parent.

    Returns a new instance of the current WmsSublayer.

    This function was introduced in Esri::ArcGISRuntime 200.1.

    QString WmsSublayer::currentStyle() const

    Returns the name of the sublayer's current style.

    Setting current style to an empty string indicates the default style will be used.

    See also setCurrentStyle().

    [override virtual] bool WmsSublayer::isAutoFetchLegendInfos() const

    Reimplements: LayerContent::isAutoFetchLegendInfos() const.

    Returns a bool that determines whether legend infos are automatically fetched by the sublayer.

    See LayerContent.

    [override virtual] bool WmsSublayer::isShowInLegend() const

    Reimplements: LayerContent::isShowInLegend() const.

    Returns a flag indicating whether the layer content participates in the legend.

    [override virtual] bool WmsSublayer::isVisible() const

    Reimplements: LayerContent::isVisible() const.

    Returns the layer content's visibility.

    The layer content visibility. Will return false if an error occurs.

    [override virtual] bool WmsSublayer::isVisibleAtScale(double scale) const

    Reimplements: LayerContent::isVisibleAtScale(double scale) const.

    Returns the layer content's effective visibility at the specified scale.

    • scale - The scale the visibility has to be calculated for.

    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.

    [override virtual] Esri::ArcGISRuntime::LegendInfoListModel *WmsSublayer::legendInfos() const

    Reimplements: LayerContent::legendInfos() const.

    Returns a list model of LegendInfo objects.

    See LayerContent.

    [override virtual] QString WmsSublayer::name() const

    Reimplements: LayerContent::name() const.

    eturns the layer content's name.

    [override virtual] void WmsSublayer::setAutoFetchLegendInfos(bool autoFetchLegendInfos)

    Reimplements: LayerContent::setAutoFetchLegendInfos(bool autoFetchLegendInfos).

    Sets whether legend infos are automatically fetched by the sublayer's legend info list model to autoFetchLegendInfos.

    See LayerContent.

    See also isAutoFetchLegendInfos().

    [since Esri::ArcGISRuntime 100.3] void WmsSublayer::setCurrentStyle(const QString &currentStyle)

    Sets the currentStyle to currentStyle.

    This function was introduced in Esri::ArcGISRuntime 100.3.

    See also currentStyle.

    [override virtual] void WmsSublayer::setShowInLegend(bool showInLegend)

    Reimplements: LayerContent::setShowInLegend(bool showInLegend).

    Sets the showInLegend to showInLegend.

    See also isShowInLegend.

    [override virtual] void WmsSublayer::setVisible(bool visible)

    Reimplements: LayerContent::setVisible(bool visible).

    Sets the visible to visible.

    See also isVisible.

    [override virtual] QList<Esri::ArcGISRuntime::LayerContent *> WmsSublayer::subLayerContents() const

    Reimplements: LayerContent::subLayerContents() const.

    Returns the sub layer contents of a layer content.

    Esri::ArcGISRuntime::WmsLayerInfo WmsSublayer::sublayerInfo() const

    Returns a WmsLayerInfo object with metadata about this sublayer.

    [since Esri::ArcGISRuntime 200.2] bool WmsSublayer::operator!=(const Esri::ArcGISRuntime::WmsSublayer &other) const

    Inequality operator. Returns true if this object and other are not equal.

    This function was introduced in Esri::ArcGISRuntime 200.2.

    See also WmsSublayer::operator==.

    [since Esri::ArcGISRuntime 200.1] bool WmsSublayer::operator==(const Esri::ArcGISRuntime::WmsSublayer &other) const

    Returns a tests if this object is equal to a second WmsSublayer object.

    • other - The second object.

    This function was introduced in Esri::ArcGISRuntime 200.1.

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