The BidsViewModel class is the base data container.
More...
#include <bidsviewmodel.h>
|
void | addData (QModelIndex selectedItem, QStandardItem *pNewItem, int iDataType) |
|
void | addToData (QStandardItem *pNewItem, const QModelIndex &parentIndex, int iDataType) |
|
QModelIndex | addSubject (const QString &sSubjectName) |
|
QModelIndex | addSessionToSubject (const QString &sSubjectName, const QString &sSessionName) |
|
QModelIndex | addSessionToSubject (QModelIndex subjectIndex, const QString &sSessionName) |
|
QModelIndex | addDataToSession (QModelIndex sessionIndex, QStandardItem *pNewItem, int iDataType) |
|
QModelIndex | moveSessionToSubject (QModelIndex subjectIndex, QModelIndex sessionIndex) |
|
QModelIndex | moveDataToSession (QModelIndex sessionIndex, QModelIndex dataIndex) |
|
bool | removeItem (QModelIndex itemIndex) |
|
The BidsViewModel class is the base data container.
DECLARE CLASS BidsViewModel
Definition at line 104 of file bidsviewmodel.h.
◆ ConstSPtr
◆ SPtr
◆ BidsViewModel()
BidsViewModel::BidsViewModel |
( |
QObject * |
pParent = Q_NULLPTR | ) |
|
◆ ~BidsViewModel()
BidsViewModel::~BidsViewModel |
( |
| ) |
|
◆ addData
void BidsViewModel::addData |
( |
QModelIndex |
selectedItem, |
|
|
QStandardItem * |
pNewItem, |
|
|
int |
iDataType |
|
) |
| |
|
slot |
Adds data to the item model.
- Parameters
-
[in] | sSubjectName | The subject name to store the data under. |
[in] | pItem | The item to be added. |
Definition at line 73 of file bidsviewmodel.cpp.
◆ addDataToSession
QModelIndex BidsViewModel::addDataToSession |
( |
QModelIndex |
sessionIndex, |
|
|
QStandardItem * |
pNewItem, |
|
|
int |
iDataType |
|
) |
| |
|
slot |
Adds data item pNewItem to session at sessionIndex
- Parameters
-
[in] | sessionIndex | Index of session to which data will be added. |
[in] | pNewItem | New item to be added. |
- Returns
- index of newly added item.
Definition at line 243 of file bidsviewmodel.cpp.
◆ addSessionToSubject [1/2]
QModelIndex BidsViewModel::addSessionToSubject |
( |
const QString & |
sSubjectName, |
|
|
const QString & |
sSessionName |
|
) |
| |
|
slot |
Adds session named after sSessionName to subjects names sSubjectName
- Parameters
-
[in] | sSubjectName | Name of subject to which session will be added. |
[in] | sSessionName | Name of session to add. |
- Returns
- index of newly added item.
Definition at line 161 of file bidsviewmodel.cpp.
◆ addSessionToSubject [2/2]
QModelIndex BidsViewModel::addSessionToSubject |
( |
QModelIndex |
subjectIndex, |
|
|
const QString & |
sSessionName |
|
) |
| |
|
slot |
Adds session named after sSessionName to subject at subjectIndex
- Parameters
-
[in] | subjectIndex | Index of subject to which session will be added. |
[in] | sSessionName | Name of session to add. |
- Returns
- index of newly added item.
Definition at line 213 of file bidsviewmodel.cpp.
◆ addSubject
QModelIndex BidsViewModel::addSubject |
( |
const QString & |
sSubjectName | ) |
|
|
slot |
Adds subject with given input name
- Parameters
-
[in] | sSubjectName | name of subject name. |
- Returns
- index of newly added item.
Definition at line 134 of file bidsviewmodel.cpp.
◆ addToData
void BidsViewModel::addToData |
( |
QStandardItem * |
pNewItem, |
|
|
const QModelIndex & |
parentIndex, |
|
|
int |
iDataType |
|
) |
| |
|
slot |
Adds a sub-item to a data item (ex. an average)
- Parameters
-
[in] | pNewItem | item to be added. |
[in] | parentIndex | index of where the nitem should be added. |
Definition at line 117 of file bidsviewmodel.cpp.
◆ moveDataToSession
QModelIndex BidsViewModel::moveDataToSession |
( |
QModelIndex |
sessionIndex, |
|
|
QModelIndex |
dataIndex |
|
) |
| |
|
slot |
Moves data at dataIndex to session at sessionIndex
- Parameters
-
[in] | sessionIndex | Target session. |
[in] | dataIndex | Data to be moved. |
- Returns
Definition at line 328 of file bidsviewmodel.cpp.
◆ moveSessionToSubject
QModelIndex BidsViewModel::moveSessionToSubject |
( |
QModelIndex |
subjectIndex, |
|
|
QModelIndex |
sessionIndex |
|
) |
| |
|
slot |
Moves a session to a new subject
- Parameters
-
[in] | subjectIndex | Target subject. |
[in] | sessionIndex | Session to be moved. |
- Returns
Definition at line 299 of file bidsviewmodel.cpp.
◆ newItemIndex
void DISPLIB::BidsViewModel::newItemIndex |
( |
QModelIndex |
itemIndex | ) |
|
|
signal |
Emit index of newly added items to be selected
- Parameters
-
[in] | itemIndex | index of new item. |
◆ removeItem
bool BidsViewModel::removeItem |
( |
QModelIndex |
itemIndex | ) |
|
|
slot |
Removes item at index itemIndex
- Parameters
-
[in] | itemIndex | index of item to be removed. |
- Returns
- true if succefully removed, false if not.
Definition at line 371 of file bidsviewmodel.cpp.
The documentation for this class was generated from the following files: