OpenScenarioModel Class Reference

Model used by the OpenScenarioView. More...

#include <ArmarXGui/gui-plugins/ScenarioManager/gui/openscenariomodel.h>

+ Inheritance diagram for OpenScenarioModel:

Public Member Functions

void clear () override
 Deletes the current root and replaces it with a new one, as if this model was newly constructed. More...
 
QVariant data (const QModelIndex &index, int role) const override
 Returns the data of the item at the given index of the given role. More...
 
OpenScenarioItemgetRootItem ()
 
 OpenScenarioModel ()
 Constructor that sets up the root of this model. More...
 
void update ()
 Updates this model. More...
 
- Public Member Functions inherited from TreeModel
int columnCount (const QModelIndex &parent=QModelIndex()) const override
 
QVariant data (const QModelIndex &index, int role) const override
 
Qt::ItemFlags flags (const QModelIndex &index) const override
 
QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
 
QModelIndex index (int row, int column, const QModelIndex &parent=QModelIndex()) const override
 
bool insertColumn (int position, QVariant data, const QModelIndex &parent=QModelIndex())
 
bool insertRow (int position, TreeItem *item, const QModelIndex &parent=QModelIndex())
 
QModelIndex parent (const QModelIndex &index) const override
 
bool removeColumn (int position, const QModelIndex &parent=QModelIndex())
 
bool removeRow (int position, const QModelIndex &parent=QModelIndex())
 
int rowCount (const QModelIndex &parent=QModelIndex()) const override
 
 TreeModel (QObject *parent=0)
 
 ~TreeModel () override
 

Additional Inherited Members

- Protected Member Functions inherited from TreeModel
TreeItemgetItem (const QModelIndex &index) const
 
- Protected Attributes inherited from TreeModel
TreeItemrootItem
 

Detailed Description

Model used by the OpenScenarioView.

Definition at line 36 of file openscenariomodel.h.

Constructor & Destructor Documentation

◆ OpenScenarioModel()

Constructor that sets up the root of this model.

Definition at line 28 of file openscenariomodel.cpp.

Member Function Documentation

◆ clear()

void clear ( )
overridevirtual

Deletes the current root and replaces it with a new one, as if this model was newly constructed.

Implements TreeModel.

Definition at line 74 of file openscenariomodel.cpp.

◆ data()

QVariant data ( const QModelIndex &  index,
int  role 
) const
override

Returns the data of the item at the given index of the given role.

Parameters
indexindex of the item
rolerole of the item

Definition at line 33 of file openscenariomodel.cpp.

+ Here is the call graph for this function:

◆ getRootItem()

OpenScenarioItem * getRootItem ( )

Definition at line 90 of file openscenariomodel.cpp.

◆ update()

void update ( )

Updates this model.

Definition at line 81 of file openscenariomodel.cpp.

+ Here is the call graph for this function:

The documentation for this class was generated from the following files: