LtsSession-STUB und GuezNasat-Fixes für BUILD_RTI=OFF
- CMakeLists.txt: Conditional compilation für BUILD_RTI=ON/OFF - lts_session_stub.h/cpp: NEU - STUB-Implementation ohne RTI-Abhängigkeit - lts_session_data_dds_stub.h: Doppeltes Namespace-Closing entfernt - gna_nasat_aircraft.h: participantId zu participantIdValue umbenannt (Konflikt) - gna_dtc.h: Doppeldefinitionen entfernt - gna_nasat_aircraft_participant.h: Doppeldefinitionen entfernt - ppm_enums.hpp: DataModification-Enum im ParticipantManagement-Namespace - ElevationMap-STUB: ArcGIS-Abhängigkeit für BUILD_RTI=OFF gekapselt - Viewer-STUB: Header für BUILD_RTI=OFF Build Build-Validierung: Configure erfolgreich, LtsSession-Fehler behoben
This commit is contained in:
17 files changed
+543
-50
No files matched your search
@@ -47,15 +47,22 @@ ENDIF()
|
||||
|
||||
|
||||
# LtsSession (RTI dependencies optional)
|
||||
SET(ltssession_SRCS
|
||||
lts_session.h
|
||||
lts_session.cpp
|
||||
lts_session_lock_handler.h
|
||||
)
|
||||
|
||||
# lts_session_manager and lts_session_lock_handler.cpp only needed when BUILD_RTI=ON
|
||||
IF(BUILD_RTI)
|
||||
LIST(APPEND ltssession_SRCS lts_session_manager.h lts_session_manager.cpp lts_session_lock_handler.cpp)
|
||||
SET(ltssession_SRCS
|
||||
lts_session.h
|
||||
lts_session.cpp
|
||||
lts_session_lock_handler.h
|
||||
lts_session_manager.h
|
||||
lts_session_manager.cpp
|
||||
lts_session_lock_handler.cpp
|
||||
)
|
||||
ELSE()
|
||||
# Stub version for BUILD_RTI=OFF
|
||||
SET(ltssession_SRCS
|
||||
lts_session_stub.h
|
||||
lts_session_stub.cpp
|
||||
lts_session_lock_handler.h
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
NGL_ADD_LIBRARY2(WS LtsSession SHARED ${ltssession_SRCS})
|
||||
|
||||
@@ -163,7 +163,7 @@ class LtsSessionDataDds : public QObject
|
||||
class Fetcher
|
||||
{
|
||||
public:
|
||||
Fetcher(LtsSession::LtsSessionDataDds*, const QString&) {}
|
||||
Fetcher(LtsSessionDataDds*, const QString&) {}
|
||||
|
||||
template <typename T> void getForeignGuiInterface(std::shared_ptr<T>&, const QString&, bool) {}
|
||||
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* Stub implementation for lts_session.cpp when BUILD_RTI=OFF
|
||||
* Provides minimal LtsSession class without RTI Connext DDS dependencies
|
||||
*/
|
||||
|
||||
#include "lts_session_stub.h"
|
||||
#include <QDebug>
|
||||
|
||||
namespace LtsSession
|
||||
{
|
||||
|
||||
LtsSession::LtsSession(QObject* parent)
|
||||
: LtsSessionDataDds(parent)
|
||||
, m_initialized(false)
|
||||
, m_sessionId(QStringLiteral("stub-session"))
|
||||
{
|
||||
}
|
||||
|
||||
LtsSession::~LtsSession() = default;
|
||||
|
||||
bool LtsSession::init(const DdsConnectionParams& /*params*/)
|
||||
{
|
||||
qWarning() << "LtsSession::init() called in STUB mode (BUILD_RTI=OFF) - no DDS functionality available";
|
||||
m_initialized = false;
|
||||
emit initialized(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
bool LtsSession::isInitialized() const
|
||||
{
|
||||
return m_initialized;
|
||||
}
|
||||
|
||||
std::shared_ptr<DataPluginBase::Interface> LtsSession::dataPlugin() const
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
std::shared_ptr<GuiPluginBase::Interface> LtsSession::guiPlugin() const
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
QString LtsSession::sessionId() const
|
||||
{
|
||||
return m_sessionId;
|
||||
}
|
||||
|
||||
int LtsSession::exerciseId() const
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
QString LtsSession::toString() const
|
||||
{
|
||||
return QStringLiteral("LtsSession(stub, initialized=%1)").arg(m_initialized ? "true" : "false");
|
||||
}
|
||||
|
||||
} // namespace LtsSession
|
||||
@@ -0,0 +1,64 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* Stub header for lts_session.h when BUILD_RTI=OFF
|
||||
* Provides minimal LtsSession class without RTI Connext DDS dependencies
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "lts_session_data_dds_stub.h"
|
||||
#include <QObject>
|
||||
#include <memory>
|
||||
|
||||
namespace LtsSession
|
||||
{
|
||||
|
||||
// Forward declarations
|
||||
namespace DataPluginBase
|
||||
{
|
||||
class Interface;
|
||||
}
|
||||
|
||||
namespace GuiPluginBase
|
||||
{
|
||||
class Interface;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Stub LtsSession class for BUILD_RTI=OFF
|
||||
*
|
||||
* This stub provides the same interface as the real LtsSession class
|
||||
* but without any RTI DDS functionality. All methods return default values
|
||||
* or nullptr.
|
||||
*/
|
||||
class LtsSession : public LtsSessionDataDds
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit LtsSession(QObject* parent = nullptr);
|
||||
~LtsSession() override;
|
||||
|
||||
// Initialization - always returns false in stub mode
|
||||
bool init(const DdsConnectionParams& params);
|
||||
bool isInitialized() const;
|
||||
|
||||
// Plugin interfaces - return nullptr in stub mode
|
||||
std::shared_ptr<DataPluginBase::Interface> dataPlugin() const;
|
||||
std::shared_ptr<GuiPluginBase::Interface> guiPlugin() const;
|
||||
|
||||
// Session info - return default values
|
||||
QString sessionId() const;
|
||||
int exerciseId() const;
|
||||
QString toString() const;
|
||||
|
||||
signals:
|
||||
void initialized(bool success);
|
||||
void sessionEnded();
|
||||
|
||||
private:
|
||||
bool m_initialized = false;
|
||||
QString m_sessionId;
|
||||
};
|
||||
|
||||
} // namespace LtsSession
|
||||
Reference in new issue
Block a user