IMqttConnectionHandler class Null safety

The connection handler interface class





autoReconnectInProgress bool?
Auto reconnect in progress
read / write
connectionMessage MqttConnectMessage?
read / write
connectionStatus MqttClientConnectionStatus
The connection status
hashCode int
The hash code for this object. [...]
read-only, inherited
onAutoReconnect AutoReconnectCallback?
Auto reconnect callback
read / write
onAutoReconnected AutoReconnectCompleteCallback?
Auto reconnected callback
read / write
onBadCertificate ↔ (bool Function?(dynamic certificate)?)
Callback function to handle bad certificate. if true, ignore the error.
read / write
onConnected ConnectCallback?
Successful connection callback
read / write
onDisconnected DisconnectCallback?
Unsolicited disconnection callback
read / write
port int?
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
server String?
read / write


close() → void
Closes a connection.
connect(String server, int port, MqttConnectMessage message) Future<MqttClientConnectionStatus>
Connects to a message broker The broker server to connect to The port to connect to The connect message to use to initiate the connection
disconnect() MqttConnectionState
Runs the disconnection process to stop communicating with a message broker.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
registerForAllSentMessages(MessageCallbackFunction sentMsgCallback) → void
Registers a callback to be executed whenever a message is sent by the connection handler.
registerForMessage(MqttMessageType msgType, MessageCallbackFunction msgProcessorCallback) → void
Register the specified callback to receive messages of a specific type. The type of message that the callback should be sent The callback function that will accept the message type
sendMessage(MqttMessage message) → void
Sends a message to a message broker.
toString() String
A string representation of this object. [...]
unRegisterForAllSentMessages(MessageCallbackFunction sentMsgCallback) → void
UnRegisters a callback that is registerd to be executed whenever a message is sent by the connection handler.
unRegisterForMessage(MqttMessageType msgType) → void
Unregisters the specified callbacks so it not longer receives messages of the specified type. The message type the callback currently receives


operator ==(Object other) bool
The equality operator. [...]