Leosac  0.8.0
Open Source Access Control
Leosac::Module::Instrumentation::InstrumentationModule Class Reference

#include <InstrumentationModule.hpp>

+ Inheritance diagram for Leosac::Module::Instrumentation::InstrumentationModule:
+ Collaboration diagram for Leosac::Module::Instrumentation::InstrumentationModule:

Public Member Functions

 InstrumentationModule (zmqpp::context &ctx, zmqpp::socket *pipe, const boost::property_tree::ptree &cfg, CoreUtilsPtr utils)
 
 InstrumentationModule (const InstrumentationModule &)=delete
 
 InstrumentationModule (InstrumentationModule &&)=delete
 
InstrumentationModuleoperator= (const InstrumentationModule &)=delete
 
InstrumentationModuleoperator= (InstrumentationModule &&)=delete
 
- Public Member Functions inherited from Leosac::Module::BaseModule
 BaseModule (zmqpp::context &ctx, zmqpp::socket *pipe, const boost::property_tree::ptree &cfg, CoreUtilsPtr utils)
 Constructor of BaseModule. More...
 
virtual ~BaseModule ()=default
 
virtual void run ()
 This is the main loop of the module. More...
 

Private Member Functions

void handle_command ()
 
void handle_gpio_command (zmqpp::message *str)
 

Private Attributes

zmqpp::socket bus_push_
 
zmqpp::socket controller_
 IPC ROUTER socket. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Leosac::Module::BaseModule
virtual void handle_pipe ()
 The base class register the pipe_ socket to its reactor_ so that this function is called when the pipe_ is available from reading. More...
 
virtual void handle_control ()
 Handle called when a message on the module's control socket arrives. More...
 
virtual void dump_additional_config (zmqpp::message *out) const
 Dump additional configuration (for example module specific config file). More...
 
void dump_config (ConfigManager::ConfigFormat fmt, zmqpp::message *out_msg) const
 Fills a message with the module's configuration information. More...
 
void config_check (const std::string &obj_name, Leosac::Hardware::DeviceClass type)
 An helper that checks configuration the existence of some objects. More...
 
void config_check (const std::string &obj_name)
 An helper that checks configuration the existence of some objects. More...
 
- Protected Attributes inherited from Leosac::Module::BaseModule
zmqpp::context & ctx_
 A reference to the ZeroMQ context in case you need it to create additional socket. More...
 
zmqpp::socket & pipe_
 A reference to the pair socket that link back to the module manager. More...
 
boost::property_tree::ptree config_
 The configuration tree passed to the start_module function. More...
 
CoreUtilsPtr utils_
 Pointer to the core utils, which gives access to scheduler and others. More...
 
bool is_running_
 Boolean indicating whether the main loop should run or not. More...
 
zmqpp::socket control_
 Control REP socket. More...
 
zmqpp::reactor reactor_
 The reactor object we poll() on in the main loop. More...
 
std::string name_
 

Detailed Description

Definition at line 33 of file InstrumentationModule.hpp.

Constructor & Destructor Documentation

◆ InstrumentationModule() [1/3]

InstrumentationModule::InstrumentationModule ( zmqpp::context &  ctx,
zmqpp::socket *  pipe,
const boost::property_tree::ptree &  cfg,
CoreUtilsPtr  utils 
)

Definition at line 25 of file InstrumentationModule.cpp.

◆ InstrumentationModule() [2/3]

Leosac::Module::Instrumentation::InstrumentationModule::InstrumentationModule ( const InstrumentationModule )
delete

◆ InstrumentationModule() [3/3]

Leosac::Module::Instrumentation::InstrumentationModule::InstrumentationModule ( InstrumentationModule &&  )
delete

Member Function Documentation

◆ handle_command()

void InstrumentationModule::handle_command ( )
private

Definition at line 43 of file InstrumentationModule.cpp.

◆ handle_gpio_command()

void InstrumentationModule::handle_gpio_command ( zmqpp::message *  str)
private

Definition at line 64 of file InstrumentationModule.cpp.

◆ operator=() [1/2]

InstrumentationModule& Leosac::Module::Instrumentation::InstrumentationModule::operator= ( const InstrumentationModule )
delete

◆ operator=() [2/2]

InstrumentationModule& Leosac::Module::Instrumentation::InstrumentationModule::operator= ( InstrumentationModule &&  )
delete

Member Data Documentation

◆ bus_push_

zmqpp::socket Leosac::Module::Instrumentation::InstrumentationModule::bus_push_
private

Definition at line 50 of file InstrumentationModule.hpp.

◆ controller_

zmqpp::socket Leosac::Module::Instrumentation::InstrumentationModule::controller_
private

IPC ROUTER socket.

Definition at line 55 of file InstrumentationModule.hpp.


The documentation for this class was generated from the following files: