1 #include "sensors/SensorManager.h" 4 this->sensorMap =
new std::map<Hardware, ISensor*>;
8 delete this->sensorMap;
14 if( this->sensorMap->find(hardware) != this->sensorMap->end() ) {
17 this->sensorMap->insert(std::make_pair(hardware, sensor));
25 Hardware hardware = msg->getHardware();
26 if( this->sensorMap->find(hardware) == this->sensorMap->end() ) {
30 this->sensorMap->at(msg->getHardware())->updateSensor(msg);
void addSensor(Hardware hardware, ISensor *sensor) override
void updateSensors(std::list< IMessage * > *messages) override
~SensorManager() override