Test your knowledge
The CocoaMQTT client library is written in:
Objective-C.
Swift 2.
Swift 3.
In the CocoaMQTT client library, a
CocoaMQTT
instance represents:The synchronous MQTT over WebSockets client.
The asynchronous MQTT over WebSockets client.
The asynchronous MQTT over TCP client (no WebSockets).
Which of the following methods does the CocoaMQTT client call after a message is received from the MQTT server?
func mqtt(_ mqtt: CocoaMQTT, didReceiveMessage message: CocoaMQTTMessage, id: UInt16 ) {
.func didReceiveMessage(_ mqtt: CocoaMQTT, message: CocoaMQTTMessage, id: UInt16 ) {
.func mqtt(didReceiveMessage message: CocoaMQTTMessage, id: UInt16 ) {
.
Which of the following properties of a
CocoaMQTTMessage
instance provides the string representation of the message's payload?Payload
.payloadString
.String
.
Which of the following properties of a
CocoaMQTTMessage
instance provides the message's destination topic?topic
.topicString
.String
.