12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313 |
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
- <meta http-equiv="X-UA-Compatible" content="IE=9"/>
- <meta name="generator" content="Doxygen 1.8.17"/>
- <meta name="viewport" content="width=device-width, initial-scale=1"/>
- <title>MQTT C Client Libraries Internals: MQTTProtocolClient.c File Reference</title>
- <link href="tabs.css" rel="stylesheet" type="text/css"/>
- <script type="text/javascript" src="jquery.js"></script>
- <script type="text/javascript" src="dynsections.js"></script>
- <link href="search/search.css" rel="stylesheet" type="text/css"/>
- <script type="text/javascript" src="search/searchdata.js"></script>
- <script type="text/javascript" src="search/search.js"></script>
- <link href="doxygen.css" rel="stylesheet" type="text/css" />
- </head>
- <body>
- <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
- <div id="titlearea">
- <table cellspacing="0" cellpadding="0">
- <tbody>
- <tr style="height: 56px;">
- <td id="projectlogo"><img alt="Logo" src="pahologo.png"/></td>
- <td id="projectalign" style="padding-left: 0.5em;">
- <div id="projectname">MQTT C Client Libraries Internals
- </div>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- <!-- end header part -->
- <!-- Generated by Doxygen 1.8.17 -->
- <script type="text/javascript">
- /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
- var searchBox = new SearchBox("searchBox", "search",false,'Search');
- /* @license-end */
- </script>
- <script type="text/javascript" src="menudata.js"></script>
- <script type="text/javascript" src="menu.js"></script>
- <script type="text/javascript">
- /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
- $(function() {
- initMenu('',true,false,'search.php','Search');
- $(document).ready(function() { init_search(); });
- });
- /* @license-end */</script>
- <div id="main-nav"></div>
- <!-- window showing the filter options -->
- <div id="MSearchSelectWindow"
- onmouseover="return searchBox.OnSearchSelectShow()"
- onmouseout="return searchBox.OnSearchSelectHide()"
- onkeydown="return searchBox.OnSearchSelectKey(event)">
- </div>
- <!-- iframe showing the search results (closed by default) -->
- <div id="MSearchResultsWindow">
- <iframe src="javascript:void(0)" frameborder="0"
- name="MSearchResults" id="MSearchResults">
- </iframe>
- </div>
- </div><!-- top -->
- <div class="header">
- <div class="summary">
- <a href="#nested-classes">Data Structures</a> |
- <a href="#define-members">Macros</a> |
- <a href="#func-members">Functions</a> |
- <a href="#var-members">Variables</a> </div>
- <div class="headertitle">
- <div class="title">MQTTProtocolClient.c File Reference</div> </div>
- </div><!--header-->
- <div class="contents">
- <p>Functions dealing with the MQTT protocol exchanges.
- <a href="#details">More...</a></p>
- <div class="textblock"><code>#include <stdlib.h></code><br />
- <code>#include <string.h></code><br />
- <code>#include <stdint.h></code><br />
- <code>#include "MQTTProtocolClient.h"</code><br />
- <code>#include "MQTTPersistence.h"</code><br />
- <code>#include "Socket.h"</code><br />
- <code>#include "SocketBuffer.h"</code><br />
- <code>#include "StackTrace.h"</code><br />
- <code>#include "Heap.h"</code><br />
- </div><div class="textblock"><div class="dynheader">
- Include dependency graph for MQTTProtocolClient.c:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c__incl.png" border="0" usemap="#MQTTProtocolClient_8c" alt=""/></div>
- <map name="MQTTProtocolClient_8c" id="MQTTProtocolClient_8c">
- <area shape="rect" title="Functions dealing with the MQTT protocol exchanges." alt="" coords="49,5,200,32"/>
- <area shape="rect" title=" " alt="" coords="5,80,68,107"/>
- <area shape="rect" title=" " alt="" coords="93,80,157,107"/>
- <area shape="rect" title=" " alt="" coords="181,80,245,107"/>
- </map>
- </div>
- </div><table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
- Data Structures</h2></td></tr>
- <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structAckRequest.html">AckRequest</a></td></tr>
- <tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
- </table><table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
- Macros</h2></td></tr>
- <tr class="memitem:a2d017cd3beb218080a7988e2deed2a11"><td class="memItemLeft" align="right" valign="top"><a id="a2d017cd3beb218080a7988e2deed2a11"></a>
- #define </td><td class="memItemRight" valign="bottom"><b>min</b>(A, B)   ( (A) < (B) ? (A):(B))</td></tr>
- <tr class="separator:a2d017cd3beb218080a7988e2deed2a11"><td class="memSeparator" colspan="2"> </td></tr>
- </table><table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
- Functions</h2></td></tr>
- <tr class="memitem:a0fc0d4eaad01f640c901311421533c3d"><td class="memItemLeft" align="right" valign="top"><a id="a0fc0d4eaad01f640c901311421533c3d"></a>
- static void </td><td class="memItemRight" valign="bottom"><b>MQTTProtocol_storeQoS0</b> (<a class="el" href="structClients.html">Clients</a> *pubclient, <a class="el" href="structPublish.html">Publish</a> *publish)</td></tr>
- <tr class="separator:a0fc0d4eaad01f640c901311421533c3d"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a4502a4b9257b32508fac87e42fb1d85a"><td class="memItemLeft" align="right" valign="top">static int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a4502a4b9257b32508fac87e42fb1d85a">MQTTProtocol_startPublishCommon</a> (<a class="el" href="structClients.html">Clients</a> *pubclient, <a class="el" href="structPublish.html">Publish</a> *publish, int qos, int retained)</td></tr>
- <tr class="memdesc:a4502a4b9257b32508fac87e42fb1d85a"><td class="mdescLeft"> </td><td class="mdescRight">Utility function to start a new publish exchange. <a href="MQTTProtocolClient_8c.html#a4502a4b9257b32508fac87e42fb1d85a">More...</a><br /></td></tr>
- <tr class="separator:a4502a4b9257b32508fac87e42fb1d85a"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ad2f52c0fff61c891b174d69b95bcd173"><td class="memItemLeft" align="right" valign="top">static void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#ad2f52c0fff61c891b174d69b95bcd173">MQTTProtocol_retries</a> (START_TIME_TYPE now, <a class="el" href="structClients.html">Clients</a> *client, int regardless)</td></tr>
- <tr class="memdesc:ad2f52c0fff61c891b174d69b95bcd173"><td class="mdescLeft"> </td><td class="mdescRight">MQTT retry processing per client. <a href="MQTTProtocolClient_8c.html#ad2f52c0fff61c891b174d69b95bcd173">More...</a><br /></td></tr>
- <tr class="separator:ad2f52c0fff61c891b174d69b95bcd173"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a68e5f17517e75326c0869a22c7995358"><td class="memItemLeft" align="right" valign="top">static int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a68e5f17517e75326c0869a22c7995358">MQTTProtocol_queueAck</a> (<a class="el" href="structClients.html">Clients</a> *client, int ackType, int msgId)</td></tr>
- <tr class="memdesc:a68e5f17517e75326c0869a22c7995358"><td class="mdescLeft"> </td><td class="mdescRight">Queue an ack message. <a href="MQTTProtocolClient_8c.html#a68e5f17517e75326c0869a22c7995358">More...</a><br /></td></tr>
- <tr class="separator:a68e5f17517e75326c0869a22c7995358"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a286c2ef2904b5eb4a0ffa5b598961c67"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a286c2ef2904b5eb4a0ffa5b598961c67">messageIDCompare</a> (void *a, void *b)</td></tr>
- <tr class="memdesc:a286c2ef2904b5eb4a0ffa5b598961c67"><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="structList.html" title="Structure to hold all data for one list.">List</a> callback function for comparing Message structures by message id. <a href="MQTTProtocolClient_8c.html#a286c2ef2904b5eb4a0ffa5b598961c67">More...</a><br /></td></tr>
- <tr class="separator:a286c2ef2904b5eb4a0ffa5b598961c67"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a0fa824f9702cb6b0d7c800fd65198fce"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a0fa824f9702cb6b0d7c800fd65198fce">MQTTProtocol_assignMsgId</a> (<a class="el" href="structClients.html">Clients</a> *client)</td></tr>
- <tr class="memdesc:a0fa824f9702cb6b0d7c800fd65198fce"><td class="mdescLeft"> </td><td class="mdescRight">Assign a new message id for a client. <a href="MQTTProtocolClient_8c.html#a0fa824f9702cb6b0d7c800fd65198fce">More...</a><br /></td></tr>
- <tr class="separator:a0fa824f9702cb6b0d7c800fd65198fce"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a0f86c2cc2debfa39e275d3c76d5d0073"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a0f86c2cc2debfa39e275d3c76d5d0073">MQTTProtocol_startPublish</a> (<a class="el" href="structClients.html">Clients</a> *pubclient, <a class="el" href="structPublish.html">Publish</a> *publish, int qos, int retained, <a class="el" href="structMessages.html">Messages</a> **mm)</td></tr>
- <tr class="memdesc:a0f86c2cc2debfa39e275d3c76d5d0073"><td class="mdescLeft"> </td><td class="mdescRight">Start a new publish exchange. <a href="MQTTProtocolClient_8c.html#a0f86c2cc2debfa39e275d3c76d5d0073">More...</a><br /></td></tr>
- <tr class="separator:a0f86c2cc2debfa39e275d3c76d5d0073"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:afbf121be11a48fcda3e0d639bc47472b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMessages.html">Messages</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#afbf121be11a48fcda3e0d639bc47472b">MQTTProtocol_createMessage</a> (<a class="el" href="structPublish.html">Publish</a> *publish, <a class="el" href="structMessages.html">Messages</a> **mm, int qos, int retained, int allocatePayload)</td></tr>
- <tr class="memdesc:afbf121be11a48fcda3e0d639bc47472b"><td class="mdescLeft"> </td><td class="mdescRight">Copy and store message data for retries. <a href="MQTTProtocolClient_8c.html#afbf121be11a48fcda3e0d639bc47472b">More...</a><br /></td></tr>
- <tr class="separator:afbf121be11a48fcda3e0d639bc47472b"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ac753a3ad12292a0a9c2f4343bd33817e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structPublications.html">Publications</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#ac753a3ad12292a0a9c2f4343bd33817e">MQTTProtocol_storePublication</a> (<a class="el" href="structPublish.html">Publish</a> *publish, int *<a class="el" href="utf-8_8c.html#afed088663f8704004425cdae2120b9b3">len</a>)</td></tr>
- <tr class="memdesc:ac753a3ad12292a0a9c2f4343bd33817e"><td class="mdescLeft"> </td><td class="mdescRight">Store message data for possible retry. <a href="MQTTProtocolClient_8c.html#ac753a3ad12292a0a9c2f4343bd33817e">More...</a><br /></td></tr>
- <tr class="separator:ac753a3ad12292a0a9c2f4343bd33817e"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a900fa28a8774ad6f5535104bb62e7abf"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a900fa28a8774ad6f5535104bb62e7abf">MQTTProtocol_removePublication</a> (<a class="el" href="structPublications.html">Publications</a> *p)</td></tr>
- <tr class="memdesc:a900fa28a8774ad6f5535104bb62e7abf"><td class="mdescLeft"> </td><td class="mdescRight">Remove stored message data. <a href="MQTTProtocolClient_8c.html#a900fa28a8774ad6f5535104bb62e7abf">More...</a><br /></td></tr>
- <tr class="separator:a900fa28a8774ad6f5535104bb62e7abf"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a2d7897d575be486bf1ed0459d7b2b8e7"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a2d7897d575be486bf1ed0459d7b2b8e7">MQTTProtocol_handlePublishes</a> (void *pack, SOCKET sock)</td></tr>
- <tr class="memdesc:a2d7897d575be486bf1ed0459d7b2b8e7"><td class="mdescLeft"> </td><td class="mdescRight">Process an incoming publish packet for a socket The payload field of the packet has not been transferred to another buffer at this point. <a href="MQTTProtocolClient_8c.html#a2d7897d575be486bf1ed0459d7b2b8e7">More...</a><br /></td></tr>
- <tr class="separator:a2d7897d575be486bf1ed0459d7b2b8e7"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:aa9f454819a84c7a43009253fabcea3f3"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#aa9f454819a84c7a43009253fabcea3f3">MQTTProtocol_handlePubacks</a> (void *pack, SOCKET sock, <a class="el" href="structPublications.html">Publications</a> **pubToRemove)</td></tr>
- <tr class="memdesc:aa9f454819a84c7a43009253fabcea3f3"><td class="mdescLeft"> </td><td class="mdescRight">Process an incoming puback packet for a socket. <a href="MQTTProtocolClient_8c.html#aa9f454819a84c7a43009253fabcea3f3">More...</a><br /></td></tr>
- <tr class="separator:aa9f454819a84c7a43009253fabcea3f3"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ac09429577a185297d8797d791b7116a2"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#ac09429577a185297d8797d791b7116a2">MQTTProtocol_handlePubrecs</a> (void *pack, SOCKET sock, <a class="el" href="structPublications.html">Publications</a> **pubToRemove)</td></tr>
- <tr class="memdesc:ac09429577a185297d8797d791b7116a2"><td class="mdescLeft"> </td><td class="mdescRight">Process an incoming pubrec packet for a socket. <a href="MQTTProtocolClient_8c.html#ac09429577a185297d8797d791b7116a2">More...</a><br /></td></tr>
- <tr class="separator:ac09429577a185297d8797d791b7116a2"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a362e0560d6f4f0e50237664a1a8e89a7"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a362e0560d6f4f0e50237664a1a8e89a7">MQTTProtocol_handlePubrels</a> (void *pack, SOCKET sock)</td></tr>
- <tr class="memdesc:a362e0560d6f4f0e50237664a1a8e89a7"><td class="mdescLeft"> </td><td class="mdescRight">Process an incoming pubrel packet for a socket. <a href="MQTTProtocolClient_8c.html#a362e0560d6f4f0e50237664a1a8e89a7">More...</a><br /></td></tr>
- <tr class="separator:a362e0560d6f4f0e50237664a1a8e89a7"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a9aa163c85710d4936ae368b8b9412440"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a9aa163c85710d4936ae368b8b9412440">MQTTProtocol_handlePubcomps</a> (void *pack, SOCKET sock, <a class="el" href="structPublications.html">Publications</a> **pubToRemove)</td></tr>
- <tr class="memdesc:a9aa163c85710d4936ae368b8b9412440"><td class="mdescLeft"> </td><td class="mdescRight">Process an incoming pubcomp packet for a socket. <a href="MQTTProtocolClient_8c.html#a9aa163c85710d4936ae368b8b9412440">More...</a><br /></td></tr>
- <tr class="separator:a9aa163c85710d4936ae368b8b9412440"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a218a69c333badc4a61b321bc830ac1e0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a218a69c333badc4a61b321bc830ac1e0">MQTTProtocol_keepalive</a> (START_TIME_TYPE now)</td></tr>
- <tr class="memdesc:a218a69c333badc4a61b321bc830ac1e0"><td class="mdescLeft"> </td><td class="mdescRight">MQTT protocol keepAlive processing. <a href="MQTTProtocolClient_8c.html#a218a69c333badc4a61b321bc830ac1e0">More...</a><br /></td></tr>
- <tr class="separator:a218a69c333badc4a61b321bc830ac1e0"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a3a1acc3bd7b09ab9d52e15e4a97c4cb2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a3a1acc3bd7b09ab9d52e15e4a97c4cb2">MQTTProtocol_retry</a> (START_TIME_TYPE now, int doRetry, int regardless)</td></tr>
- <tr class="memdesc:a3a1acc3bd7b09ab9d52e15e4a97c4cb2"><td class="mdescLeft"> </td><td class="mdescRight">MQTT retry protocol and socket pending writes processing. <a href="MQTTProtocolClient_8c.html#a3a1acc3bd7b09ab9d52e15e4a97c4cb2">More...</a><br /></td></tr>
- <tr class="separator:a3a1acc3bd7b09ab9d52e15e4a97c4cb2"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a52e062f52e5a42275471eeb23040fc0e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a52e062f52e5a42275471eeb23040fc0e">MQTTProtocol_freeClient</a> (<a class="el" href="structClients.html">Clients</a> *client)</td></tr>
- <tr class="memdesc:a52e062f52e5a42275471eeb23040fc0e"><td class="mdescLeft"> </td><td class="mdescRight">Free a client structure. <a href="MQTTProtocolClient_8c.html#a52e062f52e5a42275471eeb23040fc0e">More...</a><br /></td></tr>
- <tr class="separator:a52e062f52e5a42275471eeb23040fc0e"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ab9c5a22f0cbd4fa648663de7ae7118ab"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#ab9c5a22f0cbd4fa648663de7ae7118ab">MQTTProtocol_emptyMessageList</a> (<a class="el" href="structList.html">List</a> *msgList)</td></tr>
- <tr class="memdesc:ab9c5a22f0cbd4fa648663de7ae7118ab"><td class="mdescLeft"> </td><td class="mdescRight">Empty a message list, leaving it able to accept new messages. <a href="MQTTProtocolClient_8c.html#ab9c5a22f0cbd4fa648663de7ae7118ab">More...</a><br /></td></tr>
- <tr class="separator:ab9c5a22f0cbd4fa648663de7ae7118ab"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a8514ddc8d0f346c0da19ab4d59b4062f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a8514ddc8d0f346c0da19ab4d59b4062f">MQTTProtocol_freeMessageList</a> (<a class="el" href="structList.html">List</a> *msgList)</td></tr>
- <tr class="memdesc:a8514ddc8d0f346c0da19ab4d59b4062f"><td class="mdescLeft"> </td><td class="mdescRight">Empty and free up all storage used by a message list. <a href="MQTTProtocolClient_8c.html#a8514ddc8d0f346c0da19ab4d59b4062f">More...</a><br /></td></tr>
- <tr class="separator:a8514ddc8d0f346c0da19ab4d59b4062f"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a5906689ff10dc091d1a2b317295d39b0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a5906689ff10dc091d1a2b317295d39b0">MQTTProtocol_writeAvailable</a> (SOCKET socket)</td></tr>
- <tr class="memdesc:a5906689ff10dc091d1a2b317295d39b0"><td class="mdescLeft"> </td><td class="mdescRight">Callback that is invoked when the socket is available for writing. <a href="MQTTProtocolClient_8c.html#a5906689ff10dc091d1a2b317295d39b0">More...</a><br /></td></tr>
- <tr class="separator:a5906689ff10dc091d1a2b317295d39b0"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a447b65c664ebedef8fecb70e29dc1767"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a447b65c664ebedef8fecb70e29dc1767">MQTTStrncpy</a> (char *dest, const char *src, size_t dest_size)</td></tr>
- <tr class="memdesc:a447b65c664ebedef8fecb70e29dc1767"><td class="mdescLeft"> </td><td class="mdescRight">Copy no more than dest_size -1 characters from the string pointed to by src to the array pointed to by dest. <a href="MQTTProtocolClient_8c.html#a447b65c664ebedef8fecb70e29dc1767">More...</a><br /></td></tr>
- <tr class="separator:a447b65c664ebedef8fecb70e29dc1767"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a89588f085edc5cee4eb650e8ad114df4"><td class="memItemLeft" align="right" valign="top">char * </td><td class="memItemRight" valign="bottom"><a class="el" href="MQTTProtocolClient_8c.html#a89588f085edc5cee4eb650e8ad114df4">MQTTStrdup</a> (const char *src)</td></tr>
- <tr class="memdesc:a89588f085edc5cee4eb650e8ad114df4"><td class="mdescLeft"> </td><td class="mdescRight">Duplicate a string, safely, allocating space on the heap. <a href="MQTTProtocolClient_8c.html#a89588f085edc5cee4eb650e8ad114df4">More...</a><br /></td></tr>
- <tr class="separator:a89588f085edc5cee4eb650e8ad114df4"><td class="memSeparator" colspan="2"> </td></tr>
- </table><table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
- Variables</h2></td></tr>
- <tr class="memitem:a2dc95966878cf339e99ab7f7d1f7cc82"><td class="memItemLeft" align="right" valign="top"><a id="a2dc95966878cf339e99ab7f7d1f7cc82"></a>
- <a class="el" href="structMQTTProtocol.html">MQTTProtocol</a> </td><td class="memItemRight" valign="bottom"><b>state</b></td></tr>
- <tr class="separator:a2dc95966878cf339e99ab7f7d1f7cc82"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a2f44b42678b96ba591f6042671e3ba6b"><td class="memItemLeft" align="right" valign="top"><a id="a2f44b42678b96ba591f6042671e3ba6b"></a>
- <a class="el" href="structClientStates.html">ClientStates</a> * </td><td class="memItemRight" valign="bottom"><b>bstate</b></td></tr>
- <tr class="separator:a2f44b42678b96ba591f6042671e3ba6b"><td class="memSeparator" colspan="2"> </td></tr>
- </table>
- <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
- <div class="textblock"><p>Functions dealing with the MQTT protocol exchanges. </p>
- <p>Some other related functions are in the MQTTProtocolOut module </p>
- </div><h2 class="groupheader">Function Documentation</h2>
- <a id="a286c2ef2904b5eb4a0ffa5b598961c67"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a286c2ef2904b5eb4a0ffa5b598961c67">◆ </a></span>messageIDCompare()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int messageIDCompare </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>a</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>b</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p><a class="el" href="structList.html" title="Structure to hold all data for one list.">List</a> callback function for comparing Message structures by message id. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">a</td><td>first integer value </td></tr>
- <tr><td class="paramname">b</td><td>second integer value </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>boolean indicating whether a and b are equal </dd></dl>
- </div>
- </div>
- <a id="a0fa824f9702cb6b0d7c800fd65198fce"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a0fa824f9702cb6b0d7c800fd65198fce">◆ </a></span>MQTTProtocol_assignMsgId()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_assignMsgId </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>client</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Assign a new message id for a client. </p>
- <p>Make sure it isn't already being used and does not exceed the maximum. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">client</td><td>a client structure </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the next message id to use, or 0 if none available </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a0fa824f9702cb6b0d7c800fd65198fce_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a0fa824f9702cb6b0d7c800fd65198fce_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a0fa824f9702cb6b0d7c800fd65198fce_cgraph" id="MQTTProtocolClient_8c_a0fa824f9702cb6b0d7c800fd65198fce_cgraph">
- <area shape="rect" title="Assign a new message id for a client." alt="" coords="5,31,193,57"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="264,5,359,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a286c2ef2904b5eb4a0ffa5b598961c67" title="List callback function for comparing Message structures by message id." alt="" coords="241,56,381,83"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="429,5,548,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="afbf121be11a48fcda3e0d639bc47472b"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#afbf121be11a48fcda3e0d639bc47472b">◆ </a></span>MQTTProtocol_createMessage()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="structMessages.html">Messages</a>* MQTTProtocol_createMessage </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structPublish.html">Publish</a> * </td>
- <td class="paramname"><em>publish</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structMessages.html">Messages</a> ** </td>
- <td class="paramname"><em>mm</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>qos</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>retained</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>allocatePayload</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Copy and store message data for retries. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">publish</td><td>the publication data </td></tr>
- <tr><td class="paramname">mm</td><td>- pointer to the message data to store </td></tr>
- <tr><td class="paramname">qos</td><td>the MQTT QoS to use </td></tr>
- <tr><td class="paramname">retained</td><td>boolean - whether to set the MQTT retained flag </td></tr>
- <tr><td class="paramname">allocatePayload</td><td>boolean - whether or not to malloc payload </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>pointer to the message data stored </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_afbf121be11a48fcda3e0d639bc47472b_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_afbf121be11a48fcda3e0d639bc47472b_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_afbf121be11a48fcda3e0d639bc47472b_cgraph" id="MQTTProtocolClient_8c_afbf121be11a48fcda3e0d639bc47472b_cgraph">
- <area shape="rect" title="Copy and store message data for retries." alt="" coords="5,5,208,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#ac753a3ad12292a0a9c2f4343bd33817e" title="Store message data for possible retry." alt="" coords="256,5,463,32"/>
- <area shape="rect" href="LinkedList_8c.html#abc7a28449893dfa775c2f709349968b4" title="Append an item to a list." alt="" coords="511,5,599,32"/>
- <area shape="rect" href="LinkedList_8c.html#a321a3598d6979c7af3f995b77ea2cec3" title="Append an already allocated ListElement and content to a list." alt="" coords="647,5,789,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="ab9c5a22f0cbd4fa648663de7ae7118ab"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#ab9c5a22f0cbd4fa648663de7ae7118ab">◆ </a></span>MQTTProtocol_emptyMessageList()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_emptyMessageList </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structList.html">List</a> * </td>
- <td class="paramname"><em>msgList</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Empty a message list, leaving it able to accept new messages. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">msgList</td><td>the message list to empty </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_ab9c5a22f0cbd4fa648663de7ae7118ab_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_ab9c5a22f0cbd4fa648663de7ae7118ab_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_ab9c5a22f0cbd4fa648663de7ae7118ab_cgraph" id="MQTTProtocolClient_8c_ab9c5a22f0cbd4fa648663de7ae7118ab_cgraph">
- <area shape="rect" title="Empty a message list, leaving it able to accept new messages." alt="" coords="5,56,229,83"/>
- <area shape="rect" href="LinkedList_8c.html#a3cf8578dba23f97dd0411e85fe3b7ff2" title="Removes and frees all items in a list, leaving the list ready for new items." alt="" coords="348,5,428,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="959,81,1077,108"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a900fa28a8774ad6f5535104bb62e7abf" title="Remove stored message data." alt="" coords="277,107,499,133"/>
- <area shape="rect" href="LinkedList_8c.html#a8430370b2b15c56ec95bb8e7e36753a5" title="Removes and frees an item in a list by comparing the pointer to the content." alt="" coords="547,107,639,133"/>
- <area shape="rect" href="LinkedList_8c.html#ab82181e0c1d96954f82dee67cee41296" title="Removes and optionally frees an element in a list by comparing the content." alt="" coords="687,107,768,133"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="816,107,911,133"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a52e062f52e5a42275471eeb23040fc0e"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a52e062f52e5a42275471eeb23040fc0e">◆ </a></span>MQTTProtocol_freeClient()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_freeClient </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>client</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Free a client structure. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">client</td><td>the client data to free </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a52e062f52e5a42275471eeb23040fc0e_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a52e062f52e5a42275471eeb23040fc0e_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a52e062f52e5a42275471eeb23040fc0e_cgraph" id="MQTTProtocolClient_8c_a52e062f52e5a42275471eeb23040fc0e_cgraph">
- <area shape="rect" title="Free a client structure." alt="" coords="5,31,175,57"/>
- <area shape="rect" href="LinkedList_8c.html#a276950531b3f54e0dda27d597572c192" title="Removes and frees all items in a list, and frees the list itself." alt="" coords="558,5,629,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a8514ddc8d0f346c0da19ab4d59b4062f" title="Empty and free up all storage used by a message list." alt="" coords="223,56,433,83"/>
- <area shape="rect" href="LinkedList_8c.html#a3cf8578dba23f97dd0411e85fe3b7ff2" title="Removes and frees all items in a list, leaving the list ready for new items." alt="" coords="824,5,904,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#ab9c5a22f0cbd4fa648663de7ae7118ab" title="Empty a message list, leaving it able to accept new messages." alt="" coords="481,56,705,83"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="1435,81,1553,108"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a900fa28a8774ad6f5535104bb62e7abf" title="Remove stored message data." alt="" coords="753,107,975,133"/>
- <area shape="rect" href="LinkedList_8c.html#a8430370b2b15c56ec95bb8e7e36753a5" title="Removes and frees an item in a list by comparing the pointer to the content." alt="" coords="1023,107,1115,133"/>
- <area shape="rect" href="LinkedList_8c.html#ab82181e0c1d96954f82dee67cee41296" title="Removes and optionally frees an element in a list by comparing the content." alt="" coords="1163,107,1244,133"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="1292,107,1387,133"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a8514ddc8d0f346c0da19ab4d59b4062f"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a8514ddc8d0f346c0da19ab4d59b4062f">◆ </a></span>MQTTProtocol_freeMessageList()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_freeMessageList </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structList.html">List</a> * </td>
- <td class="paramname"><em>msgList</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Empty and free up all storage used by a message list. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">msgList</td><td>the message list to empty and free </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a8514ddc8d0f346c0da19ab4d59b4062f_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a8514ddc8d0f346c0da19ab4d59b4062f_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a8514ddc8d0f346c0da19ab4d59b4062f_cgraph" id="MQTTProtocolClient_8c_a8514ddc8d0f346c0da19ab4d59b4062f_cgraph">
- <area shape="rect" title="Empty and free up all storage used by a message list." alt="" coords="5,31,216,57"/>
- <area shape="rect" href="LinkedList_8c.html#a276950531b3f54e0dda27d597572c192" title="Removes and frees all items in a list, and frees the list itself." alt="" coords="341,5,411,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#ab9c5a22f0cbd4fa648663de7ae7118ab" title="Empty a message list, leaving it able to accept new messages." alt="" coords="264,56,488,83"/>
- <area shape="rect" href="LinkedList_8c.html#a3cf8578dba23f97dd0411e85fe3b7ff2" title="Removes and frees all items in a list, leaving the list ready for new items." alt="" coords="607,5,687,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="1217,81,1336,108"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a900fa28a8774ad6f5535104bb62e7abf" title="Remove stored message data." alt="" coords="536,107,757,133"/>
- <area shape="rect" href="LinkedList_8c.html#a8430370b2b15c56ec95bb8e7e36753a5" title="Removes and frees an item in a list by comparing the pointer to the content." alt="" coords="805,107,897,133"/>
- <area shape="rect" href="LinkedList_8c.html#ab82181e0c1d96954f82dee67cee41296" title="Removes and optionally frees an element in a list by comparing the content." alt="" coords="945,107,1027,133"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="1075,107,1169,133"/>
- </map>
- </div>
- </div>
- </div>
- <a id="aa9f454819a84c7a43009253fabcea3f3"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#aa9f454819a84c7a43009253fabcea3f3">◆ </a></span>MQTTProtocol_handlePubacks()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_handlePubacks </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>pack</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>sock</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structPublications.html">Publications</a> ** </td>
- <td class="paramname"><em>pubToRemove</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Process an incoming puback packet for a socket. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pack</td><td>pointer to the publish packet </td></tr>
- <tr><td class="paramname">sock</td><td>the socket on which the packet was received </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_aa9f454819a84c7a43009253fabcea3f3_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_aa9f454819a84c7a43009253fabcea3f3_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_aa9f454819a84c7a43009253fabcea3f3_cgraph" id="MQTTProtocolClient_8c_aa9f454819a84c7a43009253fabcea3f3_cgraph">
- <area shape="rect" title="Process an incoming puback packet for a socket." alt="" coords="5,5,208,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="256,5,351,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="399,5,517,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a9aa163c85710d4936ae368b8b9412440"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a9aa163c85710d4936ae368b8b9412440">◆ </a></span>MQTTProtocol_handlePubcomps()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_handlePubcomps </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>pack</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>sock</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structPublications.html">Publications</a> ** </td>
- <td class="paramname"><em>pubToRemove</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Process an incoming pubcomp packet for a socket. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pack</td><td>pointer to the publish packet </td></tr>
- <tr><td class="paramname">sock</td><td>the socket on which the packet was received </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a9aa163c85710d4936ae368b8b9412440_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a9aa163c85710d4936ae368b8b9412440_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a9aa163c85710d4936ae368b8b9412440_cgraph" id="MQTTProtocolClient_8c_a9aa163c85710d4936ae368b8b9412440_cgraph">
- <area shape="rect" title="Process an incoming pubcomp packet for a socket." alt="" coords="5,5,220,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="268,5,363,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="411,5,529,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a2d7897d575be486bf1ed0459d7b2b8e7"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a2d7897d575be486bf1ed0459d7b2b8e7">◆ </a></span>MQTTProtocol_handlePublishes()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_handlePublishes </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>pack</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>sock</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Process an incoming publish packet for a socket The payload field of the packet has not been transferred to another buffer at this point. </p>
- <p>If it's needed beyond the scope of this function, it has to be copied. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pack</td><td>pointer to the publish packet </td></tr>
- <tr><td class="paramname">sock</td><td>the socket on which the packet was received </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a2d7897d575be486bf1ed0459d7b2b8e7_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a2d7897d575be486bf1ed0459d7b2b8e7_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a2d7897d575be486bf1ed0459d7b2b8e7_cgraph" id="MQTTProtocolClient_8c_a2d7897d575be486bf1ed0459d7b2b8e7_cgraph">
- <area shape="rect" title="Process an incoming publish packet for a socket The payload field of the packet has not been transfer..." alt="" coords="5,5,215,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="263,5,357,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="405,5,524,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="ac09429577a185297d8797d791b7116a2"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#ac09429577a185297d8797d791b7116a2">◆ </a></span>MQTTProtocol_handlePubrecs()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_handlePubrecs </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>pack</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>sock</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structPublications.html">Publications</a> ** </td>
- <td class="paramname"><em>pubToRemove</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Process an incoming pubrec packet for a socket. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pack</td><td>pointer to the publish packet </td></tr>
- <tr><td class="paramname">sock</td><td>the socket on which the packet was received </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_ac09429577a185297d8797d791b7116a2_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_ac09429577a185297d8797d791b7116a2_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_ac09429577a185297d8797d791b7116a2_cgraph" id="MQTTProtocolClient_8c_ac09429577a185297d8797d791b7116a2_cgraph">
- <area shape="rect" title="Process an incoming pubrec packet for a socket." alt="" coords="5,5,205,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="253,5,348,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="396,5,515,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a362e0560d6f4f0e50237664a1a8e89a7"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a362e0560d6f4f0e50237664a1a8e89a7">◆ </a></span>MQTTProtocol_handlePubrels()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_handlePubrels </td>
- <td>(</td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>pack</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>sock</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Process an incoming pubrel packet for a socket. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pack</td><td>pointer to the publish packet </td></tr>
- <tr><td class="paramname">sock</td><td>the socket on which the packet was received </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a362e0560d6f4f0e50237664a1a8e89a7_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a362e0560d6f4f0e50237664a1a8e89a7_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a362e0560d6f4f0e50237664a1a8e89a7_cgraph" id="MQTTProtocolClient_8c_a362e0560d6f4f0e50237664a1a8e89a7_cgraph">
- <area shape="rect" title="Process an incoming pubrel packet for a socket." alt="" coords="5,5,201,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="249,5,344,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="392,5,511,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a218a69c333badc4a61b321bc830ac1e0"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a218a69c333badc4a61b321bc830ac1e0">◆ </a></span>MQTTProtocol_keepalive()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_keepalive </td>
- <td>(</td>
- <td class="paramtype">START_TIME_TYPE </td>
- <td class="paramname"><em>now</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>MQTT protocol keepAlive processing. </p>
- <p>Sends PINGREQ packets as required. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">now</td><td>current time </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a218a69c333badc4a61b321bc830ac1e0_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a218a69c333badc4a61b321bc830ac1e0_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a218a69c333badc4a61b321bc830ac1e0_cgraph" id="MQTTProtocolClient_8c_a218a69c333badc4a61b321bc830ac1e0_cgraph">
- <area shape="rect" title="MQTT protocol keepAlive processing." alt="" coords="5,5,175,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="223,5,341,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a68e5f17517e75326c0869a22c7995358"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a68e5f17517e75326c0869a22c7995358">◆ </a></span>MQTTProtocol_queueAck()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_queueAck </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>client</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>ackType</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>msgId</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">static</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Queue an ack message. </p>
- <p>This is used when the socket is full (e.g. SSL_ERROR_WANT_WRITE). To be completed/cleared when the socket is no longer full </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">client</td><td>the client that received the published message </td></tr>
- <tr><td class="paramname">ackType</td><td>the type of ack to send </td></tr>
- <tr><td class="paramname">msgId</td><td>the msg id of the message we are acknowledging </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a68e5f17517e75326c0869a22c7995358_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a68e5f17517e75326c0869a22c7995358_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a68e5f17517e75326c0869a22c7995358_cgraph" id="MQTTProtocolClient_8c_a68e5f17517e75326c0869a22c7995358_cgraph">
- <area shape="rect" title="Queue an ack message." alt="" coords="5,5,177,32"/>
- <area shape="rect" href="LinkedList_8c.html#abc7a28449893dfa775c2f709349968b4" title="Append an item to a list." alt="" coords="225,5,313,32"/>
- <area shape="rect" href="LinkedList_8c.html#a321a3598d6979c7af3f995b77ea2cec3" title="Append an already allocated ListElement and content to a list." alt="" coords="361,5,504,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a900fa28a8774ad6f5535104bb62e7abf"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a900fa28a8774ad6f5535104bb62e7abf">◆ </a></span>MQTTProtocol_removePublication()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_removePublication </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structPublications.html">Publications</a> * </td>
- <td class="paramname"><em>p</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Remove stored message data. </p>
- <p>Opposite of storePublication </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">p</td><td>stored publication to remove </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a900fa28a8774ad6f5535104bb62e7abf_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a900fa28a8774ad6f5535104bb62e7abf_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a900fa28a8774ad6f5535104bb62e7abf_cgraph" id="MQTTProtocolClient_8c_a900fa28a8774ad6f5535104bb62e7abf_cgraph">
- <area shape="rect" title="Remove stored message data." alt="" coords="5,5,227,32"/>
- <area shape="rect" href="LinkedList_8c.html#a8430370b2b15c56ec95bb8e7e36753a5" title="Removes and frees an item in a list by comparing the pointer to the content." alt="" coords="275,5,367,32"/>
- <area shape="rect" href="LinkedList_8c.html#ab82181e0c1d96954f82dee67cee41296" title="Removes and optionally frees an element in a list by comparing the content." alt="" coords="415,5,496,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="544,5,639,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="687,5,805,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="ad2f52c0fff61c891b174d69b95bcd173"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#ad2f52c0fff61c891b174d69b95bcd173">◆ </a></span>MQTTProtocol_retries()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">static void MQTTProtocol_retries </td>
- <td>(</td>
- <td class="paramtype">START_TIME_TYPE </td>
- <td class="paramname"><em>now</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>client</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>regardless</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">static</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>MQTT retry processing per client. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">now</td><td>current time </td></tr>
- <tr><td class="paramname">client</td><td>- the client to which to apply the retry processing </td></tr>
- <tr><td class="paramname">regardless</td><td>boolean - retry packets regardless of retry interval (used on reconnect) </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_ad2f52c0fff61c891b174d69b95bcd173_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_ad2f52c0fff61c891b174d69b95bcd173_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_ad2f52c0fff61c891b174d69b95bcd173_cgraph" id="MQTTProtocolClient_8c_ad2f52c0fff61c891b174d69b95bcd173_cgraph">
- <area shape="rect" title="MQTT retry processing per client." alt="" coords="5,5,156,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="563,31,681,57"/>
- <area shape="rect" href="Socket_8c.html#a457d9a6a9d8e886c46fcd0c096f45614" title="Indicate whether any data is pending outbound for a socket." alt="" coords="204,31,372,57"/>
- <area shape="rect" href="LinkedList_8c.html#a1738915a6d6f10022e9ee1481c0ae452" title="List callback function for comparing integers." alt="" coords="424,31,511,57"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="420,81,515,108"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a3a1acc3bd7b09ab9d52e15e4a97c4cb2"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a3a1acc3bd7b09ab9d52e15e4a97c4cb2">◆ </a></span>MQTTProtocol_retry()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_retry </td>
- <td>(</td>
- <td class="paramtype">START_TIME_TYPE </td>
- <td class="paramname"><em>now</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>doRetry</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>regardless</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>MQTT retry protocol and socket pending writes processing. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">now</td><td>current time </td></tr>
- <tr><td class="paramname">doRetry</td><td>boolean - retries as well as pending writes? </td></tr>
- <tr><td class="paramname">regardless</td><td>boolean - retry packets regardless of retry interval (used on reconnect) </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a3a1acc3bd7b09ab9d52e15e4a97c4cb2_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a3a1acc3bd7b09ab9d52e15e4a97c4cb2_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a3a1acc3bd7b09ab9d52e15e4a97c4cb2_cgraph" id="MQTTProtocolClient_8c_a3a1acc3bd7b09ab9d52e15e4a97c4cb2_cgraph">
- <area shape="rect" title="MQTT retry protocol and socket pending writes processing." alt="" coords="5,5,144,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="192,5,311,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a0f86c2cc2debfa39e275d3c76d5d0073"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a0f86c2cc2debfa39e275d3c76d5d0073">◆ </a></span>MQTTProtocol_startPublish()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">int MQTTProtocol_startPublish </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>pubclient</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structPublish.html">Publish</a> * </td>
- <td class="paramname"><em>publish</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>qos</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>retained</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structMessages.html">Messages</a> ** </td>
- <td class="paramname"><em>mm</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Start a new publish exchange. </p>
- <p>Store any state necessary and try to send the packet </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pubclient</td><td>the client to send the publication to </td></tr>
- <tr><td class="paramname">publish</td><td>the publication data </td></tr>
- <tr><td class="paramname">qos</td><td>the MQTT QoS to use </td></tr>
- <tr><td class="paramname">retained</td><td>boolean - whether to set the MQTT retained flag </td></tr>
- <tr><td class="paramname">mm</td><td>- pointer to the message to send </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a0f86c2cc2debfa39e275d3c76d5d0073_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a0f86c2cc2debfa39e275d3c76d5d0073_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a0f86c2cc2debfa39e275d3c76d5d0073_cgraph" id="MQTTProtocolClient_8c_a0f86c2cc2debfa39e275d3c76d5d0073_cgraph">
- <area shape="rect" title="Start a new publish exchange." alt="" coords="5,52,188,79"/>
- <area shape="rect" href="LinkedList_8c.html#abc7a28449893dfa775c2f709349968b4" title="Append an item to a list." alt="" coords="769,5,857,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#afbf121be11a48fcda3e0d639bc47472b" title="Copy and store message data for retries." alt="" coords="236,52,439,79"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a4502a4b9257b32508fac87e42fb1d85a" title="Utility function to start a new publish exchange." alt="" coords="246,103,429,145"/>
- <area shape="rect" href="LinkedList_8c.html#a321a3598d6979c7af3f995b77ea2cec3" title="Append an already allocated ListElement and content to a list." alt="" coords="958,5,1101,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#ac753a3ad12292a0a9c2f4343bd33817e" title="Store message data for possible retry." alt="" coords="487,52,693,79"/>
- <area shape="rect" href="MQTTPacket_8c.html#a9ebcf93ff2ba3bd103f016c975e9c9c4" title="Send an MQTT PUBLISH packet down a socket." alt="" coords="499,111,681,137"/>
- <area shape="rect" href="Log_8c.html#a669722e3f57811871f97c12392aba85d" title="Log a message." alt="" coords="791,60,835,87"/>
- <area shape="rect" href="MQTTPacket_8c.html#a3635fd8035177b20c478daea6bad9328" title="Sends an MQTT packet from multiple buffers in one system call write." alt="" coords="741,111,884,137"/>
- <area shape="rect" href="MQTTPacket_8c.html#a07aa0146eda3d32979142e7df8ad5fc3" title="Writes an integer as 2 bytes to an output buffer." alt="" coords="780,161,845,188"/>
- <area shape="rect" href="MQTTPacket_8c.html#aadd77a4fa1b2d5c7791e3542c56af856" title="Encodes the message length according to the MQTT algorithm." alt="" coords="955,60,1104,87"/>
- <area shape="rect" href="MQTTPersistence_8c.html#a18eab666c3e6aecd92a6c8f10df808e3" title="Adds a record to the persistent store." alt="" coords="932,111,1127,137"/>
- <area shape="rect" href="MQTTPacket_8c.html#a132d2d5b304d37cd2348a973f7b315de" title="Calculates an integer from two bytes read from the input buffer." alt="" coords="998,161,1061,188"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a4502a4b9257b32508fac87e42fb1d85a"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a4502a4b9257b32508fac87e42fb1d85a">◆ </a></span>MQTTProtocol_startPublishCommon()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="mlabels">
- <tr>
- <td class="mlabels-left">
- <table class="memname">
- <tr>
- <td class="memname">static int MQTTProtocol_startPublishCommon </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structClients.html">Clients</a> * </td>
- <td class="paramname"><em>pubclient</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structPublish.html">Publish</a> * </td>
- <td class="paramname"><em>publish</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>qos</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>retained</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </td>
- <td class="mlabels-right">
- <span class="mlabels"><span class="mlabel">static</span></span> </td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Utility function to start a new publish exchange. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">pubclient</td><td>the client to send the publication to </td></tr>
- <tr><td class="paramname">publish</td><td>the publication data </td></tr>
- <tr><td class="paramname">qos</td><td>the MQTT QoS to use </td></tr>
- <tr><td class="paramname">retained</td><td>boolean - whether to set the MQTT retained flag </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the completion code </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a4502a4b9257b32508fac87e42fb1d85a_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a4502a4b9257b32508fac87e42fb1d85a_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a4502a4b9257b32508fac87e42fb1d85a_cgraph" id="MQTTProtocolClient_8c_a4502a4b9257b32508fac87e42fb1d85a_cgraph">
- <area shape="rect" title="Utility function to start a new publish exchange." alt="" coords="5,49,188,90"/>
- <area shape="rect" href="MQTTPacket_8c.html#a9ebcf93ff2ba3bd103f016c975e9c9c4" title="Send an MQTT PUBLISH packet down a socket." alt="" coords="236,56,419,83"/>
- <area shape="rect" href="Log_8c.html#a669722e3f57811871f97c12392aba85d" title="Log a message." alt="" coords="516,5,560,32"/>
- <area shape="rect" href="MQTTPacket_8c.html#a3635fd8035177b20c478daea6bad9328" title="Sends an MQTT packet from multiple buffers in one system call write." alt="" coords="467,56,609,83"/>
- <area shape="rect" href="MQTTPacket_8c.html#a07aa0146eda3d32979142e7df8ad5fc3" title="Writes an integer as 2 bytes to an output buffer." alt="" coords="505,107,571,133"/>
- <area shape="rect" href="MQTTPacket_8c.html#aadd77a4fa1b2d5c7791e3542c56af856" title="Encodes the message length according to the MQTT algorithm." alt="" coords="680,5,829,32"/>
- <area shape="rect" href="MQTTPersistence_8c.html#a18eab666c3e6aecd92a6c8f10df808e3" title="Adds a record to the persistent store." alt="" coords="657,56,852,83"/>
- <area shape="rect" href="MQTTPacket_8c.html#a132d2d5b304d37cd2348a973f7b315de" title="Calculates an integer from two bytes read from the input buffer." alt="" coords="723,107,786,133"/>
- </map>
- </div>
- </div>
- </div>
- <a id="ac753a3ad12292a0a9c2f4343bd33817e"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#ac753a3ad12292a0a9c2f4343bd33817e">◆ </a></span>MQTTProtocol_storePublication()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="structPublications.html">Publications</a>* MQTTProtocol_storePublication </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structPublish.html">Publish</a> * </td>
- <td class="paramname"><em>publish</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int * </td>
- <td class="paramname"><em>len</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Store message data for possible retry. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">publish</td><td>the publication data </td></tr>
- <tr><td class="paramname">len</td><td>returned length of the data stored </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the publication stored </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_ac753a3ad12292a0a9c2f4343bd33817e_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_ac753a3ad12292a0a9c2f4343bd33817e_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_ac753a3ad12292a0a9c2f4343bd33817e_cgraph" id="MQTTProtocolClient_8c_ac753a3ad12292a0a9c2f4343bd33817e_cgraph">
- <area shape="rect" title="Store message data for possible retry." alt="" coords="5,5,212,32"/>
- <area shape="rect" href="LinkedList_8c.html#abc7a28449893dfa775c2f709349968b4" title="Append an item to a list." alt="" coords="260,5,348,32"/>
- <area shape="rect" href="LinkedList_8c.html#a321a3598d6979c7af3f995b77ea2cec3" title="Append an already allocated ListElement and content to a list." alt="" coords="396,5,539,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a5906689ff10dc091d1a2b317295d39b0"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a5906689ff10dc091d1a2b317295d39b0">◆ </a></span>MQTTProtocol_writeAvailable()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void MQTTProtocol_writeAvailable </td>
- <td>(</td>
- <td class="paramtype">SOCKET </td>
- <td class="paramname"><em>socket</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Callback that is invoked when the socket is available for writing. </p>
- <p>This is the last attempt made to acknowledge a message. Failures that occur here are ignored. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">socket</td><td>the socket that is available for writing </td></tr>
- </table>
- </dd>
- </dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a5906689ff10dc091d1a2b317295d39b0_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a5906689ff10dc091d1a2b317295d39b0_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a5906689ff10dc091d1a2b317295d39b0_cgraph" id="MQTTProtocolClient_8c_a5906689ff10dc091d1a2b317295d39b0_cgraph">
- <area shape="rect" title="Callback that is invoked when the socket is available for writing." alt="" coords="5,5,200,32"/>
- <area shape="rect" href="LinkedList_8c.html#acad319e9ce896ff1fff30ddbeb06d22d" title="Finds an element in a list by comparing the content or pointer to the content." alt="" coords="248,5,343,32"/>
- <area shape="rect" href="LinkedList_8c.html#a7c6fba7f4b569c69829676bed2852ee9" title="Forward iteration through a list." alt="" coords="391,5,509,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a89588f085edc5cee4eb650e8ad114df4"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a89588f085edc5cee4eb650e8ad114df4">◆ </a></span>MQTTStrdup()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">char* MQTTStrdup </td>
- <td>(</td>
- <td class="paramtype">const char * </td>
- <td class="paramname"><em>src</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Duplicate a string, safely, allocating space on the heap. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">src</td><td>the source string which characters copy from </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the duplicated, allocated string </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a89588f085edc5cee4eb650e8ad114df4_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a89588f085edc5cee4eb650e8ad114df4_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a89588f085edc5cee4eb650e8ad114df4_cgraph" id="MQTTProtocolClient_8c_a89588f085edc5cee4eb650e8ad114df4_cgraph">
- <area shape="rect" title="Duplicate a string, safely, allocating space on the heap." alt="" coords="5,5,103,32"/>
- <area shape="rect" href="Log_8c.html#a669722e3f57811871f97c12392aba85d" title="Log a message." alt="" coords="301,5,345,32"/>
- <area shape="rect" href="MQTTProtocolClient_8c.html#a447b65c664ebedef8fecb70e29dc1767" title="Copy no more than dest_size -1 characters from the string pointed to by src to the array pointed to b..." alt="" coords="151,31,253,57"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a447b65c664ebedef8fecb70e29dc1767"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a447b65c664ebedef8fecb70e29dc1767">◆ </a></span>MQTTStrncpy()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">char* MQTTStrncpy </td>
- <td>(</td>
- <td class="paramtype">char * </td>
- <td class="paramname"><em>dest</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">const char * </td>
- <td class="paramname"><em>src</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">size_t </td>
- <td class="paramname"><em>dest_size</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Copy no more than dest_size -1 characters from the string pointed to by src to the array pointed to by dest. </p>
- <p>The destination string will always be null-terminated. </p><dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">dest</td><td>the array which characters copy to </td></tr>
- <tr><td class="paramname">src</td><td>the source string which characters copy from </td></tr>
- <tr><td class="paramname">dest_size</td><td>the size of the memory pointed to by dest: copy no more than this -1 (allow for null). Must be >= 1 </td></tr>
- </table>
- </dd>
- </dl>
- <dl class="section return"><dt>Returns</dt><dd>the destination string pointer </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="MQTTProtocolClient_8c_a447b65c664ebedef8fecb70e29dc1767_cgraph.png" border="0" usemap="#MQTTProtocolClient_8c_a447b65c664ebedef8fecb70e29dc1767_cgraph" alt=""/></div>
- <map name="MQTTProtocolClient_8c_a447b65c664ebedef8fecb70e29dc1767_cgraph" id="MQTTProtocolClient_8c_a447b65c664ebedef8fecb70e29dc1767_cgraph">
- <area shape="rect" title="Copy no more than dest_size -1 characters from the string pointed to by src to the array pointed to b..." alt="" coords="5,5,108,32"/>
- <area shape="rect" href="Log_8c.html#a669722e3f57811871f97c12392aba85d" title="Log a message." alt="" coords="156,5,200,32"/>
- </map>
- </div>
- </div>
- </div>
- </div><!-- contents -->
- <!-- start footer part -->
- <hr class="footer"/><address class="footer"><small>
- Generated on Thu Sep 29 2022 11:34:46 for MQTT C Client Libraries Internals by  <a href="http://www.doxygen.org/index.html">
- <img class="footer" src="doxygen.png" alt="doxygen"/>
- </a> 1.8.17
- </small></address>
- </body>
- </html>
|