IoT::Devices

class SensorEventDispatcher

File Information

Library: IoT/Devices
Package: Generated
Header: IoT/Devices/SensorEventDispatcher.h

Description

The base class for analog sensors, such as temperature or ambient light sensors.

In addition to the methods defined in this interface, a Sensor implementation should expose the following properties:

  • physicalQuantity (string): The physical quantity that is being measured by the sensor, e.g. "temperature".
  • physicalUnit (string): The physical unit the measured value is being represented in (e.g. "Cel" for degree Celsius). This should use the "c/s" symbols from the Unified Code for Units of Measure (http://unitsofmeasure.org/ucum.html). See the PHYSICAL_UNIT_* strings for predefined values.
  • displayValue (string, optional): The current value of the sensor, formatted as string for display purposes.

Inheritance

Direct Base Classes: Poco::RemotingNG::EventDispatcher

All Base Classes: Poco::RefCountedObject, Poco::RemotingNG::EventDispatcher

Member Summary

Member Functions: event__statusChanged, event__valueChanged, remoting__typeId

Inherited Functions: accept, attributes, duplicate, protocol, referenceCount, release, removeEventFilter, setEventFilter, setEventFilterImpl, subscribe, transportForSubscriber, unsubscribe

Constructors

SensorEventDispatcher

SensorEventDispatcher(
    ISensor * pInterface,
    const Poco::RemotingNG::Identifiable::ObjectId & objectId,
    const std::string & protocol
);

Destructor

~SensorEventDispatcher virtual

virtual ~SensorEventDispatcher();

Destroys the SensorEventDispatcher.

Member Functions

event__statusChanged

void event__statusChanged(
    const void * pSender,
    const IoT::Devices::DeviceStatusChange & data
);

event__valueChanged

void event__valueChanged(
    const void * pSender,
    const double & data
);

remoting__typeId virtual inline

virtual const Poco::RemotingNG::Identifiable::TypeId & remoting__typeId() const;

Securely control IoT edge devices from anywhere   Connect a Device