FreePOOMA  2.4.1
Public Member Functions
RefCounted Class Reference

RefCounted is a mix-in class that supports reference counting of an object. More...

#include <RefCounted.h>

Inheritance diagram for RefCounted:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 RefCounted ()
 RefCounted (const RefCounted &)
 ~RefCounted ()
bool isShared () const
void addReference ()
void removeReference ()
bool removeRefAndCheckGarbage ()
void lock () const
void unlock () const
int count () const
int countUnlocked () const

Detailed Description

RefCounted is a mix-in class that supports reference counting of an object.

It encapsulates the count and provides an interface for manipulating and checking the count.

When running in a threaded environment, RefCounted protects the reference count with a mutex, so this class is thread safe.


Constructor & Destructor Documentation

RefCounted::RefCounted ( ) [inline]
RefCounted::RefCounted ( const RefCounted ) [inline]

Member Function Documentation

bool RefCounted::isShared ( ) const [inline]
void RefCounted::addReference ( ) [inline]
void RefCounted::removeReference ( ) [inline]
void RefCounted::lock ( ) const [inline]
void RefCounted::unlock ( ) const [inline]
int RefCounted::count ( ) const [inline]
int RefCounted::countUnlocked ( ) const [inline]

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