天嵌二次封装库使用手册  V2.1.2
MQTTSubscribe_options结构体 参考

#include <MQTTSubscribeOpts.h>

Public 属性

char struct_id [4]
 
int struct_version
 
unsigned char noLocal
 
unsigned char retainAsPublished
 
unsigned char retainHandling
 

详细描述

The MQTT V5 subscribe options, apart from QoS which existed before V5.

在文件 MQTTSubscribeOpts.h21 行定义.

类成员变量说明

unsigned char MQTTSubscribe_options::noLocal

To not receive our own publications, set to 1. 0 is the original MQTT behaviour - all messages matching the subscription are received.

在文件 MQTTSubscribeOpts.h31 行定义.

unsigned char MQTTSubscribe_options::retainAsPublished

To keep the retain flag as on the original publish message, set to 1. If 0, defaults to the original MQTT behaviour where the retain flag is only set on publications sent by a broker if in response to a subscribe request.

在文件 MQTTSubscribeOpts.h36 行定义.

unsigned char MQTTSubscribe_options::retainHandling

0 - send retained messages at the time of the subscribe (original MQTT behaviour) 1 - send retained messages on subscribe only if the subscription is new 2 - do not send retained messages at all

在文件 MQTTSubscribeOpts.h41 行定义.

char MQTTSubscribe_options::struct_id[4]

The eyecatcher for this structure. Must be MQSO.

在文件 MQTTSubscribeOpts.h24 行定义.

int MQTTSubscribe_options::struct_version

The version number of this structure. Must be 0.

在文件 MQTTSubscribeOpts.h27 行定义.


该结构体的文档由以下文件生成: