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:
2785 files changed
+18754
-18316
No files matched your search
+17
-18
@@ -27,7 +27,6 @@ ObjectSituationReplay::ObjectSituationReplay(const std::shared_ptr<DdsHandler> &
|
||||
, m_exerciseId(exerciseId)
|
||||
, m_replayTimer(new QTimer(this))
|
||||
, m_currentReplayTime(0)
|
||||
, m_logger(getLogger("ObjectSituationReplay"))
|
||||
{
|
||||
connect(m_replayTimer, &QTimer::timeout, this, &ObjectSituationReplay::onReplayTimerTimeout);
|
||||
}
|
||||
@@ -68,7 +67,7 @@ Core::FunctionReplyObject ObjectSituationReplay::createObject(const Database::Sr
|
||||
}
|
||||
|
||||
// Id is serial -> will be generated by db => inside m_data after db-insert
|
||||
DEBUG_LOG(m_logger) << "New srpId: " << m_data.id;
|
||||
DEBUG_LOG() << "New srpId: " << m_data.id;
|
||||
|
||||
switchToState(SituationReplay::SrpState_def::Stopped);
|
||||
|
||||
@@ -91,7 +90,7 @@ bool ObjectSituationReplay::setPace(double newPace)
|
||||
{
|
||||
if (newPace < 0)
|
||||
{
|
||||
WARNING_LOG(m_logger) << "Trying to set a pace < 0";
|
||||
WARNING_LOG() << "Trying to set a pace < 0";
|
||||
return false;
|
||||
}
|
||||
m_data.pace = newPace;
|
||||
@@ -114,7 +113,7 @@ bool ObjectSituationReplay::setSrpData(const Database::SrpSituationReplay &newDa
|
||||
{
|
||||
if (!m_db->update(m_data))
|
||||
{
|
||||
ERROR_LOG(m_logger) << "Error updating SitReplay data in database (exerciseState)";
|
||||
ERROR_LOG() << "Error updating SitReplay data in database (exerciseState)";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -130,7 +129,7 @@ bool ObjectSituationReplay::setSrpData(const Database::SrpSituationReplay &newDa
|
||||
|
||||
// record SrpStateChange
|
||||
if (!m_db->insert(stateChange))
|
||||
WARNING_LOG(m_logger) << "Recording change of srpState failed";
|
||||
WARNING_LOG() << "Recording change of srpState failed";
|
||||
}
|
||||
|
||||
// Publish Data via DTS
|
||||
@@ -141,7 +140,7 @@ bool ObjectSituationReplay::setSrpData(const Database::SrpSituationReplay &newDa
|
||||
|
||||
bool ObjectSituationReplay::start()
|
||||
{
|
||||
INFO_LOG(m_logger) << "start: " << m_currentReplayTime;
|
||||
INFO_LOG() << "start: " << m_currentReplayTime;
|
||||
m_currentReplayTime = m_data.beginTime;
|
||||
|
||||
emit started(m_currentReplayTime);
|
||||
@@ -157,7 +156,7 @@ bool ObjectSituationReplay::start()
|
||||
|
||||
bool ObjectSituationReplay::pause()
|
||||
{
|
||||
INFO_LOG(m_logger) << "paused: " << m_currentReplayTime;
|
||||
INFO_LOG() << "paused: " << m_currentReplayTime;
|
||||
m_replayTimer->stop();
|
||||
emit paused();
|
||||
return true;
|
||||
@@ -165,7 +164,7 @@ bool ObjectSituationReplay::pause()
|
||||
|
||||
bool ObjectSituationReplay::resume()
|
||||
{
|
||||
INFO_LOG(m_logger) << "resumed" << m_currentReplayTime;
|
||||
INFO_LOG() << "resumed" << m_currentReplayTime;
|
||||
m_replayTimer->start(1000);
|
||||
emit resumed(m_currentReplayTime);
|
||||
return true;
|
||||
@@ -173,7 +172,7 @@ bool ObjectSituationReplay::resume()
|
||||
|
||||
bool ObjectSituationReplay::stop()
|
||||
{
|
||||
INFO_LOG(m_logger) << "stopped: " << m_currentReplayTime;
|
||||
INFO_LOG() << "stopped: " << m_currentReplayTime;
|
||||
m_replayTimer->stop();
|
||||
emit stopped();
|
||||
return true;
|
||||
@@ -189,10 +188,10 @@ void ObjectSituationReplay::onPublishReplayInformation()
|
||||
m_data.endTime,
|
||||
m_data.pace);
|
||||
|
||||
INFO_LOG(m_logger) << "Publish SitReplay data: " << ddsData;
|
||||
INFO_LOG() << "Publish SitReplay data: " << ddsData;
|
||||
|
||||
if (!m_ddsInterface->dts()->publish(ddsData))
|
||||
ERROR_LOG(m_logger) << "Error publishing SitReplay data to dds";
|
||||
ERROR_LOG() << "Error publishing SitReplay data to dds";
|
||||
}
|
||||
|
||||
void ObjectSituationReplay::onPublishReplayTime()
|
||||
@@ -205,13 +204,13 @@ void ObjectSituationReplay::onPublishReplayTime()
|
||||
void ObjectSituationReplay::onReplayTimerTimeout()
|
||||
{
|
||||
m_currentReplayTime += qRound64(m_data.pace * 1000);
|
||||
DEBUG_LOG(m_logger) << "onReplayTimerTimeout, endTime: " << m_data.endTime << " - " << m_currentReplayTime;
|
||||
DEBUG_LOG() << "onReplayTimerTimeout, endTime: " << m_data.endTime << " - " << m_currentReplayTime;
|
||||
checkPublishData();
|
||||
}
|
||||
|
||||
bool ObjectSituationReplay::checkPublishData()
|
||||
{
|
||||
INFO_LOG(m_logger) << " checkPublishData...";
|
||||
INFO_LOG() << " checkPublishData...";
|
||||
|
||||
onPublishReplayTime();
|
||||
if (m_data.endTime != 0 && m_data.endTime < m_currentReplayTime)
|
||||
@@ -226,7 +225,7 @@ bool ObjectSituationReplay::checkPublishData()
|
||||
// publish data for current time
|
||||
m_dbReader->publish(m_currentReplayTime);
|
||||
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG(m_logger) << "m_dbReader->publish took " << timer.elapsed() << " [ms]";
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG() << "m_dbReader->publish took " << timer.elapsed() << " [ms]";
|
||||
|
||||
|
||||
if (qFuzzyIsNull(m_data.pace)) // pace == 0 -> snapshot
|
||||
@@ -237,7 +236,7 @@ bool ObjectSituationReplay::checkPublishData()
|
||||
if (switchToState(SrpState_def::Stopped).error())
|
||||
return false;
|
||||
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG(m_logger) << "m_dbReader->waitForAsyncOperations took " << timerReadData.elapsed() << " [ms]";
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG() << "m_dbReader->waitForAsyncOperations took " << timerReadData.elapsed() << " [ms]";
|
||||
|
||||
}
|
||||
else
|
||||
@@ -248,17 +247,17 @@ bool ObjectSituationReplay::checkPublishData()
|
||||
if (!m_dbReader->readData(m_currentReplayTime, m_currentReplayTime + qRound64(m_data.pace * 1000)))
|
||||
return false;
|
||||
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG(m_logger) << "m_dbReader->readData took " << timerReadData.elapsed() << " [ms]";
|
||||
if (m_logger.isInfoEnabled()) INFO_LOG() << "m_dbReader->readData took " << timerReadData.elapsed() << " [ms]";
|
||||
}
|
||||
}
|
||||
INFO_LOG(m_logger) << " checkPublishData... DONE";
|
||||
INFO_LOG() << " checkPublishData... DONE";
|
||||
return true;
|
||||
}
|
||||
|
||||
Core::FunctionReplyObject ObjectSituationReplay::switchToState(SrpState newSrpState)
|
||||
{
|
||||
Core::FunctionReplyObject ret(m_data.id);
|
||||
INFO_LOG(m_logger) << "-------------- switchTo: " << newSrpState
|
||||
INFO_LOG() << "-------------- switchTo: " << newSrpState
|
||||
<< ", current: " << m_data.srpStateId;
|
||||
if (m_data.srpStateId != newSrpState)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user