KmlNodeListModel Class

  • KmlNodeListModel
  • class Esri::ArcGISRuntime::KmlNodeListModel

    A list model storing a list of KmlNodes available in a KmlContainer. More...

    Header: #include <KmlNodeListModel.h>
    Since: Esri::ArcGISRuntime 100.6
    Inherits: QAbstractListModel and Esri::ArcGISRuntime::Iterable

    Public Functions

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

    Reimplemented Public Functions

    virtual Esri::ArcGISRuntime::KmlNode *at(int index) 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, moving) will update the nodes available in the KmlContainer.

    Member Function Documentation

    [override virtual] KmlNodeListModel::~KmlNodeListModel()

    Destructor.

    void KmlNodeListModel::append(Esri::ArcGISRuntime::KmlNode *kmlNode)

    Appends an kmlNode to the KmlNode list model.

    [override virtual] Esri::ArcGISRuntime::KmlNode *KmlNodeListModel::at(int index) const

    Returns the kmlNode at the specified index.

    void KmlNodeListModel::clear()

    Removes all KmlNodes 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.

    bool KmlNodeListModel::contains(Esri::ArcGISRuntime::KmlNode *kmlNode) const

    Returns true if the list model contains the specified kmlNode.

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

    Signal emitted when an error occurs.

    • error - Details about the error.

    Esri::ArcGISRuntime::KmlNode *KmlNodeListModel::first() const

    Returns the first KmlNode in the list model.

    int KmlNodeListModel::indexOf(Esri::ArcGISRuntime::KmlNode *kmlNode) const

    Returns the index of the kmlNode specified.

    void KmlNodeListModel::insert(int index, Esri::ArcGISRuntime::KmlNode *kmlNode)

    Inserts a kmlNode at a 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 KmlNodeListModel::isEmpty() const

    Returns true if the list model contains no KmlNodes.

    [signal, since Esri::ArcGISRuntime 100.15] void KmlNodeListModel::itemAdded(int index)

    Signal emitted when an item is added to the list model.

    • index - The index of the added item.

    This function was introduced in Esri::ArcGISRuntime 100.15.

    [signal, since Esri::ArcGISRuntime 100.15] void KmlNodeListModel::itemRemoved(int index)

    Signal emitted when an item is removed from the list model.

    • index - The index of the removed item.

    This function was introduced in Esri::ArcGISRuntime 100.15.

    Esri::ArcGISRuntime::KmlNode *KmlNodeListModel::last() const

    Returns the last KmlNode in the list model.

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

    Moves one kmlNode from an index in the list model to a different index.

    void KmlNodeListModel::removeAt(int index)

    Removes a kmlNode at the specified index.

    No KmlNode will be removed if the specified index is out of range.

    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 KmlNodeListModel::removeOne(Esri::ArcGISRuntime::KmlNode *kmlNode)

    Removes the specified kmlNode 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 KmlNodeListModel::size() const

    Returns the number of KmlNodes 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.