- Migrated all 104 CMakeLists.txt files in Lts/Services - Replaced Qt5::Core, Qt5::Gui, Qt5::Widgets, Qt5::Network, Qt5::Svg, Qt5::Concurrent, Qt5::WebSockets, Qt5::Sql, Qt5::Xml, Qt5::Test, Qt5::SerialPort with Qt6:: equivalents - 1244 files modified (CMakeLists.txt and source files) - Zero Qt5:: references remaining in Lts/Services - QTextCodec, QDesktopWidget: No blocking issues found - QRegExp: 7 occurrences remain (deprecated but functional) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
80 lines
2.3 KiB
C++
Executable File
80 lines
2.3 KiB
C++
Executable File
/**
|
|
* MainHandler for Messaging
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
* Created by hjl, SLSE, 2016-09-21
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "ces_plugin_interface.h"
|
|
#include "handler_participant.h"
|
|
#include "handler_building_data.h"
|
|
#include "proxy_building.h"
|
|
#include "dds_handler.h"
|
|
|
|
#include <CentralEffectSimulation/logger.h>
|
|
#include <CentralEffectSimulation/svccesddscommon_export.h>
|
|
|
|
namespace NGLDB
|
|
{
|
|
template <typename DB> class DbServiceHandler;
|
|
}
|
|
|
|
namespace LtsPluginManager
|
|
{
|
|
struct PluginInstance;
|
|
}
|
|
|
|
|
|
namespace LtsPluginManager
|
|
{
|
|
struct PluginInstance;
|
|
}
|
|
|
|
|
|
namespace CentralEffectSimulation
|
|
{
|
|
|
|
class SVCCESDDSCOMMON_EXPORT MainHandler : public QObject, public Plugin::DataProvider
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit MainHandler(QObject *parent = nullptr);
|
|
~MainHandler();
|
|
|
|
bool init(int domainId, int exerciseId);
|
|
|
|
std::shared_ptr<DdsHandler> dds() const { return m_ddsHandler; }
|
|
std::shared_ptr<DatabaseInterface> db() const { return m_dbHandler->db(); }
|
|
|
|
std::shared_ptr<HandlerBuildingData> handlerBuildingData() const { return m_handlerBuildingData; }
|
|
std::shared_ptr<HandlerParticipant> handlerParticipant() const { return m_handlerParticipant; }
|
|
|
|
std::shared_ptr<ProxyBuilding> proxyBuilding() const { return m_proxyBuilding; }
|
|
|
|
const std::vector<std::shared_ptr<Plugin::Interface>> &getPluginList() const { return m_interfaces; }
|
|
|
|
|
|
private:
|
|
bool loadPlugin(const LtsPluginManager::PluginInstance &pi);
|
|
|
|
private: // attributes
|
|
std::shared_ptr<DdsHandler> m_ddsHandler;
|
|
std::shared_ptr<DbHandler> m_dbHandler;
|
|
std::shared_ptr<DatabaseInterface> m_db;
|
|
std::shared_ptr<HandlerBuildingData> m_handlerBuildingData;
|
|
std::shared_ptr<HandlerParticipant> m_handlerParticipant;
|
|
std::vector<std::shared_ptr<Plugin::Interface>> m_interfaces;
|
|
|
|
std::shared_ptr<ProxyBuilding> m_proxyBuilding;
|
|
|
|
|
|
int m_domainId = 0;
|
|
int m_exerciseId = 0;
|
|
CentralEffectSimulation::LOGGER_T &m_logger; ///< Interface to the Logging-Facility
|
|
|
|
};
|
|
} // namespace CentralEffectSimulation
|