|
KanoopProtocolQt 1.2.3
Qt HTTP operations and MQTT client library
|
|
Encapsulates connection parameters for an MQTT broker. More...
#include <mqttparameters.h>
Public Member Functions | |
| MqttParameters () | |
| Construct default MQTT parameters. | |
| MqttParameters (const QString &host, int port=1883) | |
| Construct MQTT parameters with the given host and port. | |
| QString | host () const |
| Get the broker hostname. | |
| void | setHost (const QString &value) |
| Set the broker hostname. | |
| int | port () const |
| Get the broker port number. | |
| void | setPort (int value) |
| Set the broker port number. | |
| QString | username () const |
| Get the authentication username. | |
| void | setUsername (const QString &value) |
| Set the authentication username. | |
| QString | password () const |
| Get the authentication password. | |
| void | setPassword (const QString &value) |
| Set the authentication password. | |
| QString | clientId () const |
| Get the MQTT client identifier. | |
| void | setClientId (const QString &value) |
| Set the MQTT client identifier. | |
| QMqttClient::ProtocolVersion | protocolVersion () const |
| Get the MQTT protocol version. | |
| void | setProtocolVersion (QMqttClient::ProtocolVersion value) |
| Set the MQTT protocol version. | |
| bool | useSsl () const |
| Get whether SSL/TLS is enabled. | |
| void | setUseSsl (bool value) |
| Set whether SSL/TLS is enabled. | |
| bool | verifyPeer () const |
| Get whether peer certificate verification is enabled. | |
| void | setVerifyPeer (bool value) |
| Set whether peer certificate verification is enabled. | |
| QSslCertificate | clientCertificate () const |
| Get the client SSL certificate. | |
| void | setClientCertificate (const QSslCertificate &value) |
| Set the client SSL certificate. | |
| void | setClientCertificate (const QString &filename) |
| Set the client SSL certificate from a PEM file. | |
| QSslCertificate | caCertificate () const |
| Get the CA certificate used to verify the broker. | |
| void | setCaCertificate (const QSslCertificate &value) |
| Set the CA certificate used to verify the broker. | |
| void | setCaCertificate (const QString &filename) |
| Set the CA certificate from a PEM file. | |
| QSslKey | privateKey () const |
| Get the client private key for SSL authentication. | |
| void | setPrivateKey (const QSslKey &value) |
| Set the client private key for SSL authentication. | |
| void | setPrivateKey (const QString &filename) |
| Set the client private key from a PEM file. | |
Encapsulates connection parameters for an MQTT broker.
Definition at line 9 of file mqttparameters.h.
|
inline |
Construct default MQTT parameters.
Definition at line 13 of file mqttparameters.h.
|
inline |
Construct MQTT parameters with the given host and port.
| host | The broker hostname or IP address. |
| port | The broker port number (default 1883). |
Definition at line 17 of file mqttparameters.h.
|
inline |
Get the CA certificate used to verify the broker.
Definition at line 88 of file mqttparameters.h.
|
inline |
Get the client SSL certificate.
Definition at line 78 of file mqttparameters.h.
|
inline |
Get the MQTT client identifier.
Definition at line 50 of file mqttparameters.h.
|
inline |
Get the broker hostname.
Definition at line 22 of file mqttparameters.h.
|
inline |
Get the authentication password.
Definition at line 43 of file mqttparameters.h.
|
inline |
|
inline |
Get the client private key for SSL authentication.
Definition at line 98 of file mqttparameters.h.
|
inline |
Get the MQTT protocol version.
Definition at line 57 of file mqttparameters.h.
|
inline |
Set the CA certificate used to verify the broker.
| value | The CA certificate. |
Definition at line 91 of file mqttparameters.h.
| void MqttParameters::setCaCertificate | ( | const QString & | filename | ) |
Set the CA certificate from a PEM file.
| filename | Path to the CA certificate file. |
|
inline |
Set the client SSL certificate.
| value | The client certificate. |
Definition at line 81 of file mqttparameters.h.
| void MqttParameters::setClientCertificate | ( | const QString & | filename | ) |
Set the client SSL certificate from a PEM file.
| filename | Path to the certificate file. |
|
inline |
Set the MQTT client identifier.
| value | The client ID string. |
Definition at line 53 of file mqttparameters.h.
|
inline |
Set the broker hostname.
| value | The broker hostname or IP address. |
Definition at line 25 of file mqttparameters.h.
|
inline |
Set the authentication password.
| value | The password string. |
Definition at line 46 of file mqttparameters.h.
|
inline |
Set the broker port number.
| value | The port number. |
Definition at line 32 of file mqttparameters.h.
|
inline |
Set the client private key for SSL authentication.
| value | The private key. |
Definition at line 101 of file mqttparameters.h.
| void MqttParameters::setPrivateKey | ( | const QString & | filename | ) |
Set the client private key from a PEM file.
| filename | Path to the private key file. |
|
inline |
Set the MQTT protocol version.
| value | The protocol version enum value. |
Definition at line 60 of file mqttparameters.h.
|
inline |
Set the authentication username.
| value | The username string. |
Definition at line 39 of file mqttparameters.h.
|
inline |
Set whether SSL/TLS is enabled.
| value | True to enable SSL. |
Definition at line 67 of file mqttparameters.h.
|
inline |
Set whether peer certificate verification is enabled.
| value | True to enable peer verification. |
Definition at line 74 of file mqttparameters.h.
|
inline |
Get the authentication username.
Definition at line 36 of file mqttparameters.h.
|
inline |
Get whether SSL/TLS is enabled.
Definition at line 64 of file mqttparameters.h.
|
inline |
Get whether peer certificate verification is enabled.
Definition at line 71 of file mqttparameters.h.