Medical Imaging Interaction Toolkit  2024.06.00
Medical Imaging Interaction Toolkit
QmitkModuleTableModel.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef QmitkModuleTableModel_h
14 #define QmitkModuleTableModel_h
15 
16 #include <QAbstractTableModel>
17 #include <QList>
18 
20 
21 namespace us
22 {
23  class ModuleContext;
24  class Module;
25 }
26 
27 class QmitkModuleTableModelPrivate;
28 
29 class MITKQTWIDGETSEXT_EXPORT QmitkModuleTableModel : public QAbstractTableModel
30 {
31 public:
32  QmitkModuleTableModel(QObject *parent = nullptr, us::ModuleContext *mc = nullptr);
33  ~QmitkModuleTableModel() override;
34 
35 protected:
36  int rowCount(const QModelIndex &parent = QModelIndex()) const override;
37 
38  int columnCount(const QModelIndex &parent = QModelIndex()) const override;
39 
40  QVariant data(const QModelIndex &index, int role) const override;
41 
42  QVariant headerData(int section, Qt::Orientation orientation, int role) const override;
43 
44 private:
45  friend class QmitkModuleTableModelPrivate;
46 
47  void insertModule(us::Module *module);
48 
49  QmitkModuleTableModelPrivate *const d;
50 };
51 
52 #endif
MITKQTWIDGETSEXT_EXPORT
#define MITKQTWIDGETSEXT_EXPORT
Definition: MitkQtWidgetsExtExports.h:15
QmitkModuleTableModel
Definition: QmitkModuleTableModel.h:29
ModuleContext
Definition: usModuleContext.h:91
us
Definition: mitkAbstractFileReader.h:29
us::Module
Definition: usModule.h:78
MitkQtWidgetsExtExports.h