<!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.12"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libcbor: src/cbor/serialization.c Source File</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" />
<link href="customdoxygen.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">libcbor
 <span id="projectnumber">0.5.0</span>
</div>
<div id="projectbrief">libcbor is a C library for parsing and generating CBOR, the general-purpose schema-less binary data format.</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.12 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
</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 id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_cb565ba51d82ea933604984cbab6233d.html">cbor</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">serialization.c</div> </div>
</div><!--header-->
<div class="contents">
<a href="serialization_8c.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/*</span></div><div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> * Copyright (c) 2014-2017 Pavel Kalvoda <me@pavelkalvoda.com></span></div><div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> *</span></div><div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> * libcbor is free software; you can redistribute it and/or modify</span></div><div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> * it under the terms of the MIT license. See LICENSE for details.</span></div><div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> */</span></div><div class="line"><a name="l00007"></a><span class="lineno"> 7</span> </div><div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="preprocessor">#include "<a class="code" href="serialization_8h.html">serialization.h</a>"</span></div><div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="preprocessor">#include "<a class="code" href="encoding_8h.html">encoding.h</a>"</span></div><div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="preprocessor">#include "<a class="code" href="arrays_8h.html">cbor/arrays.h</a>"</span></div><div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#include "<a class="code" href="bytestrings_8h.html">cbor/bytestrings.h</a>"</span></div><div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="preprocessor">#include "<a class="code" href="floats__ctrls_8h.html">cbor/floats_ctrls.h</a>"</span></div><div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#include "<a class="code" href="ints_8h.html">cbor/ints.h</a>"</span></div><div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="preprocessor">#include "<a class="code" href="maps_8h.html">cbor/maps.h</a>"</span></div><div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="preprocessor">#include "<a class="code" href="strings_8h.html">cbor/strings.h</a>"</span></div><div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="preprocessor">#include "<a class="code" href="tags_8h.html">cbor/tags.h</a>"</span></div><div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="preprocessor">#include "<a class="code" href="memory__utils_8h.html">internal/memory_utils.h</a>"</span></div><div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="preprocessor">#include <string.h></span></div><div class="line"><a name="l00019"></a><span class="lineno"> 19</span> </div><div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="serialization_8h.html#a2b99415a2c6f0d226116c707772e2fc0"> 20</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00021"></a><span class="lineno"> 21</span> {</div><div class="line"><a name="l00022"></a><span class="lineno"> 22</span>  <span class="keywordflow">switch</span> (<a class="code" href="common_8c.html#ac2b9aba4cf07857524a0a520eabeef52">cbor_typeof</a>(item)) {</div><div class="line"><a name="l00023"></a><span class="lineno"> 23</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a2137d55d8028e37ff4319a633ef0634f">CBOR_TYPE_UINT</a>:</div><div class="line"><a name="l00024"></a><span class="lineno"> 24</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#ad0411e741dcb5352b9bc4198f0f18fbe">cbor_serialize_uint</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00025"></a><span class="lineno"> 25</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae140516103af792c8f2af84390acfdcd">CBOR_TYPE_NEGINT</a>:</div><div class="line"><a name="l00026"></a><span class="lineno"> 26</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#a6f00ef0ca5354471214894c2e21ff19b">cbor_serialize_negint</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00027"></a><span class="lineno"> 27</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a70b9f0b5958c8d51f15ad7bb7c4af01d">CBOR_TYPE_BYTESTRING</a>:</div><div class="line"><a name="l00028"></a><span class="lineno"> 28</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#ab4d54170870c473fe361d91740751487">cbor_serialize_bytestring</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00029"></a><span class="lineno"> 29</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae05102a66420250eacd5f17b95d04443">CBOR_TYPE_STRING</a>:</div><div class="line"><a name="l00030"></a><span class="lineno"> 30</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#a23ba67d9759dc522924ff8ee6297babd">cbor_serialize_string</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00031"></a><span class="lineno"> 31</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae48b04b3538ade49d7eae9ee6b656103">CBOR_TYPE_ARRAY</a>:</div><div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#ac8cc5befd865dd3a48ccd19730000bb3">cbor_serialize_array</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a057fc3133cb4465f9eb734acfd195db2">CBOR_TYPE_MAP</a>:</div><div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#ad6b755769880739cf33e6bd5e5ba0733">cbor_serialize_map</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a16f0eaf29eeea66fe37ec1ed0fa45415">CBOR_TYPE_TAG</a>:</div><div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#a6b946d5f299822b6b0e6d187ed36f4fa">cbor_serialize_tag</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a1276dcc4ac56df5fd7e0270344a6e57d">CBOR_TYPE_FLOAT_CTRL</a>:</div><div class="line"><a name="l00038"></a><span class="lineno"> 38</span>  <span class="keywordflow">return</span> <a class="code" href="serialization_8c.html#a31bacc1eadd9f671eec5554ae658aca6">cbor_serialize_float_ctrl</a>(item, buffer, buffer_size);</div><div class="line"><a name="l00039"></a><span class="lineno"> 39</span>  <span class="keywordflow">default</span>:</div><div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  }</div><div class="line"><a name="l00042"></a><span class="lineno"> 42</span> }</div><div class="line"><a name="l00043"></a><span class="lineno"> 43</span> </div><div class="line"><a name="l00044"></a><span class="lineno"><a class="line" href="serialization_8h.html#ab8a96a82216c07469a583eef3a3dd8d0"> 44</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#ae995c0fac946cf851f4b37899a2e59e7">cbor_serialize_alloc</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> * item,</div><div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> ** buffer,</div><div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keywordtype">size_t</span> * buffer_size)</div><div class="line"><a name="l00047"></a><span class="lineno"> 47</span> {</div><div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <span class="keywordtype">size_t</span> bfr_size = 32;</div><div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> * bfr = <a class="code" href="common_8h.html#a07a781e9212fad361b0f59f7fc921057">_CBOR_MALLOC</a>(bfr_size), * tmp_bfr;</div><div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  <span class="keywordflow">if</span> (bfr == NULL) {</div><div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  }</div><div class="line"><a name="l00053"></a><span class="lineno"> 53</span> </div><div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  <span class="keywordtype">size_t</span> written;</div><div class="line"><a name="l00055"></a><span class="lineno"> 55</span> </div><div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  <span class="comment">/* This is waaay too optimistic - figure out something smarter (eventually) */</span></div><div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  <span class="keywordflow">while</span> ((written = <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>(item, bfr, bfr_size)) == 0) {</div><div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  <span class="keywordflow">if</span> (!<a class="code" href="memory__utils_8c.html#abdee08be3f4cff35a94279fda66c4778">_cbor_safe_to_multiply</a>(CBOR_BUFFER_GROWTH, bfr_size)) {</div><div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  <a class="code" href="common_8h.html#a1300043d7db8adf6ab67f7b787f14635">_CBOR_FREE</a>(bfr);</div><div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  }</div><div class="line"><a name="l00062"></a><span class="lineno"> 62</span> </div><div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  tmp_bfr = <a class="code" href="common_8h.html#a1e39038d9b8e9b3a1e6529c9ff6091b8">_CBOR_REALLOC</a>(bfr, bfr_size *= 2);</div><div class="line"><a name="l00064"></a><span class="lineno"> 64</span> </div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  <span class="keywordflow">if</span> (tmp_bfr == NULL) {</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <a class="code" href="common_8h.html#a1300043d7db8adf6ab67f7b787f14635">_CBOR_FREE</a>(bfr);</div><div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  }</div><div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  bfr = tmp_bfr;</div><div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  }</div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  *buffer = bfr;</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  *buffer_size = bfr_size;</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  <span class="keywordflow">return</span> written;</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span> }</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span> </div><div class="line"><a name="l00076"></a><span class="lineno"><a class="line" href="serialization_8h.html#a649fbb28229d58193a7eee96995929e0"> 76</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#ad0411e741dcb5352b9bc4198f0f18fbe">cbor_serialize_uint</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00077"></a><span class="lineno"> 77</span> {</div><div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  assert(<a class="code" href="common_8c.html#a682a023f7012a5b66a57847e6f8d386f">cbor_isa_uint</a>(item));</div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <span class="keywordflow">switch</span> (<a class="code" href="ints_8c.html#a30bcfb58aa41d4c44bc2d5d6b7de105d">cbor_int_get_width</a>(item)) {</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aaa167d7a4fac34f2bae123761b4b6fc8">CBOR_INT_8</a>:</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a6c970c1c3fe2a753d76ad7343b18fc43">cbor_encode_uint8</a>(<a class="code" href="ints_8c.html#a2379bf36318e8e4faa7434c74d8553fb">cbor_get_uint8</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57a3a9caf604c45ce423b332e91f7370822">CBOR_INT_16</a>:</div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a978187eb1d49113f35204e16638a0dfa">cbor_encode_uint16</a>(<a class="code" href="ints_8c.html#a06a0997aed16fe6aa540f57bf40ce400">cbor_get_uint16</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57ad429fc90ccfb94ec85996920fe115b51">CBOR_INT_32</a>:</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#abdc5b7670f02130ba5d0ffb01b25fab2">cbor_encode_uint32</a>(<a class="code" href="ints_8c.html#a0480e5b5849b757aa9416a4c1d51b36d">cbor_get_uint32</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aafaef7945451a7f4d12298f12f8acb2d">CBOR_INT_64</a>:</div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a9bdbc2a0030ec8edd071a9036e7c17bb">cbor_encode_uint64</a>(<a class="code" href="ints_8c.html#a839ec2dc97dda1db54657cec50387a12">cbor_get_uint64</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  <span class="keywordflow">default</span>:</div><div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  }</div><div class="line"><a name="l00091"></a><span class="lineno"> 91</span> }</div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span> </div><div class="line"><a name="l00093"></a><span class="lineno"><a class="line" href="serialization_8h.html#ad7eb1501bd8282c21675333759dc7291"> 93</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#a6f00ef0ca5354471214894c2e21ff19b">cbor_serialize_negint</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span> {</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  assert(<a class="code" href="common_8c.html#a0ca5042e3807d2cc9c3d40f9266460dd">cbor_isa_negint</a>(item));</div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  <span class="keywordflow">switch</span> (<a class="code" href="ints_8c.html#a30bcfb58aa41d4c44bc2d5d6b7de105d">cbor_int_get_width</a>(item)) {</div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aaa167d7a4fac34f2bae123761b4b6fc8">CBOR_INT_8</a>:</div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#ac5f38c2536db32249b853d5f41ac91b3">cbor_encode_negint8</a>(<a class="code" href="ints_8c.html#a2379bf36318e8e4faa7434c74d8553fb">cbor_get_uint8</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57a3a9caf604c45ce423b332e91f7370822">CBOR_INT_16</a>:</div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a000a6bd597e43b3b438a5659db183f40">cbor_encode_negint16</a>(<a class="code" href="ints_8c.html#a06a0997aed16fe6aa540f57bf40ce400">cbor_get_uint16</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57ad429fc90ccfb94ec85996920fe115b51">CBOR_INT_32</a>:</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#aaa7b2d79e956ca4ac9db8fc3d140d6d9">cbor_encode_negint32</a>(<a class="code" href="ints_8c.html#a0480e5b5849b757aa9416a4c1d51b36d">cbor_get_uint32</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aafaef7945451a7f4d12298f12f8acb2d">CBOR_INT_64</a>:</div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a4553dcc867b95ecfd6eb0dae79f69d81">cbor_encode_negint64</a>(<a class="code" href="ints_8c.html#a839ec2dc97dda1db54657cec50387a12">cbor_get_uint64</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  <span class="keywordflow">default</span>:</div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  }</div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span> }</div><div class="line"><a name="l00109"></a><span class="lineno"> 109</span> </div><div class="line"><a name="l00110"></a><span class="lineno"><a class="line" href="serialization_8h.html#aeff4847e92b05b329edd1135c60f4179"> 110</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#ab4d54170870c473fe361d91740751487">cbor_serialize_bytestring</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span> {</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  assert(<a class="code" href="common_8c.html#adedaf37527b8d8261e287a0001e5a190">cbor_isa_bytestring</a>(item));</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  <span class="keywordflow">if</span> (<a class="code" href="bytestrings_8c.html#a368222dbbcea25e06469524e26587e2a">cbor_bytestring_is_definite</a>(item)) {</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="keywordtype">size_t</span> length = <a class="code" href="bytestrings_8c.html#a7c15a63fdc3830707eac0877a261f1cd">cbor_bytestring_length</a>(item);</div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <span class="keywordtype">size_t</span> written = <a class="code" href="encoding_8c.html#acb1b57ebb4156007ddca6d724b9f794a">cbor_encode_bytestring_start</a>(length, buffer, buffer_size);</div><div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  <span class="keywordflow">if</span> (written && (buffer_size - written >= length)) {</div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  memcpy(buffer + written, <a class="code" href="bytestrings_8c.html#a2c9d6feda3d0f87782168fa817f83be6">cbor_bytestring_handle</a>(item), length);</div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="keywordflow">return</span> written + length;</div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  } <span class="keywordflow">else</span></div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  assert(<a class="code" href="bytestrings_8c.html#a3a6c450f105bb18b6b56d20f0de4786a">cbor_bytestring_is_indefinite</a>(item));</div><div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keywordtype">size_t</span> chunk_count = <a class="code" href="bytestrings_8c.html#ad02102832d452fd5a5cfa96272b1095d">cbor_bytestring_chunk_count</a>(item);</div><div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <span class="keywordtype">size_t</span> written = <a class="code" href="encoding_8c.html#a72fd1996d81b30a81381707708aa186d">cbor_encode_indef_bytestring_start</a>(buffer, buffer_size);</div><div class="line"><a name="l00125"></a><span class="lineno"> 125</span> </div><div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  <span class="keywordflow">if</span> (written == 0)</div><div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00128"></a><span class="lineno"> 128</span> </div><div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  <a class="code" href="structcbor__item__t.html">cbor_item_t</a> **chunks = <a class="code" href="bytestrings_8c.html#a8ab6255d6f8f209149bdf794dffed849">cbor_bytestring_chunks_handle</a>(item);</div><div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < chunk_count; i++) {</div><div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  <span class="keywordtype">size_t</span> chunk_written = <a class="code" href="serialization_8c.html#ab4d54170870c473fe361d91740751487">cbor_serialize_bytestring</a>(chunks[i], buffer + written, buffer_size - written);</div><div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  <span class="keywordflow">if</span> (chunk_written == 0)</div><div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  written += chunk_written;</div><div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  }</div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  <span class="keywordflow">if</span> (<a class="code" href="encoding_8c.html#ad7599c3f22138b063730b6f08637392c">cbor_encode_break</a>(buffer + written, buffer_size - written) > 0)</div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <span class="keywordflow">return</span> written + 1;</div><div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  }</div><div class="line"><a name="l00142"></a><span class="lineno"> 142</span> }</div><div class="line"><a name="l00143"></a><span class="lineno"> 143</span> </div><div class="line"><a name="l00144"></a><span class="lineno"><a class="line" href="serialization_8h.html#a9fb1138391d20c1b81081e2a5f413c3d"> 144</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#a23ba67d9759dc522924ff8ee6297babd">cbor_serialize_string</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00145"></a><span class="lineno"> 145</span> {</div><div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  assert(<a class="code" href="common_8c.html#a02edd93bb8eab83bc2b8f8bf5d7d1335">cbor_isa_string</a>(item));</div><div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  <span class="keywordflow">if</span> (<a class="code" href="strings_8c.html#aa2778891e70dec4cd59c9a969294d4aa">cbor_string_is_definite</a>(item)) {</div><div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  <span class="keywordtype">size_t</span> length = <a class="code" href="strings_8c.html#aa0c17825f920ebf122bd7b9abede919f">cbor_string_length</a>(item);</div><div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  <span class="keywordtype">size_t</span> written = <a class="code" href="encoding_8c.html#abb8a85db156a80932399cce55a0694f6">cbor_encode_string_start</a>(length, buffer, buffer_size);</div><div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  <span class="keywordflow">if</span> (written && (buffer_size - written >= length)) {</div><div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  memcpy(buffer + written, <a class="code" href="strings_8c.html#ae9e5da7bdf2a79fab7965caeff49d5bb">cbor_string_handle</a>(item), length);</div><div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  <span class="keywordflow">return</span> written + length;</div><div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  } <span class="keywordflow">else</span></div><div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  assert(<a class="code" href="strings_8c.html#aa1a92438a04ae77beea9a17910805530">cbor_string_is_indefinite</a>(item));</div><div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  <span class="keywordtype">size_t</span> chunk_count = <a class="code" href="strings_8c.html#ad8062db21711a51ae520cc1e4f5fe5ab">cbor_string_chunk_count</a>(item);</div><div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  <span class="keywordtype">size_t</span> written = <a class="code" href="encoding_8c.html#ae5fc25aee8ee4bb8605e105227cb21f5">cbor_encode_indef_string_start</a>(buffer, buffer_size);</div><div class="line"><a name="l00159"></a><span class="lineno"> 159</span> </div><div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <span class="keywordflow">if</span> (written == 0)</div><div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00162"></a><span class="lineno"> 162</span> </div><div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  <a class="code" href="structcbor__item__t.html">cbor_item_t</a> **chunks = <a class="code" href="strings_8c.html#a81d1160eed81b2a29b6c5e9ff6b9e02a">cbor_string_chunks_handle</a>(item);</div><div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < chunk_count; i++) {</div><div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordtype">size_t</span> chunk_written = <a class="code" href="serialization_8c.html#a23ba67d9759dc522924ff8ee6297babd">cbor_serialize_string</a>(chunks[i], buffer + written, buffer_size - written);</div><div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <span class="keywordflow">if</span> (chunk_written == 0)</div><div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  written += chunk_written;</div><div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  }</div><div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  <span class="keywordflow">if</span> (<a class="code" href="encoding_8c.html#ad7599c3f22138b063730b6f08637392c">cbor_encode_break</a>(buffer + written, buffer_size - written) > 0)</div><div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  <span class="keywordflow">return</span> written + 1;</div><div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  }</div><div class="line"><a name="l00176"></a><span class="lineno"> 176</span> }</div><div class="line"><a name="l00177"></a><span class="lineno"> 177</span> </div><div class="line"><a name="l00178"></a><span class="lineno"><a class="line" href="serialization_8h.html#a53e7d680cf41ccda369802deaf6c1ba8"> 178</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#ac8cc5befd865dd3a48ccd19730000bb3">cbor_serialize_array</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00179"></a><span class="lineno"> 179</span> {</div><div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  assert(<a class="code" href="common_8c.html#a9ed0fa96105c211867c5032f2a5a8b20">cbor_isa_array</a>(item));</div><div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <span class="keywordtype">size_t</span> size = <a class="code" href="arrays_8c.html#a4f634a9a4bc834e4ea6ac43e94d51f84">cbor_array_size</a>(item),</div><div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  written = 0;</div><div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  <a class="code" href="structcbor__item__t.html">cbor_item_t</a> **handle = <a class="code" href="arrays_8c.html#a8dd01f4a46f162fa4f06b7df7428128e">cbor_array_handle</a>(item);</div><div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  <span class="keywordflow">if</span> (<a class="code" href="arrays_8c.html#ac2f1480c546a0268e8b046b365e58599">cbor_array_is_definite</a>(item)) {</div><div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  written = <a class="code" href="encoding_8c.html#a614462c893ad375d880178f490e4d15f">cbor_encode_array_start</a>(size, buffer, buffer_size);</div><div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  assert(<a class="code" href="arrays_8c.html#a291a9f3ff12a2e2c58b2ca8b00280d40">cbor_array_is_indefinite</a>(item));</div><div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  written = <a class="code" href="encoding_8c.html#a8794b7d67dc4b94c7191ba97518472a6">cbor_encode_indef_array_start</a>(buffer, buffer_size);</div><div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  }</div><div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  <span class="keywordflow">if</span> (written == 0)</div><div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00192"></a><span class="lineno"> 192</span> </div><div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <span class="keywordtype">size_t</span> item_written;</div><div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < size; i++) {</div><div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  item_written = <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>(*(handle++), buffer + written, buffer_size - written);</div><div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  written += item_written;</div><div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  }</div><div class="line"><a name="l00201"></a><span class="lineno"> 201</span> </div><div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  <span class="keywordflow">if</span> (<a class="code" href="arrays_8c.html#ac2f1480c546a0268e8b046b365e58599">cbor_array_is_definite</a>(item)) {</div><div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  <span class="keywordflow">return</span> written;</div><div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  assert(<a class="code" href="arrays_8c.html#a291a9f3ff12a2e2c58b2ca8b00280d40">cbor_array_is_indefinite</a>(item));</div><div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  item_written = <a class="code" href="encoding_8c.html#ad7599c3f22138b063730b6f08637392c">cbor_encode_break</a>(buffer + written, buffer_size - written);</div><div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  <span class="keywordflow">return</span> written + 1;</div><div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  }</div><div class="line"><a name="l00212"></a><span class="lineno"> 212</span> }</div><div class="line"><a name="l00213"></a><span class="lineno"> 213</span> </div><div class="line"><a name="l00214"></a><span class="lineno"><a class="line" href="serialization_8h.html#a1c07f653f5aa66fadc82f24f556a162d"> 214</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#ad6b755769880739cf33e6bd5e5ba0733">cbor_serialize_map</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00215"></a><span class="lineno"> 215</span> {</div><div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  assert(<a class="code" href="common_8c.html#af0de041481b61922d0995b63f82d8ddd">cbor_isa_map</a>(item));</div><div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  <span class="keywordtype">size_t</span> size = <a class="code" href="maps_8c.html#a1bbbee9c6f1eaa0ff4c19559fe109baf">cbor_map_size</a>(item),</div><div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  written = 0;</div><div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  <span class="keyword">struct </span><a class="code" href="structcbor__pair.html">cbor_pair</a> * handle = <a class="code" href="maps_8c.html#a4cadc8eb7ae7ff8d3f73482fb24455c9">cbor_map_handle</a>(item);</div><div class="line"><a name="l00220"></a><span class="lineno"> 220</span> </div><div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  <span class="keywordflow">if</span> (<a class="code" href="maps_8c.html#a0dccaa76ac293bb5a11dbca6d16f6253">cbor_map_is_definite</a>(item)) {</div><div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  written = <a class="code" href="encoding_8c.html#a1dc2d5e72fc65fa52120bd9e20164277">cbor_encode_map_start</a>(size, buffer, buffer_size);</div><div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  assert(<a class="code" href="maps_8c.html#a941462383a3c8a6e3a60be9778cd1913">cbor_map_is_indefinite</a>(item));</div><div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  written = <a class="code" href="encoding_8c.html#a56b2ad41ccc983fce2dbaae97beb760d">cbor_encode_indef_map_start</a>(buffer, buffer_size);</div><div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  }</div><div class="line"><a name="l00227"></a><span class="lineno"> 227</span>  <span class="keywordflow">if</span> (written == 0)</div><div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00229"></a><span class="lineno"> 229</span> </div><div class="line"><a name="l00230"></a><span class="lineno"> 230</span>  <span class="keywordtype">size_t</span> item_written;</div><div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < size; i++) {</div><div class="line"><a name="l00232"></a><span class="lineno"> 232</span>  item_written = <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>(handle-><a class="code" href="structcbor__pair.html#a5122c22ad7ef32b2c6ae0a413caca7a1">key</a>, buffer + written, buffer_size - written);</div><div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00236"></a><span class="lineno"> 236</span>  written += item_written;</div><div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  item_written = <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>((handle++)-><a class="code" href="structcbor__pair.html#a44bbea9cc120de72fc4871a05dc8ec85">value</a>, buffer + written, buffer_size - written);</div><div class="line"><a name="l00238"></a><span class="lineno"> 238</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00239"></a><span class="lineno"> 239</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00241"></a><span class="lineno"> 241</span>  written += item_written;</div><div class="line"><a name="l00242"></a><span class="lineno"> 242</span>  }</div><div class="line"><a name="l00243"></a><span class="lineno"> 243</span> </div><div class="line"><a name="l00244"></a><span class="lineno"> 244</span>  <span class="keywordflow">if</span> (<a class="code" href="maps_8c.html#a0dccaa76ac293bb5a11dbca6d16f6253">cbor_map_is_definite</a>(item)) {</div><div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  <span class="keywordflow">return</span> written;</div><div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  assert(<a class="code" href="maps_8c.html#a941462383a3c8a6e3a60be9778cd1913">cbor_map_is_indefinite</a>(item));</div><div class="line"><a name="l00248"></a><span class="lineno"> 248</span>  item_written = <a class="code" href="encoding_8c.html#ad7599c3f22138b063730b6f08637392c">cbor_encode_break</a>(buffer + written, buffer_size - written);</div><div class="line"><a name="l00249"></a><span class="lineno"> 249</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00250"></a><span class="lineno"> 250</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00251"></a><span class="lineno"> 251</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00252"></a><span class="lineno"> 252</span>  <span class="keywordflow">return</span> written + 1;</div><div class="line"><a name="l00253"></a><span class="lineno"> 253</span>  }</div><div class="line"><a name="l00254"></a><span class="lineno"> 254</span> }</div><div class="line"><a name="l00255"></a><span class="lineno"> 255</span> </div><div class="line"><a name="l00256"></a><span class="lineno"><a class="line" href="serialization_8h.html#ae67b7ceefe645e660df73bf7ea255668"> 256</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#a6b946d5f299822b6b0e6d187ed36f4fa">cbor_serialize_tag</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00257"></a><span class="lineno"> 257</span> {</div><div class="line"><a name="l00258"></a><span class="lineno"> 258</span>  assert(<a class="code" href="common_8c.html#a0d5054202c5ec9375e8daf5930087a61">cbor_isa_tag</a>(item));</div><div class="line"><a name="l00259"></a><span class="lineno"> 259</span>  <span class="keywordtype">size_t</span> written = <a class="code" href="encoding_8c.html#a41bdb572cc73d9648f4c13e8465b1dcb">cbor_encode_tag</a>(<a class="code" href="tags_8c.html#a2746e6a37373e0950b646e8146ed63b6">cbor_tag_value</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00260"></a><span class="lineno"> 260</span>  <span class="keywordflow">if</span> (written == 0)</div><div class="line"><a name="l00261"></a><span class="lineno"> 261</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00262"></a><span class="lineno"> 262</span> </div><div class="line"><a name="l00263"></a><span class="lineno"> 263</span>  <span class="keywordtype">size_t</span> item_written = <a class="code" href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a>(<a class="code" href="tags_8c.html#a162852da1313269e9d7b07dd4b964111">cbor_tag_item</a>(item), buffer + written, buffer_size - written);</div><div class="line"><a name="l00264"></a><span class="lineno"> 264</span>  <span class="keywordflow">if</span> (item_written == 0)</div><div class="line"><a name="l00265"></a><span class="lineno"> 265</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00266"></a><span class="lineno"> 266</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00267"></a><span class="lineno"> 267</span>  <span class="keywordflow">return</span> written + item_written;</div><div class="line"><a name="l00268"></a><span class="lineno"> 268</span> }</div><div class="line"><a name="l00269"></a><span class="lineno"> 269</span> </div><div class="line"><a name="l00270"></a><span class="lineno"><a class="line" href="serialization_8h.html#ad232a99d06a972ca114a2fe753b90953"> 270</a></span> <span class="keywordtype">size_t</span> <a class="code" href="serialization_8c.html#a31bacc1eadd9f671eec5554ae658aca6">cbor_serialize_float_ctrl</a>(<span class="keyword">const</span> <a class="code" href="structcbor__item__t.html">cbor_item_t</a> *item, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *buffer, <span class="keywordtype">size_t</span> buffer_size)</div><div class="line"><a name="l00271"></a><span class="lineno"> 271</span> {</div><div class="line"><a name="l00272"></a><span class="lineno"> 272</span>  assert(<a class="code" href="common_8c.html#a983dec76e934c49ed6979226f9db4386">cbor_isa_float_ctrl</a>(item));</div><div class="line"><a name="l00273"></a><span class="lineno"> 273</span>  <span class="keywordflow">switch</span> (<a class="code" href="floats__ctrls_8c.html#a05778dc7349be636d47440f758ec96a6">cbor_float_get_width</a>(item)) {</div><div class="line"><a name="l00274"></a><span class="lineno"> 274</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7ac3c49d03756f116648957c5d996f48b4">CBOR_FLOAT_0</a>:</div><div class="line"><a name="l00275"></a><span class="lineno"> 275</span>  <span class="comment">/* CTRL - special treatment */</span></div><div class="line"><a name="l00276"></a><span class="lineno"> 276</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a1d955e4c1bb4a2e3977b7387c1fafe01">cbor_encode_ctrl</a>(<a class="code" href="floats__ctrls_8c.html#a9d15faa0a33797ce0b8a1a66d5773d88">cbor_ctrl_value</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00277"></a><span class="lineno"> 277</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a6a044cc40003cef84432fe92780514e5">CBOR_FLOAT_16</a>:</div><div class="line"><a name="l00278"></a><span class="lineno"> 278</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a6d25549fbb8a0e147f2d2454a1da0bfa">cbor_encode_half</a>(<a class="code" href="floats__ctrls_8c.html#aa85d79e0f060173a9dccdada2e551cf9">cbor_float_get_float2</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00279"></a><span class="lineno"> 279</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a0b2ba87d2508e98e5f6fee7bf8beedd4">CBOR_FLOAT_32</a>:</div><div class="line"><a name="l00280"></a><span class="lineno"> 280</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#add2c3c8759e19e86cbf9ae31dd897ee1">cbor_encode_single</a>(<a class="code" href="floats__ctrls_8c.html#ad504d3d291810b0c39fc498be0bd2639">cbor_float_get_float4</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00281"></a><span class="lineno"> 281</span>  <span class="keywordflow">case</span> <a class="code" href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a792f18e66a6da153eb4f40a8f894c653">CBOR_FLOAT_64</a>:</div><div class="line"><a name="l00282"></a><span class="lineno"> 282</span>  <span class="keywordflow">return</span> <a class="code" href="encoding_8c.html#a772417a925ae556f40b6811d3fba7834">cbor_encode_double</a>(<a class="code" href="floats__ctrls_8c.html#a2f215940998d05730b23b7e0e7ad8ebe">cbor_float_get_float8</a>(item), buffer, buffer_size);</div><div class="line"><a name="l00283"></a><span class="lineno"> 283</span>  }</div><div class="line"><a name="l00284"></a><span class="lineno"> 284</span> </div><div class="line"><a name="l00285"></a><span class="lineno"> 285</span>  <span class="comment">/* Should never happen - make the compiler happy */</span></div><div class="line"><a name="l00286"></a><span class="lineno"> 286</span>  <span class="keywordflow">return</span> 0;</div><div class="line"><a name="l00287"></a><span class="lineno"> 287</span> }</div><div class="ttc" id="encoding_8c_html_a1dc2d5e72fc65fa52120bd9e20164277"><div class="ttname"><a href="encoding_8c.html#a1dc2d5e72fc65fa52120bd9e20164277">cbor_encode_map_start</a></div><div class="ttdeci">size_t cbor_encode_map_start(size_t length, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00101">encoding.c:101</a></div></div>
<div class="ttc" id="encoding_8c_html_ad7599c3f22138b063730b6f08637392c"><div class="ttname"><a href="encoding_8c.html#ad7599c3f22138b063730b6f08637392c">cbor_encode_break</a></div><div class="ttdeci">size_t cbor_encode_break(unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00178">encoding.c:178</a></div></div>
<div class="ttc" id="data_8h_html_ae0fc9740f108f0f0078b93712b061e57aaa167d7a4fac34f2bae123761b4b6fc8"><div class="ttname"><a href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aaa167d7a4fac34f2bae123761b4b6fc8">CBOR_INT_8</a></div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00047">data.h:47</a></div></div>
<div class="ttc" id="bytestrings_8c_html_a368222dbbcea25e06469524e26587e2a"><div class="ttname"><a href="bytestrings_8c.html#a368222dbbcea25e06469524e26587e2a">cbor_bytestring_is_definite</a></div><div class="ttdeci">bool cbor_bytestring_is_definite(const cbor_item_t *item)</div><div class="ttdoc">Is the byte string definite? </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00024">bytestrings.c:24</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6a16f0eaf29eeea66fe37ec1ed0fa45415"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a16f0eaf29eeea66fe37ec1ed0fa45415">CBOR_TYPE_TAG</a></div><div class="ttdoc">6 - tags </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00031">data.h:31</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6ae05102a66420250eacd5f17b95d04443"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae05102a66420250eacd5f17b95d04443">CBOR_TYPE_STRING</a></div><div class="ttdoc">3 - strings </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00028">data.h:28</a></div></div>
<div class="ttc" id="serialization_8c_html_ad0411e741dcb5352b9bc4198f0f18fbe"><div class="ttname"><a href="serialization_8c.html#ad0411e741dcb5352b9bc4198f0f18fbe">cbor_serialize_uint</a></div><div class="ttdeci">size_t cbor_serialize_uint(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize an uint. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00076">serialization.c:76</a></div></div>
<div class="ttc" id="encoding_8c_html_a6d25549fbb8a0e147f2d2454a1da0bfa"><div class="ttname"><a href="encoding_8c.html#a6d25549fbb8a0e147f2d2454a1da0bfa">cbor_encode_half</a></div><div class="ttdeci">size_t cbor_encode_half(float value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Encodes a half-precision float. </div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00131">encoding.c:131</a></div></div>
<div class="ttc" id="strings_8h_html"><div class="ttname"><a href="strings_8h.html">strings.h</a></div></div>
<div class="ttc" id="ints_8c_html_a30bcfb58aa41d4c44bc2d5d6b7de105d"><div class="ttname"><a href="ints_8c.html#a30bcfb58aa41d4c44bc2d5d6b7de105d">cbor_int_get_width</a></div><div class="ttdeci">cbor_int_width cbor_int_get_width(const cbor_item_t *item)</div><div class="ttdoc">Queries the integer width. </div><div class="ttdef"><b>Definition:</b> <a href="ints_8c_source.html#l00010">ints.c:10</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6a70b9f0b5958c8d51f15ad7bb7c4af01d"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a70b9f0b5958c8d51f15ad7bb7c4af01d">CBOR_TYPE_BYTESTRING</a></div><div class="ttdoc">2 - byte strings </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00027">data.h:27</a></div></div>
<div class="ttc" id="data_8h_html_ac80d3ecbbdc88d96a7396ac986ee47e7ac3c49d03756f116648957c5d996f48b4"><div class="ttname"><a href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7ac3c49d03756f116648957c5d996f48b4">CBOR_FLOAT_0</a></div><div class="ttdoc">Internal use - ctrl and special values. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00055">data.h:55</a></div></div>
<div class="ttc" id="serialization_8c_html_ad6b755769880739cf33e6bd5e5ba0733"><div class="ttname"><a href="serialization_8c.html#ad6b755769880739cf33e6bd5e5ba0733">cbor_serialize_map</a></div><div class="ttdeci">size_t cbor_serialize_map(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a map. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00214">serialization.c:214</a></div></div>
<div class="ttc" id="strings_8c_html_ae9e5da7bdf2a79fab7965caeff49d5bb"><div class="ttname"><a href="strings_8c.html#ae9e5da7bdf2a79fab7965caeff49d5bb">cbor_string_handle</a></div><div class="ttdeci">unsigned char * cbor_string_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the handle to the underlying string. </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00112">strings.c:112</a></div></div>
<div class="ttc" id="encoding_8c_html_a8794b7d67dc4b94c7191ba97518472a6"><div class="ttname"><a href="encoding_8c.html#a8794b7d67dc4b94c7191ba97518472a6">cbor_encode_indef_array_start</a></div><div class="ttdeci">size_t cbor_encode_indef_array_start(unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00096">encoding.c:96</a></div></div>
<div class="ttc" id="serialization_8c_html_ab4d54170870c473fe361d91740751487"><div class="ttname"><a href="serialization_8c.html#ab4d54170870c473fe361d91740751487">cbor_serialize_bytestring</a></div><div class="ttdeci">size_t cbor_serialize_bytestring(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a bytestring. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00110">serialization.c:110</a></div></div>
<div class="ttc" id="common_8c_html_a0ca5042e3807d2cc9c3d40f9266460dd"><div class="ttname"><a href="common_8c.html#a0ca5042e3807d2cc9c3d40f9266460dd">cbor_isa_negint</a></div><div class="ttdeci">bool cbor_isa_negint(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00023">common.c:23</a></div></div>
<div class="ttc" id="structcbor__pair_html_a44bbea9cc120de72fc4871a05dc8ec85"><div class="ttname"><a href="structcbor__pair.html#a44bbea9cc120de72fc4871a05dc8ec85">cbor_pair::value</a></div><div class="ttdeci">cbor_item_t * value</div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00180">data.h:180</a></div></div>
<div class="ttc" id="encoding_8c_html_abb8a85db156a80932399cce55a0694f6"><div class="ttname"><a href="encoding_8c.html#abb8a85db156a80932399cce55a0694f6">cbor_encode_string_start</a></div><div class="ttdeci">size_t cbor_encode_string_start(size_t length, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00081">encoding.c:81</a></div></div>
<div class="ttc" id="common_8c_html_a02edd93bb8eab83bc2b8f8bf5d7d1335"><div class="ttname"><a href="common_8c.html#a02edd93bb8eab83bc2b8f8bf5d7d1335">cbor_isa_string</a></div><div class="ttdeci">bool cbor_isa_string(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00033">common.c:33</a></div></div>
<div class="ttc" id="encoding_8c_html_aaa7b2d79e956ca4ac9db8fc3d140d6d9"><div class="ttname"><a href="encoding_8c.html#aaa7b2d79e956ca4ac9db8fc3d140d6d9">cbor_encode_negint32</a></div><div class="ttdeci">size_t cbor_encode_negint32(uint32_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00047">encoding.c:47</a></div></div>
<div class="ttc" id="maps_8h_html"><div class="ttname"><a href="maps_8h.html">maps.h</a></div></div>
<div class="ttc" id="bytestrings_8c_html_ad02102832d452fd5a5cfa96272b1095d"><div class="ttname"><a href="bytestrings_8c.html#ad02102832d452fd5a5cfa96272b1095d">cbor_bytestring_chunk_count</a></div><div class="ttdeci">size_t cbor_bytestring_chunk_count(const cbor_item_t *item)</div><div class="ttdoc">Get the number of chunks this string consist of. </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00087">bytestrings.c:87</a></div></div>
<div class="ttc" id="strings_8c_html_a81d1160eed81b2a29b6c5e9ff6b9e02a"><div class="ttname"><a href="strings_8c.html#a81d1160eed81b2a29b6c5e9ff6b9e02a">cbor_string_chunks_handle</a></div><div class="ttdeci">cbor_item_t ** cbor_string_chunks_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the handle to the array of chunks. </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00067">strings.c:67</a></div></div>
<div class="ttc" id="serialization_8c_html_ae995c0fac946cf851f4b37899a2e59e7"><div class="ttname"><a href="serialization_8c.html#ae995c0fac946cf851f4b37899a2e59e7">cbor_serialize_alloc</a></div><div class="ttdeci">size_t cbor_serialize_alloc(const cbor_item_t *item, unsigned char **buffer, size_t *buffer_size)</div><div class="ttdoc">Serialize the given item, allocating buffers as needed. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00044">serialization.c:44</a></div></div>
<div class="ttc" id="common_8c_html_adedaf37527b8d8261e287a0001e5a190"><div class="ttname"><a href="common_8c.html#adedaf37527b8d8261e287a0001e5a190">cbor_isa_bytestring</a></div><div class="ttdeci">bool cbor_isa_bytestring(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00028">common.c:28</a></div></div>
<div class="ttc" id="encoding_8c_html_a1d955e4c1bb4a2e3977b7387c1fafe01"><div class="ttname"><a href="encoding_8c.html#a1d955e4c1bb4a2e3977b7387c1fafe01">cbor_encode_ctrl</a></div><div class="ttdeci">size_t cbor_encode_ctrl(uint8_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00183">encoding.c:183</a></div></div>
<div class="ttc" id="maps_8c_html_a1bbbee9c6f1eaa0ff4c19559fe109baf"><div class="ttname"><a href="maps_8c.html#a1bbbee9c6f1eaa0ff4c19559fe109baf">cbor_map_size</a></div><div class="ttdeci">size_t cbor_map_size(const cbor_item_t *item)</div><div class="ttdoc">Get the number of pairs. </div><div class="ttdef"><b>Definition:</b> <a href="maps_8c_source.html#l00011">maps.c:11</a></div></div>
<div class="ttc" id="bytestrings_8c_html_a8ab6255d6f8f209149bdf794dffed849"><div class="ttname"><a href="bytestrings_8c.html#a8ab6255d6f8f209149bdf794dffed849">cbor_bytestring_chunks_handle</a></div><div class="ttdeci">cbor_item_t ** cbor_bytestring_chunks_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the handle to the array of chunks. </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00080">bytestrings.c:80</a></div></div>
<div class="ttc" id="bytestrings_8c_html_a3a6c450f105bb18b6b56d20f0de4786a"><div class="ttname"><a href="bytestrings_8c.html#a3a6c450f105bb18b6b56d20f0de4786a">cbor_bytestring_is_indefinite</a></div><div class="ttdeci">bool cbor_bytestring_is_indefinite(const cbor_item_t *item)</div><div class="ttdoc">Is the byte string indefinite? </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00030">bytestrings.c:30</a></div></div>
<div class="ttc" id="data_8h_html_ae0fc9740f108f0f0078b93712b061e57ad429fc90ccfb94ec85996920fe115b51"><div class="ttname"><a href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57ad429fc90ccfb94ec85996920fe115b51">CBOR_INT_32</a></div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00049">data.h:49</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6ae48b04b3538ade49d7eae9ee6b656103"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae48b04b3538ade49d7eae9ee6b656103">CBOR_TYPE_ARRAY</a></div><div class="ttdoc">4 - arrays </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00029">data.h:29</a></div></div>
<div class="ttc" id="tags_8c_html_a162852da1313269e9d7b07dd4b964111"><div class="ttname"><a href="tags_8c.html#a162852da1313269e9d7b07dd4b964111">cbor_tag_item</a></div><div class="ttdeci">cbor_item_t * cbor_tag_item(const cbor_item_t *item)</div><div class="ttdoc">Get the tagged item. </div><div class="ttdef"><b>Definition:</b> <a href="tags_8c_source.html#l00022">tags.c:22</a></div></div>
<div class="ttc" id="structcbor__pair_html_a5122c22ad7ef32b2c6ae0a413caca7a1"><div class="ttname"><a href="structcbor__pair.html#a5122c22ad7ef32b2c6ae0a413caca7a1">cbor_pair::key</a></div><div class="ttdeci">cbor_item_t * key</div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00180">data.h:180</a></div></div>
<div class="ttc" id="encoding_8c_html_ac5f38c2536db32249b853d5f41ac91b3"><div class="ttname"><a href="encoding_8c.html#ac5f38c2536db32249b853d5f41ac91b3">cbor_encode_negint8</a></div><div class="ttdeci">size_t cbor_encode_negint8(uint8_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00037">encoding.c:37</a></div></div>
<div class="ttc" id="serialization_8c_html_a23ba67d9759dc522924ff8ee6297babd"><div class="ttname"><a href="serialization_8c.html#a23ba67d9759dc522924ff8ee6297babd">cbor_serialize_string</a></div><div class="ttdeci">size_t cbor_serialize_string(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a string. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00144">serialization.c:144</a></div></div>
<div class="ttc" id="floats__ctrls_8h_html"><div class="ttname"><a href="floats__ctrls_8h.html">floats_ctrls.h</a></div></div>
<div class="ttc" id="encoding_8c_html_a9bdbc2a0030ec8edd071a9036e7c17bb"><div class="ttname"><a href="encoding_8c.html#a9bdbc2a0030ec8edd071a9036e7c17bb">cbor_encode_uint64</a></div><div class="ttdeci">size_t cbor_encode_uint64(uint64_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00026">encoding.c:26</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6a1276dcc4ac56df5fd7e0270344a6e57d"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a1276dcc4ac56df5fd7e0270344a6e57d">CBOR_TYPE_FLOAT_CTRL</a></div><div class="ttdoc">7 - decimals and special values (true, false, nil, ...) </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00032">data.h:32</a></div></div>
<div class="ttc" id="ints_8c_html_a0480e5b5849b757aa9416a4c1d51b36d"><div class="ttname"><a href="ints_8c.html#a0480e5b5849b757aa9416a4c1d51b36d">cbor_get_uint32</a></div><div class="ttdeci">uint32_t cbor_get_uint32(const cbor_item_t *item)</div><div class="ttdoc">Extracts the integer value. </div><div class="ttdef"><b>Definition:</b> <a href="ints_8c_source.html#l00030">ints.c:30</a></div></div>
<div class="ttc" id="common_8h_html_a1300043d7db8adf6ab67f7b787f14635"><div class="ttname"><a href="common_8h.html#a1300043d7db8adf6ab67f7b787f14635">_CBOR_FREE</a></div><div class="ttdeci">#define _CBOR_FREE</div><div class="ttdef"><b>Definition:</b> <a href="common_8h_source.html#l00086">common.h:86</a></div></div>
<div class="ttc" id="common_8h_html_a07a781e9212fad361b0f59f7fc921057"><div class="ttname"><a href="common_8h.html#a07a781e9212fad361b0f59f7fc921057">_CBOR_MALLOC</a></div><div class="ttdeci">#define _CBOR_MALLOC</div><div class="ttdef"><b>Definition:</b> <a href="common_8h_source.html#l00084">common.h:84</a></div></div>
<div class="ttc" id="maps_8c_html_a941462383a3c8a6e3a60be9778cd1913"><div class="ttname"><a href="maps_8c.html#a941462383a3c8a6e3a60be9778cd1913">cbor_map_is_indefinite</a></div><div class="ttdeci">bool cbor_map_is_indefinite(const cbor_item_t *item)</div><div class="ttdoc">Is this map indefinite? </div><div class="ttdef"><b>Definition:</b> <a href="maps_8c_source.html#l00132">maps.c:132</a></div></div>
<div class="ttc" id="structcbor__pair_html"><div class="ttname"><a href="structcbor__pair.html">cbor_pair</a></div><div class="ttdoc">Simple pair of items for use in maps. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00179">data.h:179</a></div></div>
<div class="ttc" id="data_8h_html_ae0fc9740f108f0f0078b93712b061e57aafaef7945451a7f4d12298f12f8acb2d"><div class="ttname"><a href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57aafaef7945451a7f4d12298f12f8acb2d">CBOR_INT_64</a></div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00050">data.h:50</a></div></div>
<div class="ttc" id="serialization_8h_html"><div class="ttname"><a href="serialization_8h.html">serialization.h</a></div></div>
<div class="ttc" id="arrays_8c_html_ac2f1480c546a0268e8b046b365e58599"><div class="ttname"><a href="arrays_8c.html#ac2f1480c546a0268e8b046b365e58599">cbor_array_is_definite</a></div><div class="ttdeci">bool cbor_array_is_definite(const cbor_item_t *item)</div><div class="ttdoc">Is the array definite? </div><div class="ttdef"><b>Definition:</b> <a href="arrays_8c_source.html#l00088">arrays.c:88</a></div></div>
<div class="ttc" id="data_8h_html_ac80d3ecbbdc88d96a7396ac986ee47e7a792f18e66a6da153eb4f40a8f894c653"><div class="ttname"><a href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a792f18e66a6da153eb4f40a8f894c653">CBOR_FLOAT_64</a></div><div class="ttdoc">Double. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00058">data.h:58</a></div></div>
<div class="ttc" id="arrays_8h_html"><div class="ttname"><a href="arrays_8h.html">arrays.h</a></div></div>
<div class="ttc" id="ints_8c_html_a06a0997aed16fe6aa540f57bf40ce400"><div class="ttname"><a href="ints_8c.html#a06a0997aed16fe6aa540f57bf40ce400">cbor_get_uint16</a></div><div class="ttdeci">uint16_t cbor_get_uint16(const cbor_item_t *item)</div><div class="ttdoc">Extracts the integer value. </div><div class="ttdef"><b>Definition:</b> <a href="ints_8c_source.html#l00023">ints.c:23</a></div></div>
<div class="ttc" id="data_8h_html_ac80d3ecbbdc88d96a7396ac986ee47e7a6a044cc40003cef84432fe92780514e5"><div class="ttname"><a href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a6a044cc40003cef84432fe92780514e5">CBOR_FLOAT_16</a></div><div class="ttdoc">Half float. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00056">data.h:56</a></div></div>
<div class="ttc" id="encoding_8c_html_add2c3c8759e19e86cbf9ae31dd897ee1"><div class="ttname"><a href="encoding_8c.html#add2c3c8759e19e86cbf9ae31dd897ee1">cbor_encode_single</a></div><div class="ttdeci">size_t cbor_encode_single(float value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00167">encoding.c:167</a></div></div>
<div class="ttc" id="encoding_8c_html_a56b2ad41ccc983fce2dbaae97beb760d"><div class="ttname"><a href="encoding_8c.html#a56b2ad41ccc983fce2dbaae97beb760d">cbor_encode_indef_map_start</a></div><div class="ttdeci">size_t cbor_encode_indef_map_start(unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00106">encoding.c:106</a></div></div>
<div class="ttc" id="serialization_8c_html_a6b946d5f299822b6b0e6d187ed36f4fa"><div class="ttname"><a href="serialization_8c.html#a6b946d5f299822b6b0e6d187ed36f4fa">cbor_serialize_tag</a></div><div class="ttdeci">size_t cbor_serialize_tag(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a tag. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00256">serialization.c:256</a></div></div>
<div class="ttc" id="encoding_8c_html_a772417a925ae556f40b6811d3fba7834"><div class="ttname"><a href="encoding_8c.html#a772417a925ae556f40b6811d3fba7834">cbor_encode_double</a></div><div class="ttdeci">size_t cbor_encode_double(double value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00173">encoding.c:173</a></div></div>
<div class="ttc" id="strings_8c_html_ad8062db21711a51ae520cc1e4f5fe5ab"><div class="ttname"><a href="strings_8c.html#ad8062db21711a51ae520cc1e4f5fe5ab">cbor_string_chunk_count</a></div><div class="ttdeci">size_t cbor_string_chunk_count(const cbor_item_t *item)</div><div class="ttdoc">Get the number of chunks this string consist of. </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00074">strings.c:74</a></div></div>
<div class="ttc" id="encoding_8h_html"><div class="ttname"><a href="encoding_8h.html">encoding.h</a></div></div>
<div class="ttc" id="serialization_8c_html_a31bacc1eadd9f671eec5554ae658aca6"><div class="ttname"><a href="serialization_8c.html#a31bacc1eadd9f671eec5554ae658aca6">cbor_serialize_float_ctrl</a></div><div class="ttdeci">size_t cbor_serialize_float_ctrl(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00270">serialization.c:270</a></div></div>
<div class="ttc" id="serialization_8c_html_ac8cc5befd865dd3a48ccd19730000bb3"><div class="ttname"><a href="serialization_8c.html#ac8cc5befd865dd3a48ccd19730000bb3">cbor_serialize_array</a></div><div class="ttdeci">size_t cbor_serialize_array(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize an array. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00178">serialization.c:178</a></div></div>
<div class="ttc" id="arrays_8c_html_a4f634a9a4bc834e4ea6ac43e94d51f84"><div class="ttname"><a href="arrays_8c.html#a4f634a9a4bc834e4ea6ac43e94d51f84">cbor_array_size</a></div><div class="ttdeci">size_t cbor_array_size(const cbor_item_t *item)</div><div class="ttdoc">Get the number of members. </div><div class="ttdef"><b>Definition:</b> <a href="arrays_8c_source.html#l00012">arrays.c:12</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6a2137d55d8028e37ff4319a633ef0634f"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a2137d55d8028e37ff4319a633ef0634f">CBOR_TYPE_UINT</a></div><div class="ttdoc">0 - positive integers </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00025">data.h:25</a></div></div>
<div class="ttc" id="encoding_8c_html_a614462c893ad375d880178f490e4d15f"><div class="ttname"><a href="encoding_8c.html#a614462c893ad375d880178f490e4d15f">cbor_encode_array_start</a></div><div class="ttdeci">size_t cbor_encode_array_start(size_t length, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00091">encoding.c:91</a></div></div>
<div class="ttc" id="encoding_8c_html_a6c970c1c3fe2a753d76ad7343b18fc43"><div class="ttname"><a href="encoding_8c.html#a6c970c1c3fe2a753d76ad7343b18fc43">cbor_encode_uint8</a></div><div class="ttdeci">size_t cbor_encode_uint8(uint8_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00011">encoding.c:11</a></div></div>
<div class="ttc" id="encoding_8c_html_a978187eb1d49113f35204e16638a0dfa"><div class="ttname"><a href="encoding_8c.html#a978187eb1d49113f35204e16638a0dfa">cbor_encode_uint16</a></div><div class="ttdeci">size_t cbor_encode_uint16(uint16_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00016">encoding.c:16</a></div></div>
<div class="ttc" id="ints_8c_html_a2379bf36318e8e4faa7434c74d8553fb"><div class="ttname"><a href="ints_8c.html#a2379bf36318e8e4faa7434c74d8553fb">cbor_get_uint8</a></div><div class="ttdeci">uint8_t cbor_get_uint8(const cbor_item_t *item)</div><div class="ttdoc">Extracts the integer value. </div><div class="ttdef"><b>Definition:</b> <a href="ints_8c_source.html#l00016">ints.c:16</a></div></div>
<div class="ttc" id="floats__ctrls_8c_html_ad504d3d291810b0c39fc498be0bd2639"><div class="ttname"><a href="floats__ctrls_8c.html#ad504d3d291810b0c39fc498be0bd2639">cbor_float_get_float4</a></div><div class="ttdeci">float cbor_float_get_float4(const cbor_item_t *item)</div><div class="ttdoc">Get a single precision float. </div><div class="ttdef"><b>Definition:</b> <a href="floats__ctrls_8c_source.html#l00038">floats_ctrls.c:38</a></div></div>
<div class="ttc" id="ints_8c_html_a839ec2dc97dda1db54657cec50387a12"><div class="ttname"><a href="ints_8c.html#a839ec2dc97dda1db54657cec50387a12">cbor_get_uint64</a></div><div class="ttdeci">uint64_t cbor_get_uint64(const cbor_item_t *item)</div><div class="ttdoc">Extracts the integer value. </div><div class="ttdef"><b>Definition:</b> <a href="ints_8c_source.html#l00037">ints.c:37</a></div></div>
<div class="ttc" id="floats__ctrls_8c_html_a9d15faa0a33797ce0b8a1a66d5773d88"><div class="ttname"><a href="floats__ctrls_8c.html#a9d15faa0a33797ce0b8a1a66d5773d88">cbor_ctrl_value</a></div><div class="ttdeci">uint8_t cbor_ctrl_value(const cbor_item_t *item)</div><div class="ttdoc">Reads the control value. </div><div class="ttdef"><b>Definition:</b> <a href="floats__ctrls_8c_source.html#l00018">floats_ctrls.c:18</a></div></div>
<div class="ttc" id="tags_8c_html_a2746e6a37373e0950b646e8146ed63b6"><div class="ttname"><a href="tags_8c.html#a2746e6a37373e0950b646e8146ed63b6">cbor_tag_value</a></div><div class="ttdeci">uint64_t cbor_tag_value(const cbor_item_t *item)</div><div class="ttdoc">Get tag value. </div><div class="ttdef"><b>Definition:</b> <a href="tags_8c_source.html#l00028">tags.c:28</a></div></div>
<div class="ttc" id="floats__ctrls_8c_html_a05778dc7349be636d47440f758ec96a6"><div class="ttname"><a href="floats__ctrls_8c.html#a05778dc7349be636d47440f758ec96a6">cbor_float_get_width</a></div><div class="ttdeci">cbor_float_width cbor_float_get_width(const cbor_item_t *item)</div><div class="ttdoc">Get the float width. </div><div class="ttdef"><b>Definition:</b> <a href="floats__ctrls_8c_source.html#l00012">floats_ctrls.c:12</a></div></div>
<div class="ttc" id="common_8c_html_a983dec76e934c49ed6979226f9db4386"><div class="ttname"><a href="common_8c.html#a983dec76e934c49ed6979226f9db4386">cbor_isa_float_ctrl</a></div><div class="ttdeci">bool cbor_isa_float_ctrl(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00053">common.c:53</a></div></div>
<div class="ttc" id="common_8c_html_a9ed0fa96105c211867c5032f2a5a8b20"><div class="ttname"><a href="common_8c.html#a9ed0fa96105c211867c5032f2a5a8b20">cbor_isa_array</a></div><div class="ttdeci">bool cbor_isa_array(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00038">common.c:38</a></div></div>
<div class="ttc" id="ints_8h_html"><div class="ttname"><a href="ints_8h.html">ints.h</a></div></div>
<div class="ttc" id="common_8c_html_af0de041481b61922d0995b63f82d8ddd"><div class="ttname"><a href="common_8c.html#af0de041481b61922d0995b63f82d8ddd">cbor_isa_map</a></div><div class="ttdeci">bool cbor_isa_map(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00043">common.c:43</a></div></div>
<div class="ttc" id="maps_8c_html_a0dccaa76ac293bb5a11dbca6d16f6253"><div class="ttname"><a href="maps_8c.html#a0dccaa76ac293bb5a11dbca6d16f6253">cbor_map_is_definite</a></div><div class="ttdeci">bool cbor_map_is_definite(const cbor_item_t *item)</div><div class="ttdoc">Is this map definite? </div><div class="ttdef"><b>Definition:</b> <a href="maps_8c_source.html#l00126">maps.c:126</a></div></div>
<div class="ttc" id="floats__ctrls_8c_html_aa85d79e0f060173a9dccdada2e551cf9"><div class="ttname"><a href="floats__ctrls_8c.html#aa85d79e0f060173a9dccdada2e551cf9">cbor_float_get_float2</a></div><div class="ttdeci">float cbor_float_get_float2(const cbor_item_t *item)</div><div class="ttdoc">Get a half precision float. </div><div class="ttdef"><b>Definition:</b> <a href="floats__ctrls_8c_source.html#l00031">floats_ctrls.c:31</a></div></div>
<div class="ttc" id="common_8c_html_a682a023f7012a5b66a57847e6f8d386f"><div class="ttname"><a href="common_8c.html#a682a023f7012a5b66a57847e6f8d386f">cbor_isa_uint</a></div><div class="ttdeci">bool cbor_isa_uint(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00018">common.c:18</a></div></div>
<div class="ttc" id="floats__ctrls_8c_html_a2f215940998d05730b23b7e0e7ad8ebe"><div class="ttname"><a href="floats__ctrls_8c.html#a2f215940998d05730b23b7e0e7ad8ebe">cbor_float_get_float8</a></div><div class="ttdeci">double cbor_float_get_float8(const cbor_item_t *item)</div><div class="ttdoc">Get a double precision float. </div><div class="ttdef"><b>Definition:</b> <a href="floats__ctrls_8c_source.html#l00045">floats_ctrls.c:45</a></div></div>
<div class="ttc" id="common_8c_html_a0d5054202c5ec9375e8daf5930087a61"><div class="ttname"><a href="common_8c.html#a0d5054202c5ec9375e8daf5930087a61">cbor_isa_tag</a></div><div class="ttdeci">bool cbor_isa_tag(const cbor_item_t *item)</div><div class="ttdoc">Does the item have the appropriate major type? </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00048">common.c:48</a></div></div>
<div class="ttc" id="data_8h_html_ae0fc9740f108f0f0078b93712b061e57a3a9caf604c45ce423b332e91f7370822"><div class="ttname"><a href="data_8h.html#ae0fc9740f108f0f0078b93712b061e57a3a9caf604c45ce423b332e91f7370822">CBOR_INT_16</a></div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00048">data.h:48</a></div></div>
<div class="ttc" id="encoding_8c_html_a4553dcc867b95ecfd6eb0dae79f69d81"><div class="ttname"><a href="encoding_8c.html#a4553dcc867b95ecfd6eb0dae79f69d81">cbor_encode_negint64</a></div><div class="ttdeci">size_t cbor_encode_negint64(uint64_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00052">encoding.c:52</a></div></div>
<div class="ttc" id="encoding_8c_html_abdc5b7670f02130ba5d0ffb01b25fab2"><div class="ttname"><a href="encoding_8c.html#abdc5b7670f02130ba5d0ffb01b25fab2">cbor_encode_uint32</a></div><div class="ttdeci">size_t cbor_encode_uint32(uint32_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00021">encoding.c:21</a></div></div>
<div class="ttc" id="memory__utils_8h_html"><div class="ttname"><a href="memory__utils_8h.html">memory_utils.h</a></div></div>
<div class="ttc" id="common_8c_html_ac2b9aba4cf07857524a0a520eabeef52"><div class="ttname"><a href="common_8c.html#ac2b9aba4cf07857524a0a520eabeef52">cbor_typeof</a></div><div class="ttdeci">cbor_type cbor_typeof(const cbor_item_t *item)</div><div class="ttdoc">Get the type of the item. </div><div class="ttdef"><b>Definition:</b> <a href="common_8c_source.html#l00059">common.c:59</a></div></div>
<div class="ttc" id="bytestrings_8h_html"><div class="ttname"><a href="bytestrings_8h.html">bytestrings.h</a></div></div>
<div class="ttc" id="strings_8c_html_aa2778891e70dec4cd59c9a969294d4aa"><div class="ttname"><a href="strings_8c.html#aa2778891e70dec4cd59c9a969294d4aa">cbor_string_is_definite</a></div><div class="ttdeci">bool cbor_string_is_definite(const cbor_item_t *item)</div><div class="ttdoc">Is the string definite? </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00124">strings.c:124</a></div></div>
<div class="ttc" id="bytestrings_8c_html_a2c9d6feda3d0f87782168fa817f83be6"><div class="ttname"><a href="bytestrings_8c.html#a2c9d6feda3d0f87782168fa817f83be6">cbor_bytestring_handle</a></div><div class="ttdeci">unsigned char * cbor_bytestring_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the handle to the binary data. </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00018">bytestrings.c:18</a></div></div>
<div class="ttc" id="common_8h_html_a1e39038d9b8e9b3a1e6529c9ff6091b8"><div class="ttname"><a href="common_8h.html#a1e39038d9b8e9b3a1e6529c9ff6091b8">_CBOR_REALLOC</a></div><div class="ttdeci">#define _CBOR_REALLOC</div><div class="ttdef"><b>Definition:</b> <a href="common_8h_source.html#l00085">common.h:85</a></div></div>
<div class="ttc" id="encoding_8c_html_ae5fc25aee8ee4bb8605e105227cb21f5"><div class="ttname"><a href="encoding_8c.html#ae5fc25aee8ee4bb8605e105227cb21f5">cbor_encode_indef_string_start</a></div><div class="ttdeci">size_t cbor_encode_indef_string_start(unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00086">encoding.c:86</a></div></div>
<div class="ttc" id="serialization_8c_html_a56d372b02323e8df3a37eba69acafd31"><div class="ttname"><a href="serialization_8c.html#a56d372b02323e8df3a37eba69acafd31">cbor_serialize</a></div><div class="ttdeci">size_t cbor_serialize(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize the given item. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00020">serialization.c:20</a></div></div>
<div class="ttc" id="tags_8h_html"><div class="ttname"><a href="tags_8h.html">tags.h</a></div></div>
<div class="ttc" id="strings_8c_html_aa0c17825f920ebf122bd7b9abede919f"><div class="ttname"><a href="strings_8c.html#aa0c17825f920ebf122bd7b9abede919f">cbor_string_length</a></div><div class="ttdeci">size_t cbor_string_length(const cbor_item_t *item)</div><div class="ttdoc">Returns the length of the underlying string. </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00106">strings.c:106</a></div></div>
<div class="ttc" id="encoding_8c_html_acb1b57ebb4156007ddca6d724b9f794a"><div class="ttname"><a href="encoding_8c.html#acb1b57ebb4156007ddca6d724b9f794a">cbor_encode_bytestring_start</a></div><div class="ttdeci">size_t cbor_encode_bytestring_start(size_t length, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00062">encoding.c:62</a></div></div>
<div class="ttc" id="memory__utils_8c_html_abdee08be3f4cff35a94279fda66c4778"><div class="ttname"><a href="memory__utils_8c.html#abdee08be3f4cff35a94279fda66c4778">_cbor_safe_to_multiply</a></div><div class="ttdeci">bool _cbor_safe_to_multiply(size_t a, size_t b)</div><div class="ttdoc">Can a and b be multiplied without overflowing size_t? </div><div class="ttdef"><b>Definition:</b> <a href="memory__utils_8c_source.html#l00025">memory_utils.c:25</a></div></div>
<div class="ttc" id="encoding_8c_html_a72fd1996d81b30a81381707708aa186d"><div class="ttname"><a href="encoding_8c.html#a72fd1996d81b30a81381707708aa186d">cbor_encode_indef_bytestring_start</a></div><div class="ttdeci">size_t cbor_encode_indef_bytestring_start(unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00076">encoding.c:76</a></div></div>
<div class="ttc" id="structcbor__item__t_html"><div class="ttname"><a href="structcbor__item__t.html">cbor_item_t</a></div><div class="ttdoc">The item handle. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00149">data.h:149</a></div></div>
<div class="ttc" id="encoding_8c_html_a000a6bd597e43b3b438a5659db183f40"><div class="ttname"><a href="encoding_8c.html#a000a6bd597e43b3b438a5659db183f40">cbor_encode_negint16</a></div><div class="ttdeci">size_t cbor_encode_negint16(uint16_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00042">encoding.c:42</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6ae140516103af792c8f2af84390acfdcd"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6ae140516103af792c8f2af84390acfdcd">CBOR_TYPE_NEGINT</a></div><div class="ttdoc">1 - negative integers </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00026">data.h:26</a></div></div>
<div class="ttc" id="maps_8c_html_a4cadc8eb7ae7ff8d3f73482fb24455c9"><div class="ttname"><a href="maps_8c.html#a4cadc8eb7ae7ff8d3f73482fb24455c9">cbor_map_handle</a></div><div class="ttdeci">struct cbor_pair * cbor_map_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the pairs storage. </div><div class="ttdef"><b>Definition:</b> <a href="maps_8c_source.html#l00137">maps.c:137</a></div></div>
<div class="ttc" id="arrays_8c_html_a291a9f3ff12a2e2c58b2ca8b00280d40"><div class="ttname"><a href="arrays_8c.html#a291a9f3ff12a2e2c58b2ca8b00280d40">cbor_array_is_indefinite</a></div><div class="ttdeci">bool cbor_array_is_indefinite(const cbor_item_t *item)</div><div class="ttdoc">Is the array indefinite? </div><div class="ttdef"><b>Definition:</b> <a href="arrays_8c_source.html#l00094">arrays.c:94</a></div></div>
<div class="ttc" id="bytestrings_8c_html_a7c15a63fdc3830707eac0877a261f1cd"><div class="ttname"><a href="bytestrings_8c.html#a7c15a63fdc3830707eac0877a261f1cd">cbor_bytestring_length</a></div><div class="ttdeci">size_t cbor_bytestring_length(const cbor_item_t *item)</div><div class="ttdoc">Returns the length of the binary data. </div><div class="ttdef"><b>Definition:</b> <a href="bytestrings_8c_source.html#l00012">bytestrings.c:12</a></div></div>
<div class="ttc" id="encoding_8c_html_a41bdb572cc73d9648f4c13e8465b1dcb"><div class="ttname"><a href="encoding_8c.html#a41bdb572cc73d9648f4c13e8465b1dcb">cbor_encode_tag</a></div><div class="ttdeci">size_t cbor_encode_tag(uint64_t value, unsigned char *buffer, size_t buffer_size)</div><div class="ttdef"><b>Definition:</b> <a href="encoding_8c_source.html#l00111">encoding.c:111</a></div></div>
<div class="ttc" id="serialization_8c_html_a6f00ef0ca5354471214894c2e21ff19b"><div class="ttname"><a href="serialization_8c.html#a6f00ef0ca5354471214894c2e21ff19b">cbor_serialize_negint</a></div><div class="ttdeci">size_t cbor_serialize_negint(const cbor_item_t *item, unsigned char *buffer, size_t buffer_size)</div><div class="ttdoc">Serialize a negint. </div><div class="ttdef"><b>Definition:</b> <a href="serialization_8c_source.html#l00093">serialization.c:93</a></div></div>
<div class="ttc" id="arrays_8c_html_a8dd01f4a46f162fa4f06b7df7428128e"><div class="ttname"><a href="arrays_8c.html#a8dd01f4a46f162fa4f06b7df7428128e">cbor_array_handle</a></div><div class="ttdeci">cbor_item_t ** cbor_array_handle(const cbor_item_t *item)</div><div class="ttdoc">Get the array contents. </div><div class="ttdef"><b>Definition:</b> <a href="arrays_8c_source.html#l00100">arrays.c:100</a></div></div>
<div class="ttc" id="data_8h_html_a3a931b40fc31b51cccfd1bc3dc5fc5d6a057fc3133cb4465f9eb734acfd195db2"><div class="ttname"><a href="data_8h.html#a3a931b40fc31b51cccfd1bc3dc5fc5d6a057fc3133cb4465f9eb734acfd195db2">CBOR_TYPE_MAP</a></div><div class="ttdoc">5 - maps </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00030">data.h:30</a></div></div>
<div class="ttc" id="data_8h_html_ac80d3ecbbdc88d96a7396ac986ee47e7a0b2ba87d2508e98e5f6fee7bf8beedd4"><div class="ttname"><a href="data_8h.html#ac80d3ecbbdc88d96a7396ac986ee47e7a0b2ba87d2508e98e5f6fee7bf8beedd4">CBOR_FLOAT_32</a></div><div class="ttdoc">Single float. </div><div class="ttdef"><b>Definition:</b> <a href="data_8h_source.html#l00057">data.h:57</a></div></div>
<div class="ttc" id="strings_8c_html_aa1a92438a04ae77beea9a17910805530"><div class="ttname"><a href="strings_8c.html#aa1a92438a04ae77beea9a17910805530">cbor_string_is_indefinite</a></div><div class="ttdeci">bool cbor_string_is_indefinite(const cbor_item_t *item)</div><div class="ttdoc">Is the string indefinite? </div><div class="ttdef"><b>Definition:</b> <a href="strings_8c_source.html#l00130">strings.c:130</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Mon Feb 6 2017 00:26:19 for libcbor by  <a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.12
</small></address>
</body>
</html>