IoT::MQTT

struct MessageArrivedEvent

File Information

Library: IoT/MQTT
Package: MQTTClient
Header: IoT/MQTT/Types.h

Description

Event arguments for MQTTClient::messageArrived.

Variables

dup

bool dup = false;

The dup flag indicates whether or not this message is a duplicate. It is only meaningful when receiving QoS1 messages. When true, the client application should take appropriate action to deal with the duplicate message.

handled

bool handled = false;

The handled flag must be set by the event delegate after processing of the message to indicate whether the message has been successfully processed. If set to false, the MQTT client will attempt to deliver the message again. The handled flag defaults to true. If the event delegate throws, the handled flag will be set to false by the framework. This means that in most cases the delegate does not need to concern itself with this flag.

message

Message message;

The published message.

topic

std::string topic;

The topic the message has been published to.

Securely control IoT edge devices from anywhere   Connect a Device