]>
Commit | Line | Data |
---|---|---|
6d0f32dd RR |
1 | \section{\class{wxScopedPtr<T>}}\label{wxscopedptrtemplate} |
2 | ||
3 | A scoped pointer template class. It is the template version of | |
4 | the old-style \helpref{scoped pointer macros}{wxscopedptr}. | |
5 | ||
6 | \wxheading{Derived from} | |
7 | ||
8 | No base class | |
9 | ||
10 | \wxheading{Include files} | |
11 | ||
12 | <ptr\_scpd.h> | |
13 | ||
14 | \wxheading{Data structures} | |
15 | ||
16 | {\small \begin{verbatim} | |
17 | typedef T element\_type | |
18 | \end{verbatim}} | |
19 | ||
20 | \latexignore{\rtfignore{\wxheading{Members}}} | |
21 | ||
22 | ||
23 | \membersection{wxScopedPtr<T>::wxScopedPtr<T>}\label{wxscopedptrtemplatewxscopedptrtemplate} | |
24 | ||
25 | \func{wxEXPLICIT}{wxScopedPtr<T>}{\param{T * }{ptr = NULL}} | |
26 | ||
27 | Constructor. | |
28 | ||
29 | \membersection{wxScopedPtr<T>::\destruct{wxScopedPtr<T>}}\label{wxscopedptrtemplatedtor} | |
30 | ||
31 | \func{}{\destruct{wxScopedPtr<T>}}{\void} | |
32 | ||
33 | Destructor. | |
34 | ||
35 | \membersection{wxScopedPtr<T>::get}\label{wxscopedptrtemplateget} | |
36 | ||
37 | \constfunc{T *}{get}{\void} | |
38 | ||
39 | Returns pointer to object or NULL. | |
40 | ||
41 | \membersection{wxScopedPtr<T>::operator*}\label{wxscopedptrtemplateoperatorptrt} | |
42 | ||
43 | \constfunc{T \&}{operator*}{\void} | |
44 | ||
45 | Returns pointer to object. If the pointer is NULL this method will | |
46 | cause an assert in debug mode. | |
47 | ||
48 | \membersection{wxScopedPtr<T>::operator->}\label{wxscopedptrtemplateoperatorderef} | |
49 | ||
50 | \constfunc{T *}{operator->}{\void} | |
51 | ||
52 | Returns pointer to object. If the pointer is NULL this method will | |
53 | cause an assert in debug mode. | |
54 | ||
55 | \membersection{wxScopedPtr<T>::release}\label{wxscopedptrtemplaterelease} | |
56 | ||
57 | \func{T*}{release}{\void} | |
58 | ||
59 | Returns pointer to object or NULL. | |
60 | ||
61 | \membersection{wxScopedPtr<T>::reset}\label{wxscopedptrtemplatereset} | |
62 | ||
63 | \func{void}{reset}{\param{T * }{ptr = NULL}} | |
64 | ||
65 | Reset pointer. Afterwards the caller is responsible for deleting | |
66 | the data contained in the scoped pointer before. | |
67 | ||
68 | \membersection{wxScopedPtr<T>::swap}\label{wxscopedptrtemplateswap} | |
69 | ||
70 | \func{void}{swap}{\param{wxScopedPtr<T> \& }{ot}} | |
71 | ||
72 | Swaps pointers. | |
73 |