.. _object_MqttTopic: :index:`MqttTopic` ------------------ Description *********** The MqttTopic object represents an MQTT topic identified by its :ref:`name `. MQTT topics can be either subscribed or published and need to be specified within :ref:`MqttSubscription ` or :ref:`MqttPublication ` objects. The :ref:`DataObject.name ` property holds the name of the topic, e.g. ``machine/sensor0``. More information on MQTT topic names is available at `mosquitto.org `_. The :ref:`DataObject.data ` property holds the data to publish or the subscribed (received) data. :**› Inherits**: :ref:`DataObject ` Overview ******** Properties ++++++++++ .. hlist:: :columns: 2 * :ref:`DataObject.data ` * :ref:`DataObject.dataType ` * :ref:`DataObject.description ` * :ref:`DataObject.name ` * :ref:`DataObject.timestamp ` * :ref:`DataObject.uuid ` * :ref:`DataObject.view ` * :ref:`Object.objectId ` * :ref:`Object.parent ` Methods +++++++ .. hlist:: :columns: 1 * :ref:`DataObject.touch() ` * :ref:`Object.deserializeProperties() ` * :ref:`Object.fromJson() ` * :ref:`Object.serializeProperties() ` * :ref:`Object.toJson() ` Signals +++++++ .. hlist:: :columns: 1 * :ref:`Object.completed() ` Enumerations ++++++++++++ .. hlist:: :columns: 1 * :ref:`DataObject.DataType ` Properties ********** Example ******* See :ref:`MqttClient example ` on how to use MqttTopic.