MessageFieldItemModel.h
Go to the documentation of this file.
1 /******************************************************************************
2  * Copyright (C) 2015 by Ralf Kaestner *
3  * ralf.kaestner@gmail.com *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the Lesser GNU General Public License as published by*
7  * the Free Software Foundation; either version 3 of the License, or *
8  * (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * Lesser GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the Lesser GNU General Public License *
16  * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17  ******************************************************************************/
18 
19 #ifndef RQT_MULTIPLOT_MESSAGE_FIELD_ITEM_MODEL_H
20 #define RQT_MULTIPLOT_MESSAGE_FIELD_ITEM_MODEL_H
21 
22 #include <QAbstractItemModel>
23 
25 
26 #include <variant_topic_tools/MessageDataType.h>
27 
28 namespace rqt_multiplot {
30  public QAbstractItemModel {
31  Q_OBJECT
32  public:
33  MessageFieldItemModel(QObject* parent = 0);
34  virtual ~MessageFieldItemModel();
35 
36  void setMessageDataType(const variant_topic_tools::MessageDataType&
37  dataType);
38  variant_topic_tools::MessageDataType getMessageDataType() const;
39  variant_topic_tools::DataType getFieldDataType(const QString& field)
40  const;
41 
42  int rowCount(const QModelIndex& parent) const;
43  int columnCount(const QModelIndex& parent) const;
44  QVariant data(const QModelIndex& index, int role) const;
45  QModelIndex index(int row, int column, const QModelIndex& parent) const;
46  QModelIndex parent(const QModelIndex& index) const;
47 
48  void update(const QString& path);
49 
50  private:
52  };
53 };
54 
55 #endif
QModelIndex index(int row, int column, const QModelIndex &parent) const
int columnCount(const QModelIndex &parent) const
QModelIndex parent(const QModelIndex &index) const
int rowCount(const QModelIndex &parent) const
QVariant data(const QModelIndex &index, int role) const
variant_topic_tools::DataType getFieldDataType(const QString &field) const
void setMessageDataType(const variant_topic_tools::MessageDataType &dataType)
variant_topic_tools::MessageDataType getMessageDataType() const


rqt_multiplot
Author(s): Ralf Kaestner
autogenerated on Wed Jul 10 2019 03:49:44