-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathprognownextmodel.h
More file actions
37 lines (28 loc) · 913 Bytes
/
prognownextmodel.h
File metadata and controls
37 lines (28 loc) · 913 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#ifndef PROGNOWNEXTMODEL_H
#define PROGNOWNEXTMODEL_H
#include <QAbstractTableModel>
class NodeNames;
class ProgNowNextModel : public QAbstractTableModel
{
Q_OBJECT
public:
ProgNowNextModel(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;
QVariant headerData(int section, Qt::Orientation orientation, int role) const;
void setNodeNameHelper(NodeNames *n);
public slots:
void newData(quint32 id1, quint32 zone, float tempNow, float tempNext, quint32 countDown);
private:
struct record_t {
quint32 id1;
quint32 zone;
float tempNow;
float tempNext;
quint32 countDown;
};
NodeNames *nn;
QMap<QString, record_t> temperatureMap;
};
#endif // SETPOINTMODEL_H