MqttCommunicator class

Inheritance

Constructors

MqttCommunicator({required String server, required int port, String? username, String? password, String? clientIdentifier, bool autoReconnect = true, bool secure = true})

Properties

clientId String
latefinalinherited
hashCode int
The hash code for this object.
no setterinherited
isConnected bool
no setteroverride
isConnecting bool
no setteroverride
isDisconnected bool
no setteroverride
isDisconnecting bool
no setteroverride
messages Stream<FarmMessage>
latefinalinherited
mqtt ↔ MqttClient
latefinal
onAutoReconnect Callback?
Auto reconnect callback, if auto reconnect is selected this callback will be called before auto reconnect processing is invoked to allow the user to perform any pre auto reconnect actions.
getter/setter pairinherited
onAutoReconnected Callback?
Auto reconnected callback, if auto reconnect is selected this callback will be called after auto reconnect processing is completed to allow the user to perform any post auto reconnect actions.
getter/setter pairinherited
onConnected Callback?
Client connect callback, called on successful connect
getter/setter pairinherited
onDisconnected Callback?
Client disconnect callback, called on unsolicited disconnect. This will not be called even if set if [autoReconnect} is set,instead onAutoReconnect will be called.
getter/setter pairinherited
password String?
latefinalinherited
port int
latefinalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
server String
latefinalinherited
username String?
latefinalinherited

Methods

connect() Future<void>
override
disconnect() Future<void>
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
publish(String topic, String data, {CommunicatorQos qos = CommunicatorQos.atLeastOnce, bool retain = false}) int
override
subscribe(String topic, CommunicatorQos qos) int?
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited