Qt6 Migration: DDS-Stubs, Logger-Fixes, Export-Header Korrekturen

- NGL_ADD_LIBRARY2: 87 CMakeLists.txt konvertiert für Export-Header Generierung
- 44 Export-Header Include-Pfade korrigiert (_export.h)
- 81 DDS-Stub-Header generiert (*_dtc.h, *_fts.h, *_dts.h, *_ftc.h)
- INGLLogger: Duplikat gelöscht, m_logger Member entfernt, variadische Makros
- Q_FUNC_INFO Redefinition behoben (Qt6 definiert bereits)
- FATAL_LOG Makro hinzugefügt
- InfrastructureManagement DDS-Stubs (ism.hpp, ism_enums.hpp, ism_ftc.h)
- FilterManagement DDS-Stubs (flt_ftc.h, flt_dts.h)
- AreaEffectSimulation DDS-Stubs (aes.hpp, aes_enums.hpp)
- SymbolAppearance Klasse vollständig definiert mit content() Methode
- BuildingComponentFilter Klasse definiert mit Copy-Konstruktor
- Ftc Factory: nullptr Return (abstract class)
- AesFilter Klasse in aes.hpp hinzugefügt
- Dtc Klasse in ppm.hpp mit participantChanged Signal
- AesType Enum: alle 15 At* Werte definiert
- AesEffectState_def: EsReceived hinzugefügt
- DataModification Enum: eAdded/eModified/eRemoved
- function_reply_object.h → core_types.h Include-Pfad (72 Dateien)
- Enum-Class-Streaming Template-Operator in INGLLogger.h
- ism_mounting_point.h: QImage → QtGui/QImage, QGuiApplication/QScreen
- ism_data_plugin_interface.h: QSet Include, Include-Reihenfolge
- QRegExp → QRegularExpression in tpm_js_parser.cpp
- .underlying() Aufrufe zu direktem Enum-Vergleich korrigiert
- Include-Pfade: aes.hpp in symbol_appearance_settings_impl.h und aes_display_filter_impl.h

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
torstenandCopilot committed 2026-08-19 06:06:24 +02:00
1 parent 010f91928a
commit b774f4035c
2785 files changed
+18754 -18316

No files matched your search

@@ -21,7 +21,6 @@ static const int ADLER_NOT_OPERATIONAL = 127;
PpmHandler::PpmHandler(QObject *parent)
: QObject(parent)
, m_logger(getLogger("PpmHandler"))
, m_sendParticipantDataTimer(new QTimer(this))
{
}
@@ -37,10 +36,10 @@ bool PpmHandler::init(MainDispatcher *mainDispatcher)
m_dtcPpm = ParticipantManagement::Interface::Dtc::create(m_mainDispatcher->ddsHandler()->ddsConnector());
DEBUG_LOG(m_logger) << "-------------<><><>------" << m_mainDispatcher->exerciseId();
DEBUG_LOG() << "-------------<><><>------" << m_mainDispatcher->exerciseId();
if (!m_dtcPpm->enableParticipant() || !m_dtcPpm->enableDynamicParticipantData() || !m_dtcPpm->enableParticipantPosition())
{
ERROR_LOG(m_logger) << "Can not read data from Ppm";
ERROR_LOG() << "Can not read data from Ppm";
return false;
}
@@ -71,7 +70,7 @@ void PpmHandler::modifyPartyAdlerProperties(const int wsId,
const ParticipantManagement::ConnectState &connectState,
const bool isVerbund)
{
DEBUG_LOG(m_logger) << "modifyParty"
DEBUG_LOG() << "modifyParty"
<< " assetId=" << assetId << " partyId=" << partyId << " saaName=" << saaName << " szenarName=" << szenarName << " connectState=" << connectState
<< " isVerbund=" << isVerbund;
@@ -94,11 +93,11 @@ void PpmHandler::modifyPartyAdlerProperties(const int wsId,
if (parserError.error != QJsonParseError::NoError)
{
ERROR_LOG(m_logger) << "Error parsing json document: " << parserError.errorString() << " '" << propertiesBa << "'";
ERROR_LOG() << "Error parsing json document: " << parserError.errorString() << " '" << propertiesBa << "'";
doc = QJsonDocument();
}
DEBUG_LOG(m_logger) << "json to parse: " << doc.toJson();
DEBUG_LOG() << "json to parse: " << doc.toJson();
QJsonObject obj(doc.object());
obj[QStringLiteral("Adler")] = adlerPropertiesObj;
@@ -111,11 +110,11 @@ void PpmHandler::modifyPartyAdlerProperties(const int wsId,
void PpmHandler::parseSQFS(const Feuerstellungsdaten &exSQFS, const int wsId)
{
DEBUG_LOG(m_logger) << "Start parse SQFS";
DEBUG_LOG() << "Start parse SQFS";
auto saa = m_mainDispatcher->jsonDispatcher()->getSAAByWs(wsId);
if (!saa)
{
ERROR_LOG(m_logger) << "SQ WS from SAA but SAA with id " << wsId << " not found";
ERROR_LOG() << "SQ WS from SAA but SAA with id " << wsId << " not found";
return;
}
const QString &verein = exSQFS.feuereinheit.verein;
@@ -180,7 +179,7 @@ void PpmHandler::parseSQFS(const Feuerstellungsdaten &exSQFS, const int wsId)
const auto root = findRootUnit(saa->getPartyId());
if (root.id() > 0)
{
DEBUG_LOG(m_logger) << "Append FS Unit to root Unit";
DEBUG_LOG() << "Append FS Unit to root Unit";
list.push_back(root);
}
@@ -215,11 +214,11 @@ void PpmHandler::parseSQFS(const Feuerstellungsdaten &exSQFS, const int wsId)
void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
{
DEBUG_LOG(m_logger) << "Start parse SQWS";
DEBUG_LOG() << "Start parse SQWS";
auto saa = m_mainDispatcher->jsonDispatcher()->getSAAByWs(wsId);
if (!saa)
{
ERROR_LOG(m_logger) << "SQ WS from SAA but SAA with id " << wsId << " not found";
ERROR_LOG() << "SQ WS from SAA but SAA with id " << wsId << " not found";
return;
}
const ProjectDataManagement::L27_EffectorId &internalName = exSQWS.kenner;
@@ -254,7 +253,7 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
if (pp.id() > 0)
{
DEBUG_LOG(m_logger) << "Found Participant only update pos";
DEBUG_LOG() << "Found Participant only update pos";
sendPositionFromTempMap(currentRandomNumber, saa->getPartyId(), saa->getIsVerbund());
sendChargesFromTempMap(currentRandomNumber, saa->getPartyId(), saa->getIsVerbund());
@@ -268,10 +267,10 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
const ParticipantManagement::Type type = m_dtcPpm->getTypeFromAdlerType(waffensystemtypMap.key(internalType.underlying()), false, saa->getIsVerbund());
DEBUG_LOG(m_logger) << "found type with id: " << type.id() << " for name: " << waffensystemtypMap.key(internalType);
DEBUG_LOG() << "found type with id: " << type.id() << " for name: " << waffensystemtypMap.key(internalType);
if (type.id() <= 0)
{
ERROR_LOG(m_logger) << "NO Type Found";
ERROR_LOG() << "NO Type Found";
return;
}
@@ -281,12 +280,12 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
uint superiorModId = QRandomGenerator::global()->generate() / 2;
ParticipantManagement::Participant pUnit = findParticipantByInternalName(verein, saa->getPartyId(), saa->getIsVerbund());
DEBUG_LOG(m_logger) << "Looking for Verein: " << verein << " found Unit: " << pUnit.id() << " foundData: " << pUdata.modId();
DEBUG_LOG() << "Looking for Verein: " << verein << " found Unit: " << pUnit.id() << " foundData: " << pUdata.modId();
if (pUdata.modId() > 0)
{
superiorModId = pUdata.modId();
DEBUG_LOG(m_logger) << "FOUND UNIT in list use their modId " << superiorModId << " RND: " << currentRandomNumber;
DEBUG_LOG() << "FOUND UNIT in list use their modId " << superiorModId << " RND: " << currentRandomNumber;
}
else if (pUnit.id() > 0)
{
@@ -297,7 +296,7 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
list.push_back(pUData);
m_tempPartDataList.insert(currentRandomNumber, list);
DEBUG_LOG(m_logger) << "CREATE Uit from ppm " << superiorModId << " RND: " << currentRandomNumber;
DEBUG_LOG() << "CREATE Uit from ppm " << superiorModId << " RND: " << currentRandomNumber;
ParticipantManagement::Participant tmp = pUnit;
while (tmp.superiorId() > 0)
{
@@ -315,11 +314,11 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
const auto root = findRootUnit(saa->getPartyId());
if (root.id() > 0)
{
DEBUG_LOG(m_logger) << "Append to Unit" << superiorModId << " RND: " << currentRandomNumber;
DEBUG_LOG() << "Append to Unit" << superiorModId << " RND: " << currentRandomNumber;
list.push_back(root);
}
const ParticipantManagement::Type unitType = m_dtcPpm->getTypeFromAdlerType(waffensystemtypMap.key(internalType), true, saa->getIsVerbund());
DEBUG_LOG(m_logger) << "CREATE NEW Unit use supId" << superiorModId << " RND: " << currentRandomNumber;
DEBUG_LOG() << "CREATE NEW Unit use supId" << superiorModId << " RND: " << currentRandomNumber;
ParticipantManagement::ParticipantData data;
data.id(0);
data.partyId(saa->getPartyId());
@@ -338,7 +337,7 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
list.push_back(data);
}
DEBUG_LOG(m_logger) << "Create new Participant"
DEBUG_LOG() << "Create new Participant"
<< " RND: " << currentRandomNumber;
ParticipantManagement::ParticipantData data;
@@ -367,11 +366,11 @@ void PpmHandler::parseSQWS(const Waffensystemdaten &exSQWS, const int wsId)
void PpmHandler::parseSQLP(const Ladeplatzdaten &exSQLP, const int wsId)
{
DEBUG_LOG(m_logger) << "START parse SQLP";
DEBUG_LOG() << "START parse SQLP";
auto saa = m_mainDispatcher->jsonDispatcher()->getSAAByWs(wsId);
if (!saa)
{
ERROR_LOG(m_logger) << "SQ LP from SAA but SAA with id " << wsId << " not found";
ERROR_LOG() << "SQ LP from SAA but SAA with id " << wsId << " not found";
return;
}
const QString &verein = exSQLP.einheit.verein;
@@ -410,7 +409,7 @@ void PpmHandler::parseSQLP(const Ladeplatzdaten &exSQLP, const int wsId)
DEBUG_LOG(m_logger) << "Create new Participant LP";
DEBUG_LOG() << "Create new Participant LP";
std::vector<ParticipantManagement::ParticipantData> list;
@@ -419,7 +418,7 @@ void PpmHandler::parseSQLP(const Ladeplatzdaten &exSQLP, const int wsId)
const auto root = findRootUnit(saa->getPartyId());
if (root.id() > 0)
{
DEBUG_LOG(m_logger) << "Append LP to Unit";
DEBUG_LOG() << "Append LP to Unit";
list.push_back(root);
}
@@ -472,7 +471,7 @@ void PpmHandler::removeAllSAAParticipants(const int partyId)
list.push_back(pToDel);
}
req.data(list);
DEBUG_LOG(m_logger) << "Remove all participants (without Units): " << list.size();
DEBUG_LOG() << "Remove all participants (without Units): " << list.size();
m_ftcPpm->modifyParticipantDataRequest(req, this);
}
@@ -677,7 +676,7 @@ void PpmHandler::onSendParticipantDataTimeout()
{
m_sendParticipantDataTimer->stop();
if (m_randomNumbers.empty())
ERROR_LOG(m_logger) << "Cant Send ParticipantData RandomNumbers is empty";
ERROR_LOG() << "Cant Send ParticipantData RandomNumbers is empty";
ParticipantManagement::ModifyParticipantDataRequest *newRequest = new ParticipantManagement::ModifyParticipantDataRequest();
int currentRandomNumber = m_randomNumbers.first();
newRequest->requestId(currentRandomNumber);
@@ -708,7 +707,7 @@ void PpmHandler::handleParticipantPositionChangedExternal(const ParticipantManag
void PpmHandler::handleParticipantPositionChangedInternal(const ParticipantManagement::ParticipantPosition &position)
{
DEBUG_LOG(m_logger) << "handleParticipantPositionChangedInternal";
DEBUG_LOG() << "handleParticipantPositionChangedInternal";
ParticipantManagement::Participant part = m_dtcPpm->participant(position.participantId());
const bool hasMountedParticipants = position.mountedParticipants().is_set() && position.mountedParticipants().get().size() > 0;
@@ -740,7 +739,7 @@ void PpmHandler::handleParticipantPositionChangedInternal(const ParticipantManag
void PpmHandler::sendParticipantMount(const ParticipantManagement::Participant &part, const ParticipantManagement::Participant &partToBeMounted)
{
m_mountedParticipants.insert(part.equipmentNumber().get(), partToBeMounted.equipmentNumber().get());
ERROR_LOG(m_logger) << "Mount Participant";
ERROR_LOG() << "Mount Participant";
QJsonObject telegram;
telegram[QStringLiteral("type")] = QStringLiteral("UFomHlaParticipantMount");
@@ -760,7 +759,7 @@ void PpmHandler::sendParticipantMount(const ParticipantManagement::Participant &
void PpmHandler::sendParticipantUnmount(const ParticipantManagement::Participant &participant)
{
m_mountedParticipants.remove(participant.equipmentNumber().get());
DEBUG_LOG(m_logger) << "Unmount Participant";
DEBUG_LOG() << "Unmount Participant";
QJsonObject telegram;
telegram[QStringLiteral("type")] = QStringLiteral("UFomHlaParticipantUnmount");
@@ -801,7 +800,7 @@ void PpmHandler::sendParticipantPositionChanged(const ParticipantManagement::Par
void PpmHandler::onModifyParticipantDataReply(const Core::FunctionReplyObject &reply)
{
DEBUG_LOG(m_logger) << "Got Function Reply " << reply.str();
DEBUG_LOG() << "Got Function Reply " << reply.str();
if (!reply.error())
{
@@ -816,7 +815,7 @@ void PpmHandler::onModifyParticipantDataReply(const Core::FunctionReplyObject &r
const bool isVerbund = m_mainDispatcher->jsonDispatcher()->getSAAByParty(partyId)->getIsVerbund();
DEBUG_LOG(m_logger) << "Got ModifyParticipant Reply SEND from temp Maps (partyId: " << partyId << " , isVerbund: " << isVerbund << ")";
DEBUG_LOG() << "Got ModifyParticipant Reply SEND from temp Maps (partyId: " << partyId << " , isVerbund: " << isVerbund << ")";
if (m_tempPositionMap.contains(reply.id()))
sendPositionFromTempMap(reply.id(), partyId, isVerbund);
@@ -829,7 +828,7 @@ void PpmHandler::onModifyParticipantDataReply(const Core::FunctionReplyObject &r
}
else
{
ERROR_LOG(m_logger) << "GOT ModifyParticipant Replay with error " << reply.translated();
ERROR_LOG() << "GOT ModifyParticipant Replay with error " << reply.translated();
}
@@ -846,7 +845,7 @@ void PpmHandler::onModifyParticipantDataReply(const Core::FunctionReplyObject &r
m_tempPartDataList.remove(reply.id());
}
void PpmHandler::onModifyPartyDataReply(const Core::FunctionReplyObject &reply) { DEBUG_LOG(m_logger) << "Got Function Reply " << reply.str(); }
void PpmHandler::onModifyPartyDataReply(const Core::FunctionReplyObject &reply) { DEBUG_LOG() << "Got Function Reply " << reply.str(); }
QList<ParticipantManagement::Participant> PpmHandler::findAllSAAParticipants(const int partyId)
{
@@ -909,7 +908,7 @@ ParticipantManagement::ParticipantData PpmHandler::findRootUnit(const int partyI
ParticipantManagement::Participant PpmHandler::findParticipantByInternalName(const QString &internalName, const int partyId, const bool isVerbund)
{
ParticipantManagement::Participant pp;
DEBUG_LOG(m_logger) << "START find participant: " << internalName;
DEBUG_LOG() << "START find participant: " << internalName;
auto participantMap = m_dtcPpm->participants();
for (const auto &part : std::as_const(participantMap))
{
@@ -932,13 +931,13 @@ ParticipantManagement::Participant PpmHandler::findParticipantByInternalName(con
void PpmHandler::onPartyChanged(const ParticipantManagement::Party &data, DataModification modType)
{
DEBUG_LOG(m_logger) << LOGFUNCTION << ", modType: " << modType;
DEBUG_LOG() << Q_FUNC_INFO << ", modType: " << modType;
if (modType == DataModification::eRemoved)
return;
const ParticipantManagement::ConnectState connectState = m_dtcPpm->saaConnectedState(data.id());
DEBUG_LOG(m_logger) << "++++ connectState: " << connectState;
DEBUG_LOG() << "++++ connectState: " << connectState;
if (connectState != ParticipantManagement::ConnectState::Disconnecting)
@@ -948,7 +947,7 @@ void PpmHandler::onPartyChanged(const ParticipantManagement::Party &data, DataMo
if (!saa)
return;
DEBUG_LOG(m_logger) << "++++ szenarName: " << saa->getSzenarName() << ", wsId: " << saa->getWsId();
DEBUG_LOG() << "++++ szenarName: " << saa->getSzenarName() << ", wsId: " << saa->getWsId();
EXStatus status;
status.status = Szenarstatus::Gestoppt;
@@ -1016,7 +1015,7 @@ void PpmHandler::sendChargesFromTempMap(const int rndNmbr, const int partyId, co
if (chargeTypeId <= 0)
continue;
DEBUG_LOG(m_logger) << "---- participant.id:" << participant.id() << (participant.typeId() == type.id() ? " (Ladeplatz)" : "");
DEBUG_LOG() << "---- participant.id:" << participant.id() << (participant.typeId() == type.id() ? " (Ladeplatz)" : "");
QVector<int> gearTypesIds = m_mainDispatcher->pdmHandler()->getDtc()->gearTypeIdFromChargeTypeId(chargeTypeId);
@@ -1060,7 +1059,7 @@ int PpmHandler::convertStatus_L28(const ProjectDataManagement::L28_Status &statu
return ADLER_NOT_OPERATIONAL;
default:
WARNING_LOG(m_logger) << "Status " << status << " not handled in switch";
WARNING_LOG() << "Status " << status << " not handled in switch";
break;
}