ArcGISMapImageSublayer Class

  • ArcGISMapImageSublayer
  • class Esri::ArcGISRuntime::ArcGISMapImageSublayer

    A sublayer of an ArcGISMapImageLayer. More...

    Header: #include <ArcGISMapImageSublayer.h>
    Since: Esri::ArcGISRuntime 100.0
    Inherits: Esri::ArcGISRuntime::ArcGISSublayer

    This class was introduced in Esri::ArcGISRuntime 100.0.

    Public Functions

    ArcGISMapImageSublayer(qint64 id, Esri::ArcGISRuntime::SublayerSource *sublayerSource, QObject *parent = nullptr)
    ArcGISMapImageSublayer(qint64 id, QObject *parent = nullptr)
    virtual ~ArcGISMapImageSublayer() override
    bool isDefaultVisible() const
    Esri::ArcGISRuntime::LabelDefinitionListModel *labelDefinitions() const
    void setDefinitionExpression(const QString &definitionExpression)
    void setLabelsEnabled(bool labelsEnabled)
    void setMaxScale(double maxScale)
    void setMinScale(double minScale)
    void setName(const QString &name)
    void setOpacity(float opacity)
    void setRenderer(Esri::ArcGISRuntime::Renderer *renderer)
    void setScaleSymbols(bool scaleSymbols)
    Esri::ArcGISRuntime::SublayerSource *source() const
    Esri::ArcGISRuntime::ServiceFeatureTable *table() const

    Detailed Description

    ArcGISMapImageLayer displays maps from an ArcGIS map server. Each layer in the underlying map service is represented by an ArcGISSublayer. Sublayers can be accessed from the ArcGISMapImageLayer as ArcGISMapImageSublayer. You can control the visibility and symbols of sublayers and filter data with layer definition expressions.

    You can get this object from ArcGISMapImageLayer::mapImageSublayers after the map image layer is loaded, or you can get a collection of handles from another map image sublayer by using ArcGISSublayer::sublayers. The sublayer ID is the index number of the map layer that is listed in the ArcGIS REST Services Directory documentation for the service. You can also create a new sublayer from ArcGISMapImageSublayer::ArcGISMapImageSublayer.

    Member Function Documentation

    ArcGISMapImageSublayer::ArcGISMapImageSublayer(qint64 id, Esri::ArcGISRuntime::SublayerSource *sublayerSource, QObject *parent = nullptr)

    Constructor that accepts a sublayer ID and a sublayer source.

    • id - The sublayer ID.
    • sublayerSource - The sublayer source. (Can be set only when instantiating.)
    • parent - The optional parent object. Defaults to nullptr.

    ArcGISMapImageSublayer::ArcGISMapImageSublayer(qint64 id, QObject *parent = nullptr)

    Constructor that accepts a sublayer ID.

    • id - The sublayer ID.
    • parent - The optional parent object. Defaults to nullptr.

    [override virtual] ArcGISMapImageSublayer::~ArcGISMapImageSublayer()

    Destructor.

    bool ArcGISMapImageSublayer::isDefaultVisible() const

    Returns whether the sublayer is visible by default.

    Esri::ArcGISRuntime::LabelDefinitionListModel *ArcGISMapImageSublayer::labelDefinitions() const

    Returns the list model of label definitions in the layer.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setDefinitionExpression(const QString &definitionExpression)

    Sets the sublayer's definition expression to definitionExpression.

    The definition expression string uses the SQL-92 WHERE clause syntax. Be sure to escape special characters in the expression string as required for your platform. The DATE keyword expects the date format yyyy-mm-dd and the TIMESTAMP keyword expects the time stamp format yyyy-mm-dd hh:mm:ss. See the ArcGIS Blog article Querying Feature Services Date-Time Queries for more information.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setLabelsEnabled(bool labelsEnabled)

    Sets whether the sublayer's labels are displayed to labelsEnabled.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setMaxScale(double maxScale)

    Sets the maximum scale at which the sublayer displays to maxScale.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setMinScale(double minScale)

    Sets the minimum scale at which the sublayer displays to minScale.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setName(const QString &name)

    Sets the name of the sublayer to name.

    void ArcGISMapImageSublayer::setOpacity(float opacity)

    Sets the sublayer's opacity to opacity.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setRenderer(Esri::ArcGISRuntime::Renderer *renderer)

    Sets the renderer that specifies how the features should be symbolized to renderer.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    void ArcGISMapImageSublayer::setScaleSymbols(bool scaleSymbols)

    Sets whether the sublayer renders its symbols based on scale to scaleSymbols.

    This function was introduced in Esri::ArcGISRuntime 100.1.

    Esri::ArcGISRuntime::SublayerSource *ArcGISMapImageSublayer::source() const

    Returns the sublayer source.

    Esri::ArcGISRuntime::ServiceFeatureTable *ArcGISMapImageSublayer::table() const

    Returns the sublayer's feature table.

    This only applies to sublayers of type "Feature layer" or "Table". This method returns nullptr if the sublayer has not been loaded.

    This function was introduced in Esri::ArcGISRuntime 100.3.

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