Function CSPPtr<T>::Detach()
Description:
Detaches the contained pointer from the smart pointer.
 |
Prototype:
T* Detach();
Arguments:
No arguments (void).
Return value:
The contained pointer.
Remarks:
After the contained pointer is detached, the smart pointer contains a null pointer.
Examples:
CSPPtr<char> sp; sp.New(); ... char* p = sp.Detach(); ... delete p;
See also:
member function Attach( CSPPtr<T>& spPtr ), Attach( T* p )
|
|