-
-
Notifications
You must be signed in to change notification settings - Fork 36
Open
Description
The init and connect functions of MQTTNewConnection should be considered internal. The public API should be a withConnection style function which is supplied a closure to run using the generated connection. When you exit the closure a DISCONNECT is sent and the connection is closed eg
MQTTNewConnection.withConnection { connection in
connection.publish(to: "MyTopic", payload: ByteBuffer(string: "Testing"))
}Metadata
Metadata
Assignees
Labels
No labels