A KML dataset represents the current state of the KML data specified in a KML/KMZ file. More...
Header | #include <Kml |
Since | Esri |
Inherits | Esri |
Public Functions
(since Esri | Kml |
(since Esri | Kml |
virtual | ~ |
Q | root |
Reimplemented Public Functions
virtual void | cancel |
(deprecated) virtual Esri | credential() const override |
virtual void | load() override |
virtual Esri | load |
virtual Esri | load |
(deprecated) virtual Esri | request |
virtual void | retry |
(deprecated) virtual void | set |
virtual Q | url() const override |
Signals
void | done |
void | kml |
(since Esri void | kml |
void | kml |
void | load |
Detailed Description
The KML Dataset provides an entry point to traverse the tree of KML nodes that make up the KML document. You can create a KML dataset from an existing KML/KMZ file by using KmlDataset(const QUrl&, QObject*) or you can create a new KML dataset by using a specified root node (KmlDataset(Esri::ArcGISRuntime::KmlNode*, QObject*)).
Relevant samples:
- Display KML: Display KML from a URL, portal item, or local KML file.
- Display KML network links: Display a file with a KML network link, including displaying any network link control messages at launch.
- Edit KML ground overlay: Edit the values of a KML ground overlay.
- List KML contents: List the contents of a KML file.
Member Function Documentation
[explicit, since Esri::ArcGISRuntime 100.6]
KmlDataset::KmlDataset (Esri::ArcGISRuntime::KmlNode *rootNode , QObject *parent = nullptr)
Creates a KML dataset from the specified root node.
- rootNode - The root KML node with which to create a KML dataset.
- parent - The optional parent QObject.
KML dataset is the source of KML information backing a KML layer. You can use the KML dataset to interact with the contents of a KML layer. Licensing for KML depends on the method of access. Creating a KML dataset from a root node requires an ArcGIS Runtime 'Standard' license level.
This function was introduced in Esri::ArcGISRuntime 100.6.
[explicit, since Esri::ArcGISRuntime 100.4]
KmlDataset::KmlDataset (const QUrl &url, QObject *parent = nullptr)
Creates a KML dataset from the provided path to a KML/KMZ file.
- url - The location of the file, either on disk or from the network.
- parent - The optional parent QObject.
KML dataset is the source of KML information backing a KML layer. You can use the KML dataset to interact with the contents of a KML layer. Licensing for KML depends on the method of access. Accessing files on disk requires an ArcGIS Runtime 'Standard' license level.
This function was introduced in Esri::ArcGISRuntime 100.4.
[override virtual noexcept]
KmlDataset::~KmlDataset ()
Destructor.
[override virtual]
void KmlDataset::cancelLoad ()
Reimplements: Loadable::cancelLoad().
See Loadable.
[signal]
void KmlDataset::doneLoading (const Esri::ArcGISRuntime::Error &loadError )
Signal emitted when this object is done loading.
- loadError - Details about any error that may have occurred.
Note: If there is a load error it will also be emitted on the errorOccurred signal.
[signal]
void KmlDataset::kmlNetworkLinkMessageReceived (Esri::ArcGISRuntime::KmlNetworkLink *networkLink , const QString &message)
Signal emitted when a KML dataset network link message is available.
This is used to deliver a popup message, such as usage guidelines for the network link. The message is available when the network link is first loaded, or when it is changed in the network link control.
- networkLink - the KmlNetworkLink that had the new message.
- message - the message.
The returned KmlNetworkLink object has the KmlDataset as its parent.
See also Returned QObjects Parenting.
[signal, since Esri::ArcGISRuntime 100.7]
void KmlDataset::kmlNodeBalloonVisibilityChanged (Esri::ArcGISRuntime::KmlNode *target, bool balloonVisibility )
Signal emitted whenever a KML node's balloon visibility changes.
- target - the node target for the balloon visibility event.
- balloonVisibility - the visibility for the balloon.
The returned KmlNode object has the KmlDataset as its parent.
This function was introduced in Esri::ArcGISRuntime 100.7.
See also Returned QObjects Parenting.
[signal]
void KmlDataset::kmlNodeRefreshStatusChanged (Esri::ArcGISRuntime::KmlNode *target, Esri::ArcGISRuntime::KmlRefreshStatus refreshStatus )
Signal emitted when a KML refresh event is raised.
- target - the node target for the refresh event.
- refreshStatus - the refresh status of the KML node.
The returned KmlNode object has the KmlDataset as its parent.
See also Returned QObjects Parenting.
[override virtual]
void KmlDataset::load()
Reimplements: Loadable::load().
See Loadable.
[override virtual]
Esri::ArcGISRuntime::Error KmlDataset::loadError () const
Reimplements: Loadable::loadError() const.
See Loadable.
[override virtual]
Esri::ArcGISRuntime::LoadStatus KmlDataset::loadStatus () const
Reimplements: Loadable::loadStatus() const.
See Loadable.
[signal]
void KmlDataset::loadStatusChanged (Esri::ArcGISRuntime::LoadStatus loadStatus )
Signal emitted when the load status changes for this object.
- loadStatus - The LoadStatus.
See also Loadable.
[override virtual]
void KmlDataset::retryLoad ()
Reimplements: Loadable::retryLoad().
See Loadable.
QList <Esri::ArcGISRuntime::KmlNode *> KmlDataset::rootNodes () const
Returns the KML dataset's root nodes.
KML files can have multiple root nodes, each of which may have children. When traversing the KML feature tree (for example to build a TOC), rootNodes is the correct starting point. Each root node can be the start of a tree of nodes.
[override virtual]
QUrl KmlDataset::url() const
Reimplements: RemoteResource::url() const.
Returns the URL to the KML dataset.
Returns the location of the KML/KMZ file, which can either be on disk or from the network. The URL of the backing file. Files can be loaded from local storage or the network. Note that KML files often point to network locations for their data (using network links). As a result, the loaded KML layer may display more information than is contained in the loaded KML file. KML files can point to network locations. These locations may be insecure (over plain text HTTP) even when the URL returned from this function is pointing to an SSL/TLS-secured resource.