summaryrefslogtreecommitdiffstats
path: root/examples/tutorials/modelview/1_readonly/mymodel.h
blob: 01ae6cb403275178e4251fcd8a5f146cfb2432ec (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#ifndef MYMODEL_H
#define MYMODEL_H

#include <QAbstractTableModel>

class MyModel : public QAbstractTableModel
{
    Q_OBJECT
public:
    MyModel(QObject *parent);
    int rowCount(const QModelIndex &parent = QModelIndex()) const ;
    int columnCount(const QModelIndex &parent = QModelIndex()) const;
    QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
};

#endif // MYMODEL_H