Class PowerSwitch

Class Documentation

class PowerSwitch

power switch information class, associates a vector of plug name(s) with a given subsystem

This class contains the list (vector) of plug names for a given subsystem and a function for loading the vector from the configuration file.

This is only information — power control is performed using the power daemon, but this allows the Sequencer to know which plugs are associated with a given subsystem. This vector is read from the configuration file.

For proper usage, an STL map is created in the Sequence class, std::map<std::string, class PowerSwitch> power_switch so there is a map between each hardware subsystem and this class.

The subsystem names mirror the configuration parameter names defined above, i.e. const std::string POWER_SLIT const std::string POWER_CAMERA etc.

Public Functions

PowerSwitch() = default
long configure(std::string arglist)

function to load plugname from cfg file

Public Members

std::vector<std::string> plugname

vector of plug names required for this hardware subsystem