QMqttMessageStatusProperties Class

QMqttMessageStatusProperties 클래스는 메시지 전송 중에 서버가 제공하는 추가 정보를 나타냅니다. 더 보기...

헤더: #include <QMqttMessageStatusProperties>
CMake: find_package(Qt6 REQUIRED COMPONENTS Mqtt)
target_link_libraries(mytarget PRIVATE Qt6::Mqtt)
qmake: QT += mqtt

공용 함수

QString reason() const
QMqtt::ReasonCode reasonCode() const
QMqttUserProperties userProperties() const

상세 설명

QMqttClient::publish()에서 전송되는 메시지의 QoS 수준에 따라 서버는 전송 상태를 보고합니다. QMqtt::MessageStatus 에 추가하여 서버에서 보완 정보를 포함할 수 있습니다. 이러한 정보는 QMqttMessageStatusProperties를 통해 사용자에게 노출됩니다.

참고: 메시지 상태 프로퍼티는 MQTT 5.0 사양의 일부이며 하위 프로토콜 수준과 연결할 때는 사용할 수 없습니다. 자세한 내용은 QMqttClient::ProtocolVersion 을 참조하세요.

멤버 함수 문서

QString QMqttMessageStatusProperties::reason() const

메시지 전송 실패의 이유 문자열을 반환합니다.

QMqtt::ReasonCode QMqttMessageStatusProperties::reasonCode() const

메시지 전송 실패의 사유 코드를 반환합니다.

QMqttUserProperties QMqttMessageStatusProperties::userProperties() const

메시지와 함께 지정된 속성을 반환합니다.

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.