cloudy trunk
Loading...
Searching...
No Matches
count_ptr< T > Class Template Reference

#include <count_ptr.h>

Collaboration diagram for count_ptr< T >:

Public Member Functions

 count_ptr (T *ptr=0)
 count_ptr (const count_ptr< T > &p)
 ~count_ptr () throw ()
count_ptr< T > & operator= (count_ptr< T > temp)
T & operator* () const
T * operator-> () const throw ()
int equiv (const count_ptr< T > &p) const throw ()
T * get_ptr () const throw ()
long count () const
void swap (count_ptr< T > &a) throw ()
int compare (const count_ptr< T > &a) const

Private Member Functions

void cancel ()

Private Attributes

T * m_ptr
long * m_count

Detailed Description

template<class T>
class count_ptr< T >

Definition at line 11 of file count_ptr.h.

Constructor & Destructor Documentation

◆ count_ptr() [1/2]

template<class T>
count_ptr< T >::count_ptr ( T * ptr = 0)
inlineexplicit

Definition at line 17 of file count_ptr.h.

References m_count, and m_ptr.

Referenced by compare(), count_ptr(), equiv(), operator=(), and swap().

◆ count_ptr() [2/2]

template<class T>
count_ptr< T >::count_ptr ( const count_ptr< T > & p)
inline

Definition at line 20 of file count_ptr.h.

References count_ptr(), m_count, and m_ptr.

Here is the call graph for this function:

◆ ~count_ptr()

template<class T>
count_ptr< T >::~count_ptr ( )
throw ( )
inline

Definition at line 25 of file count_ptr.h.

References cancel().

Here is the call graph for this function:

Member Function Documentation

◆ cancel()

template<class T>
void count_ptr< T >::cancel ( )
inlineprivate

Definition at line 71 of file count_ptr.h.

References m_count, and m_ptr.

Referenced by ~count_ptr().

◆ compare()

template<class T>
int count_ptr< T >::compare ( const count_ptr< T > & a) const
inline

Definition at line 62 of file count_ptr.h.

References count_ptr(), and m_ptr.

Referenced by operator<(), operator<=(), operator==(), operator>(), and operator>=().

Here is the call graph for this function:

◆ count()

template<class T>
long count_ptr< T >::count ( ) const
inline

Definition at line 53 of file count_ptr.h.

References m_count.

◆ equiv()

template<class T>
int count_ptr< T >::equiv ( const count_ptr< T > & p) const
throw ( )
inline

Definition at line 45 of file count_ptr.h.

References count_ptr(), and m_ptr.

Here is the call graph for this function:

◆ get_ptr()

template<class T>
T * count_ptr< T >::get_ptr ( ) const
throw ( )
inline

Definition at line 49 of file count_ptr.h.

References m_ptr.

Referenced by newisotope(), and parse_species_label().

◆ operator*()

template<class T>
T & count_ptr< T >::operator* ( ) const
inline

Definition at line 37 of file count_ptr.h.

References m_ptr.

◆ operator->()

template<class T>
T * count_ptr< T >::operator-> ( ) const
throw ( )
inline

Definition at line 41 of file count_ptr.h.

References m_ptr.

◆ operator=()

template<class T>
count_ptr< T > & count_ptr< T >::operator= ( count_ptr< T > temp)
inline

Definition at line 30 of file count_ptr.h.

References count_ptr(), and swap().

Here is the call graph for this function:

◆ swap()

template<class T>
void count_ptr< T >::swap ( count_ptr< T > & a)
throw ( )
inline

Definition at line 57 of file count_ptr.h.

References count_ptr(), m_count, and m_ptr.

Referenced by operator=(), and swap().

Here is the call graph for this function:

Field Documentation

◆ m_count

template<class T>
long* count_ptr< T >::m_count
private

Definition at line 14 of file count_ptr.h.

Referenced by cancel(), count(), count_ptr(), count_ptr(), and swap().

◆ m_ptr

template<class T>
T* count_ptr< T >::m_ptr
private

Definition at line 13 of file count_ptr.h.

Referenced by cancel(), compare(), count_ptr(), count_ptr(), equiv(), get_ptr(), operator*(), operator->(), and swap().


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