/usr/share/doc/opendbx-doc/html/classOpenDBX_1_1Lob.html is in opendbx-doc 1.4.6-8.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 | <!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.8"/>
<title>opendbx: OpenDBX::Lob Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="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">opendbx
 <span id="projectnumber">1.4.6</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.8 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="functions.html"><span>Class Members</span></a></li>
</ul>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespaceOpenDBX.html">OpenDBX</a></li><li class="navelem"><a class="el" href="classOpenDBX_1_1Lob.html">Lob</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> |
<a href="#pro-methods">Protected Member Functions</a> |
<a href="classOpenDBX_1_1Lob-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">OpenDBX::Lob Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Handling large objects if supported by the database.
<a href="classOpenDBX_1_1Lob.html#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ab422fa80149df087aedff86aea415ae2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#ab422fa80149df087aedff86aea415ae2">close</a> () throw ( std::exception )</td></tr>
<tr class="memdesc:ab422fa80149df087aedff86aea415ae2"><td class="mdescLeft"> </td><td class="mdescRight">Closes the large object and commits the changes. <a href="#ab422fa80149df087aedff86aea415ae2">More...</a><br /></td></tr>
<tr class="separator:ab422fa80149df087aedff86aea415ae2"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8453ee06562ed3d12c1e995d1b98d451"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#a8453ee06562ed3d12c1e995d1b98d451">Lob</a> (const <a class="el" href="classOpenDBX_1_1Lob.html">Lob</a> &ref) throw ()</td></tr>
<tr class="memdesc:a8453ee06562ed3d12c1e995d1b98d451"><td class="mdescLeft"> </td><td class="mdescRight">Copy constructor. <a href="#a8453ee06562ed3d12c1e995d1b98d451">More...</a><br /></td></tr>
<tr class="separator:a8453ee06562ed3d12c1e995d1b98d451"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab391e5b3e919503e97438084a63ee639"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classOpenDBX_1_1Lob.html">Lob</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#ab391e5b3e919503e97438084a63ee639">operator=</a> (const <a class="el" href="classOpenDBX_1_1Lob.html">Lob</a> &ref) throw ()</td></tr>
<tr class="memdesc:ab391e5b3e919503e97438084a63ee639"><td class="mdescLeft"> </td><td class="mdescRight">Assign large object instance to another one. <a href="#ab391e5b3e919503e97438084a63ee639">More...</a><br /></td></tr>
<tr class="separator:ab391e5b3e919503e97438084a63ee639"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8a1640bc761e54312f890acbf42faf57"><td class="memItemLeft" align="right" valign="top">ssize_t </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#a8a1640bc761e54312f890acbf42faf57">read</a> (void *buffer, size_t buflen) throw ( std::exception )</td></tr>
<tr class="memdesc:a8a1640bc761e54312f890acbf42faf57"><td class="mdescLeft"> </td><td class="mdescRight">Reads content from large object into the buffer. <a href="#a8a1640bc761e54312f890acbf42faf57">More...</a><br /></td></tr>
<tr class="separator:a8a1640bc761e54312f890acbf42faf57"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ad4f1eed1131cc11232b2f362cae5026d"><td class="memItemLeft" align="right" valign="top">ssize_t </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#ad4f1eed1131cc11232b2f362cae5026d">write</a> (void *buffer, size_t buflen) throw ( std::exception )</td></tr>
<tr class="memdesc:ad4f1eed1131cc11232b2f362cae5026d"><td class="mdescLeft"> </td><td class="mdescRight">Writes data from the buffer into the large object. <a href="#ad4f1eed1131cc11232b2f362cae5026d">More...</a><br /></td></tr>
<tr class="separator:ad4f1eed1131cc11232b2f362cae5026d"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a707489f5aae2291e8cd32df9fc9719bb"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#a707489f5aae2291e8cd32df9fc9719bb">~Lob</a> () throw ()</td></tr>
<tr class="memdesc:a707489f5aae2291e8cd32df9fc9719bb"><td class="mdescLeft"> </td><td class="mdescRight">Destroy large object instance if no other references exist. <a href="#a707489f5aae2291e8cd32df9fc9719bb">More...</a><br /></td></tr>
<tr class="separator:a707489f5aae2291e8cd32df9fc9719bb"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr class="memitem:af3cc35ec89c1b08cf8039b62b73612a8"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#af3cc35ec89c1b08cf8039b62b73612a8">Lob</a> () throw ()</td></tr>
<tr class="memdesc:af3cc35ec89c1b08cf8039b62b73612a8"><td class="mdescLeft"> </td><td class="mdescRight">Default constructor. <a href="#af3cc35ec89c1b08cf8039b62b73612a8">More...</a><br /></td></tr>
<tr class="separator:af3cc35ec89c1b08cf8039b62b73612a8"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ad8416db441f7ebc1ca2a00979ff618c5"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classOpenDBX_1_1Lob.html#ad8416db441f7ebc1ca2a00979ff618c5">Lob</a> (Lob_Iface *impl) throw ( std::exception )</td></tr>
<tr class="memdesc:ad8416db441f7ebc1ca2a00979ff618c5"><td class="mdescLeft"> </td><td class="mdescRight">Create large object instance. <a href="#ad8416db441f7ebc1ca2a00979ff618c5">More...</a><br /></td></tr>
<tr class="separator:ad8416db441f7ebc1ca2a00979ff618c5"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Handling large objects if supported by the database. </p>
<dl class="section author"><dt>Author</dt><dd>Norbert Sendetzky <a href="#" onclick="location.href='mai'+'lto:'+'nor'+'be'+'rt@'+'li'+'nux'+'ne'+'two'+'rk'+'s.d'+'e'; return false;">norbe<span style="display: none;">.nosp@m.</span>rt@l<span style="display: none;">.nosp@m.</span>inuxn<span style="display: none;">.nosp@m.</span>etwo<span style="display: none;">.nosp@m.</span>rks.d<span style="display: none;">.nosp@m.</span>e</a> </dd></dl>
<dl class="section version"><dt>Version</dt><dd>1.0 </dd></dl>
</div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
<a class="anchor" id="af3cc35ec89c1b08cf8039b62b73612a8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">OpenDBX::Lob::Lob </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2"></td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">protected</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Default constructor. </p>
<p>The default constructor isn't part of the public interface as the object must not be created manually. Instead, the <a class="el" href="classOpenDBX_1_1Result.html#ab2a9754356726bd7174348ac66c7c7ba" title="Creates a large object instance if supported by the database. ">Result::getLob()</a> method is a factory for instances of the large object class.</p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classOpenDBX_1_1Lob.html" title="Handling large objects if supported by the database. ">Lob</a> instance </dd></dl>
</div>
</div>
<a class="anchor" id="ad8416db441f7ebc1ca2a00979ff618c5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">OpenDBX::Lob::Lob </td>
<td>(</td>
<td class="paramtype">Lob_Iface * </td>
<td class="paramname"><em>impl</em></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2">std::exception</td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Create large object instance. </p>
<p>The constructor isn't part of the public interface as the object must not be created manually. Instead, the <a class="el" href="classOpenDBX_1_1Result.html#ab2a9754356726bd7174348ac66c7c7ba" title="Creates a large object instance if supported by the database. ">Result::getLob()</a> method is a factory for instances of the large object class.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">impl</td><td>Pointer to private implementation </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classOpenDBX_1_1Lob.html" title="Handling large objects if supported by the database. ">Lob</a> instance </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">std::exception</td><td>If an error occures </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="a707489f5aae2291e8cd32df9fc9719bb"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">OpenDBX::Lob::~Lob </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2"></td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Destroy large object instance if no other references exist. </p>
<p>Each large object uses a reference counter to remember if the internal variables are shared with other objects. If this isn't the case or if this object is the last one referencing the variables, the object is cleanup up and the allocated memory freed. </p>
</div>
</div>
<a class="anchor" id="a8453ee06562ed3d12c1e995d1b98d451"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">OpenDBX::Lob::Lob </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classOpenDBX_1_1Lob.html">Lob</a> & </td>
<td class="paramname"><em>ref</em></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2"></td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Copy constructor. </p>
<p>Enables the transfer of the internal state of an object <em>ref</em> of the same type to this object. Both objects share the same variables and the reference counter afterwards. The reference counter is incremented each time an object is copied and will be decremented if it is destroyed.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">ref</td><td>Original large object instance </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="ab422fa80149df087aedff86aea415ae2"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void OpenDBX::Lob::close </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2">std::exception</td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Closes the large object and commits the changes. </p>
<p>After reading from or writing new content into the large object, it should be closed to commit changes to the disk and clean up the resources. If this isn't done, the destructor of the object tries to close the large object automatically, but there's no guarantee it was successful as the destructor doesn't throw an exception in case of an error. Therefore, it's highly recommended to call this method once when you don't need the object any more.</p>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classOpenDBX_1_1Exception.html" title="Exceptions thrown by the OpenDBX classes. ">OpenDBX::Exception</a></td><td>If the underlying database library returns an error </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="ab391e5b3e919503e97438084a63ee639"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classOpenDBX_1_1Lob.html">Lob</a>& OpenDBX::Lob::operator= </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classOpenDBX_1_1Lob.html">Lob</a> & </td>
<td class="paramname"><em>ref</em></td><td>)</td>
<td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2"></td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Assign large object instance to another one. </p>
<p>Assigns the internal state of an object <em>ref</em> of the same type to this object. Both objects share the same variables and the reference counter afterwards. The reference counter is incremented each time an object is copied and will be decremented if it is destroyed.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">ref</td><td>Large object instance </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Large object reference of this instance </dd></dl>
</div>
</div>
<a class="anchor" id="a8a1640bc761e54312f890acbf42faf57"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">ssize_t OpenDBX::Lob::read </td>
<td>(</td>
<td class="paramtype">void * </td>
<td class="paramname"><em>buffer</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t </td>
<td class="paramname"><em>buflen</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2">std::exception</td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Reads content from large object into the buffer. </p>
<p>To get the content of a large object, this method fetches the data in one or more pieces from the server and stores it into the user supplied buffer. The first call to <a class="el" href="classOpenDBX_1_1Lob.html#a8a1640bc761e54312f890acbf42faf57" title="Reads content from large object into the buffer. ">read()</a> will return the bytes from the beginning. The second and all other calls will store subsequent parts of the large object content into the buffer until the end of the data is reached. To reread the content a second time, you have to close the large object handle and reopen it again as some databases provide no way to reposition the internal file position indicator for the stream. The large object content fetched from the server is stored into the user supplied <em>buffer</em> up to <em>buflen</em> bytes.</p>
<p>The method returns the number of bytes placed into <em>buffer</em>, which may be up to <em>buflen</em> bytes. If the end of the content is reached and no more data is available, the return value will be 0 (zero).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">buffer</td><td>Pointer to a byte array where the data should be written to </td></tr>
<tr><td class="paramname">buflen</td><td>Length of the given buffer in bytes </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Number of bytes written into the buffer </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classOpenDBX_1_1Exception.html" title="Exceptions thrown by the OpenDBX classes. ">OpenDBX::Exception</a></td><td>If the underlying database library returns an error </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="ad4f1eed1131cc11232b2f362cae5026d"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">ssize_t OpenDBX::Lob::write </td>
<td>(</td>
<td class="paramtype">void * </td>
<td class="paramname"><em>buffer</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t </td>
<td class="paramname"><em>buflen</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
<tr>
<td align="right">throw </td><td>(</td><td colspan="2">std::exception</td>
</tr>
<tr>
<td align="right"></td><td>)</td><td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Writes data from the buffer into the large object. </p>
<p>It sends the data supplied in buffer to the server for storing it inside the large object. The function can be called more than once to add subsequent parts of the content to the object. If it isn't a new or empty object, the existing data will be overwritten and truncated to the new size. It's not possible to update only parts of the content as some databases doesn't support to position the internal file position indicator. The data which should be send to the server is read from <em>buffer</em> up to <em>buflen</em> bytes.</p>
<p>The method returns the number of bytes read from <em>buffer</em> and sent to the database server, which may be up to <em>buflen</em> bytes. It isn't guaranteed that the complete chunk was sent to the server, so the returned size may be less than the value in <em>buflen</em>.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">buffer</td><td>Pointer to a byte array where the content is stored </td></tr>
<tr><td class="paramname">buflen</td><td>Length of the data in the buffer in bytes </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Number of bytes written into the large object </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classOpenDBX_1_1Exception.html" title="Exceptions thrown by the OpenDBX classes. ">OpenDBX::Exception</a></td><td>If the underlying database library returns an error </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>opendbx/api.dox</li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Fri Sep 5 2014 18:37:24 for opendbx by  <a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.8
</small></address>
</body>
</html>
|