Popup QML Type

The combination of a PopupDefinition and a GeoElement, which allows a visual representation of the GeoElement's attributes as well as the ability to edit them. More...

Import Statement: import Esri.ArcGISRuntime 100.15
Since: Esri.ArcGISRuntime 100.0
Inherits:

Object

Properties

Signals

Methods

Detailed Description

A Popup can be instantiated with the following property combinations only: 1: A GeoElement 2: A GeoElement and a PopupDefinition

A PopupDefinition alone will not instantiate a Popup.

Use the Popup to create a PopupManager. The PopupManager can then be used in conjunction with the PopupView (from the ArcGIS Runtime Toolkit) for a visual representation of the Popup.

This QML type supports the following default properties. A default property may be declared inside another declared object without being assigned explicitly to a property.

Property Documentation

evaluateExpressionsResults : list<PopupExpressionEvaluation>

Returns a list of results from an evaluate of expressions operation.

The results are asynchronously evaluated expressions, including Arcade FeatureSet functions, available at PopupDefinition::expressions. If there are no PopupDefinition::expressions then the result list will be empty.

Obtain the results once the evaluateExpressionsStatusChanged signal emits, and the evaluateExpressionsStatus is complete.

This property was introduced in Esri.ArcGISRuntime 100.8.


evaluateExpressionsStatus : Enums.TaskStatus

The status for the task of evaluating popup expressions.

This property was introduced in Esri.ArcGISRuntime 100.8.

See also Enums.TaskStatus.


evaluatedElements : list<PopupElement>

A list of PopupElement objects evaluated asynchronously by evaluateExpressions. During the evaluation, each ExpressionPopupElement is replaced by the PopupElement returned by the Arcade expression and each placeholder is replaced by its value. If the Arcade expression returns a list of attributes to be used by the pop-up element, these attributes will be used by formattedValue(PopupField) (read-only).

The list is empty while evaluateExpressions has not been executed, and is cleared if evaluateExpressions is executed more than once. After evaluation, the order of the pop-up elements in the list matches the order elements present in PopupDefinition::elements and shown in the pop-up window. If an ExpressionPopupElement fails to be evaluated, then it will be skipped in the list. Use the list of PopupExpressionEvaluation returned from evaluateExpressions to learn the cause of the error.

This property was introduced in Esri.ArcGISRuntime 100.14.

See also PopupDefinition::elements and evaluateExpressions.


geoElement : GeoElement

Returns the GeoElement of this Popup, such as a Feature or Graphic (read-only).

Note: To set the GeoElement that is used to create this Popup, use initGeoElement.


[default] initGeoElement : GeoElement

The GeoElement that should be used to create the Popup.

Note: To create a Popup, you can either provide only a GeoElement, or a GeoElement and a PopupDefinition.


[default] initPopupDefinition : PopupDefinition

The PopupDefinition that should be used to create the Popup.

Note: A PopupDefinition alone is not enough to create a Popup. You must also supply a GeoElement.


popupDefinition : PopupDefinition

Returns the PopupDefinition of this Popup (read-only).

Note: To set the PopupDefinition that is used to create this Popup, use initPopupDefinition.


symbol : Symbol

Returns the Symbol of this Popup (read-only).


title : string

Returns the title of this Popup (read-only).


Signal Documentation

evaluateExpressionsStatusChanged()

Emitted when the evaluateExpressionsStatus property changes.

Note: The corresponding handler is onEvaluateExpressionsStatusChanged.

This signal was introduced in Esri.ArcGISRuntime 100.8.


evaluatedElementsChanged()

Emitted when the evaluatedElements property changes.

Note: The corresponding handler is onEvaluatedElementsChanged.


geoElementChanged()

Emitted when the geoElement property changes.

Note: The corresponding handler is onGeoElementChanged.


initGeoElementChanged()

Emitted when the initGeoElement property changes.

Note: The corresponding handler is onInitGeoElementChanged.


initPopupDefinitionChanged()

Emitted when the initPopupDefinition property changes.

Note: The corresponding handler is onInitPopupDefinitionChanged.


popupDefinitionChanged()

Emitted when the popupDefinition property changes.

Note: The corresponding handler is onPopupDefinitionChanged.


symbolChanged()

Emitted when the symbol property changes.

Note: The corresponding handler is onSymbolChanged.


titleChanged()

Emitted when the title property changes.

Note: The corresponding handler is onTitleChanged.


Method Documentation

bool cancelTask(string taskId)

Cancel the task with the ID taskId.

Returns false if the task cannot be canceled or there is no task with the specified id taskId.

See also Cancelable.


string evaluateExpressions()

Asynchronously evaluates all expressions, including Arcade FeatureSet functions, available at PopupDefinition::expressions. This method must be called before displaying the popup information in a UI so you can use synchronous methods Popup::formattedValue() and PopupManager::substitute() to get the formatted string representation. If there are no PopupDefinition::expressions then the result list will be empty.

The PopupExpression may be used in the PopupDefinition::fields, PopupDefinition::media, PopupDefinition::title and PopupDefinition::description.

This method was introduced in Esri.ArcGISRuntime 100.8.


string formattedValue(PopupField popupField)

Returns the formatted value of the popupField.

If PopupDefinition::expressions is not empty then the PopupField may be using expressions with Arcade FeatureSet functions. Use Popup::evaluateExpressions to evaluate the Arcade expressions before trying to get the formatted string representation of the popup field's value, otherwise it may return an empty string.


Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.