<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>Crystal Space 1.2.1: csRefCount Class Reference (Crystal Space 1.2.1 Public API Reference)</title> <link href="tabs.css" rel="stylesheet" type="text/css"> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body> <table border="0" cellpadding="0" cellspacing="0" width="100%" class="head"> <tr height="59"> <td class="head" width="202" valign="bottom" style="padding-left:0;"><a href="http://www.crystalspace3d.org/"><img src="csblur.png" width="236" height="59" alt="CrystalSpace" border="0"></a></td> <td class="head"><h2>Public API Reference</h2></td> </tr> <tr height="11"> <td colspan="2" class="headshadow" valign="top" style="padding-left:0;"><img src="csblurb.png" width="236" height="11" alt="" border="0"></td> </tr> </table> <div class="content"> <!-- Generated by Doxygen 1.5.3 --> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="classes.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="classes.html"><span>Alphabetical List</span></a></li> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <h1>csRefCount Class Reference</h1><!-- doxytag: class="csRefCount" -->This is a class which provides basic reference-counting semantics. <a href="#_details">More...</a> <p> <code>#include <<a class="el" href="refcount_8h-source.html">csutil/refcount.h</a>></code> <p> <div class="dynheader"> Inheritance diagram for csRefCount:</div> <div class="dynsection"> <p><center><img src="classcsRefCount__inherit__graph.png" border="0" usemap="#csRefCount__inherit__map" alt="Inheritance graph"></center> <map name="csRefCount__inherit__map"> <area shape="rect" href="classCS_1_1Threading_1_1Runnable.html" title="Abstract base class for objects to be run in threads." alt="" coords="153,5,332,32"><area shape="rect" href="classCS_1_1Threading_1_1Thread.html" title="Object representing a separate execution thread." alt="" coords="161,56,324,83"><area shape="rect" href="classcsCondition.html" title="A condition object." alt="" coords="195,107,291,133"><area shape="rect" href="classcsFrustum.html" title="A general frustum." alt="" coords="199,157,287,184"><area shape="rect" href="classcsMemoryMappedIO.html" title="Defines a simple memory-mapped IO class that is portable." alt="" coords="165,208,320,235"><area shape="rect" href="classcsMemoryMapping.html" title="Memory mapping, as returned by csMemoryMappedIO::GetData()." alt="" coords="171,259,315,285"><area shape="rect" href="classcsMutex.html" title="A mutual-exclusion object." alt="" coords="205,309,280,336"><area shape="rect" href="classcsRenderBufferHolder.html" title="Holder of standard renderbuffers." alt="" coords="160,360,325,387"><area shape="rect" href="classcsSemaphore.html" title="A semaphore object." alt="" coords="188,411,297,437"><area shape="rect" href="classcsShaderVariable.html" title="Storage class for "shader vars", inheritable variables in the shader system..." alt="" coords="177,461,308,488"><area shape="rect" href="classcsThread.html" title="Representation of a thread of executation." alt="" coords="204,512,281,539"></map> <center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div> <p> <a href="classcsRefCount-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0"> <tr><td></td></tr> <tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#3af47061de0fe29e50682463ac643155">csRefCount</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Initialize object and set reference to 1. <a href="#3af47061de0fe29e50682463ac643155"></a><br></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#0433b436ab8a82ea5dcf5926beb96fc1">DecRef</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Decrease the number of references to this object. <a href="#0433b436ab8a82ea5dcf5926beb96fc1"></a><br></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#667033c15e262996687ac17a07073b1b">GetRefCount</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the reference count (only for debugging). <a href="#667033c15e262996687ac17a07073b1b"></a><br></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#44da1c92e2fad79c8b4acea3cb1651d7">IncRef</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Increase the number of references to this object. <a href="#44da1c92e2fad79c8b4acea3cb1651d7"></a><br></td></tr> <tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="9d1d1fd5a215528f02130328a8a43cdb"></a><!-- doxytag: member="csRefCount::Delete" ref="9d1d1fd5a215528f02130328a8a43cdb" args="()" --> virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#9d1d1fd5a215528f02130328a8a43cdb">Delete</a> ()</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="23533d9425defdaa0140c5e692dd44ab"></a><!-- doxytag: member="csRefCount::~csRefCount" ref="23533d9425defdaa0140c5e692dd44ab" args="()" --> virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#23533d9425defdaa0140c5e692dd44ab">~csRefCount</a> ()</td></tr> <tr><td colspan="2"><br><h2>Protected Attributes</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="192cf91d3cfafcbeb2b97eeb136dc180"></a><!-- doxytag: member="csRefCount::ref_count" ref="192cf91d3cfafcbeb2b97eeb136dc180" args="" --> int </td><td class="memItemRight" valign="bottom"><a class="el" href="classcsRefCount.html#192cf91d3cfafcbeb2b97eeb136dc180">ref_count</a></td></tr> </table> <hr><a name="_details"></a><h2>Detailed Description</h2> This is a class which provides basic reference-counting semantics. <p> It can be used in conjunction with the smart pointer template class <a class="el" href="classcsRef.html" title="A smart pointer.">csRef</a> (see <<a class="el" href="ref_8h.html" title="Smart Pointers.">ref.h</a>>). This class itself provides no functionality beyond reference counting. It is intended that you should subclass <a class="el" href="classcsRefCount.html" title="This is a class which provides basic reference-counting semantics.">csRefCount</a> and add needed functionality. <p>Definition at line <a class="el" href="refcount_8h-source.html#l00037">37</a> of file <a class="el" href="refcount_8h-source.html">refcount.h</a>.</p> <hr><h2>Constructor & Destructor Documentation</h2> <a class="anchor" name="3af47061de0fe29e50682463ac643155"></a><!-- doxytag: member="csRefCount::csRefCount" ref="3af47061de0fe29e50682463ac643155" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">csRefCount::csRefCount </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p> Initialize object and set reference to 1. <p> <p>Definition at line <a class="el" href="refcount_8h-source.html#l00058">58</a> of file <a class="el" href="refcount_8h-source.html">refcount.h</a>.</p> <p>References <a class="el" href="reftrackeraccess_8h-source.html#l00048">csRefTrackerAccess::TrackConstruction()</a>.</p> </div> </div><p> <hr><h2>Member Function Documentation</h2> <a class="anchor" name="0433b436ab8a82ea5dcf5926beb96fc1"></a><!-- doxytag: member="csRefCount::DecRef" ref="0433b436ab8a82ea5dcf5926beb96fc1" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void csRefCount::DecRef </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p> Decrease the number of references to this object. <p> <p>Definition at line <a class="el" href="refcount_8h-source.html#l00070">70</a> of file <a class="el" href="refcount_8h-source.html">refcount.h</a>.</p> <p>References <a class="el" href="refcount_8h-source.html#l00046">Delete()</a>, <a class="el" href="refcount_8h-source.html#l00040">ref_count</a>, and <a class="el" href="reftrackeraccess_8h-source.html#l00047">csRefTrackerAccess::TrackDecRef()</a>.</p> </div> </div><p> <a class="anchor" name="667033c15e262996687ac17a07073b1b"></a><!-- doxytag: member="csRefCount::GetRefCount" ref="667033c15e262996687ac17a07073b1b" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int csRefCount::GetRefCount </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p> Get the reference count (only for debugging). <p> <p>Definition at line <a class="el" href="refcount_8h-source.html#l00078">78</a> of file <a class="el" href="refcount_8h-source.html">refcount.h</a>.</p> <p>References <a class="el" href="refcount_8h-source.html#l00040">ref_count</a>.</p> </div> </div><p> <a class="anchor" name="44da1c92e2fad79c8b4acea3cb1651d7"></a><!-- doxytag: member="csRefCount::IncRef" ref="44da1c92e2fad79c8b4acea3cb1651d7" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void csRefCount::IncRef </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p> Increase the number of references to this object. <p> <p>Definition at line <a class="el" href="refcount_8h-source.html#l00064">64</a> of file <a class="el" href="refcount_8h-source.html">refcount.h</a>.</p> <p>References <a class="el" href="refcount_8h-source.html#l00040">ref_count</a>, and <a class="el" href="reftrackeraccess_8h-source.html#l00046">csRefTrackerAccess::TrackIncRef()</a>.</p> </div> </div><p> <hr>The documentation for this class was generated from the following file:<ul> <li>csutil/<a class="el" href="refcount_8h-source.html">refcount.h</a></ul> <hr size="1"><address><small>Generated for Crystal Space 1.2.1 by <a href="http://www.doxygen.org/index.html">doxygen</a> 1.5.3 </small></address> </div></body> </html>