Creates a disconnected client from the given options.
Connects to the broker and starts the background event loop.
Closes the connection and stops the background event loop.
Reports whether the client currently holds an active connection.
Publishes a payload to a topic, resolving once it is queued for the broker.
Optionaloptions: MqttPublishOptions | nullPublishes a payload to a topic, resolving once the broker acknowledges it: its
PUBACK at AtLeastOnce, its PUBCOMP at ExactlyOnce, and once the connection
has taken it at AtMostOnce, where MQTT acknowledges nothing. It rejects if the
connection ends first, when the message may or may not have arrived.
Optionaloptions: MqttPublishOptions | nullAwaits the next message from any subscribed topic, or null once the
connection has ended. A connection that ends on its own rejects one receive
with the reason.
OptionaltimeoutMs: number | null
how long to wait before rejecting; a message that arrives later waits for the next receive.
Subscribes to a topic filter.
An MQTT client transport backed by the native pamoja core.