Files
pcp/man/html/buffer_8h_source.html
2014-02-20 20:09:24 +01:00

192 lines
33 KiB
HTML

<!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"/>
<title>libpcp: buffer.h 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="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">libpcp
&#160;<span id="projectnumber">0.2.1</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.2 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="annotated.html"><span>Classes</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="files.html"><span>File&#160;List</span></a></li>
</ul>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_76e3dfa7802a76391b3a5cc4012b4dd7.html">pcp</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">buffer.h</div> </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span>&#160;<span class="comment"> This file is part of Pretty Curved Privacy (pcp1).</span></div>
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span>&#160;<span class="comment"> Copyright (C) 2013-2014 T.v.Dein.</span></div>
<div class="line"><a name="l00005"></a><span class="lineno"> 5</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span>&#160;<span class="comment"> This program is free software: you can redistribute it and/or modify</span></div>
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span>&#160;<span class="comment"> it under the terms of the GNU General Public License as published by</span></div>
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span>&#160;<span class="comment"> the Free Software Foundation, either version 3 of the License, or</span></div>
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span>&#160;<span class="comment"> (at your option) any later version.</span></div>
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span>&#160;<span class="comment"> This program is distributed in the hope that it will be useful,</span></div>
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span>&#160;<span class="comment"> but WITHOUT ANY WARRANTY; without even the implied warranty of</span></div>
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span>&#160;<span class="comment"> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span></div>
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span>&#160;<span class="comment"> GNU General Public License for more details.</span></div>
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span>&#160;<span class="comment"> You should have received a copy of the GNU General Public License</span></div>
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span>&#160;<span class="comment"> along with this program. If not, see &lt;http://www.gnu.org/licenses/&gt;.</span></div>
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>&#160;<span class="comment"> You can contact me by mail: &lt;tom AT vondein DOT org&gt;.</span></div>
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span>&#160;<span class="comment">*/</span></div>
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span>&#160;</div>
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span>&#160;<span class="preprocessor">#ifndef HAVE_PCP_BUFFER_H</span></div>
<div class="line"><a name="l00023"></a><span class="lineno"> 23</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HAVE_PCP_BUFFER_H</span></div>
<div class="line"><a name="l00024"></a><span class="lineno"> 24</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span>&#160;<span class="preprocessor">#include &lt;stdio.h&gt;</span></div>
<div class="line"><a name="l00026"></a><span class="lineno"> 26</span>&#160;<span class="preprocessor">#include &lt;stdarg.h&gt;</span></div>
<div class="line"><a name="l00027"></a><span class="lineno"> 27</span>&#160;<span class="preprocessor">#include &quot;mem.h&quot;</span></div>
<div class="line"><a name="l00028"></a><span class="lineno"> 28</span>&#160;<span class="preprocessor">#include &quot;util.h&quot;</span></div>
<div class="line"><a name="l00029"></a><span class="lineno"> 29</span>&#160;<span class="preprocessor">#include &quot;defines.h&quot;</span></div>
<div class="line"><a name="l00030"></a><span class="lineno"> 30</span>&#160;</div>
<div class="line"><a name="l00050"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html"> 50</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">_pcp_buffer</a> {</div>
<div class="line"><a name="l00051"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3"> 51</a></span>&#160; <span class="keywordtype">char</span> *<a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3" title="just for convenience in error messages and the like, so we know which buffer cause trouble...">name</a>; </div>
<div class="line"><a name="l00052"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#a48fee003c319d92f8d9a5e4c2c735e6f"> 52</a></span>&#160; uint8_t <a class="code" href="struct__pcp__buffer.html#a48fee003c319d92f8d9a5e4c2c735e6f" title="marks the buffer as allocated">allocated</a>; </div>
<div class="line"><a name="l00053"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#a7fdd9e4a9ed7abfc5eec36cb1eca281a"> 53</a></span>&#160; <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a7fdd9e4a9ed7abfc5eec36cb1eca281a" title="the blocksize to use when resizing, also used for initial malloc()">blocksize</a>; </div>
<div class="line"><a name="l00054"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#a8bf9eb28e7fa878847212133ece0c482"> 54</a></span>&#160; <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a8bf9eb28e7fa878847212133ece0c482" title="stores the current allocated size of the object">size</a>; </div>
<div class="line"><a name="l00055"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#a0ea19798e2cd04c152980bd7caac5d10"> 55</a></span>&#160; <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a0ea19798e2cd04c152980bd7caac5d10" title="current read position">offset</a>; </div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#acad944641be2d2e4c4109f83b6a6609f"> 56</a></span>&#160; <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#acad944641be2d2e4c4109f83b6a6609f" title="current write position, data end.">end</a>; </div>
<div class="line"><a name="l00057"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#aa1e4c60e982f39498ce66af85325bab6"> 57</a></span>&#160; uint8_t <a class="code" href="struct__pcp__buffer.html#aa1e4c60e982f39498ce66af85325bab6" title="treat as char array/string">isstring</a>; </div>
<div class="line"><a name="l00058"></a><span class="lineno"><a class="code" href="struct__pcp__buffer.html#a8d80e52785446bcc9e2fd4456c97daf5"> 58</a></span>&#160; <span class="keywordtype">void</span> *<a class="code" href="struct__pcp__buffer.html#a8d80e52785446bcc9e2fd4456c97daf5" title="the actual storage buffer">buf</a>; </div>
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>&#160;};</div>
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>&#160;</div>
<div class="line"><a name="l00062"></a><span class="lineno"><a class="code" href="group__Buffer.html#ga2460ea15a51a37433b5f2e1503667e8f"> 62</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">_pcp_buffer</a> <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a>;</div>
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>&#160;</div>
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>&#160;<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *<a class="code" href="group__Buffer.html#ga55e468b36750f28308b7fa5dfea5b564" title="Create a new buffer.">buffer_new</a>(<span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a7fdd9e4a9ed7abfc5eec36cb1eca281a" title="the blocksize to use when resizing, also used for initial malloc()">blocksize</a>, <span class="keywordtype">char</span> *<a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3" title="just for convenience in error messages and the like, so we know which buffer cause trouble...">name</a>);</div>
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>&#160;</div>
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>&#160;<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *<a class="code" href="group__Buffer.html#ga770f9c4e3caf1bcf315666a56312246f" title="Create a new string buffer.">buffer_new_str</a>(<span class="keywordtype">char</span> *<a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3" title="just for convenience in error messages and the like, so we know which buffer cause trouble...">name</a>);</div>
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>&#160;</div>
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>&#160;</div>
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>&#160;<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *<a class="code" href="group__Buffer.html#ga924b013cdf1e6f7b38ba9d10b3b7112e" title="Create a new buffer from existing data.">buffer_new_buf</a>(<span class="keywordtype">char</span> *<a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3" title="just for convenience in error messages and the like, so we know which buffer cause trouble...">name</a>, <span class="keywordtype">void</span> *data, <span class="keywordtype">size_t</span> datasize);</div>
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>&#160;</div>
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>&#160;<span class="comment">/* initialize buffer vars */</span></div>
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>&#160;<span class="keywordtype">void</span> buffer_init(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a7fdd9e4a9ed7abfc5eec36cb1eca281a" title="the blocksize to use when resizing, also used for initial malloc()">blocksize</a>, <span class="keywordtype">char</span> *<a class="code" href="struct__pcp__buffer.html#aa45619703bed4597d1ac7a45c40b92e3" title="just for convenience in error messages and the like, so we know which buffer cause trouble...">name</a>);</div>
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>&#160;</div>
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#gaa1c00049898e0ea7d6570748bf9a0e9e" title="Clears and frees the Buffer.">buffer_free</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>&#160;</div>
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga96b992409df040ca36ac65c83c748e71" title="Clears the Buffer.">buffer_clear</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>&#160;</div>
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#gaf8731a858abb423ad9cbecc8666b79dd" title="Put read offset back to start.">buffer_rewind</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>&#160;</div>
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga17edc4ffe7ea459a42ffdd6540d5f213" title="Add data to the buffer.">buffer_add</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keyword">const</span> <span class="keywordtype">void</span> *data, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>&#160;</div>
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#gab3b5de7a9eb3cca96a9df0b8f90766eb" title="Add data to the buffer.">buffer_add_buf</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *dst, <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *src);</div>
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>&#160;</div>
<div class="line"><a name="l00239"></a><span class="lineno"> 239</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga5b99c0ae55b2e279339c745b6fd7bb21" title="Add a formated string to the buffer.">buffer_add_str</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keyword">const</span> <span class="keywordtype">char</span> * fmt, ...);</div>
<div class="line"><a name="l00240"></a><span class="lineno"> 240</span>&#160;</div>
<div class="line"><a name="l00256"></a><span class="lineno"> 256</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga3a57658aba6c18d93219334b369e8663" title="Add data as hex string to the buffer.">buffer_add_hex</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keywordtype">void</span> *data, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00257"></a><span class="lineno"> 257</span>&#160;</div>
<div class="line"><a name="l00258"></a><span class="lineno"> 258</span>&#160;<span class="comment">/* resize the buffer if necessary, used internally only */</span></div>
<div class="line"><a name="l00259"></a><span class="lineno"> 259</span>&#160;<span class="keywordtype">void</span> buffer_resize(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00260"></a><span class="lineno"> 260</span>&#160;</div>
<div class="line"><a name="l00270"></a><span class="lineno"> 270</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group__Buffer.html#ga914506665c6fac92ccb17f92cefd0914" title="Tell if there are no more bytes to read.">buffer_done</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00271"></a><span class="lineno"> 271</span>&#160;</div>
<div class="line"><a name="l00303"></a><span class="lineno"> 303</span>&#160;<span class="keywordtype">size_t</span> <a class="code" href="group__Buffer.html#gaddf2e52378c6cd765b940617cdef2bd2" title="Read some chunk of data from the Buffer.">buffer_get_chunk</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keywordtype">void</span> *<a class="code" href="struct__pcp__buffer.html#a8d80e52785446bcc9e2fd4456c97daf5" title="the actual storage buffer">buf</a>, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00304"></a><span class="lineno"> 304</span>&#160;</div>
<div class="line"><a name="l00319"></a><span class="lineno"> 319</span>&#160;<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *<a class="code" href="group__Buffer.html#ga4411acab20dfabc5834fe11322bee661" title="Read the whole Buffer content.">buffer_get</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00320"></a><span class="lineno"> 320</span>&#160;</div>
<div class="line"><a name="l00345"></a><span class="lineno"> 345</span>&#160;<span class="keywordtype">char</span> *<a class="code" href="group__Buffer.html#ga8c89e4ab5d03dff079b7b861a1e04a7f" title="Read the whole Buffer content as string.">buffer_get_str</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00346"></a><span class="lineno"> 346</span>&#160;</div>
<div class="line"><a name="l00381"></a><span class="lineno"> 381</span>&#160;<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *<a class="code" href="group__Buffer.html#gaeafab0893e204b624eb5181954cbc9ca" title="Read the remaining data after current read offset.">buffer_get_remainder</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00382"></a><span class="lineno"> 382</span>&#160;</div>
<div class="line"><a name="l00418"></a><span class="lineno"> 418</span>&#160;<span class="keywordtype">size_t</span> <a class="code" href="group__Buffer.html#gab91a95b51ecfa067bdcca086f7afe4e4" title="Read some data inside the Buffer.">buffer_extract</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, <span class="keywordtype">void</span> *<a class="code" href="struct__pcp__buffer.html#a8d80e52785446bcc9e2fd4456c97daf5" title="the actual storage buffer">buf</a>, <span class="keywordtype">size_t</span> <a class="code" href="struct__pcp__buffer.html#a0ea19798e2cd04c152980bd7caac5d10" title="current read position">offset</a>, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00419"></a><span class="lineno"> 419</span>&#160;</div>
<div class="line"><a name="l00424"></a><span class="lineno"> 424</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga0e0f433cbd077d3048ebdda35aa9ccb6" title="Dump the Buffer contents to stderr in hex form.">buffer_dump</a>(<span class="keyword">const</span> <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00425"></a><span class="lineno"> 425</span>&#160;</div>
<div class="line"><a name="l00430"></a><span class="lineno"> 430</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#gad4b243dbcad9cb27abad40c8dcab7b22" title="Print Buffer counters to stderr.">buffer_info</a>(<span class="keyword">const</span> <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00431"></a><span class="lineno"> 431</span>&#160;</div>
<div class="line"><a name="l00442"></a><span class="lineno"> 442</span>&#160;<span class="keywordtype">size_t</span> <a class="code" href="group__Buffer.html#ga714b0a831d0f31a33e66e8ef76a26e46" title="Tell how much data there is in the buffer available.">buffer_size</a>(<span class="keyword">const</span> <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00443"></a><span class="lineno"> 443</span>&#160;</div>
<div class="line"><a name="l00472"></a><span class="lineno"> 472</span>&#160;<span class="keywordtype">size_t</span> <a class="code" href="group__Buffer.html#gaedba431c6b8e302e0d94cd9fafc3d292" title="Tell how much data is left to read in the Buffer.">buffer_left</a>(<span class="keyword">const</span> <a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00473"></a><span class="lineno"> 473</span>&#160;</div>
<div class="line"><a name="l00480"></a><span class="lineno"> 480</span>&#160;uint8_t <a class="code" href="group__Buffer.html#gae6a7aec563f6d66a94abc1fd3e10bf1e" title="Read 1 byte (8 bit) number from a Buffer.">buffer_get8</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00481"></a><span class="lineno"> 481</span>&#160;</div>
<div class="line"><a name="l00488"></a><span class="lineno"> 488</span>&#160;uint16_t <a class="code" href="group__Buffer.html#ga5b9bd1a6b474438db8cf4901ed750b92" title="Read 2 bytes (16 bit) number from a Buffer.">buffer_get16</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00489"></a><span class="lineno"> 489</span>&#160;</div>
<div class="line"><a name="l00496"></a><span class="lineno"> 496</span>&#160;uint32_t <a class="code" href="group__Buffer.html#ga42354f61519e2c7d6ae81a695f36d580" title="Read 4 byte (32 bit) number from a Buffer.">buffer_get32</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00497"></a><span class="lineno"> 497</span>&#160;</div>
<div class="line"><a name="l00504"></a><span class="lineno"> 504</span>&#160;uint64_t <a class="code" href="group__Buffer.html#gaf4da4b1c370490997c9d7103cfd20a83" title="Read 8 byte (64 bit) from a Buffer.">buffer_get64</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00505"></a><span class="lineno"> 505</span>&#160;</div>
<div class="line"><a name="l00512"></a><span class="lineno"> 512</span>&#160;uint16_t <a class="code" href="group__Buffer.html#ga1d71a1ae861f7d9763f8f59ca317ad49" title="Read 2 bytes (16 bit) number from a Buffer, converted to host endian.">buffer_get16na</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00513"></a><span class="lineno"> 513</span>&#160;</div>
<div class="line"><a name="l00520"></a><span class="lineno"> 520</span>&#160;uint32_t <a class="code" href="group__Buffer.html#ga46f10bed24ace6987844d4b12b39362f" title="Read 4 byte (32 bit) number from a Buffer, converted to host endian.">buffer_get32na</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00521"></a><span class="lineno"> 521</span>&#160;</div>
<div class="line"><a name="l00528"></a><span class="lineno"> 528</span>&#160;uint64_t <a class="code" href="group__Buffer.html#ga3c32fbab871258600bbdc848358c28cb" title="Read 8 byte (64 bit) from a Buffer, converted to host endian.">buffer_get64na</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00529"></a><span class="lineno"> 529</span>&#160;</div>
<div class="line"><a name="l00538"></a><span class="lineno"> 538</span>&#160;uint8_t <a class="code" href="group__Buffer.html#ga29dc7e7f34028600a92f8b85c8f94c38" title="Read the last 1 byte (8 bit) number from a Buffer.">buffer_last8</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00539"></a><span class="lineno"> 539</span>&#160;</div>
<div class="line"><a name="l00548"></a><span class="lineno"> 548</span>&#160;uint16_t <a class="code" href="group__Buffer.html#ga32959cf4cfad7c456e46fa93175508e4" title="Read the last 2 byte (16 bit) number from a Buffer.">buffer_last16</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00549"></a><span class="lineno"> 549</span>&#160;</div>
<div class="line"><a name="l00558"></a><span class="lineno"> 558</span>&#160;uint32_t <a class="code" href="group__Buffer.html#gafe524705c638959590e08ed3f63da37e" title="Read the last 4 byte (32 bit) number from a Buffer.">buffer_last32</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00559"></a><span class="lineno"> 559</span>&#160;</div>
<div class="line"><a name="l00568"></a><span class="lineno"> 568</span>&#160;uint64_t <a class="code" href="group__Buffer.html#ga48e50f95c09c029c265c37f2af7755f3" title="Read the last 8 byte (64 bit) number from a Buffer.">buffer_last64</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b);</div>
<div class="line"><a name="l00569"></a><span class="lineno"> 569</span>&#160;</div>
<div class="line"><a name="l00586"></a><span class="lineno"> 586</span>&#160;<span class="keywordtype">size_t</span> <a class="code" href="group__Buffer.html#ga2330b241d4fd267d193b05b508035935" title="Read data from a file directly into a Buffer.">buffer_fd_read</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, FILE *in, <span class="keywordtype">size_t</span> len);</div>
<div class="line"><a name="l00587"></a><span class="lineno"> 587</span>&#160;</div>
<div class="line"><a name="l00594"></a><span class="lineno"> 594</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga9125df8f37c49ae4443364acf711ae36" title="Write a 1 byte (8 bit) number in binary form into the buffer.">buffer_add8</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint8_t v);</div>
<div class="line"><a name="l00595"></a><span class="lineno"> 595</span>&#160;</div>
<div class="line"><a name="l00602"></a><span class="lineno"> 602</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga5f1e47affe629232ebdabb1070f9c8c6" title="Write a 2 byte (16 bit) number in binary form into the buffer.">buffer_add16</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint16_t v);</div>
<div class="line"><a name="l00603"></a><span class="lineno"> 603</span>&#160;</div>
<div class="line"><a name="l00610"></a><span class="lineno"> 610</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga2f36174e848271c8b0c525ea36d884fa" title="Write a 4 byte (32 bit) number in binary form into the buffer.">buffer_add32</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint32_t v);</div>
<div class="line"><a name="l00611"></a><span class="lineno"> 611</span>&#160;</div>
<div class="line"><a name="l00618"></a><span class="lineno"> 618</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga4d37d8261c678d747472e47b30c6299f" title="Write a 8 byte (64 bit) number in binary form into the buffer.">buffer_add64</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint64_t v);</div>
<div class="line"><a name="l00619"></a><span class="lineno"> 619</span>&#160;</div>
<div class="line"><a name="l00626"></a><span class="lineno"> 626</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#gab2141b987b8eb383da3f336f285384c5" title="Write a 2 byte (16 bit) number in binary form into the buffer, converted to big endian.">buffer_add16be</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint16_t v);</div>
<div class="line"><a name="l00627"></a><span class="lineno"> 627</span>&#160;</div>
<div class="line"><a name="l00634"></a><span class="lineno"> 634</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga601c4d9cd62c52639f0536524830dfa5" title="Write a 4 byte (32 bit) number in binary form into the buffer, converted to big endian.">buffer_add32be</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint32_t v);</div>
<div class="line"><a name="l00635"></a><span class="lineno"> 635</span>&#160;</div>
<div class="line"><a name="l00642"></a><span class="lineno"> 642</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__Buffer.html#ga6bbc5298e3c0a31eda31d48bfd63943a" title="Write a 8 byte (64 bit) number in binary form into the buffer, converted to big endian.">buffer_add64be</a>(<a class="code" href="struct__pcp__buffer.html" title="A flexible buffer object wich automatically resizes, if neccessary.">Buffer</a> *b, uint64_t v);</div>
<div class="line"><a name="l00643"></a><span class="lineno"> 643</span>&#160;</div>
<div class="line"><a name="l00644"></a><span class="lineno"> 644</span>&#160;</div>
<div class="line"><a name="l00645"></a><span class="lineno"> 645</span>&#160;<span class="preprocessor">#endif // HAVE_PCP_BUFFER_H</span></div>
<div class="line"><a name="l00646"></a><span class="lineno"> 646</span>&#160;<span class="preprocessor"></span></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Thu Feb 20 2014 19:59:14 for libpcp by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.2
</small></address>
</body>
</html>