Skip To Content ArcGIS for Developers Sign In Dashboard

LicenseInfo Class

(Esri::ArcGISRuntime::LicenseInfo)

Contains information for licensing an app for Lite or Basic-level functionality from a portal instance. More...

Header: #include <LicenseInfo>
Since: Esri::ArcGISRuntime 100.0
Inherits: JsonSerializable

Public Functions

LicenseInfo()
LicenseInfo(const LicenseInfo &other)
LicenseInfo(LicenseInfo &&other)
~LicenseInfo()
bool isEmpty() const
LicenseInfo &operator=(const LicenseInfo &other)
LicenseInfo &operator=(LicenseInfo &&other)

Reimplemented Public Functions

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

Static Public Members

LicenseInfo fromJson(const QString &json)

Detailed Description

Contains information for licensing an app for Lite or Basic-level functionality from a portal instance.

To validate with information from a portal, you will need a LicenseInfo instance. This can be obtained by calling PortalInfo::licenseInfo(). The LicenseInfo can then be used to authorize the ArcGIS Runtime app for either Lite or Basic-level functionality by calling ArcGISRuntimeEnvironment::setLicense(const LicenseInfo&).

Note that this information is only available when a user is logged in to the portal.

Member Function Documentation

LicenseInfo::LicenseInfo()

Default constructor.

LicenseInfo::LicenseInfo(const LicenseInfo &other)

Copy constructor from other LicenseInfo.

LicenseInfo::LicenseInfo(LicenseInfo &&other)

Move constructor from other LicenseInfo.

LicenseInfo::~LicenseInfo()

Destructor

[static] LicenseInfo LicenseInfo::fromJson(const QString &json)

Creates new LicenseInfo from json.

This LicenseInfo instance can then be applied by calling ArcGISRuntimeEnvironment::setLicense(const LicenseInfo&).

bool LicenseInfo::isEmpty() const

Returns true if this LicenseInfo is empty.

[virtual] QString LicenseInfo::toJson() const

Reimplemented from JsonSerializable::toJson().

Returns the LicenseInfo as a JSON string representation.

This JSON string can be persisted to disk and reapplied to the app by calling fromJson which returns a new instance of LicenseInfo to be passed to ArcGISRuntimeEnvironment::setLicense(const LicenseInfo&). The LicenseInfo is valid for 30 days before it expires and requires the user to log in to the portal to acquire a new LicenseInfo object.

[virtual] QJsonObject LicenseInfo::unknownJson() const

Reimplemented from JsonSerializable::unknownJson().

Gets the unknown JSON of this object.

See also JsonSerializable.

[virtual] QJsonObject LicenseInfo::unsupportedJson() const

Reimplemented from JsonSerializable::unsupportedJson().

Gets the unsupported JSON of this object.

See also JsonSerializable.

LicenseInfo &LicenseInfo::operator=(const LicenseInfo &other)

Assignment operator from other LicenseInfo.

LicenseInfo &LicenseInfo::operator=(LicenseInfo &&other)

Move operator from other LicenseInfo.


Feedback on this topic?