fix Warning
This commit is contained in:
1 parent
593c221d23
commit
8345470273
316 files changed
+1246
-929
No files matched your search
+2
@@ -32,5 +32,7 @@ void TestExAnmeldebestaetigung::testExAnmeldebestaetigung()
|
||||
const QJsonObject jsonObj = jsonDoc.object();
|
||||
QJsonObject dataObj = jsonObj[AdlerJson::JsonKeys::DATA()].toObject();
|
||||
|
||||
// WIP: parsed from dataObj once the test body is completed
|
||||
AdlerJson::AnBestaetigungsdaten anBestaetigungsdaten;
|
||||
Q_UNUSED(anBestaetigungsdaten);
|
||||
}
|
||||
+18
-17
@@ -8,6 +8,7 @@
|
||||
*/
|
||||
|
||||
#include "aes_handler.h"
|
||||
#include <utility>
|
||||
#include "DDS/Core/function_reply_object.h"
|
||||
#include "aes.hpp"
|
||||
#include "json_dispatcher.h"
|
||||
@@ -128,7 +129,7 @@ void AesHandler::onEffectClusterModifyReply(const Core::FunctionReplyObject &rep
|
||||
|
||||
std::vector<std::string> args;
|
||||
args.reserve(argsList.size());
|
||||
for (const auto &str : qAsConst(argsList))
|
||||
for (const auto &str : std::as_const(argsList))
|
||||
args.emplace_back(str.toStdString());
|
||||
|
||||
req.notification().content(content.toStdString());
|
||||
@@ -171,7 +172,7 @@ void AesHandler::onEffectClusterModifyReply(const Core::FunctionReplyObject &rep
|
||||
std::vector<NotificationManagement::Address> recipientIdsDds;
|
||||
recipientIdsDds.reserve(recipientIds.size());
|
||||
|
||||
for (const auto &recipientId : qAsConst(recipientIds))
|
||||
for (const auto &recipientId : std::as_const(recipientIds))
|
||||
{
|
||||
NotificationManagement::Address addr;
|
||||
addr.addressId(recipientId);
|
||||
@@ -349,7 +350,7 @@ void AesHandler::sendTrajectoryAdlerModifyRequest(const WirkfeldplanungData &dat
|
||||
QVector<int> subordinates = m_dtcPpm->getSubordinatesByParticipant(participantId);
|
||||
QVector<ParticipantManagement::ParticipantPosition> subordinatePositions;
|
||||
|
||||
for (int subordinate : qAsConst(subordinates))
|
||||
for (int subordinate : std::as_const(subordinates))
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "subordinates(" << participantId << ") :" << subordinate;
|
||||
subordinatePositions.append(m_dtcPpm->participantPosition(subordinate));
|
||||
@@ -365,7 +366,7 @@ void AesHandler::sendTrajectoryAdlerModifyRequest(const WirkfeldplanungData &dat
|
||||
|
||||
double grad = (data.zieldaten.zielachse / 6400.) * 360.0;
|
||||
|
||||
for (Flugbahnpunkt pos : qAsConst(data.feuerkommando.wirkmittel.at(wirkmittelIndex).flugbahnpunkt))
|
||||
for (Flugbahnpunkt pos : std::as_const(data.feuerkommando.wirkmittel.at(wirkmittelIndex).flugbahnpunkt))
|
||||
{
|
||||
/*
|
||||
DEBUG_LOG(m_logger) << "Flugbahnpunkt:"
|
||||
@@ -625,7 +626,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
QList<QRectF> rects;
|
||||
int zone = 0;
|
||||
QVector<QPointF> vecPoints;
|
||||
for (const WirkmittelFeuerkommando &effector : qAsConst(data.feuerkommando.wirkmittel))
|
||||
for (const WirkmittelFeuerkommando &effector : std::as_const(data.feuerkommando.wirkmittel))
|
||||
{
|
||||
// get the target point for the effector
|
||||
const QPointF centerPoint(effector.auftreffpunkt.koordinate.longitude * (M_PI / 180.0), effector.auftreffpunkt.koordinate.latitude * (M_PI / 180.0));
|
||||
@@ -674,9 +675,9 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
// Now that we know the impact radius we create a boundingbox around all impact areas
|
||||
int zone = 0;
|
||||
QVector<QPointF> vecPoints;
|
||||
for (const WirkmittelFeuerkommandoRakete &effector : qAsConst(data.feuerkommando.wirkmittelRakete))
|
||||
for (const WirkmittelFeuerkommandoRakete &effector : std::as_const(data.feuerkommando.wirkmittelRakete))
|
||||
{
|
||||
for (const Treffpunkt &treffpunkt : qAsConst(effector.treffpunkte))
|
||||
for (const Treffpunkt &treffpunkt : std::as_const(effector.treffpunkte))
|
||||
{
|
||||
const QPointF centerPoint(treffpunkt.koordinate.koordinate.longitude * (M_PI / 180.0), treffpunkt.koordinate.koordinate.latitude * (M_PI / 180.0));
|
||||
|
||||
@@ -744,7 +745,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
|
||||
if (data.feuerkommando.wirkmittel.size() > 0)
|
||||
{
|
||||
for (const auto &effectorAdler : qAsConst(data.feuerkommando.wirkmittel))
|
||||
for (const auto &effectorAdler : std::as_const(data.feuerkommando.wirkmittel))
|
||||
{
|
||||
AreaEffectSimulation::EffectorData effectorData;
|
||||
effectorData.angleOfFall() = 0;
|
||||
@@ -778,7 +779,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
const double useNewGrad = -90 + std::atan2(coordDiff.y, coordDiff.x) * (180.0 / M_PI);
|
||||
DEBUG_LOG(m_logger) << "Atan2 Deg to: last point " << std::atan2(coordDiff.y, coordDiff.x) * (180.0 / M_PI);
|
||||
|
||||
for (const auto &flightPointAdler : qAsConst(effectorAdler.flugbahnpunkt))
|
||||
for (const auto &flightPointAdler : std::as_const(effectorAdler.flugbahnpunkt))
|
||||
{
|
||||
Core::RelativePositionRelativeTime flightPoint;
|
||||
flightPoint.offsetX() = 0; // flightPointAdler.zRelativ;
|
||||
@@ -826,7 +827,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
}
|
||||
else if (data.feuerkommando.wirkmittelRakete.size() > 0)
|
||||
{
|
||||
for (const auto &effectorAdler : qAsConst(data.feuerkommando.wirkmittelRakete))
|
||||
for (const auto &effectorAdler : std::as_const(data.feuerkommando.wirkmittelRakete))
|
||||
{
|
||||
AreaEffectSimulation::EffectorData effectorData;
|
||||
|
||||
@@ -851,7 +852,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
// create centroid
|
||||
Core::GeoPosition mhpPos;
|
||||
QPointF centroid;
|
||||
for (const auto &treffpunkt : qAsConst(effectorAdler.treffpunkte))
|
||||
for (const auto &treffpunkt : std::as_const(effectorAdler.treffpunkte))
|
||||
centroid += {treffpunkt.koordinate.koordinate.latitude, treffpunkt.koordinate.koordinate.longitude};
|
||||
|
||||
centroid /= effectorAdler.treffpunkte.size();
|
||||
@@ -889,7 +890,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
double currentFlightTime = 0.0;
|
||||
|
||||
const LtsCoordTrans::UtmCoordinate utmStartPos = LtsCoordTrans::UtmCoordinate::fromGeographic(participantPosition.pos().lon(), participantPosition.pos().lat());
|
||||
for (const Core::GeoPosition &pos : qAsConst(trajectoryWithoutTime))
|
||||
for (const Core::GeoPosition &pos : std::as_const(trajectoryWithoutTime))
|
||||
{
|
||||
const LtsCoordTrans::UtmCoordinate utmCurrentPos = LtsCoordTrans::UtmCoordinate::fromGeographic(pos.lon(), pos.lat());
|
||||
|
||||
@@ -935,7 +936,7 @@ void AesHandler::handleEffectCluster(const WirkfeldplanungData &data, int wsId)
|
||||
std::vector<ProjectDataManagement::L27_EffectorId> refWirkmittel;
|
||||
refWirkmittel.reserve(data.feuerkommando.wirkmittel.size());
|
||||
|
||||
for (const auto &wm : qAsConst(data.feuerkommando.wirkmittel))
|
||||
for (const auto &wm : std::as_const(data.feuerkommando.wirkmittel))
|
||||
{
|
||||
ammoCounter += wm.geschoss.anzahl; // Counts every Ammo that will be shooted
|
||||
DEBUG_LOG(m_logger) << "INSERT KENNER INTO MAP: " << data.feuerkampfReferenz << "---------" << wm.kenner;
|
||||
@@ -954,7 +955,7 @@ QList<qint32> AesHandler::findAllPendingEffectCluster(int partyId)
|
||||
// QList<AreaEffectSimulation::EffectCluster> ret;
|
||||
QList<qint32> ret;
|
||||
const auto &effectClusters = m_dtcAes->effectClusters();
|
||||
for (const auto &effectCluster : qAsConst(effectClusters))
|
||||
for (const auto &effectCluster : std::as_const(effectClusters))
|
||||
{
|
||||
if (effectCluster.partyId() != partyId)
|
||||
continue;
|
||||
@@ -993,7 +994,7 @@ void AesHandler::handleAmmoCount(const Feuerkampfdaten &data, int saaPartyId, bo
|
||||
|
||||
const auto &aesEffetClusters = m_dtcAes->effectClusters();
|
||||
|
||||
for (const auto &aes : qAsConst(aesEffetClusters))
|
||||
for (const auto &aes : std::as_const(aesEffetClusters))
|
||||
{
|
||||
if (aes.isDeleted() || aes.partyId() != saaPartyId || aes.element() != refTrimmed.toStdString())
|
||||
{
|
||||
@@ -1024,7 +1025,7 @@ void AesHandler::handleAmmoCount(const Feuerkampfdaten &data, int saaPartyId, bo
|
||||
{
|
||||
auto refKenners = m_feuerkampfReferenzWirkmittel.value(refTrimmed);
|
||||
|
||||
for (const auto &kenner : qAsConst(refKenners))
|
||||
for (const auto &kenner : std::as_const(refKenners))
|
||||
{
|
||||
ExVollzugsmeldung exvm;
|
||||
exvm.feuerkampfdaten.feuerkampfReferenz = data.feuerkampfReferenz;
|
||||
@@ -1056,7 +1057,7 @@ void AesHandler::removeAllPendingEffectCluster(int partyId)
|
||||
|
||||
INFO_LOG(m_logger) << "Pending effect cluster size: " << effectClusterIds.size();
|
||||
Core::RemoveElementRequest req;
|
||||
for (const qint32 id : qAsConst(effectClusterIds))
|
||||
for (const qint32 id : std::as_const(effectClusterIds))
|
||||
{
|
||||
req.id(id);
|
||||
INFO_LOG(m_logger) << "Remove effect cluster id: " << id;
|
||||
|
||||
+3
-2
@@ -8,6 +8,7 @@
|
||||
*/
|
||||
|
||||
#include "json_dispatcher.h"
|
||||
#include <utility>
|
||||
#include "json_handler_rx.h"
|
||||
#include "json_handler_tx.h"
|
||||
#include "settings.h"
|
||||
@@ -910,7 +911,7 @@ void JsonDispatcher::getCreateNotificationRequestData(const int wsId,
|
||||
|
||||
std::vector<std::string> args;
|
||||
args.reserve(contentArgs.size());
|
||||
for (const auto & str : qAsConst(contentArgs))
|
||||
for (const auto & str : std::as_const(contentArgs))
|
||||
args.emplace_back(str.toStdString());
|
||||
|
||||
notif.content(content.toStdString());
|
||||
@@ -930,7 +931,7 @@ void JsonDispatcher::getCreateNotificationRequestData(const int wsId,
|
||||
std::vector<NotificationManagement::Address> recipientIdsDds;
|
||||
recipientIdsDds.reserve(recipientIds.size());
|
||||
|
||||
for (const auto &recipientId : qAsConst(recipientIds))
|
||||
for (const auto &recipientId : std::as_const(recipientIds))
|
||||
{
|
||||
NotificationManagement::Address addr;
|
||||
addr.addressId(recipientId);
|
||||
|
||||
+30
-29
@@ -1,4 +1,5 @@
|
||||
#include "telegrams.h"
|
||||
#include <utility>
|
||||
|
||||
#include <QDebug>
|
||||
#include <QJsonDocument>
|
||||
@@ -332,7 +333,7 @@ void SAATELEGRAMS_EXPORT zielmeldedatenFromJson(const QJsonObject &data, Zielmel
|
||||
zielmeldedaten.forderung = ForderungMap.value(data[JsonKeys::FORDERUNG()].toString());
|
||||
zielmeldedaten.dauer = toInteger(data[JsonKeys::DAUER()], bOk);
|
||||
QJsonArray FeuerkommandoArray = data[JsonKeys::FEUERKOMMANDO()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(FeuerkommandoArray))
|
||||
for (const QJsonValue &value : std::as_const(FeuerkommandoArray))
|
||||
{
|
||||
Feuerkommando feuerkommando;
|
||||
feuerkommandoFromJson(value.toObject(), feuerkommando, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -362,7 +363,7 @@ void SAATELEGRAMS_EXPORT feuerstellungsdatenFromJson(const QJsonObject &data, Fe
|
||||
einheitfromJson(data[JsonKeys::FEUEREINHEIT()].toObject(), feuerstellungsdaten.feuereinheit, bOk); // EX-L3
|
||||
koordinateMitHoeheFromJson(data[JsonKeys::MITTELPUNKT()].toObject(), feuerstellungsdaten.mittelpunkt, bOk); // EX-L3
|
||||
QJsonArray koordinatenArray = data[JsonKeys::KOORDINATEN()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(koordinatenArray))
|
||||
for (const QJsonValue &value : std::as_const(koordinatenArray))
|
||||
{
|
||||
KoordinateMitHoehe koordinate;
|
||||
koordinateMitHoeheFromJson(value.toObject(), koordinate, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -370,7 +371,7 @@ void SAATELEGRAMS_EXPORT feuerstellungsdatenFromJson(const QJsonObject &data, Fe
|
||||
}
|
||||
|
||||
QJsonArray geschosseArray = data[JsonKeys::GESCHOSSE()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(geschosseArray))
|
||||
for (const QJsonValue &value : std::as_const(geschosseArray))
|
||||
{
|
||||
Geschoss geschosse;
|
||||
geschossfromJson(value.toObject(), geschosse, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -394,7 +395,7 @@ void SAATELEGRAMS_EXPORT feuerstellungsdatenToJson(QJsonObject &data, const Feue
|
||||
data[JsonKeys::MITTELPUNKT()] = mittelpunkt;
|
||||
|
||||
QJsonArray koordinaten;
|
||||
for (const auto &koordinate : qAsConst(feuerstellungsdaten.koordinaten))
|
||||
for (const auto &koordinate : std::as_const(feuerstellungsdaten.koordinaten))
|
||||
{
|
||||
QJsonObject koordinateObj;
|
||||
koordinateMitHoeheToJson(koordinateObj, koordinate);
|
||||
@@ -403,7 +404,7 @@ void SAATELEGRAMS_EXPORT feuerstellungsdatenToJson(QJsonObject &data, const Feue
|
||||
data[JsonKeys::KOORDINATEN()] = koordinaten;
|
||||
|
||||
QJsonArray geschosse;
|
||||
for (const auto &geschoss : qAsConst(feuerstellungsdaten.geschosse))
|
||||
for (const auto &geschoss : std::as_const(feuerstellungsdaten.geschosse))
|
||||
{
|
||||
QJsonObject geschossObj;
|
||||
geschossToJson(geschossObj, geschoss);
|
||||
@@ -425,7 +426,7 @@ void SAATELEGRAMS_EXPORT waffensystemdatenFromJson(const QJsonObject &data, Waff
|
||||
einheitfromJson(data[JsonKeys::EINHEIT()].toObject(), waffensystemdaten.einheit, bOk); // EX-L3
|
||||
|
||||
QJsonArray geschosseArray = data[JsonKeys::GESCHOSSE()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(geschosseArray))
|
||||
for (const QJsonValue &value : std::as_const(geschosseArray))
|
||||
{
|
||||
Geschoss geschosse;
|
||||
geschossfromJson(value.toObject(), geschosse, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -445,7 +446,7 @@ void SAATELEGRAMS_EXPORT waffensystemdatenToJson(QJsonObject &data, const Waffen
|
||||
data[JsonKeys::EINHEIT()] = einheit;
|
||||
|
||||
QJsonArray geschosse;
|
||||
for (const auto &geschoss : qAsConst(waffensystemdaten.geschosse))
|
||||
for (const auto &geschoss : std::as_const(waffensystemdaten.geschosse))
|
||||
{
|
||||
QJsonObject geschossObj;
|
||||
geschossToJson(geschossObj, geschoss);
|
||||
@@ -469,7 +470,7 @@ void SAATELEGRAMS_EXPORT ladeplatzdatenFromJson(const QJsonObject &data, Ladepla
|
||||
|
||||
koordinateMitHoeheFromJson(data[JsonKeys::KOORDINATE()].toObject(), ladeplatzdaten.koordinate, bOk);
|
||||
QJsonArray geschosseArray = data[JsonKeys::GESCHOSSE()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(geschosseArray))
|
||||
for (const QJsonValue &value : std::as_const(geschosseArray))
|
||||
{
|
||||
Geschoss geschosse;
|
||||
geschossfromJson(value.toObject(), geschosse, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -484,7 +485,7 @@ void SAATELEGRAMS_EXPORT ladeplatzdatenToJson(QJsonObject &data, const Ladeplatz
|
||||
data[JsonKeys::EINHEIT()] = einheit;
|
||||
|
||||
QJsonArray geschosse;
|
||||
for (const auto &geschoss : qAsConst(ladeplatzdaten.geschosse))
|
||||
for (const auto &geschoss : std::as_const(ladeplatzdaten.geschosse))
|
||||
{
|
||||
QJsonObject geschossObj;
|
||||
geschossToJson(geschossObj, geschoss);
|
||||
@@ -536,7 +537,7 @@ void SAATELEGRAMS_EXPORT koordinierungsdatenFromJson(const QJsonObject &data, Ko
|
||||
zeitangabe_DTGFromJson(data[JsonKeys::BIS()].toObject(), koordinierungsdaten.bis, bOk); // EX-L15
|
||||
|
||||
QJsonArray koordinatenArray = data[JsonKeys::KOORDINATEN()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(koordinatenArray))
|
||||
for (const QJsonValue &value : std::as_const(koordinatenArray))
|
||||
{
|
||||
Koordinate koordinate;
|
||||
koordinatefromJson(value.toObject(), koordinate, bOk); // EX-L13
|
||||
@@ -561,7 +562,7 @@ void SAATELEGRAMS_EXPORT koordinierungsdatenToJson(QJsonObject &data, const Koor
|
||||
data[JsonKeys::BIS()] = objTimestamp;
|
||||
|
||||
QJsonArray koordinatenArray;
|
||||
for (const auto &koordinate : qAsConst(koordinierungsdaten.koordinaten))
|
||||
for (const auto &koordinate : std::as_const(koordinierungsdaten.koordinaten))
|
||||
{
|
||||
QJsonObject objKoordinate;
|
||||
koordinateToJson(objKoordinate, koordinate);
|
||||
@@ -817,7 +818,7 @@ void SAATELEGRAMS_EXPORT erkundungsstellungenFromJson(const QJsonObject &data, E
|
||||
// Wirkungsbereich wirkungsbereich; // EX-L18
|
||||
|
||||
QJsonArray waffenplaetzeArray = data[JsonKeys::WAFFENPLAETZE()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(waffenplaetzeArray))
|
||||
for (const QJsonValue &value : std::as_const(waffenplaetzeArray))
|
||||
{
|
||||
KoordinateMitHoehe koordinateMitHoehe;
|
||||
koordinateMitHoeheFromJson(value.toObject(), koordinateMitHoehe, bOk);
|
||||
@@ -829,7 +830,7 @@ void SAATELEGRAMS_EXPORT erkundungsstellungenFromJson(const QJsonObject &data, E
|
||||
void SAATELEGRAMS_EXPORT erkundungsstellungenToJson(QJsonObject &data, const Erkundungsstellungen &erkundungsstellungen)
|
||||
{
|
||||
QJsonArray objWaffenplatzList;
|
||||
for (const auto waffenplatz : qAsConst(erkundungsstellungen.waffenplaetze))
|
||||
for (const auto waffenplatz : std::as_const(erkundungsstellungen.waffenplaetze))
|
||||
{
|
||||
QJsonObject objWaffenplatz;
|
||||
koordinateMitHoeheToJson(objWaffenplatz, waffenplatz);
|
||||
@@ -855,7 +856,7 @@ void SAATELEGRAMS_EXPORT feuerkommandoFromJson(const QJsonObject &data, Feuerkom
|
||||
else
|
||||
{
|
||||
QJsonArray wirkmittelArray = data[JsonKeys::WIRKMITTEL()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(wirkmittelArray))
|
||||
for (const QJsonValue &value : std::as_const(wirkmittelArray))
|
||||
{
|
||||
WirkmittelFeuerkommando wirkmittel;
|
||||
wirkmittelFeuerkommandoFromJson(value.toObject(), wirkmittel, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -867,7 +868,7 @@ void SAATELEGRAMS_EXPORT feuerkommandoFromJson(const QJsonObject &data, Feuerkom
|
||||
else
|
||||
{
|
||||
QJsonArray wirkmittelArray = data[JsonKeys::WIRKMITTELRAKETE()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(wirkmittelArray))
|
||||
for (const QJsonValue &value : std::as_const(wirkmittelArray))
|
||||
{
|
||||
WirkmittelFeuerkommandoRakete wirkmittel;
|
||||
wirkmittelFeuerkommandoRaketeFromJson(value.toObject(), wirkmittel, bOk); // EX-L34 Wirkmittel Feuerkommando
|
||||
@@ -878,7 +879,7 @@ void SAATELEGRAMS_EXPORT feuerkommandoFromJson(const QJsonObject &data, Feuerkom
|
||||
|
||||
void SAATELEGRAMS_EXPORT feuerkommandosToJson(QJsonArray &data, const QVector<Feuerkommando> &feuerkommandos)
|
||||
{
|
||||
for (const auto &feuerkommando : qAsConst(feuerkommandos))
|
||||
for (const auto &feuerkommando : std::as_const(feuerkommandos))
|
||||
{
|
||||
QJsonObject objFeuerkommand;
|
||||
feuerkommandoToJson(objFeuerkommand, feuerkommando);
|
||||
@@ -892,7 +893,7 @@ void SAATELEGRAMS_EXPORT feuerkommandoToJson(QJsonObject &data, const Feuerkomma
|
||||
data[JsonKeys::TYP()] = waffensystemtypMap.key(feuerkommando.typ);
|
||||
QJsonArray objWirkmittelList;
|
||||
QJsonArray objWirkmittelRaketeList;
|
||||
for (const auto &kommando : qAsConst(feuerkommando.wirkmittel))
|
||||
for (const auto &kommando : std::as_const(feuerkommando.wirkmittel))
|
||||
{
|
||||
QJsonObject objWirkmittel;
|
||||
wirkmittelFeuerkommandoToJson(objWirkmittel, kommando);
|
||||
@@ -900,7 +901,7 @@ void SAATELEGRAMS_EXPORT feuerkommandoToJson(QJsonObject &data, const Feuerkomma
|
||||
}
|
||||
data[JsonKeys::WIRKMITTEL()] = objWirkmittelList;
|
||||
|
||||
for (const auto &kommando : qAsConst(feuerkommando.wirkmittelRakete))
|
||||
for (const auto &kommando : std::as_const(feuerkommando.wirkmittelRakete))
|
||||
{
|
||||
QJsonObject objWirkmittel;
|
||||
wirkmittelFeuerkommandoRaketeToJson(objWirkmittel, kommando);
|
||||
@@ -937,7 +938,7 @@ void wirkmittelFeuerkommandoFromJson(const QJsonObject &data, WirkmittelFeuerkom
|
||||
|
||||
void wirkmittelFeuerkommandosToJson(QJsonArray &data, const QVector<WirkmittelFeuerkommando> &wirkmittelFeuerkommando)
|
||||
{
|
||||
for (const auto &feuerkommando : qAsConst(wirkmittelFeuerkommando))
|
||||
for (const auto &feuerkommando : std::as_const(wirkmittelFeuerkommando))
|
||||
{
|
||||
QJsonObject fkd;
|
||||
wirkmittelFeuerkommandoToJson(fkd, feuerkommando);
|
||||
@@ -947,7 +948,7 @@ void wirkmittelFeuerkommandosToJson(QJsonArray &data, const QVector<WirkmittelFe
|
||||
|
||||
void wirkmittelFeuerkommansdoToJson(QJsonArray &data, const QVector<WirkmittelFeuerkommando> &wirkmittelFeuerkommando)
|
||||
{
|
||||
for (const auto &wfk : qAsConst(wirkmittelFeuerkommando))
|
||||
for (const auto &wfk : std::as_const(wirkmittelFeuerkommando))
|
||||
{
|
||||
QJsonObject obj;
|
||||
wirkmittelFeuerkommandoToJson(obj, wfk);
|
||||
@@ -1007,7 +1008,7 @@ void SAATELEGRAMS_EXPORT flugbahnpunktToJson(QJsonObject &data, const Flugbahnpu
|
||||
// Array [EX-L35 Flugbahnpunkte]
|
||||
void SAATELEGRAMS_EXPORT flugbahnpunkteFromJson(const QJsonArray &data, QVector<Flugbahnpunkt> &flugbahnpunkte, bool &bOk)
|
||||
{
|
||||
for (const QJsonValue &value : qAsConst(data))
|
||||
for (const QJsonValue &value : std::as_const(data))
|
||||
{
|
||||
QJsonObject obj = value.toObject();
|
||||
Flugbahnpunkt flugbahnpunkt;
|
||||
@@ -1021,7 +1022,7 @@ void SAATELEGRAMS_EXPORT flugbahnpunkteToJson(QJsonArray &data, const QVector<Fl
|
||||
if (flugbahnpunkte.isEmpty())
|
||||
return;
|
||||
|
||||
for (const auto &flugpunkt : qAsConst(flugbahnpunkte))
|
||||
for (const auto &flugpunkt : std::as_const(flugbahnpunkte))
|
||||
{
|
||||
QJsonObject objFlugpunkt;
|
||||
flugbahnpunktToJson(objFlugpunkt, flugpunkt);
|
||||
@@ -1168,7 +1169,7 @@ void treffpunktfromJson(const QJsonObject &data, Treffpunkt &treffpunkt, bool &b
|
||||
|
||||
void treffpunktefromJson(const QJsonArray &data, QVector<Treffpunkt> &treffpunkte, bool &bOk)
|
||||
{
|
||||
for (const QJsonValue &val : qAsConst(data))
|
||||
for (const QJsonValue &val : std::as_const(data))
|
||||
{
|
||||
Treffpunkt treffpunkt;
|
||||
treffpunktfromJson(val.toObject(), treffpunkt, bOk);
|
||||
@@ -1215,7 +1216,7 @@ void trefferpunktToJson(QJsonObject &data, const Treffpunkt &treffpunkt)
|
||||
|
||||
void trefferpunkteToJson(QJsonArray &data, const QVector<Treffpunkt> &treffpunkte)
|
||||
{
|
||||
for (const auto &treffpunkt : qAsConst(treffpunkte))
|
||||
for (const auto &treffpunkt : std::as_const(treffpunkte))
|
||||
{
|
||||
QJsonObject trp;
|
||||
trefferpunktToJson(trp, treffpunkt);
|
||||
@@ -1244,7 +1245,7 @@ void wirkmittelFeuerkommandoRaketeToJson(QJsonObject &data, const WirkmittelFeue
|
||||
|
||||
void wirkmittelFeuerkommandosRaketeToJson(QJsonArray &data, const QVector<WirkmittelFeuerkommandoRakete> &wirkmittelFeuerkommandoRakete)
|
||||
{
|
||||
for (const auto &feuerkommandoRakete : qAsConst(wirkmittelFeuerkommandoRakete))
|
||||
for (const auto &feuerkommandoRakete : std::as_const(wirkmittelFeuerkommandoRakete))
|
||||
{
|
||||
QJsonObject fkr;
|
||||
wirkmittelFeuerkommandoRaketeToJson(fkr, feuerkommandoRakete);
|
||||
@@ -1292,7 +1293,7 @@ void SAATELEGRAMS_EXPORT fuehrungsdatenFromJson(const QJsonObject &data, Fuehrun
|
||||
zeitangabe_DTGFromJson(data[JsonKeys::AB()].toObject(), fuehrungsdaten.ab, bOk); // EX-L15
|
||||
zeitangabe_DTGFromJson(data[JsonKeys::BIS()].toObject(), fuehrungsdaten.bis, bOk); // EX-L15
|
||||
QJsonArray koordinatenArray = data[JsonKeys::KOORDINATEN()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(koordinatenArray))
|
||||
for (const QJsonValue &value : std::as_const(koordinatenArray))
|
||||
{
|
||||
Koordinate koordinate;
|
||||
koordinatefromJson(value.toObject(), koordinate, bOk); // EX-L13
|
||||
@@ -1315,7 +1316,7 @@ void SAATELEGRAMS_EXPORT fuehrungsdatenToJson(QJsonObject &data, const Fuehrungs
|
||||
data[JsonKeys::BIS()] = objTimestamp;
|
||||
|
||||
QJsonArray koordinatenArray;
|
||||
for (const auto &koordinate : qAsConst(fuehrungsdaten.koordinaten))
|
||||
for (const auto &koordinate : std::as_const(fuehrungsdaten.koordinaten))
|
||||
{
|
||||
QJsonObject objKoordinate;
|
||||
koordinateToJson(objKoordinate, koordinate);
|
||||
@@ -1378,7 +1379,7 @@ void SAATELEGRAMS_EXPORT flugbahndatenFromJson(const QJsonObject &data, Flugbahn
|
||||
flugbahndaten.fallwinkel = toInteger(data[JsonKeys::FALLWINKEL()], bOk);
|
||||
|
||||
QJsonArray flugbahnpunkteArray = data[JsonKeys::FLUGBAHNPUNKT()].toArray();
|
||||
for (const QJsonValue &value : qAsConst(flugbahnpunkteArray))
|
||||
for (const QJsonValue &value : std::as_const(flugbahnpunkteArray))
|
||||
{
|
||||
Flugbahnpunkt flugbahnpunkt;
|
||||
flugbahnpunktFromJson(value.toObject(), flugbahnpunkt, bOk); // EX-L13
|
||||
@@ -1410,7 +1411,7 @@ void SAATELEGRAMS_EXPORT flugbahndatenToJson(QJsonObject &data, const Flugbahnda
|
||||
data[JsonKeys::FALLWINKEL()] = flugbahndaten.fallwinkel;
|
||||
|
||||
QJsonArray flugbahnpunkte;
|
||||
for (const auto &flugbahnpunkt : qAsConst(flugbahndaten.flugbahnpunkt))
|
||||
for (const auto &flugbahnpunkt : std::as_const(flugbahndaten.flugbahnpunkt))
|
||||
{
|
||||
QJsonObject flugbahnpunktObj;
|
||||
flugbahnpunktToJson(flugbahnpunktObj, flugbahnpunkt);
|
||||
|
||||
Reference in new issue
Block a user