QMqttAuthenticationProperties Class
The QMqttAuthenticationProperties class represents configuration options during the authentication process. More...
Header: | #include <QMqttAuthenticationProperties> |
CMake: | find_package(Qt6 REQUIRED COMPONENTS Mqtt) target_link_libraries(mytarget PRIVATE Qt6::Mqtt) |
qmake: | QT += mqtt |
Since: | Qt 5.12 |
Public Functions
QByteArray | authenticationData() const |
QString | authenticationMethod() const |
QString | reason() const |
void | setAuthenticationData(const QByteArray &adata) |
void | setAuthenticationMethod(const QString &method) |
void | setReason(const QString &r) |
void | setUserProperties(const QMqttUserProperties &user) |
QMqttUserProperties | userProperties() const |
Detailed Description
Note: Authentication properties are part of the MQTT 5.0 specification and cannot be used when connecting with a lower protocol level. See QMqttClient::ProtocolVersion for more information.
Member Function Documentation
QByteArray QMqttAuthenticationProperties::authenticationData() const
Returns the authentication data
See also setAuthenticationData().
QString QMqttAuthenticationProperties::authenticationMethod() const
Returns the authentication method.
See also setAuthenticationMethod().
QString QMqttAuthenticationProperties::reason() const
Returns the reason string. The reason string specifies the reason for a disconnect.
See also setReason().
void QMqttAuthenticationProperties::setAuthenticationData(const QByteArray &adata)
Sets the authentication data to adata.
Authentication data can only be used if an authentication method has been specified.
See also authenticationData() and authenticationMethod().
void QMqttAuthenticationProperties::setAuthenticationMethod(const QString &method)
Sets the authentication method to method.
See also authenticationMethod().
void QMqttAuthenticationProperties::setReason(const QString &r)
Sets the reason string to r.
See also reason().
void QMqttAuthenticationProperties::setUserProperties(const QMqttUserProperties &user)
Sets the user properties to user.
See also userProperties().
QMqttUserProperties QMqttAuthenticationProperties::userProperties() const
Returns the user properties.
See also setUserProperties().