Make your own free website on Tripod.com
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

freddy77::hp_auto_ptr< _Ty > Class Template Reference

List of all members.

Public Types

typedef _Ty element_type

Public Methods

 hp_auto_ptr (_Ty *P=0)
 hp_auto_ptr (const hp_auto_ptr< _Ty > &_Y)
hp_auto_ptr< _Ty > & operator= (const hp_auto_ptr< _Ty > &_Y)
 ~hp_auto_ptr ()
_Ty & operator * () const
_Ty * operator-> () const
_Ty * get () const
_Ty * release () const

Private Attributes

bool _Owns
_Ty * _Ptr

template<class _Ty>
class freddy77::hp_auto_ptr< _Ty >


Member Typedef Documentation

template<class _Ty>
typedef _Ty freddy77::hp_auto_ptr< _Ty >::element_type
 

Definition at line 15 of file f77auto_ptr.


Constructor & Destructor Documentation

template<class _Ty>
freddy77::hp_auto_ptr< _Ty >::hp_auto_ptr _Ty *    P = 0 [inline, explicit]
 

Definition at line 16 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::_Owns, and freddy77::hp_auto_ptr< _Ty >::_Ptr.

00017                 : _Owns(P != 0), _Ptr(P) {;}

template<class _Ty>
freddy77::hp_auto_ptr< _Ty >::hp_auto_ptr const hp_auto_ptr< _Ty > &    _Y [inline]
 

Definition at line 18 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::_Owns, freddy77::hp_auto_ptr< _Ty >::_Ptr, and freddy77::hp_auto_ptr< _Ty >::release().

00019                 : _Owns(_Y._Owns), _Ptr(_Y.release()) {;}

template<class _Ty>
freddy77::hp_auto_ptr< _Ty >::~hp_auto_ptr   [inline]
 

Definition at line 30 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::_Ptr.

00031                 {if (_Owns)
00032                         delete _Ptr; }


Member Function Documentation

template<class _Ty>
_Ty* freddy77::hp_auto_ptr< _Ty >::get   const [inline]
 

Definition at line 37 of file f77auto_ptr.

Referenced by freddy77::hp_auto_ptr< _Ty >::operator *(), freddy77::hp_auto_ptr< _Ty >::operator->(), and freddy77::hp_auto_ptr< _Ty >::operator=().

00038                 {return (_Ptr); }

template<class _Ty>
_Ty& freddy77::hp_auto_ptr< _Ty >::operator *   const [inline]
 

Definition at line 33 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::get().

00034                 {return (*get()); }

template<class _Ty>
_Ty* freddy77::hp_auto_ptr< _Ty >::operator->   const [inline]
 

Definition at line 35 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::get().

00036                 {return (get()); }

template<class _Ty>
hp_auto_ptr<_Ty>& freddy77::hp_auto_ptr< _Ty >::operator= const hp_auto_ptr< _Ty > &    _Y [inline]
 

Definition at line 20 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::_Owns, freddy77::hp_auto_ptr< _Ty >::_Ptr, freddy77::hp_auto_ptr< _Ty >::get(), and freddy77::hp_auto_ptr< _Ty >::release().

00021                 {if (this != &_Y)
00022                         {if (_Ptr != _Y.get())
00023                                 {if (_Owns)
00024                                         delete _Ptr;
00025                                 _Owns = _Y._Owns; }
00026                         else if (_Y._Owns)
00027                                 _Owns = true;
00028                         _Ptr = _Y.release(); }
00029                 return (*this); }

template<class _Ty>
_Ty* freddy77::hp_auto_ptr< _Ty >::release   const [inline]
 

Definition at line 39 of file f77auto_ptr.

References freddy77::hp_auto_ptr< _Ty >::_Owns.

Referenced by freddy77::hp_auto_ptr< _Ty >::hp_auto_ptr(), and freddy77::hp_auto_ptr< _Ty >::operator=().

00040                 { this->_Owns = false;
00041                 return (_Ptr); }


Member Data Documentation

template<class _Ty>
bool freddy77::hp_auto_ptr< _Ty >::_Owns [private]
 

Definition at line 43 of file f77auto_ptr.

Referenced by freddy77::hp_auto_ptr< _Ty >::hp_auto_ptr(), freddy77::hp_auto_ptr< _Ty >::operator=(), and freddy77::hp_auto_ptr< _Ty >::release().

template<class _Ty>
_Ty* freddy77::hp_auto_ptr< _Ty >::_Ptr [private]
 

Definition at line 44 of file f77auto_ptr.

Referenced by freddy77::hp_auto_ptr< _Ty >::hp_auto_ptr(), freddy77::hp_auto_ptr< _Ty >::operator=(), and freddy77::hp_auto_ptr< _Ty >::~hp_auto_ptr().


The documentation for this class was generated from the following file:
Generated on Mon Jan 13 22:20:37 2003 for perdr by doxygen1.2.15