AutoPtrArray & operator=(AutoPtrArray< T > &a_)
Assignment from another AutoPtrArray of a different but related type.
AutoPtr(AutoPtr< T > &a_)
Construct AutoPtr from another AutoPtr of different (but related) type.
X * m_ptr
Pointer to the object we own.
X * operator->() const
Smart pointer dereferencing.
AutoPtrArray handles memory management of an array of objects.
AutoPtrArray & operator=(AutoPtrArray &a_)
Assignment operator deletes memory it owns and transfers the ownership from a_ to itself.
AutoPtr & operator=(AutoPtr &a_)
Assignment operator deletes memory it owns and transfers the ownership from a_ to itself.
X * get() const
Get a raw memory pointer without changing ownership status.
AutoPtrArray & operator=(AutoPtrArrayRef< X > ref_)
X & operator[](int i) const
Access operator.
X * m_ptr
Pointer to the object we own.
void reset(X *p_=0)
Forcibly delete the managed object and assume the ownership of a_.
AutoPtrArray(X *p_=0)
Construct an AutoPtrArray from a raw pointer.
~AutoPtr()
When AutoPtr goes out of scope, the object it owns is deleted.
AutoPtr & operator=(AutoPtr< T > &a_)
Assignment from another AutoPtr of a different but related type.
void reset(X *p_=0)
Forcibly delete the managed object and assume the ownership of a_.
X * release()
Give up the ownership of the memory.
AutoPtrArray(AutoPtrArrayRef< X > ref_)
Automagic conversions.
X & operator*() const
Smart pointer dereferencing.
X * get() const
Get a raw memory pointer without changing ownership status.
AutoPtrArray(AutoPtrArray< T > &a_)
Construct AutoPtrArray from another AutoPtrArray of different (but related) type.
AutoPtr(AutoPtr &a_)
Construct AutoPtr from another AutoPtr.
AutoPtr(AutoPtrRef< X > ref_)
Automagic conversions.
~AutoPtrArray()
When AutoPtrArray goes out of scope, the object it owns is deleted.
AutoPtr & operator=(AutoPtrRef< X > ref_)
X * release()
Give up the ownership of the memory.
AutoPtrArray(AutoPtrArray &a_)
Construct AutoPtrArray from another AutoPtrArray.
X * operator->() const
Smart pointer dereferencing.
AutoPtr(X *p_=0)
Construct an AutoPtr from a raw pointer.
X & operator*() const
Smart pointer dereferencing.