open fun connect(port: Int, host: String, connectHandler: Handler<AsyncResult<MqttConnAckMessage>>): MqttClient
Connects to an MQTT server calling connectHandler after connection
port - port of the MQTT server
host - hostname/ip address of the MQTT server
connectHandler - handler called when the asynchronous connect call ends
Return
current MQTT client instance
open fun connect(port: Int, host: String, serverName: String, connectHandler: Handler<AsyncResult<MqttConnAckMessage>>): MqttClient
Connects to an MQTT server calling connectHandler after connection
port - port of the MQTT server
host - hostname/ip address of the MQTT server
serverName - the SNI server name
connectHandler - handler called when the asynchronous connect call ends
Return
current MQTT client instance