G::Counter< D, C > Class Template Reference

An instance counter to help with leak testing. More...

#include <gcounter.h>

Inheritance diagram for G::Counter< D, C >:

G::CounterImp

List of all members.

Public Member Functions

 Counter ()
 Constructor.
 ~Counter ()
 Destructor.
 Counter (const Counter< D, C > &)
 Copy constructor.
void operator= (const Counter< D, C > &)
 Assignment operator.


Detailed Description

template<typename D, const char * C>
class G::Counter< D, C >

An instance counter to help with leak testing.

Typically used as a private base class. (Strictly this uses the curiously recurring template pattern, but it does not do any static_cast<D> downcasting.)

Note that the second template parameter (the class name) needs a declaration like "extern char FooClassName[]", not a string literal.

Definition at line 60 of file gcounter.h.


Constructor & Destructor Documentation

template<typename D, const char * C>
G::Counter< D, C >::Counter (  )  [inline]

Constructor.

Definition at line 83 of file gcounter.h.

References G::CounterImp::check().

template<typename D, const char * C>
G::Counter< D, C >::~Counter (  )  [inline]

Destructor.

Definition at line 90 of file gcounter.h.

References G::CounterImp::check().

template<typename D, const char * C>
G::Counter< D, C >::Counter ( const Counter< D, C > &   )  [inline]

Copy constructor.

Definition at line 97 of file gcounter.h.

References G::CounterImp::check().


Member Function Documentation

template<typename D, const char * C>
void G::Counter< D, C >::operator= ( const Counter< D, C > &   )  [inline]

Assignment operator.

Definition at line 104 of file gcounter.h.


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

Generated on Fri Apr 18 15:56:13 2008 for E-MailRelay by  doxygen 1.5.5