annotator/example/include/process/default_controller.hpp
Alexander Kobjolke 04b878f078 Initial version
2022-03-01 22:13:15 +01:00

36 lines
953 B
C++

#ifndef PROCESS_DEFAULT_CONTROLLER_HPP
#define PROCESS_DEFAULT_CONTROLLER_HPP
#include <memory>
#include <filesystem>
#include <asap/asap.hpp>
#include <process/watchdog.hpp>
namespace process::controller {
class ProcessCollection;
class CommandReceiver;
class DefinitionReceiver;
class DefaultProcessController {
public:
DefaultProcessController(std::shared_ptr<ProcessCollection> collection, const std::string& node_name,
const std::string& transport, const std::string& ctrl_prefix, const std::string& info_prefix);
virtual ~DefaultProcessController() = default;
void start();
void stop();
private:
std::shared_ptr<const asap::Configuration> m_cfg;
std::shared_ptr<asap::Participant> m_participant;
std::shared_ptr<ProcessCollection> m_collection;
std::shared_ptr<DefinitionReceiver> m_definition_receiver;
std::shared_ptr<CommandReceiver> m_command_receiver;
Watchdog m_watchdog;
};
}
#endif