DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dbse::CustomSubClassModel Class Reference

#include <SchemaCustomSubClassModel.hpp>

Inheritance diagram for dbse::CustomSubClassModel:
[legend]
Collaboration diagram for dbse::CustomSubClassModel:
[legend]

Public Member Functions

 CustomSubClassModel (dunedaq::oks::OksClass *ClassInfo, QStringList Headers)
 
 ~CustomSubClassModel ()
 
void setupModel ()
 
- Public Member Functions inherited from dbse::CustomModelInterface
 CustomModelInterface (QStringList Headers, QObject *parent=nullptr)
 Including Schema Editor.
 
 ~CustomModelInterface ()
 
int rowCount (const QModelIndex &parent) const
 
int columnCount (const QModelIndex &parent) const
 
Qt::ItemFlags flags (const QModelIndex &index) const
 
QVariant headerData (int section, Qt::Orientation orientation, int role) const
 
QVariant data (const QModelIndex &index, int role) const
 
QStringList getRowFromIndex (QModelIndex &index)
 

Private Attributes

dunedaq::oks::OksClassSchemaClass
 

Additional Inherited Members

- Protected Attributes inherited from dbse::CustomModelInterface
QStringList HeaderList
 
QList< QStringList > Data
 

Detailed Description

Definition at line 13 of file SchemaCustomSubClassModel.hpp.

Constructor & Destructor Documentation

◆ CustomSubClassModel()

dbse::CustomSubClassModel::CustomSubClassModel ( dunedaq::oks::OksClass * ClassInfo,
QStringList Headers )

Definition at line 5 of file SchemaCustomSubClassModel.cpp.

7 : CustomModelInterface ( Headers ),
8 SchemaClass ( ClassInfo )
9{
10 setupModel();
11}
CustomModelInterface(QStringList Headers, QObject *parent=nullptr)
Including Schema Editor.
dunedaq::oks::OksClass * SchemaClass

◆ ~CustomSubClassModel()

dbse::CustomSubClassModel::~CustomSubClassModel ( )
default

Member Function Documentation

◆ setupModel()

void dbse::CustomSubClassModel::setupModel ( )
virtual

Implements dbse::CustomModelInterface.

Definition at line 13 of file SchemaCustomSubClassModel.cpp.

14{
15 Data.clear();
16
17 const OksClass::FList* allClasses = SchemaClass->all_sub_classes();
18 if(allClasses != nullptr) {
19 for(const OksClass* cl : *allClasses) {
20 QStringList Row;
21 Row.append ( QString::fromStdString ( cl->get_name() ) );
22 Data.append ( Row );
23 }
24 }
25}
The OKS class.
Definition class.hpp:200
const FList * all_sub_classes() const noexcept
Definition class.hpp:466
std::list< OksClass *, boost::fast_pool_allocator< OksClass * > > FList
Definition class.hpp:235

Member Data Documentation

◆ SchemaClass

dunedaq::oks::OksClass* dbse::CustomSubClassModel::SchemaClass
private

Definition at line 20 of file SchemaCustomSubClassModel.hpp.


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