;

ImmutablePortalItemListModel Class

  • ImmutablePortalItemListModel
  • class Esri::ArcGISRuntime::ImmutablePortalItemListModel

    Represents an immutable list of portal items. More...

    Header: #include <ImmutablePortalItemListModel>
    Since: Esri::ArcGISRuntime 100.3
    Inherits: QAbstractListModel and Esri::ArcGISRuntime::Iterable

    This class was introduced in Esri::ArcGISRuntime 100.3.

    Public Functions

    virtual ~ImmutablePortalItemListModel() override
    bool contains(Esri::ArcGISRuntime::PortalItem *portalItem) const
    Esri::ArcGISRuntime::PortalItem *first() const
    int indexOf(Esri::ArcGISRuntime::PortalItem *portalItem) const
    bool isEmpty() const
    Esri::ArcGISRuntime::PortalItem *last() const

    Reimplemented Public Functions

    virtual Esri::ArcGISRuntime::PortalItem *at(int index) const override
    virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override
    virtual int size() const override

    Signals

    void errorOccurred(Esri::ArcGISRuntime::Error error)

    Detailed Description

    A PortalItem is a unit of content in the Portal.

    The model returns data for the following roles:

    RoleTypeDescriptionPortalItemListModel::PortalItemRoles
    urlQUrlThe URL for the resource represented by the item.PortalItemUrlRole
    itemIdQStringThe ID of the item.PortalItemItemIdRole
    accessPortalAccessThe level of access to the item.PortalItemAccessRole
    accessAndUseConstraintsHtmlQStringThe access and use constraints HTML.PortalItemAccessAndUseConstraintsHtmlRole
    averageRatingintThe average rating of the item.PortalItemAverageRatingRole
    commentCountintThe number of comments for the item.PortalItemCommentCountRole
    commentsEnabledboolWhether comments are allowed on the item.PortalItemCommentsEnabledRole
    cultureQStringThe item locale information (language and country).PortalItemCultureRole
    folderIdQStringThe ID of the folder containing the item.PortalItemFolderIdRole
    nameQStringThe name of this item.PortalItemNameRole
    ownerQStringThe username of the user who owns the item.PortalItemOwnerRole
    ratingCountintThe number of ratings received by the item.PortalItemRatingCountRole
    serviceUrlintThe service URL for the item.PortalItemServiceUrlRole
    sizeqint64The size of the item in bytes.PortalItemSizeRole
    typePortalItemTypeThe type of the item.PortalItemTypeRole
    typeKeywordsQStringListA set of keywords that further describes the type of the item.PortalItemTypeKeywordsRole
    typeNameQStringThe name of the type of this item.PortalItemTypeNameRole
    viewCountintThe number of times this item has been viewed.PortalItemViewCountRole
    descriptionQStringThe item description.PortalItemDescriptionRole
    extentEnvelopeThe bounding rectangle of the item.PortalItemExtentRole
    snippetQStringThe short summary description of the item.PortalItemSnippetRole
    titleQStringThe title of the item.PortalItemTitleRole
    accessInformationQStringThe access information on the source of the item.PortalItemAccessInformationRole
    tagsQStringListThe user-defined tags that describe the item.PortalItemTagsRole
    createdQDateTimeThe creation date of the item.PortalItemCreatedRole
    modifiedQDateTimeThe date the item was last modified.PortalItemModifiedRole
    spatialReferenceSpatialReferenceThe spatial reference of the item.PortalItemSpatialReferenceRole
    thumbnailUrlQUrlThe thumbnail of the item as a local file URL.PortalItemThumbnailUrlRole

    See also Portal, PortalUser, and PortalItem.

    Member Function Documentation

    [signal] void ImmutablePortalItemListModel::errorOccurred(Esri::ArcGISRuntime::Error error)

    Signal emitted when an error occurs.

    • error - Details about the error.

    [override virtual] ImmutablePortalItemListModel::~ImmutablePortalItemListModel()

    Destructor.

    [override virtual] Esri::ArcGISRuntime::PortalItem *ImmutablePortalItemListModel::at(int index) const

    Returns the PortalItem at the specified index.

    bool ImmutablePortalItemListModel::contains(Esri::ArcGISRuntime::PortalItem *portalItem) const

    Returns whether the list model contains the specified portalItem.

    [override virtual] QVariant ImmutablePortalItemListModel::data(const QModelIndex &index, int role = Qt::DisplayRole) const

    Reimplements: QAbstractItemModel::data(const QModelIndex &index, int role) const.

    Returns the data stored under the given role for the portal item referred to by the index.

    • index. The index in the model for which to return data.
    • role. The role for which to return data.

    Esri::ArcGISRuntime::PortalItem *ImmutablePortalItemListModel::first() const

    Returns the first PortalItem in the list model.

    int ImmutablePortalItemListModel::indexOf(Esri::ArcGISRuntime::PortalItem *portalItem) const

    Returns the index of the PortalItem portalItem.

    bool ImmutablePortalItemListModel::isEmpty() const

    Returns whether the list model contains no items.

    Esri::ArcGISRuntime::PortalItem *ImmutablePortalItemListModel::last() const

    Returns the last PortalItem in the list model.

    [override virtual] int ImmutablePortalItemListModel::size() const

    Returns the number of items contained in the list model.

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