6 #include <Poco/SharedPtr.h>
7 #include <Poco/Timestamp.h>
9 #include "model/DeviceID.h"
10 #include "model/ModuleType.h"
11 #include "model/RefreshTime.h"
12 #include "model/SensorData.h"
13 #include "net/MqttMessage.h"
14 #include "util/Loggable.h"
23 typedef Poco::SharedPtr<SonoffDevice> Ptr;
25 static const std::string VENDOR_NAME;
30 const std::string& productName,
31 const std::list<ModuleType>& moduleTypes);
36 std::list<ModuleType> moduleTypes()
const;
37 std::string vendor()
const;
38 std::string productName()
const;
39 Poco::Timestamp lastSeen()
const;
49 std::string m_productName;
50 std::list<ModuleType> m_moduleTypes;
51 Poco::Timestamp m_lastSeen;
RefreshTime represents time of refreshing values from sensors. E.g. sensors are polled periodically o...
Definition: RefreshTime.h:24
Definition: SensorData.h:20
Abstract class representing generic Sonoff device.
Definition: SonoffDevice.h:21
Definition: MqttMessage.h:7
Definition: Loggable.h:19
virtual SensorData parseMessage(const MqttMessage &message)=0
Transforms received MQTT message to SensorData.
Definition: DeviceID.h:17