Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext
boost::mqtt5::mqtt_client::credentials

Assign credentials that will be used to connect to a Broker.

Synopsis
boost::mqtt5::mqtt_client&
credentials(
    std::string client_id,
    std::string username = "",
    std::string password = "");
Description

Credentials consist of a unique Client Identifier and, optionally, a User Name and Password.

Attention

This function has no effect while the Client is running. Call it before async_run, or after cancel or async_disconnect and before invoking async_run again.


PrevUpHomeNext