/usr/share/doc/libucommon-dev/a00155.html is in libucommon-doc 3.2.0-0ubuntu1.
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 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 | <!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"/>
<title>UCommon: ucc::stack Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.6.3 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="main.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>Data Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
<li><a href="examples.html"><span>Examples</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Data Structures</span></a></li>
<li><a href="classes.html"><span>Data Structure Index</span></a></li>
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
<li><a href="functions.html"><span>Data Fields</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="a00214.html">ucc</a>::<a class="el" href="a00155.html">stack</a>
</div>
</div>
<div class="contents">
<h1>ucc::stack Class Reference</h1><!-- doxytag: class="ucc::stack" --><!-- doxytag: inherits="ucc::Conditional" -->
<p>Manage a thread-safe stack of objects through reference pointers.
<a href="#_details">More...</a></p>
<p><code>#include <<a class="el" href="a00208_source.html">thread.h</a>></code></p>
<div class="dynheader">
Inheritance diagram for ucc::stack:</div>
<div class="dynsection">
<div class="center"><img src="a00553.png" border="0" usemap="#ucc_1_1stack_inherit__map" alt="Inheritance graph"/></div>
<map name="ucc_1_1stack_inherit__map" id="ucc_1_1stack_inherit__map">
<area shape="rect" id="node5" href="a00156.html" title="A templated typed class for thread-safe stack of object pointers." alt="" coords="5,160,139,189"/><area shape="rect" id="node2" href="a00040.html" title="The conditional is a common base for other thread synchronizing classes." alt="" coords="11,5,133,35"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<div class="dynheader">
Collaboration diagram for ucc::stack:</div>
<div class="dynsection">
<div class="center"><img src="a00554.png" border="0" usemap="#ucc_1_1stack_coll__map" alt="Collaboration graph"/></div>
<map name="ucc_1_1stack_coll__map" id="ucc_1_1stack_coll__map">
<area shape="rect" id="node2" href="a00040.html" title="The conditional is a common base for other thread synchronizing classes." alt="" coords="5,96,128,125"/><area shape="rect" id="node4" href="a00081.html" title="A managed private heap for small allocations." alt="" coords="152,96,275,125"/><area shape="rect" id="node6" href="a00080.html" title="An alternate memory pager private heap manager." alt="" coords="156,5,271,35"/><area shape="rect" id="node8" href="a00069.html" title="Common base class for all objects that can be formed into a linked list." alt="" coords="299,96,432,125"/><area shape="rect" id="node10" href="a00093.html" title="A common base class for all managed objects." alt="" coords="319,5,412,35"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td colspan="2"><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a2e8e3e25994d9154f7f5a64f7b00699e">getCount</a> (void)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get number of object points currently in the stack. <a href="#a2e8e3e25994d9154f7f5a64f7b00699e"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="a00093.html">Object</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a7c98ac66f6d9c440d3fc3a95e6c6ae1a">pull</a> (<a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> timeout=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get and remove last object pushed on the stack. <a href="#a7c98ac66f6d9c440d3fc3a95e6c6ae1a"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a9b5e008fb6a164368c769dddc5b9d03c">push</a> (<a class="el" href="a00093.html">Object</a> *object, <a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> timeout=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Push an object into the stack by it's pointer. <a href="#a9b5e008fb6a164368c769dddc5b9d03c"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a177d074dbfa85598ea27df9600789f90">remove</a> (<a class="el" href="a00093.html">Object</a> *object)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Remove a specific object pointer for the queue. <a href="#a177d074dbfa85598ea27df9600789f90"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#afed24b4af2e2135f05118c3292b5de6f">stack</a> (<a class="el" href="a00081.html">mempager</a> *<a class="el" href="a00102.html">pager</a>=NULL, size_t number=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create a stack that uses a memory pager for internally managed member objects for a specified maximum number of object pointers. <a href="#afed24b4af2e2135f05118c3292b5de6f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a5a09db86099f07bda46f5ccfd332a6b2">~stack</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Destroy queue. <a href="#a5a09db86099f07bda46f5ccfd332a6b2"></a><br/></td></tr>
<tr><td colspan="2"><h2>Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#acfd9f28bdc3e5c28a841f52cbf753cd0">count</a> (<a class="el" href="a00155.html">stack</a> &<a class="el" href="a00155.html">stack</a>)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convenience function to get count of objects in the stack. <a href="#acfd9f28bdc3e5c28a841f52cbf753cd0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="a00093.html">Object</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a739b615f83ea098d8f745c408c525063">pull</a> (<a class="el" href="a00155.html">stack</a> &<a class="el" href="a00155.html">stack</a>, <a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> timeout=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convenience function pull last object from the stack. <a href="#a739b615f83ea098d8f745c408c525063"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a6022731e8799fffb574c07db65b03a9f">push</a> (<a class="el" href="a00155.html">stack</a> &<a class="el" href="a00155.html">stack</a>, <a class="el" href="a00093.html">Object</a> *object, <a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> timeout=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convenience function to push object into the stack. <a href="#a6022731e8799fffb574c07db65b03a9f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00155.html#a8525a1092c1dfa31efd711d7dbe56aeb">remove</a> (<a class="el" href="a00155.html">stack</a> &<a class="el" href="a00155.html">stack</a>, <a class="el" href="a00093.html">Object</a> *object)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convenience function to remove an object from the stacl. <a href="#a8525a1092c1dfa31efd711d7dbe56aeb"></a><br/></td></tr>
<tr><td colspan="2"><h2>Protected Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a23e2df1d062ff144b644e4ab994ce003"></a><!-- doxytag: member="ucc::stack::limit" ref="a23e2df1d062ff144b644e4ab994ce003" args="" -->
size_t </td><td class="memItemRight" valign="bottom"><b>limit</b></td></tr>
<tr><td colspan="2"><h2>Friends</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0352b76113cdfb8a6e0a3be7165742b8"></a><!-- doxytag: member="ucc::stack::member" ref="a0352b76113cdfb8a6e0a3be7165742b8" args="" -->
class </td><td class="memItemRight" valign="bottom"><b>member</b></td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>Manage a thread-safe stack of objects through reference pointers. </p>
<p>This Thread-safe access is managed through a conditional. This differs from the queue in lifo mode because delinking the last object is immediate, and because it has much less overhead. A pool of self-managed member objects are used to operate the stack. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>David Sugar <<a href="mailto:dyfet@gnutelephony.org">dyfet@gnutelephony.org</a>> </dd></dl>
<p>Definition at line <a class="el" href="a00208_source.html#l01801">1801</a> of file <a class="el" href="a00208_source.html">thread.h</a>.</p>
<hr/><h2>Constructor & Destructor Documentation</h2>
<a class="anchor" id="afed24b4af2e2135f05118c3292b5de6f"></a><!-- doxytag: member="ucc::stack::stack" ref="afed24b4af2e2135f05118c3292b5de6f" args="(mempager *pager=NULL, size_t number=0)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">ucc::stack::stack </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00081.html">mempager</a> * </td>
<td class="paramname"> <em>pager</em> = <code>NULL</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t </td>
<td class="paramname"> <em>number</em> = <code>0</code></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Create a stack that uses a memory pager for internally managed member objects for a specified maximum number of object pointers. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>pager</em> </td><td>to use for internal member object or NULL to use heap. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>number</em> </td><td>of pointers that can be in the stack or 0 if unlimited. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="a5a09db86099f07bda46f5ccfd332a6b2"></a><!-- doxytag: member="ucc::stack::~stack" ref="a5a09db86099f07bda46f5ccfd332a6b2" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">ucc::stack::~stack </td>
<td>(</td>
<td class="paramname"></td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Destroy queue. </p>
<p>If no pager is used, then frees heap. </p>
</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="acfd9f28bdc3e5c28a841f52cbf753cd0"></a><!-- doxytag: member="ucc::stack::count" ref="acfd9f28bdc3e5c28a841f52cbf753cd0" args="(stack &stack)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static size_t ucc::stack::count </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00155.html">stack</a> & </td>
<td class="paramname"> <em>stack</em></td>
<td> ) </td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Convenience function to get count of objects in the stack. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>stack</em> </td><td>to count. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>number of objects in the stack. </dd></dl>
<p>Definition at line <a class="el" href="a00208_source.html#l01901">1901</a> of file <a class="el" href="a00208_source.html">thread.h</a>.</p>
<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<div class="center"><img src="a00155_acfd9f28bdc3e5c28a841f52cbf753cd0_cgraph.png" border="0" usemap="#a00155_acfd9f28bdc3e5c28a841f52cbf753cd0_cgraph_map" alt=""></div>
<map name="a00155_acfd9f28bdc3e5c28a841f52cbf753cd0_cgraph_map" id="a00155_acfd9f28bdc3e5c28a841f52cbf753cd0_cgraph">
<area shape="rect" id="node3" href="a00155.html#a2e8e3e25994d9154f7f5a64f7b00699e" title="Get number of object points currently in the stack." alt="" coords="185,5,337,35"/></map>
</div>
</p>
</div>
</div>
<a class="anchor" id="a2e8e3e25994d9154f7f5a64f7b00699e"></a><!-- doxytag: member="ucc::stack::getCount" ref="a2e8e3e25994d9154f7f5a64f7b00699e" args="(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">size_t ucc::stack::getCount </td>
<td>(</td>
<td class="paramtype">void </td>
<td class="paramname"></td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get number of object points currently in the stack. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>number of objects in stack. </dd></dl>
</div>
</div>
<a class="anchor" id="a739b615f83ea098d8f745c408c525063"></a><!-- doxytag: member="ucc::stack::pull" ref="a739b615f83ea098d8f745c408c525063" args="(stack &stack, timeout_t timeout=0)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="a00093.html">Object</a>* ucc::stack::pull </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00155.html">stack</a> & </td>
<td class="paramname"> <em>stack</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> </td>
<td class="paramname"> <em>timeout</em> = <code>0</code></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Convenience function pull last object from the stack. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>stack</em> </td><td>to get from. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>to wait if empty. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>last object or NULL if timed out empty. </dd></dl>
<p>Definition at line <a class="el" href="a00208_source.html#l01893">1893</a> of file <a class="el" href="a00208_source.html">thread.h</a>.</p>
<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<div class="center"><img src="a00155_a739b615f83ea098d8f745c408c525063_cgraph.png" border="0" usemap="#a00155_a739b615f83ea098d8f745c408c525063_cgraph_map" alt=""></div>
<map name="a00155_a739b615f83ea098d8f745c408c525063_cgraph_map" id="a00155_a739b615f83ea098d8f745c408c525063_cgraph">
<area shape="rect" id="node3" href="a00155.html#a7c98ac66f6d9c440d3fc3a95e6c6ae1a" title="Get and remove last object pushed on the stack." alt="" coords="172,5,287,35"/></map>
</div>
</p>
</div>
</div>
<a class="anchor" id="a7c98ac66f6d9c440d3fc3a95e6c6ae1a"></a><!-- doxytag: member="ucc::stack::pull" ref="a7c98ac66f6d9c440d3fc3a95e6c6ae1a" args="(timeout_t timeout=0)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="a00093.html">Object</a>* ucc::stack::pull </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> </td>
<td class="paramname"> <em>timeout</em> = <code>0</code></td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get and remove last object pushed on the stack. </p>
<p>This can wait for a specified timeout of the stack is empty. The object is still retained and must be released or deleted by the receiving function. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>to wait if empty in milliseconds. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>object pulled from stack or NULL if empty and timed out. </dd></dl>
<p>Reimplemented in <a class="el" href="a00156.html#af4026ccd808a0140f0d0597ce0598e30">ucc::stackof< T ></a>.</p>
</div>
</div>
<a class="anchor" id="a6022731e8799fffb574c07db65b03a9f"></a><!-- doxytag: member="ucc::stack::push" ref="a6022731e8799fffb574c07db65b03a9f" args="(stack &stack, Object *object, timeout_t timeout=0)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool ucc::stack::push </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00155.html">stack</a> & </td>
<td class="paramname"> <em>stack</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00093.html">Object</a> * </td>
<td class="paramname"> <em>object</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> </td>
<td class="paramname"> <em>timeout</em> = <code>0</code></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Convenience function to push object into the stack. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>stack</em> </td><td>to push into. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>object</em> </td><td>to push. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>to wait if full. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if pusheded, false if timed out while full. </dd></dl>
<p>Definition at line <a class="el" href="a00208_source.html#l01884">1884</a> of file <a class="el" href="a00208_source.html">thread.h</a>.</p>
<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<div class="center"><img src="a00155_a6022731e8799fffb574c07db65b03a9f_cgraph.png" border="0" usemap="#a00155_a6022731e8799fffb574c07db65b03a9f_cgraph_map" alt=""></div>
<map name="a00155_a6022731e8799fffb574c07db65b03a9f_cgraph_map" id="a00155_a6022731e8799fffb574c07db65b03a9f_cgraph">
<area shape="rect" id="node3" href="a00155.html#a9b5e008fb6a164368c769dddc5b9d03c" title="Push an object into the stack by it's pointer." alt="" coords="179,5,304,35"/></map>
</div>
</p>
</div>
</div>
<a class="anchor" id="a9b5e008fb6a164368c769dddc5b9d03c"></a><!-- doxytag: member="ucc::stack::push" ref="a9b5e008fb6a164368c769dddc5b9d03c" args="(Object *object, timeout_t timeout=0)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool ucc::stack::push </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00093.html">Object</a> * </td>
<td class="paramname"> <em>object</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00201.html#af412159e5cef839836a5e7b19ee75d1c">timeout_t</a> </td>
<td class="paramname"> <em>timeout</em> = <code>0</code></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Push an object into the stack by it's pointer. </p>
<p>This can wait for a specified timeout if the stack is full, for example, for another thread to remove an object pointer. This also retains the object. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>object</em> </td><td>to push. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>to wait if stack is full in milliseconds. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if object pushed, false if stack full and timeout expired. </dd></dl>
</div>
</div>
<a class="anchor" id="a8525a1092c1dfa31efd711d7dbe56aeb"></a><!-- doxytag: member="ucc::stack::remove" ref="a8525a1092c1dfa31efd711d7dbe56aeb" args="(stack &stack, Object *object)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool ucc::stack::remove </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00155.html">stack</a> & </td>
<td class="paramname"> <em>stack</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00093.html">Object</a> * </td>
<td class="paramname"> <em>object</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Convenience function to remove an object from the stacl. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>stack</em> </td><td>to remove object from. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>object</em> </td><td>to remove. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if removed, false if not found. </dd></dl>
<p>Definition at line <a class="el" href="a00208_source.html#l01874">1874</a> of file <a class="el" href="a00208_source.html">thread.h</a>.</p>
</div>
</div>
<a class="anchor" id="a177d074dbfa85598ea27df9600789f90"></a><!-- doxytag: member="ucc::stack::remove" ref="a177d074dbfa85598ea27df9600789f90" args="(Object *object)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool ucc::stack::remove </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00093.html">Object</a> * </td>
<td class="paramname"> <em>object</em></td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Remove a specific object pointer for the queue. </p>
<p>This can remove a member from any location in the queue, whether beginning, end, or somewhere in the middle. This also releases the object. </p>
<dl><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>object</em> </td><td>to remove. </td></tr>
</table>
</dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if object was removed, false if not found. </dd></dl>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>ucommon/<a class="el" href="a00208_source.html">thread.h</a></li>
</ul>
</div>
<hr class="footer"/><address style="text-align: right;"><small>Generated on Tue Jul 6 08:22:50 2010 for UCommon by
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>
|