Skip To Content ArcGIS for Developers Sign In Dashboard

PreplannedMapArea Class


Represents a single preplanned offline map area. More...

Header: #include <PreplannedMapArea>
Since: Esri::ArcGISRuntime 100.2
Inherits: Object and Loadable

Public Functions

PreplannedMapArea(PortalItem *portalItem, QObject *parent = nullptr)
Geometry areaOfInterest() const
TaskWatcher contentItems()
PortalItem *portalItem() const
OfflineMapUpdateCapabilities *updateCapabilities() const

Reimplemented Public Functions

virtual void cancelLoad()
virtual void load()
virtual Error loadError() const
virtual LoadStatus loadStatus() const
virtual void retryLoad()


void contentItemsCompleted(QUuid taskId, Esri::ArcGISRuntime::ImmutablePortalItemListModel *contentItems)
void doneLoading(Esri::ArcGISRuntime::Error loadError)
void loadStatusChanged(Esri::ArcGISRuntime::LoadStatus loadStatus)

Additional Inherited Members

  • 1 property inherited from QObject
  • 1 public slot inherited from QObject
  • 1 public variable inherited from QObject
  • 10 static public members inherited from QObject
  • 9 protected functions inherited from QObject
  • 2 protected variables inherited from QObject

Detailed Description

Represents a single preplanned offline map area.

Preplanned map areas are specific work areas or major incident areas that are defined by an online map author. Each online map can contain several map areas. These can be provided in a list by the OfflineMapTask::preplannedMapAreas method.

Each preplanned map area creates map content that is stored online.

Download this map content by running a DownloadPreplannedOfflineMapJob.

Create this job by passing the preplanned map area to the OfflineMapTask::downloadPreplannedOfflineMap method on the task.

Member Function Documentation

PreplannedMapArea::PreplannedMapArea(PortalItem *portalItem, QObject *parent = nullptr)

Constructor that accepts a PortalItem (portalItem) and an optional parent.

Use this constructor to create a preplanned map area instance with a portal item that is of type map area.



Geometry PreplannedMapArea::areaOfInterest() const

Returns the area of interest bounding the preplanned map area.

The area of interest is returned as a Geometry which can be either an Envelope or a Polygon depending on how the online map was created.

[virtual] void PreplannedMapArea::cancelLoad()

Reimplemented from Loadable::cancelLoad().

See Loadable.

TaskWatcher PreplannedMapArea::contentItems()

Starts a task to fetch the content items for this preplanned map area.

This method populates an ImmutablePortalItemListModel with the content items for this preplanned area. The results of this operation are cached, so the same portal item instances will be returned with each subsequent call of this method.

This method returns a TaskWatcher for the asynchronous operation.

This function was introduced in Esri::ArcGISRuntime 100.3.

[signal] void PreplannedMapArea::contentItemsCompleted(QUuid taskId, Esri::ArcGISRuntime::ImmutablePortalItemListModel *contentItems)

Signal emitted when contentItems completes.

  • taskId - The task ID that this signal corresponds to.
  • contentItems - A list model containing the fetched content items.

The returned ImmutablePortalItemListModel object has the PreplannedMapArea as its parent.

This function was introduced in Esri::ArcGISRuntime 100.3.

See also Returned QObjects Parenting.

[signal] void PreplannedMapArea::doneLoading(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.

See also Loadable and Object.

[virtual] void PreplannedMapArea::load()

Reimplemented from Loadable::load().

See Loadable.

[virtual] Error PreplannedMapArea::loadError() const

Reimplemented from Loadable::loadError().

See Loadable.

[virtual] LoadStatus PreplannedMapArea::loadStatus() const

Reimplemented from Loadable::loadStatus().

See Loadable.

[signal] void PreplannedMapArea::loadStatusChanged(Esri::ArcGISRuntime::LoadStatus loadStatus)

Signal emitted when the loadStatus changes for this object.

See also Loadable.

PortalItem *PreplannedMapArea::portalItem() const

Returns the portal item that this preplanned map area was created from.

[virtual] void PreplannedMapArea::retryLoad()

Reimplemented from Loadable::retryLoad().

See Loadable.

OfflineMapUpdateCapabilities *PreplannedMapArea::updateCapabilities() const

Describes what methods for obtaining updates are supported for this preplanned map area. This property will return an empty OfflineMapUpdateCapabilities until loaded.

This function was introduced in Esri::ArcGISRuntime 100.6.0.

Feedback on this topic?