UseCount Class Reference

: A Class Encapsulating Reference Counts More...

#include <UseCount.H>

List of all members.

Public Member Functions

 UseCount ()
 Construct a UseCount initialized to one.
 UseCount (const UseCount &rhs)
 The copy constructor -- bumps reference count.
UseCountoperator= (const UseCount &rhs)
 The assignment operator.
 ~UseCount ()
 The destructor -- decrements the reference count.
bool unique () const
 The UseCount is unique if the reference count == 1.
int linkCount () const
 Returns the reference count.


Detailed Description

: A Class Encapsulating Reference Counts

This class encapsulates reference counts.


Constructor & Destructor Documentation

UseCount::UseCount (  ) 

Construct a UseCount initialized to one.

UseCount::UseCount ( const UseCount rhs  ) 

The copy constructor -- bumps reference count.

UseCount::~UseCount (  ) 

The destructor -- decrements the reference count.


Member Function Documentation

UseCount & UseCount::operator= ( const UseCount rhs  ) 

The assignment operator.

Increments the reference count on rhs, decrements the reference count on this, and then makes this and rhs point to the same reference count.

References cnt.

bool UseCount::unique (  )  const [inline]

The UseCount is unique if the reference count == 1.

Referenced by LnClassPtr< T >::unique(), LnPtr< T >::unique(), LnClassPtr< T >::~LnClassPtr(), and LnPtr< T >::~LnPtr().

int UseCount::linkCount (  )  const [inline]

Returns the reference count.

Referenced by LnClassPtr< T >::linkCount(), and LnPtr< T >::linkCount().


The documentation for this class was generated from the following files:

Generated on Fri Nov 21 10:11:03 2008 for AMRParticlePaths by  doxygen 1.5.5