/////////////////////////////////////////////////////////////////////////////
// Name: ptr_scpd.h
-// Purpose: documentation for wxScopedPtr class
+// Purpose: interface of wxScopedPtr
// Author: wxWidgets team
// RCS-ID: $Id$
// Licence: wxWindows license
use macros instead.
Since wxWidgets 2.9.0 there is also a templated version of this class
- with the same name. See wxScopedPtrT.
+ with the same name. See wxScopedPtrT().
A smart pointer holds a pointer to an object. The memory used by the object is
deleted when the smart pointer goes out of scope. This class is different from
@library{wxbase}
@category{FIXME}
- @seealso
- wxScopedArray
+ @see wxScopedArray
*/
class wxScopedPtr
{
};
+
/**
@class wxScopedArray
@wxheader{ptr_scpd.h}
@library{wxbase}
@category{FIXME}
- @seealso
- wxScopedPtr
+ @see wxScopedPtr
*/
class wxScopedArray
{
};
+
/**
@class wxScopedTiedPtr
@wxheader{ptr_scpd.h}
};
+
/**
@class wxScopedPtrT
@wxheader{ptr_scpd.h}
@library{wxbase}
@category{FIXME}
- @seealso
- wxSharedPtr, wxWeakRef
+ @see wxSharedPtr, wxWeakRef
*/
class wxScopedPtr<T>
{
/**
Returns pointer to object or @NULL.
*/
- T* get();
+ T* get() const;
/**
Conversion to a boolean expression (in a variant which is not
contains a valid pointer it will return @e @true, if it contains
a @NULL pointer it will return @e @false.
*/
- operator unspecified_bool_type();
+ operator unspecified_bool_type() const;
/**
Returns a reference to the object. If the internal pointer is @NULL
this method will cause an assert in debug mode.
*/
- T operator*();
+ T operator*() const;
/**
Returns pointer to object. If the pointer is @NULL this method will
cause an assert in debug mode.
*/
- T* operator-();
+ T* operator-() const;
/**
Releases the current pointer and returns it.
*/
void swap(wxScopedPtr<T>& ot);
};
+