[AFV] Add method to read all aliased HF stations

ref T729
This commit is contained in:
Roland Rossgotterer
2019-09-19 21:54:40 +02:00
committed by Mat Sutcliffe
parent 4a578110b0
commit 8b1fb1baca
6 changed files with 83 additions and 3 deletions

View File

@@ -16,6 +16,7 @@
#include <QByteArray>
#include <QJsonObject>
#include <QString>
#include <QUuid>
namespace BlackCore
{
@@ -137,6 +138,24 @@ namespace BlackCore
}
};
struct StationDto
{
QUuid id;
QString name;
quint32 frequency;
quint32 frequencyAlias;
static StationDto fromJson(const QJsonObject &json)
{
StationDto dto;
dto.id = json.value("id").toString();
dto.name = json.value("name").toString();
dto.frequency = json.value("frequency").toInt();
dto.frequencyAlias = json.value("frequencyAlias").toInt();
return dto;
}
};
struct HeartbeatDto
{
static QByteArray getDtoName() { return "HeartbeatDto"; }