BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
QREDataLoaderResultModel.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/View/Loaders/QREDataLoaderResultModel.h
6 //! @brief Defines class QREDataLoaderResultModel
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2021
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifndef BORNAGAIN_GUI_VIEW_LOADERS_QREDATALOADERRESULTMODEL_H
16 #define BORNAGAIN_GUI_VIEW_LOADERS_QREDATALOADERRESULTMODEL_H
17 
20 
21 //! The result model of a QREDataLoader (for showing the import results in a table view).
23 public:
25 
26 protected:
27  bool rowIsSkipped(int row) const override;
29  QString headerTextOfCalculatedColumn(int column) const override;
30  int columnCount(ColumnType type) const override;
32  QString cellText(ColumnType type, int row, int col) const override;
33  bool rowHasError(int row) const override;
35  int rowCount() const override;
37 
38 private:
40 };
41 
42 #endif // BORNAGAIN_GUI_VIEW_LOADERS_QREDATALOADERRESULTMODEL_H
Defines class AbstractDataLoaderResultModel.
Defines class QREDataLoader.
Base class for result tables of data loaders. Derive from this class and return an instance in YourDa...
virtual bool rowIsSkipped(const QModelIndex &index) const
Returns whether the row given in the index is a skipped row. Only override this for performance reaso...
int columnCount(const QModelIndex &parent=QModelIndex()) const override
virtual bool rowHasError(const QModelIndex &index) const
Returns whether the row given in the index contains errors. Only override this for performance reason...
virtual int rowCount() const =0
The row count of the result table.
The result model of a QREDataLoader (for showing the import results in a table view).
QREDataLoaderResultModel(QREDataLoader::ImportResult *importResult)
int rowCount() const override
The row count of the result table.
QString headerTextOfCalculatedColumn(int column) const override
Return the table header text for the given column. For convenience, column starts at 0 for first calc...
QString cellText(ColumnType type, int row, int col) const override
The text of the given cell. For convenience, column starts at 0 for the given column type,...
virtual bool rowIsSkipped(const QModelIndex &index) const
Returns whether the row given in the index is a skipped row. Only override this for performance reaso...
int columnCount(const QModelIndex &parent=QModelIndex()) const override
virtual bool rowHasError(const QModelIndex &index) const
Returns whether the row given in the index contains errors. Only override this for performance reason...
QREDataLoader::ImportResult * m_importResult
Result of the file import. Some of the contained data is only relevant for showing the results in the...