/** * @RDE_HEADER@ * DdsHandlerExercise * $Id$ * $HeadURL$ * $Author$ * Created by Christian Fröbel, NLE, 2019-08-02 */ #pragma once #include #include namespace DDSConnector { class DdsConnector; } namespace ParticipantManagement { namespace Interface { class Dtc; } } namespace CombatNetRadio { /** * @author Christian Fröbel */ class DdsHandlerExercise { public: explicit DdsHandlerExercise(const dds::domain::DomainParticipant &domainParticipant, int exerciseId); virtual ~DdsHandlerExercise(); /** * Must be called *after* all DTC-consuming instances have been setup. * This is to avoid data races that otherwise could arise * when * - connecting to the onFooChanged() signal and * - shortly after that calling foo() to get all received entities so far. */ void enableDtcs(); ParticipantManagement::Interface::Dtc *ppmDtc() const { return m_ppmDtc.get(); } private: std::shared_ptr m_ddsConnector; std::shared_ptr m_ppmDtc; }; } // namespace CombatNetRadio