123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386 |
- <!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: Tree.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="#define-members">Macros</a> |
- <a href="#func-members">Functions</a> </div>
- <div class="headertitle">
- <div class="title">Tree.c File Reference</div> </div>
- </div><!--header-->
- <div class="contents">
- <p>functions which apply to tree structures.
- <a href="#details">More...</a></p>
- <div class="textblock"><code>#include "Tree.h"</code><br />
- <code>#include <stdlib.h></code><br />
- <code>#include <stdio.h></code><br />
- <code>#include <string.h></code><br />
- <code>#include "Heap.h"</code><br />
- </div><div class="textblock"><div class="dynheader">
- Include dependency graph for Tree.c:</div>
- <div class="dyncontent">
- <div class="center"><img src="Tree_8c__incl.png" border="0" usemap="#Tree_8c" alt=""/></div>
- <map name="Tree_8c" id="Tree_8c">
- <area shape="rect" title="functions which apply to tree structures." alt="" coords="93,5,151,32"/>
- <area shape="rect" title=" " alt="" coords="5,80,68,107"/>
- <area shape="rect" title=" " alt="" coords="92,80,152,107"/>
- <area shape="rect" title=" " alt="" coords="177,80,241,107"/>
- </map>
- </div>
- </div><table class="memberdecls">
- <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
- Macros</h2></td></tr>
- <tr class="memitem:a98e60eaccf67d1bcce846ad591c71a2a"><td class="memItemLeft" align="right" valign="top"><a id="a98e60eaccf67d1bcce846ad591c71a2a"></a>
- #define </td><td class="memItemRight" valign="bottom"><b>TREE_C</b>   /* so that malloc/free/realloc aren't redefined by Heap.h */</td></tr>
- <tr class="separator:a98e60eaccf67d1bcce846ad591c71a2a"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a437ef08681e7210d6678427030446a54"><td class="memItemLeft" align="right" valign="top"><a id="a437ef08681e7210d6678427030446a54"></a>
- #define </td><td class="memItemRight" valign="bottom"><b>LEFT</b>   0</td></tr>
- <tr class="separator:a437ef08681e7210d6678427030446a54"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a80fb826a684cf3f0d306b22aa100ddac"><td class="memItemLeft" align="right" valign="top"><a id="a80fb826a684cf3f0d306b22aa100ddac"></a>
- #define </td><td class="memItemRight" valign="bottom"><b>RIGHT</b>   1</td></tr>
- <tr class="separator:a80fb826a684cf3f0d306b22aa100ddac"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:affe776513b24d84b39af8ab0930fef7f"><td class="memItemLeft" align="right" valign="top"><a id="affe776513b24d84b39af8ab0930fef7f"></a>
- #define </td><td class="memItemRight" valign="bottom"><b>max</b>(a, b)   (a > b) ? a : b;</td></tr>
- <tr class="separator:affe776513b24d84b39af8ab0930fef7f"><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:a652270057d64439ce3d6207d7a2cc84b"><td class="memItemLeft" align="right" valign="top"><a id="a652270057d64439ce3d6207d7a2cc84b"></a>
- int </td><td class="memItemRight" valign="bottom"><b>isRed</b> (<a class="el" href="structNodeStruct.html">Node</a> *aNode)</td></tr>
- <tr class="separator:a652270057d64439ce3d6207d7a2cc84b"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a88bbea08f3a6d6f58e794f20a77cd114"><td class="memItemLeft" align="right" valign="top"><a id="a88bbea08f3a6d6f58e794f20a77cd114"></a>
- int </td><td class="memItemRight" valign="bottom"><b>isBlack</b> (<a class="el" href="structNodeStruct.html">Node</a> *aNode)</td></tr>
- <tr class="separator:a88bbea08f3a6d6f58e794f20a77cd114"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a9410a1449678720e084a7e19e1419f0b"><td class="memItemLeft" align="right" valign="top"><a id="a9410a1449678720e084a7e19e1419f0b"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeRotate</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int direction, int index)</td></tr>
- <tr class="separator:a9410a1449678720e084a7e19e1419f0b"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a09e97005c4b558e417576263f6a2e519"><td class="memItemLeft" align="right" valign="top"><a id="a09e97005c4b558e417576263f6a2e519"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeBAASub</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int which, int index)</td></tr>
- <tr class="separator:a09e97005c4b558e417576263f6a2e519"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a798ac646499c5855a4a0bbb0980ad574"><td class="memItemLeft" align="right" valign="top"><a id="a798ac646499c5855a4a0bbb0980ad574"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeBalanceAfterAdd</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int index)</td></tr>
- <tr class="separator:a798ac646499c5855a4a0bbb0980ad574"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:afa8473167abb71831644bf8a322bc3b6"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="Tree_8c.html#afa8473167abb71831644bf8a322bc3b6">TreeAddByIndex</a> (<a class="el" href="structTree.html">Tree</a> *aTree, void *content, size_t size, int index)</td></tr>
- <tr class="memdesc:afa8473167abb71831644bf8a322bc3b6"><td class="mdescLeft"> </td><td class="mdescRight">Add an item to a tree. <a href="Tree_8c.html#afa8473167abb71831644bf8a322bc3b6">More...</a><br /></td></tr>
- <tr class="separator:afa8473167abb71831644bf8a322bc3b6"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a22375e6de7f2422f62f2094994568e15"><td class="memItemLeft" align="right" valign="top"><a id="a22375e6de7f2422f62f2094994568e15"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeFindIndex1</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key, int index, int value)</td></tr>
- <tr class="separator:a22375e6de7f2422f62f2094994568e15"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a250a4ceabb1ca40055aa195374dd5411"><td class="memItemLeft" align="right" valign="top"><a id="a250a4ceabb1ca40055aa195374dd5411"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeFindContentIndex</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key, int index)</td></tr>
- <tr class="separator:a250a4ceabb1ca40055aa195374dd5411"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a9d8b49c88976a5fe898cde75921d1455"><td class="memItemLeft" align="right" valign="top"><a id="a9d8b49c88976a5fe898cde75921d1455"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeMinimum</b> (<a class="el" href="structNodeStruct.html">Node</a> *curnode)</td></tr>
- <tr class="separator:a9d8b49c88976a5fe898cde75921d1455"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ad985fd2cdb2aa281a4be97566eb13853"><td class="memItemLeft" align="right" valign="top"><a id="ad985fd2cdb2aa281a4be97566eb13853"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeSuccessor</b> (<a class="el" href="structNodeStruct.html">Node</a> *curnode)</td></tr>
- <tr class="separator:ad985fd2cdb2aa281a4be97566eb13853"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:afaf848f42d095378d5045464fa4a1abd"><td class="memItemLeft" align="right" valign="top"><a id="afaf848f42d095378d5045464fa4a1abd"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeNextElementIndex</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int index)</td></tr>
- <tr class="separator:afaf848f42d095378d5045464fa4a1abd"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a1340134baba9248dbabf43ad4a8aa622"><td class="memItemLeft" align="right" valign="top"><a id="a1340134baba9248dbabf43ad4a8aa622"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeBARSub</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int which, int index)</td></tr>
- <tr class="separator:a1340134baba9248dbabf43ad4a8aa622"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a3e25fa034e04bd945ab61dcbca9243dc"><td class="memItemLeft" align="right" valign="top"><a id="a3e25fa034e04bd945ab61dcbca9243dc"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeBalanceAfterRemove</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int index)</td></tr>
- <tr class="separator:a3e25fa034e04bd945ab61dcbca9243dc"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a1263bdfc6a906db3023ca1a6ad5302a4"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="Tree_8c.html#a1263bdfc6a906db3023ca1a6ad5302a4">TreeRemoveIndex</a> (<a class="el" href="structTree.html">Tree</a> *aTree, void *content, int index)</td></tr>
- <tr class="memdesc:a1263bdfc6a906db3023ca1a6ad5302a4"><td class="mdescLeft"> </td><td class="mdescRight">Remove an item from a tree. <a href="Tree_8c.html#a1263bdfc6a906db3023ca1a6ad5302a4">More...</a><br /></td></tr>
- <tr class="separator:a1263bdfc6a906db3023ca1a6ad5302a4"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a6ec04f95fe9b003836f7f789cc6d90af"><td class="memItemLeft" align="right" valign="top"><a id="a6ec04f95fe9b003836f7f789cc6d90af"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeInitializeNoMalloc</b> (<a class="el" href="structTree.html">Tree</a> *aTree, int(*compare)(void *, void *, int))</td></tr>
- <tr class="separator:a6ec04f95fe9b003836f7f789cc6d90af"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:aa5ee1e466d266b289dc45cbd97116b83"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structTree.html">Tree</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="Tree_8c.html#aa5ee1e466d266b289dc45cbd97116b83">TreeInitialize</a> (int(*compare)(void *, void *, int))</td></tr>
- <tr class="memdesc:aa5ee1e466d266b289dc45cbd97116b83"><td class="mdescLeft"> </td><td class="mdescRight">Allocates and initializes a new tree structure. <a href="Tree_8c.html#aa5ee1e466d266b289dc45cbd97116b83">More...</a><br /></td></tr>
- <tr class="separator:aa5ee1e466d266b289dc45cbd97116b83"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a8e255acb509907266243b2881d0d0baa"><td class="memItemLeft" align="right" valign="top"><a id="a8e255acb509907266243b2881d0d0baa"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeAddIndex</b> (<a class="el" href="structTree.html">Tree</a> *aTree, int(*compare)(void *, void *, int))</td></tr>
- <tr class="separator:a8e255acb509907266243b2881d0d0baa"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ac3cc0c325bb8ee4d1bfd5b823d7c0c44"><td class="memItemLeft" align="right" valign="top"><a id="ac3cc0c325bb8ee4d1bfd5b823d7c0c44"></a>
- void </td><td class="memItemRight" valign="bottom"><b>TreeFree</b> (<a class="el" href="structTree.html">Tree</a> *aTree)</td></tr>
- <tr class="separator:ac3cc0c325bb8ee4d1bfd5b823d7c0c44"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a2ca6a0094a3e0e0760423cb9a9057bdd"><td class="memItemLeft" align="right" valign="top"><a id="a2ca6a0094a3e0e0760423cb9a9057bdd"></a>
- void * </td><td class="memItemRight" valign="bottom"><b>TreeAdd</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *content, size_t size)</td></tr>
- <tr class="separator:a2ca6a0094a3e0e0760423cb9a9057bdd"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:accf6b6e5252b940776ab3753e6534ce9"><td class="memItemLeft" align="right" valign="top"><a id="accf6b6e5252b940776ab3753e6534ce9"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeFindIndex</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key, int index)</td></tr>
- <tr class="separator:accf6b6e5252b940776ab3753e6534ce9"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a4d470b2b9029b3f2fba6a7f6010be415"><td class="memItemLeft" align="right" valign="top"><a id="a4d470b2b9029b3f2fba6a7f6010be415"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeFind</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key)</td></tr>
- <tr class="separator:a4d470b2b9029b3f2fba6a7f6010be415"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a4a8f51ee862702cb3e6b8df539b5e1a4"><td class="memItemLeft" align="right" valign="top"><a id="a4a8f51ee862702cb3e6b8df539b5e1a4"></a>
- <a class="el" href="structNodeStruct.html">Node</a> * </td><td class="memItemRight" valign="bottom"><b>TreeNextElement</b> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode)</td></tr>
- <tr class="separator:a4a8f51ee862702cb3e6b8df539b5e1a4"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a9c3b81e7e63498e3a8f7bd28c4caec10"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="Tree_8c.html#a9c3b81e7e63498e3a8f7bd28c4caec10">TreeRemoveNodeIndex</a> (<a class="el" href="structTree.html">Tree</a> *aTree, <a class="el" href="structNodeStruct.html">Node</a> *curnode, int index)</td></tr>
- <tr class="memdesc:a9c3b81e7e63498e3a8f7bd28c4caec10"><td class="mdescLeft"> </td><td class="mdescRight">Remove an item from a tree. <a href="Tree_8c.html#a9c3b81e7e63498e3a8f7bd28c4caec10">More...</a><br /></td></tr>
- <tr class="separator:a9c3b81e7e63498e3a8f7bd28c4caec10"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a118186877dc679b41a00db4edf8b473e"><td class="memItemLeft" align="right" valign="top"><a id="a118186877dc679b41a00db4edf8b473e"></a>
- void * </td><td class="memItemRight" valign="bottom"><b>TreeRemove</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *content)</td></tr>
- <tr class="separator:a118186877dc679b41a00db4edf8b473e"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:afe83c51e65e3cb9ba66acd431e3bdb6e"><td class="memItemLeft" align="right" valign="top"><a id="afe83c51e65e3cb9ba66acd431e3bdb6e"></a>
- void * </td><td class="memItemRight" valign="bottom"><b>TreeRemoveKeyIndex</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key, int index)</td></tr>
- <tr class="separator:afe83c51e65e3cb9ba66acd431e3bdb6e"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a2476b2a8c0ba785b45dfa82b8fd52907"><td class="memItemLeft" align="right" valign="top"><a id="a2476b2a8c0ba785b45dfa82b8fd52907"></a>
- void * </td><td class="memItemRight" valign="bottom"><b>TreeRemoveKey</b> (<a class="el" href="structTree.html">Tree</a> *aTree, void *key)</td></tr>
- <tr class="separator:a2476b2a8c0ba785b45dfa82b8fd52907"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a5900a3b9572e7b362b76a30d6074438d"><td class="memItemLeft" align="right" valign="top"><a id="a5900a3b9572e7b362b76a30d6074438d"></a>
- int </td><td class="memItemRight" valign="bottom"><b>TreeIntCompare</b> (void *a, void *b, int content)</td></tr>
- <tr class="separator:a5900a3b9572e7b362b76a30d6074438d"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:ac7cdf54a1d2710c2231d64e9a1c5550d"><td class="memItemLeft" align="right" valign="top"><a id="ac7cdf54a1d2710c2231d64e9a1c5550d"></a>
- int </td><td class="memItemRight" valign="bottom"><b>TreePtrCompare</b> (void *a, void *b, int content)</td></tr>
- <tr class="separator:ac7cdf54a1d2710c2231d64e9a1c5550d"><td class="memSeparator" colspan="2"> </td></tr>
- <tr class="memitem:a7160d170563e914085a8769155c9eae1"><td class="memItemLeft" align="right" valign="top"><a id="a7160d170563e914085a8769155c9eae1"></a>
- int </td><td class="memItemRight" valign="bottom"><b>TreeStringCompare</b> (void *a, void *b, int content)</td></tr>
- <tr class="separator:a7160d170563e914085a8769155c9eae1"><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 which apply to tree structures. </p>
- <p>These trees can hold data of any sort, pointed to by the content pointer of the Node structure. </p>
- </div><h2 class="groupheader">Function Documentation</h2>
- <a id="afa8473167abb71831644bf8a322bc3b6"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#afa8473167abb71831644bf8a322bc3b6">◆ </a></span>TreeAddByIndex()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void * TreeAddByIndex </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structTree.html">Tree</a> * </td>
- <td class="paramname"><em>aTree</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>content</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">size_t </td>
- <td class="paramname"><em>size</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>index</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Add an item to a tree. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">aTree</td><td>the list to which the item is to be added </td></tr>
- <tr><td class="paramname">content</td><td>the list item content itself </td></tr>
- <tr><td class="paramname">size</td><td>the size of the element </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="Tree_8c_afa8473167abb71831644bf8a322bc3b6_cgraph.png" border="0" usemap="#Tree_8c_afa8473167abb71831644bf8a322bc3b6_cgraph" alt=""/></div>
- <map name="Tree_8c_afa8473167abb71831644bf8a322bc3b6_cgraph" id="Tree_8c_afa8473167abb71831644bf8a322bc3b6_cgraph">
- <area shape="rect" title="Add an item to a tree." alt="" coords="5,5,123,32"/>
- <area shape="rect" href="Heap_8c.html#a59e53a989d69c3da767487596d9bfa1f" title="Allocates a block of memory." alt="" coords="171,5,248,32"/>
- <area shape="rect" href="Thread_8c.html#a7e92185eb22775c76e1b6b8865468f17" title="Lock a mutex which has alrea." alt="" coords="296,5,431,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="aa5ee1e466d266b289dc45cbd97116b83"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#aa5ee1e466d266b289dc45cbd97116b83">◆ </a></span>TreeInitialize()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname"><a class="el" href="structTree.html">Tree</a>* TreeInitialize </td>
- <td>(</td>
- <td class="paramtype">int(*)(void *, void *, int) </td>
- <td class="paramname"><em>compare</em></td><td>)</td>
- <td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Allocates and initializes a new tree structure. </p>
- <dl class="section return"><dt>Returns</dt><dd>a pointer to the new tree structure </dd></dl>
- <div class="dynheader">
- Here is the call graph for this function:</div>
- <div class="dyncontent">
- <div class="center"><img src="Tree_8c_aa5ee1e466d266b289dc45cbd97116b83_cgraph.png" border="0" usemap="#Tree_8c_aa5ee1e466d266b289dc45cbd97116b83_cgraph" alt=""/></div>
- <map name="Tree_8c_aa5ee1e466d266b289dc45cbd97116b83_cgraph" id="Tree_8c_aa5ee1e466d266b289dc45cbd97116b83_cgraph">
- <area shape="rect" title="Allocates and initializes a new tree structure." alt="" coords="5,5,100,32"/>
- <area shape="rect" href="Heap_8c.html#a59e53a989d69c3da767487596d9bfa1f" title="Allocates a block of memory." alt="" coords="148,5,225,32"/>
- <area shape="rect" href="Thread_8c.html#a7e92185eb22775c76e1b6b8865468f17" title="Lock a mutex which has alrea." alt="" coords="273,5,408,32"/>
- </map>
- </div>
- </div>
- </div>
- <a id="a1263bdfc6a906db3023ca1a6ad5302a4"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a1263bdfc6a906db3023ca1a6ad5302a4">◆ </a></span>TreeRemoveIndex()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void * TreeRemoveIndex </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structTree.html">Tree</a> * </td>
- <td class="paramname"><em>aTree</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">void * </td>
- <td class="paramname"><em>content</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>index</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Remove an item from a tree. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">aTree</td><td>the list to which the item is to be added </td></tr>
- <tr><td class="paramname">curnode</td><td>the list item content itself </td></tr>
- </table>
- </dd>
- </dl>
- </div>
- </div>
- <a id="a9c3b81e7e63498e3a8f7bd28c4caec10"></a>
- <h2 class="memtitle"><span class="permalink"><a href="#a9c3b81e7e63498e3a8f7bd28c4caec10">◆ </a></span>TreeRemoveNodeIndex()</h2>
- <div class="memitem">
- <div class="memproto">
- <table class="memname">
- <tr>
- <td class="memname">void* TreeRemoveNodeIndex </td>
- <td>(</td>
- <td class="paramtype"><a class="el" href="structTree.html">Tree</a> * </td>
- <td class="paramname"><em>aTree</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype"><a class="el" href="structNodeStruct.html">Node</a> * </td>
- <td class="paramname"><em>curnode</em>, </td>
- </tr>
- <tr>
- <td class="paramkey"></td>
- <td></td>
- <td class="paramtype">int </td>
- <td class="paramname"><em>index</em> </td>
- </tr>
- <tr>
- <td></td>
- <td>)</td>
- <td></td><td></td>
- </tr>
- </table>
- </div><div class="memdoc">
- <p>Remove an item from a tree. </p>
- <dl class="params"><dt>Parameters</dt><dd>
- <table class="params">
- <tr><td class="paramname">aTree</td><td>the list to which the item is to be added </td></tr>
- <tr><td class="paramname">curnode</td><td>the list item content itself </td></tr>
- </table>
- </dd>
- </dl>
- </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>
|