Sophie

Sophie

distrib > Mandriva > 2010.1 > i586 > by-pkgid > 4f5f2dc0f55b453456458df885792b0b > files > 269

ucommon-doc-5.0.4-1mdv2010.2.i586.rpm

<!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: ucommon::sarray&lt; T &gt; Class Template 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&nbsp;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Data&nbsp;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&nbsp;Structures</span></a></li>
      <li><a href="classes.html"><span>Data&nbsp;Structure&nbsp;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
    </ul>
  </div>
  <div class="navpath"><a class="el" href="a00208.html">ucommon</a>::<a class="el" href="a00117.html">sarray</a>
  </div>
</div>
<div class="contents">
<h1>ucommon::sarray&lt; T &gt; Class Template Reference</h1><!-- doxytag: class="ucommon::sarray" --><!-- doxytag: inherits="ucommon::sparse_array" -->
<p>Generate a typed sparse managed object array.  
<a href="#_details">More...</a></p>

<p><code>#include &lt;<a class="el" href="a00192_source.html">object.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for ucommon::sarray&lt; T &gt;:</div>
<div class="dynsection">
<div class="center"><img src="a00489.png" border="0" usemap="#ucommon_1_1sarray_3_01_t_01_4_inherit__map" alt="Inheritance graph"/></div>
<map name="ucommon_1_1sarray_3_01_t_01_4_inherit__map" id="ucommon_1_1sarray_3_01_t_01_4_inherit__map">
<area shape="rect" id="node2" href="a00142.html" title="A sparse array of managed objects." alt="" coords="5,5,237,32"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<div class="dynheader">
Collaboration diagram for ucommon::sarray&lt; T &gt;:</div>
<div class="dynsection">
<div class="center"><img src="a00490.png" border="0" usemap="#ucommon_1_1sarray_3_01_t_01_4_coll__map" alt="Collaboration graph"/></div>
<map name="ucommon_1_1sarray_3_01_t_01_4_coll__map" id="ucommon_1_1sarray_3_01_t_01_4_coll__map">
<area shape="rect" id="node2" href="a00142.html" title="A sparse array of managed objects." alt="" coords="15,96,247,123"/><area shape="rect" id="node4" href="a00095.html" title="A common base class for all managed objects." alt="" coords="5,5,256,32"/></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">T *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00117.html#ae9a0fa2485c336c85ecf4114cf97a564">get</a> (unsigned offset)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get typed member of array.  <a href="#ae9a0fa2485c336c85ecf4114cf97a564"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">T &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00117.html#a458a11b6eaab5ade8566dbf1585c1317">operator[]</a> (unsigned offset)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Array operation to access member object.  <a href="#a458a11b6eaab5ade8566dbf1585c1317"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00117.html#a697ace911a1df2f9b76e1f3e4a424116">sarray</a> (unsigned size)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Generate a sparse typed array of specified size.  <a href="#a697ace911a1df2f9b76e1f3e4a424116"></a><br/></td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<h3>template&lt;class T&gt;<br/>
 class ucommon::sarray&lt; T &gt;</h3>

<p>Generate a typed sparse managed object array. </p>
<p>Members in the array are created when they are first referenced. The types for objects that are generated by sarray must have Object as a base class. Managed sparse arrays differ from standard arrays in that the member elements are not allocated from the heap when the array is created, but rather as they are needed. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>David Sugar &lt;<a href="mailto:dyfet@gnutelephony.org">dyfet@gnutelephony.org</a>&gt; </dd></dl>

<p>Definition at line <a class="el" href="a00192_source.html#l00301">301</a> of file <a class="el" href="a00192_source.html">object.h</a>.</p>
<hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a697ace911a1df2f9b76e1f3e4a424116"></a><!-- doxytag: member="ucommon::sarray::sarray" ref="a697ace911a1df2f9b76e1f3e4a424116" args="(unsigned size)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00117.html">ucommon::sarray</a>&lt; T &gt;::<a class="el" href="a00117.html">sarray</a> </td>
          <td>(</td>
          <td class="paramtype">unsigned&nbsp;</td>
          <td class="paramname"> <em>size</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Generate a sparse typed array of specified size. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>of array to create. </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="a00192_source.html#l00308">308</a> of file <a class="el" href="a00192_source.html">object.h</a>.</p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="ae9a0fa2485c336c85ecf4114cf97a564"></a><!-- doxytag: member="ucommon::sarray::get" ref="ae9a0fa2485c336c85ecf4114cf97a564" args="(unsigned offset)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">T* <a class="el" href="a00117.html">ucommon::sarray</a>&lt; T &gt;::get </td>
          <td>(</td>
          <td class="paramtype">unsigned&nbsp;</td>
          <td class="paramname"> <em>offset</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get typed member of array. </p>
<p>If the object does not exist, it is created. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>offset</em>&nbsp;</td><td>in array for object. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>pointer to typed object. </dd></dl>

<p>Reimplemented from <a class="el" href="a00142.html#a3530371b1cbddf09b37a09170f6253d6">ucommon::sparse_array</a>.</p>

<p>Definition at line <a class="el" href="a00192_source.html#l00316">316</a> of file <a class="el" href="a00192_source.html">object.h</a>.</p>

</div>
</div>
<a class="anchor" id="a458a11b6eaab5ade8566dbf1585c1317"></a><!-- doxytag: member="ucommon::sarray::operator[]" ref="a458a11b6eaab5ade8566dbf1585c1317" args="(unsigned offset)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">T&amp; <a class="el" href="a00117.html">ucommon::sarray</a>&lt; T &gt;::operator[] </td>
          <td>(</td>
          <td class="paramtype">unsigned&nbsp;</td>
          <td class="paramname"> <em>offset</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Array operation to access member object. </p>
<p>If the object does not exist, it is created. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>offset</em>&nbsp;</td><td>in array for object. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>pointer to typed object. </dd></dl>

<p>Definition at line <a class="el" href="a00192_source.html#l00325">325</a> of file <a class="el" href="a00192_source.html">object.h</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>ucommon/<a class="el" href="a00192_source.html">object.h</a></li>
</ul>
</div>
<hr class="footer"/><address style="text-align: right;"><small>Generated on Thu Jul 14 16:39:55 2011 for ucommon by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>