A list model storing a list of PopupAttachment available for an ArcGISFeature. More...
Import Statement: | import Esri.ArcGISRuntime 100.15 |
Since: | Esri.ArcGISRuntime 100.1 |
Properties
- applyFilter : bool
- autoFetchFullImages : bool
- autoFetchThumbnails : bool
- autoLoad : bool
- count : int
- thumbnailAspectRatioMode : Enums.AspectRatioMode
- thumbnailHeight : int
- thumbnailWidth : int
Signals
- applyFilterChanged()
- autoFetchFullImagesChanged()
- autoFetchThumbnailsChanged()
- autoLoadChanged()
- countChanged()
- thumbnailAspectRatioModeChanged()
- thumbnailHeightChanged()
- thumbnailWidthChanged()
Methods
Detailed Description
Obtain a PopupAttachmentListModel from a PopupAttachmentManager.
The model will automatically fetch and load attachments from the underlying features so that they can be displayed in a view.
Note: You cannot declare or create a component of this type in QML code.
The model returns data for the following roles:
Role | Type | Description |
---|---|---|
name | string | The name of the attachment. |
contentType | string | The MIME type of the attachment file. |
size | int | The size of the attachment in bytes. |
local | bool | Whether the data for the attachments has been downloaded locally. |
attachmentUrl | url | The URL of the attachment. |
popupType | Enums.PopupAttachmentType | The type of popup attachment. |
editState | Enums.PopupAttachmentEditState | The popup attachment edit state. |
thumbnailUrl | url | The URL to the thumbnail. |
fullImageUrl | url | The URL to the full image. |
Property Documentation
Whether the model should display the PopupAttachmentManager::attachments or PopupAttachmentManager::filterAttachments. This can be changed at any time.
Note: Setting this to true
will return the filtered attachments. The default value is false
.
See also PopupAttachmentManager::filterAttachments and PopupAttachmentManager::attachments.
Whether full images should be requested by the model.
If this is false
the model will not request full images if it encounters an empty image from the underlying popup attachment.
The popup attachment will be loaded when full images are requested if it is not loaded.
Note: The default value is true
.
See also Loadable.
Whether thumbnails should be requested by the model automatically.
If this is false
the model will not request thumbnail images if it encounters an empty thumbnail from the underlying popup attachment.
The popup attachment will be loaded when thumbnails are requested if it is not loaded.
Note: The default value is true
.
See also thumbnailAspectRatioMode, thumbnailWidth, thumbnailHeight, and Loadable.
Whether each attachment should be loaded by the model as they are accessed.
Note: The default value is true
.
See also Loadable.
The aspect ratio mode that will be used to generate all thumbnails.
Note: The default value is Enums.AspectRatioModeKeepAspectRatio
See also Enums.AspectRatioMode.
The height that will be used to generate all thumbnails.
Note: The default value is 64.
The width that will be used to generate all thumbnails.
Note: The default value is 64.
Signal Documentation
Emitted when the applyFilter property changes.
Note: The corresponding handler is onApplyFilterChanged
.
Emitted when the autoFetchFullImages property changes.
Note: The corresponding handler is onAutoFetchFullImagesChanged
.
Emitted when the autoFetchThumbnails property changes.
Note: The corresponding handler is onAutoFetchThumbnailsChanged
.
Emitted when the autoLoad property changes.
Note: The corresponding handler is onAutoLoadChanged
.
Emitted when the count property changes.
Note: The corresponding handler is onCountChanged
.
Emitted when the thumbnailAspectRatioMode property changes.
Note: The corresponding handler is onThumbnailAspectRatioModeChanged
.
Emitted when the thumbnailHeight property changes.
Note: The corresponding handler is onThumbnailHeightChanged
.
Emitted when the thumbnailWidth property changes.
Note: The corresponding handler is onThumbnailWidthChanged
.
Method Documentation
Receives a callback function to execute for each attachment in the model.
The callback function can take 0 to 3 optional arguments, in order:
- element Current attachment.
- index Current index in array.
- array Reference to PopupAttachmentListModel.
Returns undefined if no error occurred, and an error message otherwise.
const error = PopupAttachmentListModel.forEach(function(element, index, array) { ... }); if (error) { console.error(error.message); }
PopupAttachment get(int index) |
Gets the PopupAttachment at a given index in the model.