mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-15 09:31:45 +00:00
Extract state queue into own class. Use in device, plugins
This commit is contained in:
committed by
Dennis Klein
parent
4487b81de8
commit
f515eb1100
@@ -11,6 +11,7 @@
|
||||
|
||||
#include <fairmq/Plugin.h>
|
||||
#include <fairmq/Version.h>
|
||||
#include <fairmq/StateQueue.h>
|
||||
|
||||
#include <DDS/dds_intercom.h>
|
||||
|
||||
@@ -67,7 +68,6 @@ class DDS : public Plugin
|
||||
|
||||
private:
|
||||
auto HandleControl() -> void;
|
||||
auto WaitForNextState() -> DeviceState;
|
||||
|
||||
auto FillChannelContainers() -> void;
|
||||
auto SubscribeForConnectingChannels() -> void;
|
||||
@@ -92,10 +92,8 @@ class DDS : public Plugin
|
||||
const std::set<std::string> fTransitions;
|
||||
|
||||
std::thread fControllerThread;
|
||||
std::queue<DeviceState> fEvents;
|
||||
std::mutex fEventsMutex;
|
||||
std::condition_variable fNewEvent;
|
||||
DeviceState fCurrentState, fLastState;
|
||||
fair::mq::StateQueue fStateQueue;
|
||||
|
||||
std::atomic<bool> fDeviceTerminationRequested;
|
||||
std::atomic<bool> fServiceStarted;
|
||||
|
Reference in New Issue
Block a user