Skip To Content ArcGIS for Developers Sign In Dashboard

LabelDefinition Class


Labeling information about a sublayer of a map service or feature service. More...

Header: #include <LabelDefinition>
Since: Esri::ArcGISRuntime 100.1
Inherits: Object and JsonSerializable

Public Functions

LabelDefinition(QObject *parent = nullptr)

Reimplemented Public Functions

virtual QString toJson() const
virtual QJsonObject unknownJson() const
virtual QJsonObject unsupportedJson() const

Static Public Members

LabelDefinition *fromJson(const QString &json, QObject *parent = nullptr)
  • 10 static public members inherited from QObject

Additional Inherited Members

Detailed Description

Labeling information about a sublayer of a map service or feature service.

LabelDefinitions can only be created from JSON currently. The JSON required follows the ArcGIS REST API specification for the various labeling objects.

An example of JSON that can be used for setting a LabelDefinition is:


Member Function Documentation

LabelDefinition::LabelDefinition(QObject *parent = nullptr)

Constructor that creates an empty LabelDefinition.

  • parent - The parent object.



[static] LabelDefinition *LabelDefinition::fromJson(const QString &json, QObject *parent = nullptr)

Creates this LabelDefinition from its JSON representation.

Returns a LabelDefinition created using the data in the json parameter and an optional parent.

See also JsonSerializable.

[virtual] QString LabelDefinition::toJson() const

Reimplemented from JsonSerializable::toJson().

Returns this LabelDefinition instance represented as a JSON String.

See also JsonSerializable.

[virtual] QJsonObject LabelDefinition::unknownJson() const

Reimplemented from JsonSerializable::unknownJson().

Gets the unknown JSON of this object.

See also JsonSerializable.

[virtual] QJsonObject LabelDefinition::unsupportedJson() const

Reimplemented from JsonSerializable::unsupportedJson().

Gets the unsupported JSON of this object.

See also JsonSerializable.

Feedback on this topic?