<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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.11"/>
<title>Simple JSON: /home/djkehoe/git/simple_json/src/simple_json_list.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="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</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>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</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="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Simple JSON
   &#160;<span id="projectnumber">0.1</span>
   </div>
   <div id="projectbrief">A free simple json library for C</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="../../annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="../../files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="../../search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="../../files.html"><span>File&#160;List</span></a></li>
      <li><a href="../../globals.html"><span>File&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('d4/dc8/simple__json__list_8c.html','../../');});
</script>
<div id="doc-content">
<!-- 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 class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">simple_json_list.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &lt;stdio.h&gt;</code><br />
<code>#include &lt;string.h&gt;</code><br />
<code>#include &lt;stdlib.h&gt;</code><br />
<code>#include &quot;<a class="el" href="../../d1/d2e/simple__json__list_8h_source.html">simple_json_list.h</a>&quot;</code><br />
<code>#include &quot;<a class="el" href="../../d6/d6f/simple__json__error_8h_source.html">simple_json_error.h</a>&quot;</code><br />
</div><div class="textblock"><div class="dynheader">
Include dependency graph for simple_json_list.c:</div>
<div class="dyncontent">
<div class="center"><img src="../../de/d87/simple__json__list_8c__incl.png" border="0" usemap="#_2home_2djkehoe_2git_2simple__json_2src_2simple__json__list_8c" alt=""/></div>
<map name="_2home_2djkehoe_2git_2simple__json_2src_2simple__json__list_8c" id="_2home_2djkehoe_2git_2simple__json_2src_2simple__json__list_8c">
<area shape="rect" id="node5" href="../../d1/d2e/simple__json__list_8h.html" title="simple_json_list.h" alt="" coords="270,95,397,121"/>
<area shape="rect" id="node6" href="../../d6/d6f/simple__json__error_8h.html" title="simple_json_error.h" alt="" coords="421,95,555,121"/>
</map>
</div>
</div>
<p><a href="../../d4/dc8/simple__json__list_8c_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:a4498df009cb743e4161f4b5a3fe3e7d8"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a4498df009cb743e4161f4b5a3fe3e7d8">sj_list_delete</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list)</td></tr>
<tr class="memdesc:a4498df009cb743e4161f4b5a3fe3e7d8"><td class="mdescLeft">&#160;</td><td class="mdescRight">deletes a list that has been previously allocated  <a href="#a4498df009cb743e4161f4b5a3fe3e7d8">More...</a><br /></td></tr>
<tr class="separator:a4498df009cb743e4161f4b5a3fe3e7d8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a78de0f56ef6afe7c22f0ebd4933607de"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a78de0f56ef6afe7c22f0ebd4933607de">sj_list_new</a> ()</td></tr>
<tr class="memdesc:a78de0f56ef6afe7c22f0ebd4933607de"><td class="mdescLeft">&#160;</td><td class="mdescRight">create a new list  <a href="#a78de0f56ef6afe7c22f0ebd4933607de">More...</a><br /></td></tr>
<tr class="separator:a78de0f56ef6afe7c22f0ebd4933607de"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a34c6cbe1af545d7cfd0c30e98e99e8ae"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a34c6cbe1af545d7cfd0c30e98e99e8ae">sj_list_new_size</a> (unsigned int count)</td></tr>
<tr class="memdesc:a34c6cbe1af545d7cfd0c30e98e99e8ae"><td class="mdescLeft">&#160;</td><td class="mdescRight">allocate a new empty list of size 'count'  <a href="#a34c6cbe1af545d7cfd0c30e98e99e8ae">More...</a><br /></td></tr>
<tr class="separator:a34c6cbe1af545d7cfd0c30e98e99e8ae"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a38cb6cd4286019d518ab87691e2693bc"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a38cb6cd4286019d518ab87691e2693bc">sj_list_get_nth</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, unsigned int n)</td></tr>
<tr class="memdesc:a38cb6cd4286019d518ab87691e2693bc"><td class="mdescLeft">&#160;</td><td class="mdescRight">get the data stored at the nth element  <a href="#a38cb6cd4286019d518ab87691e2693bc">More...</a><br /></td></tr>
<tr class="separator:a38cb6cd4286019d518ab87691e2693bc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3a75e39da2d6908d5e1ac77504d37524"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a3a75e39da2d6908d5e1ac77504d37524">sj_list_expand</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list)</td></tr>
<tr class="separator:a3a75e39da2d6908d5e1ac77504d37524"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a45a595f33a0cf30ff2e205a3571c7507"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a45a595f33a0cf30ff2e205a3571c7507">sj_list_append</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, void *data)</td></tr>
<tr class="memdesc:a45a595f33a0cf30ff2e205a3571c7507"><td class="mdescLeft">&#160;</td><td class="mdescRight">add an element to the end of the list  <a href="#a45a595f33a0cf30ff2e205a3571c7507">More...</a><br /></td></tr>
<tr class="separator:a45a595f33a0cf30ff2e205a3571c7507"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a168903c2134f06073b0a7e59f1e2dd67"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a168903c2134f06073b0a7e59f1e2dd67">sj_list_prepend</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, void *data)</td></tr>
<tr class="separator:a168903c2134f06073b0a7e59f1e2dd67"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5df14d77a6ed3ff7c461176d900f168e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a5df14d77a6ed3ff7c461176d900f168e">sj_list_insert</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, void *data, unsigned int n)</td></tr>
<tr class="memdesc:a5df14d77a6ed3ff7c461176d900f168e"><td class="mdescLeft">&#160;</td><td class="mdescRight">instert a new element at the position provided  <a href="#a5df14d77a6ed3ff7c461176d900f168e">More...</a><br /></td></tr>
<tr class="separator:a5df14d77a6ed3ff7c461176d900f168e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a31540e4441f700dbd6409d567c55ec98"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a31540e4441f700dbd6409d567c55ec98">sj_list_delete_first</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list)</td></tr>
<tr class="separator:a31540e4441f700dbd6409d567c55ec98"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5117df142c99572867f79ede5a457835"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a5117df142c99572867f79ede5a457835">sj_list_delete_last</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list)</td></tr>
<tr class="separator:a5117df142c99572867f79ede5a457835"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2ef30e013f6c4986c2d66157be901001"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a2ef30e013f6c4986c2d66157be901001">sj_list_delete_data</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, void *data)</td></tr>
<tr class="memdesc:a2ef30e013f6c4986c2d66157be901001"><td class="mdescLeft">&#160;</td><td class="mdescRight">delete the first element in the list pointing to the address of data  <a href="#a2ef30e013f6c4986c2d66157be901001">More...</a><br /></td></tr>
<tr class="separator:a2ef30e013f6c4986c2d66157be901001"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae208fdf2ebaee60fd437d305f5e3ebbf"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#ae208fdf2ebaee60fd437d305f5e3ebbf">sj_list_delete_nth</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, unsigned int n)</td></tr>
<tr class="memdesc:ae208fdf2ebaee60fd437d305f5e3ebbf"><td class="mdescLeft">&#160;</td><td class="mdescRight">delete the element at the nth position in the list  <a href="#ae208fdf2ebaee60fd437d305f5e3ebbf">More...</a><br /></td></tr>
<tr class="separator:ae208fdf2ebaee60fd437d305f5e3ebbf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a20c3361477b5a57bd46579d961277c23"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a20c3361477b5a57bd46579d961277c23">sj_list_get_count</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list)</td></tr>
<tr class="memdesc:a20c3361477b5a57bd46579d961277c23"><td class="mdescLeft">&#160;</td><td class="mdescRight">get the number of tracked elements in the list  <a href="#a20c3361477b5a57bd46579d961277c23">More...</a><br /></td></tr>
<tr class="separator:a20c3361477b5a57bd46579d961277c23"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a01ebe1a232a431157e23a5bac1fe222a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/dc8/simple__json__list_8c.html#a01ebe1a232a431157e23a5bac1fe222a">sj_list_foreach</a> (<a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *list, void(*function)(void *data, void *context), void *contextData)</td></tr>
<tr class="separator:a01ebe1a232a431157e23a5bac1fe222a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="a45a595f33a0cf30ff2e205a3571c7507"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void sj_list_append </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>add an element to the end of the list </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to add to </td></tr>
    <tr><td class="paramname">data</td><td>the data to assign to the new element </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00083">83</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a4498df009cb743e4161f4b5a3fe3e7d8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void sj_list_delete </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>deletes a list that has been previously allocated </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to delete; </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00007">7</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a2ef30e013f6c4986c2d66157be901001"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int sj_list_delete_data </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>delete the first element in the list pointing to the address of data </p>
<dl class="section note"><dt>Note</dt><dd>does not delete the data itself </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to delete the element from </td></tr>
    <tr><td class="paramname">data</td><td>used to match against which element to delete </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on complete, error otherwise </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00148">148</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a31540e4441f700dbd6409d567c55ec98"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_delete_first </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00133">133</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a5117df142c99572867f79ede5a457835"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_delete_last </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00138">138</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="ae208fdf2ebaee60fd437d305f5e3ebbf"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_delete_nth </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>delete the element at the nth position in the list </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to delete out of </td></tr>
    <tr><td class="paramname">n</td><td>the element to delete. This is no-op if the nth element is beyond the scope of the list (event is logged) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the list provided </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00170">170</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a3a75e39da2d6908d5e1ac77504d37524"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_expand </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00060">60</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a01ebe1a232a431157e23a5bac1fe222a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void sj_list_foreach </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void(*)(void *data, void *context)&#160;</td>
          <td class="paramname"><em>function</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>contextData</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00198">198</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a20c3361477b5a57bd46579d961277c23"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int sj_list_get_count </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>get the number of tracked elements in the list </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list the check </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the count in the list. Will be zero if list was NULL </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00192">192</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a38cb6cd4286019d518ab87691e2693bc"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void* sj_list_get_nth </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>get the data stored at the nth element </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to pull data from </td></tr>
    <tr><td class="paramname">n</td><td>which element to look out </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error (such as if n &gt; the element count) or the address of the data otherwise </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00049">49</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a5df14d77a6ed3ff7c461176d900f168e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_insert </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>instert a new element at the position provided </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">list</td><td>the list to insert into </td></tr>
    <tr><td class="paramname">data</td><td>the data to assin to the new element </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the address of the list. In the event that the list needed to expand this will be different from the list provided </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00109">109</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a78de0f56ef6afe7c22f0ebd4933607de"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_new </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>create a new list </p>
<dl class="section return"><dt>Returns</dt><dd>NULL on memory error or an initialized list </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00017">17</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a34c6cbe1af545d7cfd0c30e98e99e8ae"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_new_size </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>count</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>allocate a new empty list of size 'count' </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">count</td><td>how many elements you wish to support in this list. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on memory error or a new empty list </dd></dl>

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00022">22</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
<a class="anchor" id="a168903c2134f06073b0a7e59f1e2dd67"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a>* sj_list_prepend </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d9/d7e/structSJList.html">SJList</a> *&#160;</td>
          <td class="paramname"><em>list</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html#l00104">104</a> of file <a class="el" href="../../d4/dc8/simple__json__list_8c_source.html">simple_json_list.c</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="../../d4/dc8/simple__json__list_8c.html">simple_json_list.c</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
  </ul>
</div>
</body>
</html>
