MqttMonitor/Documentation/source/Plugin_Mqtt_Monitor.MqttMonitor.MqttClient.html

branch
eric7
changeset 143
51bc5bcc672a
parent 141
864edfb1bb63
equal deleted inserted replaced
142:cf158867ed89 143:51bc5bcc672a
25 </table> 25 </table>
26 26
27 <h3>Functions</h3> 27 <h3>Functions</h3>
28 <table> 28 <table>
29 <tr> 29 <tr>
30 <td><a href="#mqttConnackMessage">mqttConnackMessage</a></td>
31 <td>Module function to get the string associated with a CONNACK result.</td>
32 </tr>
33 <tr>
34 <td><a href="#mqttErrorMessage">mqttErrorMessage</a></td> 30 <td><a href="#mqttErrorMessage">mqttErrorMessage</a></td>
35 <td>Module function to get the error string associated with an MQTT error number.</td> 31 <td>Module function to get the error string associated with an MQTT error number.</td>
36 </tr> 32 </tr>
37 <tr> 33 <tr>
38 <td><a href="#mqttLogLevelString">mqttLogLevelString</a></td> 34 <td><a href="#mqttLogLevelString">mqttLogLevelString</a></td>
54 <dt>connectTimeout()</dt> 50 <dt>connectTimeout()</dt>
55 <dd> 51 <dd>
56 emitted to indicate, that a connection attempt 52 emitted to indicate, that a connection attempt
57 timed out 53 timed out
58 </dd> 54 </dd>
59 <dt>onConnectV3(flags, rc)</dt> 55 <dt>onConnect(connectFlags, rc, packetType, properties)</dt>
60 <dd> 56 <dd>
61 emitted after the client has connected to 57 emitted after the
62 the broker (MQTT v3) 58 client has connected to the broker
63 </dd> 59 </dd>
64 <dt>onConnectV5(flags, rc, packetType, properties emitted after theclient has connected to the broker (MQTT v5)</dt> 60 <dt>onDisconnected(rc, packetType)</dt>
65 <dd>
66
67 </dd>
68 <dt>onDisconnectedV3(rc)</dt>
69 <dd>
70 emitted after the client has disconnected from
71 the broker (MQTT v3)
72 </dd>
73 <dt>onDisconnectedV5(rc, packetType)</dt>
74 <dd> 61 <dd>
75 emitted after the client has 62 emitted after the client has
76 disconnected from the broker (MQTT v5) 63 disconnected from the broker
77 </dd> 64 </dd>
78 <dt>onLog(level, message)</dt> 65 <dt>onLog(level, message)</dt>
79 <dd> 66 <dd>
80 emitted to send client log data 67 emitted to send client log data
81 </dd> 68 </dd>
82 <dt>onMessageV3(topic, payload, qos, retain)</dt> 69 <dt>onMessage(topic, payload, qos, retain, properties)</dt>
83 <dd>
84 emitted after a message
85 has been received by the client (MQTT v3)
86 </dd>
87 <dt>onMessageV5(topic, payload, qos, retain, properties)</dt>
88 <dd> 70 <dd>
89 emitted after 71 emitted after
90 a message has been received by the client (MQTT v5) 72 a message has been received by the client
91 </dd> 73 </dd>
92 <dt>onPublish(mid)</dt> 74 <dt>onPublish(mid)</dt>
93 <dd> 75 <dd>
94 emitted after a message has been published 76 emitted after a message has been published
95 </dd> 77 </dd>
96 <dt>onSubscribeV3(mid, grantedQos)</dt> 78 <dt>onSubscribe(mid, reasonCodes, properties)</dt>
97 <dd>
98 emitted after the client has
99 subscribed to some topics (MQTT v3)
100 </dd>
101 <dt>onSubscribeV5(mid, reasonCodes, properties)</dt>
102 <dd> 79 <dd>
103 emitted after the 80 emitted after the
104 client has subscribed to some topics (MQTT v5) 81 client has subscribed to some topics
105 </dd> 82 </dd>
106 <dt>onUnsubscribeV3(mid)</dt> 83 <dt>onUnsubscribe(mid)</dt>
107 <dd> 84 <dd>
108 emitted after the client has unsubscribed from 85 emitted after the client has unsubscribed from
109 some topics (MQTT v3) 86 some topics (MQTT v3)
110 </dd> 87 </dd>
111 <dt>onUnsubscribeV5(mid, rc, packetType, properties)</dt> 88 <dt>onUnsubscribe(mid, rc, packetType, properties)</dt>
112 <dd> 89 <dd>
113 emitted after the 90 emitted after the
114 client has unsubscribed from some topics (MQTT v5) 91 client has unsubscribed from some topics (MQTT v5)
115 </dd> 92 </dd>
116 </dl> 93 </dl>
153 <tr> 130 <tr>
154 <td><a href="#MqttClient.__initCallbacks">__initCallbacks</a></td> 131 <td><a href="#MqttClient.__initCallbacks">__initCallbacks</a></td>
155 <td>Private method to initialize the MQTT callback methods.</td> 132 <td>Private method to initialize the MQTT callback methods.</td>
156 </tr> 133 </tr>
157 <tr> 134 <tr>
158 <td><a href="#MqttClient.__onConnectV3">__onConnectV3</a></td> 135 <td><a href="#MqttClient.__onConnect">__onConnect</a></td>
159 <td>Private method to handle the connect to the broker (MQTT v3.1 and v3.1.1).</td> 136 <td>Private method to handle the connect to the broker.</td>
160 </tr> 137 </tr>
161 <tr> 138 <tr>
162 <td><a href="#MqttClient.__onConnectV5">__onConnectV5</a></td> 139 <td><a href="#MqttClient.__onDisconnected">__onDisconnected</a></td>
163 <td>Private method to handle the connect to the broker (MQTT v5.0).</td> 140 <td>Private method to handle the disconnect from the broker.</td>
164 </tr>
165 <tr>
166 <td><a href="#MqttClient.__onDisconnectedV3">__onDisconnectedV3</a></td>
167 <td>Private method to handle the disconnect from the broker (MQTT v3.1 and v3.1.1).</td>
168 </tr>
169 <tr>
170 <td><a href="#MqttClient.__onDisconnectedV5">__onDisconnectedV5</a></td>
171 <td>Private method to handle the disconnect from the broker (MQTT v5.0).</td>
172 </tr> 141 </tr>
173 <tr> 142 <tr>
174 <td><a href="#MqttClient.__onLog">__onLog</a></td> 143 <td><a href="#MqttClient.__onLog">__onLog</a></td>
175 <td>Private method to handle a log event (MQTT v3.1, v3.1.1 and v5.0).</td> 144 <td>Private method to handle a log event.</td>
176 </tr> 145 </tr>
177 <tr> 146 <tr>
178 <td><a href="#MqttClient.__onMessageV3">__onMessageV3</a></td> 147 <td><a href="#MqttClient.__onMessage">__onMessage</a></td>
179 <td>Private method to handle a new message received from the broker (MQTT v3.1 and v3.1.1).</td> 148 <td>Private method to handle a new message received from the broker.</td>
180 </tr>
181 <tr>
182 <td><a href="#MqttClient.__onMessageV5">__onMessageV5</a></td>
183 <td>Private method to handle a new message received from the broker (MQTT v5.0).</td>
184 </tr> 149 </tr>
185 <tr> 150 <tr>
186 <td><a href="#MqttClient.__onPublish">__onPublish</a></td> 151 <td><a href="#MqttClient.__onPublish">__onPublish</a></td>
187 <td>Private method to handle the publishing of a message (MQTT v3.1, v3.1.1 and v5.0).</td> 152 <td>Private method to handle the publishing of a message.</td>
188 </tr> 153 </tr>
189 <tr> 154 <tr>
190 <td><a href="#MqttClient.__onSubscribeV3">__onSubscribeV3</a></td> 155 <td><a href="#MqttClient.__onSubscribe">__onSubscribe</a></td>
191 <td>Private method to handle a subscribe event (MQTT v3.1 and v3.1.1).</td> 156 <td>Private method to handle a subscribe event.</td>
192 </tr> 157 </tr>
193 <tr> 158 <tr>
194 <td><a href="#MqttClient.__onSubscribeV5">__onSubscribeV5</a></td> 159 <td><a href="#MqttClient.__onUnsubscribe">__onUnsubscribe</a></td>
195 <td>Private method to handle a subscribe event (MQTT v5.0).</td> 160 <td>Private method to handle an unsubscribe event.</td>
196 </tr>
197 <tr>
198 <td><a href="#MqttClient.__onUnsubscribeV3">__onUnsubscribeV3</a></td>
199 <td>Private method to handle an unsubscribe event (MQTT v3.1 and v3.1.1).</td>
200 </tr>
201 <tr>
202 <td><a href="#MqttClient.__onUnsubscribeV5">__onUnsubscribeV5</a></td>
203 <td>Private method to handle an unsubscribe event (MQTT v5.0).</td>
204 </tr> 161 </tr>
205 <tr> 162 <tr>
206 <td><a href="#MqttClient.clearLastWill">clearLastWill</a></td> 163 <td><a href="#MqttClient.clearLastWill">clearLastWill</a></td>
207 <td>Public method to remove a will that was previously configured with setLastWill().</td> 164 <td>Public method to remove a will that was previously configured with setLastWill().</td>
208 </tr> 165 </tr>
377 Properties 334 Properties
378 </dd> 335 </dd>
379 </dl> 336 </dl>
380 <a NAME="MqttClient.__initCallbacks" ID="MqttClient.__initCallbacks"></a> 337 <a NAME="MqttClient.__initCallbacks" ID="MqttClient.__initCallbacks"></a>
381 <h4>MqttClient.__initCallbacks</h4> 338 <h4>MqttClient.__initCallbacks</h4>
382 <b>__initCallbacks</b>(<i>protocol</i>) 339 <b>__initCallbacks</b>(<i></i>)
383 <p> 340 <p>
384 Private method to initialize the MQTT callback methods. 341 Private method to initialize the MQTT callback methods.
385 </p> 342 </p>
386 343
387 <dl> 344 <a NAME="MqttClient.__onConnect" ID="MqttClient.__onConnect"></a>
388 345 <h4>MqttClient.__onConnect</h4>
389 <dt><i>protocol</i> (MqttProtocols)</dt> 346 <b>__onConnect</b>(<i>_client, _userdata, connectFlags, rc, properties, </i>)
390 <dd> 347 <p>
391 MQTT protocol version 348 Private method to handle the connect to the broker.
392 </dd> 349 </p>
393 </dl> 350
394 <a NAME="MqttClient.__onConnectV3" ID="MqttClient.__onConnectV3"></a> 351 <dl>
395 <h4>MqttClient.__onConnectV3</h4> 352
396 <b>__onConnectV3</b>(<i>client, userdata, flags, rc, properties=None, </i>) 353 <dt><i>_client</i> (paho.mqtt.Client)</dt>
397 <p> 354 <dd>
398 Private method to handle the connect to the broker (MQTT v3.1 and v3.1.1). 355 reference to the client object (unused)
399 </p> 356 </dd>
400 357 <dt><i>_userdata</i> (Any)</dt>
401 <dl> 358 <dd>
402 359 user data (unused)
403 <dt><i>client</i> (paho.mqtt.Client)</dt> 360 </dd>
404 <dd> 361 <dt><i>connectFlags</i> (mqtt.ConnectFlags)</dt>
405 reference to the client object 362 <dd>
406 </dd> 363 response flags sent by the broker
407 <dt><i>userdata</i> (Any)</dt> 364 </dd>
408 <dd> 365 <dt><i>rc</i> (paho.mqtt.ReasonCodes)</dt>
409 user data 366 <dd>
410 </dd> 367 reason code
411 <dt><i>flags</i> (dict)</dt> 368 </dd>
369 <dt><i>properties</i> (dict)</dt>
370 <dd>
371 MQTT v5.0 properties received from the broker
372 </dd>
373 </dl>
374 <a NAME="MqttClient.__onDisconnected" ID="MqttClient.__onDisconnected"></a>
375 <h4>MqttClient.__onDisconnected</h4>
376 <b>__onDisconnected</b>(<i>_client, _userdata, _flags, rc, _properties=None, </i>)
377 <p>
378 Private method to handle the disconnect from the broker.
379 </p>
380
381 <dl>
382
383 <dt><i>_client</i> (paho.mqtt.Client)</dt>
384 <dd>
385 reference to the client object (unused)
386 </dd>
387 <dt><i>_userdata</i> (Any)</dt>
388 <dd>
389 user data (unused)
390 </dd>
391 <dt><i>_flags</i> (dict)</dt>
412 <dd> 392 <dd>
413 dictionary containing the response flags sent by the broker 393 dictionary containing the response flags sent by the broker
414 </dd> 394 (unused)
415 <dt><i>rc</i> (int)</dt>
416 <dd>
417 result code
418 </dd>
419 <dt><i>properties</i> (dict (optional))</dt>
420 <dd>
421 optional properties (defaults to None)
422 </dd>
423 </dl>
424 <a NAME="MqttClient.__onConnectV5" ID="MqttClient.__onConnectV5"></a>
425 <h4>MqttClient.__onConnectV5</h4>
426 <b>__onConnectV5</b>(<i>client, userdata, flags, rc, properties=None, </i>)
427 <p>
428 Private method to handle the connect to the broker (MQTT v5.0).
429 </p>
430
431 <dl>
432
433 <dt><i>client</i> (paho.mqtt.Client)</dt>
434 <dd>
435 reference to the client object
436 </dd>
437 <dt><i>userdata</i> (Any)</dt>
438 <dd>
439 user data
440 </dd>
441 <dt><i>flags</i> (dict)</dt>
442 <dd>
443 dictionary containing the response flags sent by the broker
444 </dd>
445 <dt><i>rc</i> (paho.mqtt.ReasonCodes)</dt>
446 <dd>
447 reason code
448 </dd>
449 <dt><i>properties</i> (dict (optional))</dt>
450 <dd>
451 optional properties (defaults to None)
452 </dd>
453 </dl>
454 <a NAME="MqttClient.__onDisconnectedV3" ID="MqttClient.__onDisconnectedV3"></a>
455 <h4>MqttClient.__onDisconnectedV3</h4>
456 <b>__onDisconnectedV3</b>(<i>client, userdata, rc, </i>)
457 <p>
458 Private method to handle the disconnect from the broker (MQTT v3.1 and v3.1.1).
459 </p>
460
461 <dl>
462
463 <dt><i>client</i> (paho.mqtt.Client)</dt>
464 <dd>
465 reference to the client object
466 </dd>
467 <dt><i>userdata</i> (Any)</dt>
468 <dd>
469 user data
470 </dd>
471 <dt><i>rc</i> (int)</dt>
472 <dd>
473 result code
474 </dd>
475 </dl>
476 <a NAME="MqttClient.__onDisconnectedV5" ID="MqttClient.__onDisconnectedV5"></a>
477 <h4>MqttClient.__onDisconnectedV5</h4>
478 <b>__onDisconnectedV5</b>(<i>client, userdata, rc, properties=None, </i>)
479 <p>
480 Private method to handle the disconnect from the broker (MQTT v5.0).
481 </p>
482
483 <dl>
484
485 <dt><i>client</i> (paho.mqtt.Client)</dt>
486 <dd>
487 reference to the client object
488 </dd>
489 <dt><i>userdata</i> (Any)</dt>
490 <dd>
491 user data
492 </dd> 395 </dd>
493 <dt><i>rc</i> (int or paho.mqtt.ReasonCodes)</dt> 396 <dt><i>rc</i> (int or paho.mqtt.ReasonCodes)</dt>
494 <dd> 397 <dd>
495 result code or reason code 398 result code or reason code
496 </dd> 399 </dd>
497 <dt><i>properties</i> (dict (optional))</dt> 400 <dt><i>_properties</i> (dict (optional))</dt>
498 <dd> 401 <dd>
499 optional properties (defaults to None) 402 MQTT v5.0 properties received from the broker
403 (defaults to None) (unused)
500 </dd> 404 </dd>
501 </dl> 405 </dl>
502 <a NAME="MqttClient.__onLog" ID="MqttClient.__onLog"></a> 406 <a NAME="MqttClient.__onLog" ID="MqttClient.__onLog"></a>
503 <h4>MqttClient.__onLog</h4> 407 <h4>MqttClient.__onLog</h4>
504 <b>__onLog</b>(<i>client, userdata, level, buf, </i>) 408 <b>__onLog</b>(<i>_client, _userdata, level, buf, </i>)
505 <p> 409 <p>
506 Private method to handle a log event (MQTT v3.1, v3.1.1 and v5.0). 410 Private method to handle a log event.
507 </p> 411 </p>
508 412
509 <dl> 413 <dl>
510 414
511 <dt><i>client</i> (paho.mqtt.Client)</dt> 415 <dt><i>_client</i> (paho.mqtt.Client)</dt>
512 <dd> 416 <dd>
513 reference to the client object 417 reference to the client object (unused)
514 </dd> 418 </dd>
515 <dt><i>userdata</i> (Any)</dt> 419 <dt><i>_userdata</i> (Any)</dt>
516 <dd> 420 <dd>
517 user data 421 user data (unused)
518 </dd> 422 </dd>
519 <dt><i>level</i> (int)</dt> 423 <dt><i>level</i> (int)</dt>
520 <dd> 424 <dd>
521 severity of the log message 425 severity of the log message
522 </dd> 426 </dd>
523 <dt><i>buf</i> (str)</dt> 427 <dt><i>buf</i> (str)</dt>
524 <dd> 428 <dd>
525 log message 429 log message
526 </dd> 430 </dd>
527 </dl> 431 </dl>
528 <a NAME="MqttClient.__onMessageV3" ID="MqttClient.__onMessageV3"></a> 432 <a NAME="MqttClient.__onMessage" ID="MqttClient.__onMessage"></a>
529 <h4>MqttClient.__onMessageV3</h4> 433 <h4>MqttClient.__onMessage</h4>
530 <b>__onMessageV3</b>(<i>client, userdata, message, </i>) 434 <b>__onMessage</b>(<i>_client, _userdata, message, </i>)
531 <p> 435 <p>
532 Private method to handle a new message received from the broker (MQTT v3.1 436 Private method to handle a new message received from the broker.
533 and v3.1.1). 437 </p>
534 </p> 438
535 439 <dl>
536 <dl> 440
537 441 <dt><i>_client</i> (paho.mqtt.Client)</dt>
538 <dt><i>client</i> (paho.mqtt.Client)</dt> 442 <dd>
539 <dd> 443 reference to the client object (unused)
540 reference to the client object 444 </dd>
541 </dd> 445 <dt><i>_userdata</i> (Any)</dt>
542 <dt><i>userdata</i> (Any)</dt> 446 <dd>
543 <dd> 447 user data (unused)
544 user data
545 </dd>
546 <dt><i>message</i> (paho.mqtt.MQTTMessage)</dt>
547 <dd>
548 received message object
549 </dd>
550 </dl>
551 <a NAME="MqttClient.__onMessageV5" ID="MqttClient.__onMessageV5"></a>
552 <h4>MqttClient.__onMessageV5</h4>
553 <b>__onMessageV5</b>(<i>client, userdata, message, </i>)
554 <p>
555 Private method to handle a new message received from the broker (MQTT v5.0).
556 </p>
557
558 <dl>
559
560 <dt><i>client</i> (paho.mqtt.Client)</dt>
561 <dd>
562 reference to the client object
563 </dd>
564 <dt><i>userdata</i> (Any)</dt>
565 <dd>
566 user data
567 </dd> 448 </dd>
568 <dt><i>message</i> (paho.mqtt.MQTTMessage)</dt> 449 <dt><i>message</i> (paho.mqtt.MQTTMessage)</dt>
569 <dd> 450 <dd>
570 received message object 451 received message object
571 </dd> 452 </dd>
572 </dl> 453 </dl>
573 <a NAME="MqttClient.__onPublish" ID="MqttClient.__onPublish"></a> 454 <a NAME="MqttClient.__onPublish" ID="MqttClient.__onPublish"></a>
574 <h4>MqttClient.__onPublish</h4> 455 <h4>MqttClient.__onPublish</h4>
575 <b>__onPublish</b>(<i>client, userdata, mid, </i>) 456 <b>__onPublish</b>(<i>_client, _userdata, mid, _reasonCode, _properties, </i>)
576 <p> 457 <p>
577 Private method to handle the publishing of a message (MQTT v3.1, v3.1.1 458 Private method to handle the publishing of a message.
578 and v5.0). 459 </p>
579 </p> 460
580 461 <dl>
581 <dl> 462
582 463 <dt><i>_client</i> (paho.mqtt.Client)</dt>
583 <dt><i>client</i> (paho.mqtt.Client)</dt> 464 <dd>
584 <dd> 465 reference to the client object (unused)
585 reference to the client object 466 </dd>
586 </dd> 467 <dt><i>_userdata</i> (Any)</dt>
587 <dt><i>userdata</i> (Any)</dt> 468 <dd>
588 <dd> 469 user data (unused)
589 user data
590 </dd> 470 </dd>
591 <dt><i>mid</i> (int)</dt> 471 <dt><i>mid</i> (int)</dt>
592 <dd> 472 <dd>
593 message ID 473 message ID
594 </dd> 474 </dd>
595 </dl> 475 <dt><i>_reasonCode</i> (paho.mqtt.ReasonCodes)</dt>
596 <a NAME="MqttClient.__onSubscribeV3" ID="MqttClient.__onSubscribeV3"></a> 476 <dd>
597 <h4>MqttClient.__onSubscribeV3</h4> 477 reason code (unused)
598 <b>__onSubscribeV3</b>(<i>client, userdata, mid, grantedQos, </i>) 478 </dd>
599 <p> 479 <dt><i>_properties</i> (dict)</dt>
600 Private method to handle a subscribe event (MQTT v3.1 and v3.1.1). 480 <dd>
601 </p> 481 MQTT v5.0 properties received from the broker (unused)
602 482 </dd>
603 <dl> 483 </dl>
604 484 <a NAME="MqttClient.__onSubscribe" ID="MqttClient.__onSubscribe"></a>
605 <dt><i>client</i> (paho.mqtt.Client)</dt> 485 <h4>MqttClient.__onSubscribe</h4>
606 <dd> 486 <b>__onSubscribe</b>(<i>_client, _userdata, mid, reasonCodes, properties, </i>)
607 reference to the client object 487 <p>
608 </dd> 488 Private method to handle a subscribe event.
609 <dt><i>userdata</i> (Any)</dt> 489 </p>
610 <dd> 490
611 user data 491 <dl>
492
493 <dt><i>_client</i> (paho.mqtt.Client)</dt>
494 <dd>
495 reference to the client object (unused)
496 </dd>
497 <dt><i>_userdata</i> (Any)</dt>
498 <dd>
499 user data (unused)
612 </dd> 500 </dd>
613 <dt><i>mid</i> (int)</dt> 501 <dt><i>mid</i> (int)</dt>
614 <dd> 502 <dd>
615 message ID 503 message ID
616 </dd> 504 </dd>
617 <dt><i>grantedQos</i> (list of int)</dt> 505 <dt><i>reasonCodes</i> (list of paho.mqtt.ReasonCodes)</dt>
618 <dd> 506 <dd>
619 list of granted QoS for each subscription request 507 list of reason code for each subscribed topic
620 </dd> 508 </dd>
621 </dl> 509 <dt><i>properties</i> (dict)</dt>
622 <a NAME="MqttClient.__onSubscribeV5" ID="MqttClient.__onSubscribeV5"></a> 510 <dd>
623 <h4>MqttClient.__onSubscribeV5</h4> 511 MQTT v5.0 properties received from the broker
624 <b>__onSubscribeV5</b>(<i>client, userdata, mid, reasonCodes, properties=None, </i>) 512 </dd>
625 <p> 513 </dl>
626 Private method to handle a subscribe event (MQTT v5.0). 514 <a NAME="MqttClient.__onUnsubscribe" ID="MqttClient.__onUnsubscribe"></a>
627 </p> 515 <h4>MqttClient.__onUnsubscribe</h4>
628 516 <b>__onUnsubscribe</b>(<i>_client, _userdata, mid, reasonCodes, properties, </i>)
629 <dl> 517 <p>
630 518 Private method to handle an unsubscribe event.
631 <dt><i>client</i> (paho.mqtt.Client)</dt> 519 </p>
632 <dd> 520
633 reference to the client object 521 <dl>
634 </dd> 522
635 <dt><i>userdata</i> (Any)</dt> 523 <dt><i>_client</i> (paho.mqtt.Client)</dt>
636 <dd> 524 <dd>
637 user data 525 reference to the client object (unused)
526 </dd>
527 <dt><i>_userdata</i> (Any)</dt>
528 <dd>
529 user data (unused)
638 </dd> 530 </dd>
639 <dt><i>mid</i> (int)</dt> 531 <dt><i>mid</i> (int)</dt>
640 <dd> 532 <dd>
641 message ID 533 message ID
642 </dd> 534 </dd>
643 <dt><i>reasonCodes</i> (list of paho.mqtt.ReasonCodes)</dt> 535 <dt><i>reasonCodes</i> (list of paho.mqtt.ReasonCodes)</dt>
644 <dd> 536 <dd>
645 list of reason code for each subscribed topic
646 </dd>
647 <dt><i>properties</i> (dict (optional))</dt>
648 <dd>
649 optional properties (defaults to None)
650 </dd>
651 </dl>
652 <a NAME="MqttClient.__onUnsubscribeV3" ID="MqttClient.__onUnsubscribeV3"></a>
653 <h4>MqttClient.__onUnsubscribeV3</h4>
654 <b>__onUnsubscribeV3</b>(<i>client, userdata, mid, </i>)
655 <p>
656 Private method to handle an unsubscribe event (MQTT v3.1 and v3.1.1).
657 </p>
658
659 <dl>
660
661 <dt><i>client</i> (paho.mqtt.Client)</dt>
662 <dd>
663 reference to the client object
664 </dd>
665 <dt><i>userdata</i> (Any)</dt>
666 <dd>
667 user data
668 </dd>
669 <dt><i>mid</i> (int)</dt>
670 <dd>
671 message ID
672 </dd>
673 </dl>
674 <a NAME="MqttClient.__onUnsubscribeV5" ID="MqttClient.__onUnsubscribeV5"></a>
675 <h4>MqttClient.__onUnsubscribeV5</h4>
676 <b>__onUnsubscribeV5</b>(<i>client, userdata, mid, properties, reasonCodes, </i>)
677 <p>
678 Private method to handle an unsubscribe event (MQTT v5.0).
679 </p>
680
681 <dl>
682
683 <dt><i>client</i> (paho.mqtt.Client)</dt>
684 <dd>
685 reference to the client object
686 </dd>
687 <dt><i>userdata</i> (Any)</dt>
688 <dd>
689 user data
690 </dd>
691 <dt><i>mid</i> (int)</dt>
692 <dd>
693 message ID
694 </dd>
695 <dt><i>properties</i> (dict (optional))</dt>
696 <dd>
697 optional properties (defaults to None)
698 </dd>
699 <dt><i>reasonCodes</i> (list of paho.mqtt.ReasonCodes)</dt>
700 <dd>
701 list of reason code for each unsubscribed topic 537 list of reason code for each unsubscribed topic
538 </dd>
539 <dt><i>properties</i> (dict)</dt>
540 <dd>
541 MQTT v5.0 properties received from the broker
702 </dd> 542 </dd>
703 </dl> 543 </dl>
704 <a NAME="MqttClient.clearLastWill" ID="MqttClient.clearLastWill"></a> 544 <a NAME="MqttClient.clearLastWill" ID="MqttClient.clearLastWill"></a>
705 <h4>MqttClient.clearLastWill</h4> 545 <h4>MqttClient.clearLastWill</h4>
706 <b>clearLastWill</b>(<i></i>) 546 <b>clearLastWill</b>(<i></i>)
1086 </dd> 926 </dd>
1087 </dl> 927 </dl>
1088 <div align="right"><a href="#top">Up</a></div> 928 <div align="right"><a href="#top">Up</a></div>
1089 <hr /> 929 <hr />
1090 <hr /> 930 <hr />
1091 <a NAME="mqttConnackMessage" ID="mqttConnackMessage"></a>
1092 <h2>mqttConnackMessage</h2>
1093 <b>mqttConnackMessage</b>(<i>connackCode</i>)
1094 <p>
1095 Module function to get the string associated with a CONNACK result.
1096 </p>
1097
1098 <dl>
1099
1100 <dt><i>connackCode</i> (int)</dt>
1101 <dd>
1102 result code of the connection request
1103 </dd>
1104 </dl>
1105 <dl>
1106 <dt>Return:</dt>
1107 <dd>
1108 textual representation for the result code
1109 </dd>
1110 </dl>
1111 <dl>
1112 <dt>Return Type:</dt>
1113 <dd>
1114 str
1115 </dd>
1116 </dl>
1117 <div align="right"><a href="#top">Up</a></div>
1118 <hr />
1119 <hr />
1120 <a NAME="mqttErrorMessage" ID="mqttErrorMessage"></a> 931 <a NAME="mqttErrorMessage" ID="mqttErrorMessage"></a>
1121 <h2>mqttErrorMessage</h2> 932 <h2>mqttErrorMessage</h2>
1122 <b>mqttErrorMessage</b>(<i>mqttErrno</i>) 933 <b>mqttErrorMessage</b>(<i>mqttErrno</i>)
1123 <p> 934 <p>
1124 Module function to get the error string associated with an MQTT error 935 Module function to get the error string associated with an MQTT error

eric ide

mercurial