SynchronousMqttServerConnectionHandler class

Connection handler that performs server based connections and disconnections to the hostname in a synchronous manner.

Inheritance

Constructors

SynchronousMqttServerConnectionHandler(dynamic clientEventBus, {@required int maxConnectionAttempts})
Initializes a new instance of the SynchronousMqttConnectionHandler class.

Properties

autoReconnectInProgress bool
Auto reconnect in progress
read / write, inherited
clientEventBus EventBus
The event bus
@protected, read / write, inherited
connection ↔ dynamic
The connection
@protected, read / write, inherited
connectionMessage MqttConnectMessage
read / write, inherited
connectionStatus MqttClientConnectionStatus
Connection status
read / write, inherited
connectTimer MqttCancellableAsyncSleep
The broker connection acknowledgment timer
@protected, read / write, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
maxConnectionAttempts int
Max connection attempts
final, inherited
messageProcessorRegistry Map<MqttMessageType, MessageCallbackFunction>
Registry of message processors
@protected, read / write, inherited
onAutoReconnect AutoReconnectCallback
Auto reconnect callback
read / write, inherited
onBadCertificate bool Function(dynamic certificate)
Callback function to handle bad certificate. if true, ignore the error.
read / write, inherited
onConnected ConnectCallback
Successful connection callback.
read / write, inherited
onDisconnected DisconnectCallback
Unsolicited disconnection callback.
read / write, inherited
port int
read / write, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
secure bool
If set use a secure connection, note TCP only, not websocket.
read / write, inherited
securityContext ↔ dynamic
The security context for secure usage
read / write, inherited
sentMessageCallbacks List<MessageCallbackFunction>
Registry of sent message callbacks
@protected, read / write, inherited
server String
read / write, inherited
useAlternateWebSocketImplementation bool
Alternate websocket implementation. [...]
read / write, inherited
useWebSocket bool
Use a websocket rather than TCP
read / write, inherited
websocketProtocols List<String>
User supplied websocket protocols
@protected, read / write, inherited

Methods

autoReconnect(AutoReconnect reconnectEvent) → void
Auto reconnect
@protected, inherited
close() → void
Closes the connection to the Mqtt message broker.
inherited
connect(String server, int port, MqttConnectMessage message) Future<MqttClientConnectionStatus>
Connect to the specific Mqtt Connection.
inherited
connectAckProcessor(MqttMessage msg) bool
Processes the connect acknowledgement message.
@protected, inherited
disconnect() MqttConnectionState
Disconnects
inherited
internalConnect(String hostname, int port, MqttConnectMessage connectMessage) Future<MqttClientConnectionStatus>
Synchronously connect to the specific Mqtt Connection.
override
messageAvailable(MessageAvailable event) → void
Handles the Message Available event of the connection control for handling non connection messages.
@protected, inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
registerForAllSentMessages(MessageCallbackFunction sentMsgCallback) → void
Registers a callback to be called whenever a message is sent.
inherited
registerForMessage(MqttMessageType msgType, MessageCallbackFunction callback) → void
Registers for the receipt of messages when they arrive.
inherited
sendMessage(MqttMessage message) → void
Sends a message to the broker through the current connection.
inherited
toString() String
Returns a string representation of this object.
inherited
unRegisterForAllSentMessages(MessageCallbackFunction sentMsgCallback) → void
UnRegisters a callback that is called whenever a message is sent.
inherited
unRegisterForMessage(MqttMessageType msgType) → void
UnRegisters for the receipt of messages when they arrive.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited