Skip To Content ArcGIS for Developers Sign In Dashboard

AnnotationLayer Class

(Esri::ArcGISRuntime::AnnotationLayer)

A layer that can visualize annotation text data. More...

Header: #include <AnnotationLayer>
Since: Esri::ArcGISRuntime 100.5
Inherits: Layer

Public Functions

AnnotationLayer(Item *item, qint64 serviceLayerId, QObject *parent = nullptr)
AnnotationLayer(ArcGISFeatureTable *featureTable, QObject *parent = nullptr)
AnnotationLayer(const QUrl &url, QObject *parent = nullptr)
~AnnotationLayer()
ArcGISFeatureTable *featureTable() const
double referenceScale() const
qint64 serviceLayerId() const
QUrl url() const

Additional Inherited Members

Detailed Description

A layer that can visualize annotation text data.

Member Function Documentation

AnnotationLayer::AnnotationLayer(Item *item, qint64 serviceLayerId, QObject *parent = nullptr)

Creates a new annotation layer from a feature service portal item.

  • item - a feature service PortalItem.
  • serviceLayerId - the layer ID for which to create the layer.
  • parent - an optional parent QObject.

AnnotationLayer::AnnotationLayer(ArcGISFeatureTable *featureTable, QObject *parent = nullptr)

Creates a new annotation layer from a feature service table.

This function was introduced in Esri::ArcGISRuntime 100.6.

AnnotationLayer::AnnotationLayer(const QUrl &url, QObject *parent = nullptr)

Creates a new annotation layer from a feature service URL.

  • url - the URL to the feature service layer.
  • parent - an optional parent QObject.

AnnotationLayer::~AnnotationLayer()

Destructor.

ArcGISFeatureTable *AnnotationLayer::featureTable() const

Returns the feature table associated with this layer.

This function was introduced in Esri::ArcGISRuntime 100.6.

double AnnotationLayer::referenceScale() const

Returns the reference scale for the layer.

The reference scale of the layer is the scale at which a client should view the layer for the text to appear at its authored size.

If the client changes the viewing scale, then text will grow or shrink to keep a consistent size on the map (not the screen).

For a valid layer, the reference scale will always be a finite value, greater than zero. Until the layer is loaded, the reference scale will be zero.

qint64 AnnotationLayer::serviceLayerId() const

Returns the layer ID for the layer.

QUrl AnnotationLayer::url() const

Returns the Feature Service URL for the layer.


Feedback on this topic?