• PointCloudColorUniqueValueListModel
  • class Esri::ArcGISRuntime::PointCloudColorUniqueValueListModel

    A list model that stores a list of point cloud color unique values. More...

    Header: #include <PointCloudColorUniqueValueListModel.h>
    Since: Esri::ArcGISRuntime 300.1
    Inherits: QAbstractListModel and Esri::ArcGISRuntime::Iterable

    Public Types

    enum PointCloudColorUniqueValueRoles { PointCloudColorUniqueValueColorRole, PointCloudColorUniqueValueDescriptionRole, PointCloudColorUniqueValueLabelRole, PointCloudColorUniqueValueValuesRole }

    Public Functions

    virtual ~PointCloudColorUniqueValueListModel() override
    void append(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)
    void clear()
    bool contains(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue) const
    Esri::ArcGISRuntime::PointCloudColorUniqueValue *first() const
    int indexOf(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue) const
    void insert(int index, Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)
    bool isEmpty() const
    Esri::ArcGISRuntime::PointCloudColorUniqueValue *last() const
    void move(int from, int to)
    void removeAt(int index)
    void removeOne(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)

    Reimplemented Public Functions

    virtual Esri::ArcGISRuntime::PointCloudColorUniqueValue *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(const Esri::ArcGISRuntime::Error &error)
    void itemAdded(int index)
    void itemRemoved(int index)

    Detailed Description

    Modifying this model (adding, removing, or moving) will update the values in a PointCloudUniqueValueRenderer.

    The model returns data for the following roles:

    RoleTypeDescriptionPointCloudColorUniqueValueRoles
    colorQColorThe point cloud color unique value's color.PointCloudColorUniqueValueColorRole
    descriptionQStringThe point cloud color unique value's description.PointCloudColorUniqueValueDescriptionRole
    labelQStringThe point cloud color unique value's label.PointCloudColorUniqueValueLabelRole
    valuesQVariantListThe point cloud color unique value's values.PointCloudColorUniqueValueValuesRole

    Member Type Documentation

    enum PointCloudColorUniqueValueListModel::PointCloudColorUniqueValueRoles

    This enum specifies the custom roles which can be used with PointCloudColorUniqueValueListModel::data.

    ConstantValueDescription
    Esri::ArcGISRuntime::PointCloudColorUniqueValueListModel::PointCloudColorUniqueValueColorRoleQt::UserRole + 1The point cloud color unique value's color.
    Esri::ArcGISRuntime::PointCloudColorUniqueValueListModel::PointCloudColorUniqueValueDescriptionRoleQt::UserRole + 2The point cloud color unique value's description.
    Esri::ArcGISRuntime::PointCloudColorUniqueValueListModel::PointCloudColorUniqueValueLabelRoleQt::UserRole + 3The point cloud color unique value's label.
    Esri::ArcGISRuntime::PointCloudColorUniqueValueListModel::PointCloudColorUniqueValueValuesRoleQt::UserRole + 4The point cloud color unique value's values.

    Member Function Documentation

    [override virtual noexcept] PointCloudColorUniqueValueListModel::~PointCloudColorUniqueValueListModel()

    Destructor.

    void PointCloudColorUniqueValueListModel::append(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)

    Appends a pointCloudColorUniqueValue to the list model.

    [override virtual] Esri::ArcGISRuntime::PointCloudColorUniqueValue *PointCloudColorUniqueValueListModel::at(int index) const

    Returns the point cloud color unique value at the specified index.

    void PointCloudColorUniqueValueListModel::clear()

    List models do not take ownership of the objects they contain. Therefore, removing or clearing objects from the list model will not delete those objects. An RAII technique should be used to ensure that memory is properly deallocated.

    bool PointCloudColorUniqueValueListModel::contains(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue) const

    Returns whether this list model contains the specified pointCloudColorUniqueValue.

    [override virtual] QVariant PointCloudColorUniqueValueListModel::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 point cloud color unique value referred to by the index.

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

    [signal] void PointCloudColorUniqueValueListModel::errorOccurred(const Esri::ArcGISRuntime::Error &error)

    Signal emitted when an error occurs.

    • error - Details about the error.

    Esri::ArcGISRuntime::PointCloudColorUniqueValue *PointCloudColorUniqueValueListModel::first() const

    Returns the first point cloud color unique value in the list model.

    int PointCloudColorUniqueValueListModel::indexOf(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue) const

    Returns the index of the specified pointCloudColorUniqueValue.

    void PointCloudColorUniqueValueListModel::insert(int index, Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)

    Inserts a pointCloudColorUniqueValue at the specified index in the list model.

    This method will append to the list if the index is greater than the current size of the list model.

    bool PointCloudColorUniqueValueListModel::isEmpty() const

    Returns true if the list model contains no point cloud color unique values.

    [signal] void PointCloudColorUniqueValueListModel::itemAdded(int index)

    Signal emitted when a point cloud color unique value is added to the list model.

    • index - The index of the added point cloud color unique value.

    [signal] void PointCloudColorUniqueValueListModel::itemRemoved(int index)

    Signal emitted when a point cloud color unique value is removed from the list model.

    • index - The index of the removed point cloud color unique value.

    Esri::ArcGISRuntime::PointCloudColorUniqueValue *PointCloudColorUniqueValueListModel::last() const

    Returns the last point cloud color unique value in the list model.

    void PointCloudColorUniqueValueListModel::move(int from, int to)

    Moves one point cloud color unique value from an index in the list model to a different index.

    void PointCloudColorUniqueValueListModel::removeAt(int index)

    Removes a point cloud color unique value at the specified index.

    List models do not take ownership of the objects they contain. Therefore, removing or clearing objects from the list model will not delete those objects. An RAII technique should be used to ensure that memory is properly deallocated.

    void PointCloudColorUniqueValueListModel::removeOne(Esri::ArcGISRuntime::PointCloudColorUniqueValue *pointCloudColorUniqueValue)

    Removes a specific point cloud color unique value (pointCloudColorUniqueValue) from the list model.

    List models do not take ownership of the objects they contain. Therefore, removing or clearing objects from the list model will not delete those objects. An RAII technique should be used to ensure that memory is properly deallocated.

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

    Returns the number of point cloud color unique values in the list model.