9 #include <spdlog/spdlog.h>
34 virtual std::string
json(
const std::string
name = {})
const;
36 virtual void update(
int timeout)
final;
std::shared_ptr< spdlog::logger > _logger
Pointer to spd logger.
std::vector< ObSensor * > & sensors()
Return list of sensors.
SensorType _type
Sensor type.
ObSensor(std::string name={"sensor"})
std::string name() const
Returns name of sensor.
virtual void speed(ObSensor *, ObSensor *, int)
Calculate time change (speed)
std::vector< ObSensor * > _sensors
List of subsensors.
ObSensor * _first
Pointer to first sensor.
SensorType
Enums for sensor type.
ObSensor * _change
Pointer to change sensor.
virtual std::string json(const std::string name={}) const
ObSensor * _second
Pointer to second sensor.
virtual void update(int timeout) final
virtual void process()
Process function.
SensorType type() const
Returns sensor type.
std::string _name
Sensor name.
void type(SensorType t)
Sets sensor type.