QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
FactGroupListModel.h
Go to the documentation of this file.
1#pragma once
2
4#include "QGCMAVLink.h"
5#include "FactGroupWithId.h"
6
7#include <QList>
8
11{
13 QML_ELEMENT
15
16public:
17 explicit FactGroupListModel(const char* factGroupNamePrefix, QObject* parent = nullptr);
18
20 void handleMessageForFactGroupCreation(Vehicle *vehicle, const mavlink_message_t &message);
21
22protected:
23 virtual bool _shouldHandleMessage(const mavlink_message_t &message, QList<uint32_t> &ids) const = 0;
25
28
30};
struct __mavlink_message mavlink_message_t
Dynamically manages FactGroupWithIds based on incoming messages.
virtual bool _shouldHandleMessage(const mavlink_message_t &message, QList< uint32_t > &ids) const =0
FactGroupWithId * _findOrAddFactGroupById(Vehicle *vehicle, uint32_t id)
virtual FactGroupWithId * _createFactGroupWithId(uint32_t id)=0
QString _factGroupNameWithId(uint32_t id) const
void handleMessageForFactGroupCreation(Vehicle *vehicle, const mavlink_message_t &message)
Allows for creation/updating of dynamic FactGroups based on incoming messages.
const char * _factGroupNamePrefix
QModelIndex index(int row, int column=0, const QModelIndex &parent=QModelIndex()) const override
QModelIndex parent(const QModelIndex &child) const override