MqttConnectionBase<T extends Object> class
abstract
The MQTT client connection base class
- Implementers
Constructors
- MqttConnectionBase(EventBus? clientEventBus)
- Default constructor
- MqttConnectionBase.fromConnect(String server, int port, EventBus? clientEventBus)
- Initializes a new instance of the MqttConnection class.
Properties
- client ↔ T?
-
The socket that maintains the connection to the MQTT broker.
getter/setter pair
- clientEventBus ↔ EventBus?
-
The event bus
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
-
listeners
↔ List<
StreamSubscription> -
The stream controller as returned when clients listen.
getter/setter pair
- messageStream ↔ MqttByteBuffer
-
The read buffer
getter/setter pair
- onDisconnected ↔ DisconnectCallback?
-
Unsolicited disconnection callback
getter/setter pair
- readWrapper ↔ ReadWrapper?
-
The read wrapper
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
closeClient(
) → void - Closes the socket immediately, must be overridden in connection classes
-
connect(
String server, int port) → Future< void> - Connect, must be overridden in connection classes
-
connectAuto(
String server, int port) → Future< void> - Connect for auto reconnect , must be overridden in connection classes
-
disconnect(
{bool auto = false}) → void - User requested or auto disconnect disconnection
-
disposeClient(
) → void - Closes and dispose the socket immediately, must be overridden in connection classes
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onDone(
) → void - OnDone listener callback
-
onError(
dynamic error) → void - OnError listener callback
-
send(
MqttByteBuffer message) → void - Sends the message in the stream to the broker.
-
stopListening(
) → void - Stops listening the socket immediately, must be overridden in connection classes
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited