]>
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 | ||
0155f164 RR |
16 | {\small% |
17 | \begin{verbatim} | |
18 | typedef T element_type | |
19 | \end{verbatim} | |
20 | }% | |
6d0f32dd RR |
21 | |
22 | \latexignore{\rtfignore{\wxheading{Members}}} | |
23 | ||
24 | ||
25 | \membersection{wxScopedPtr<T>::wxScopedPtr<T>}\label{wxscopedptrtemplatewxscopedptrtemplate} | |
26 | ||
27 | \func{wxEXPLICIT}{wxScopedPtr<T>}{\param{T * }{ptr = NULL}} | |
28 | ||
29 | Constructor. | |
30 | ||
31 | \membersection{wxScopedPtr<T>::\destruct{wxScopedPtr<T>}}\label{wxscopedptrtemplatedtor} | |
32 | ||
33 | \func{}{\destruct{wxScopedPtr<T>}}{\void} | |
34 | ||
35 | Destructor. | |
36 | ||
37 | \membersection{wxScopedPtr<T>::get}\label{wxscopedptrtemplateget} | |
38 | ||
39 | \constfunc{T *}{get}{\void} | |
40 | ||
41 | Returns pointer to object or NULL. | |
42 | ||
43 | \membersection{wxScopedPtr<T>::operator*}\label{wxscopedptrtemplateoperatorptrt} | |
44 | ||
45 | \constfunc{T \&}{operator*}{\void} | |
46 | ||
47 | Returns pointer to object. If the pointer is NULL this method will | |
48 | cause an assert in debug mode. | |
49 | ||
50 | \membersection{wxScopedPtr<T>::operator->}\label{wxscopedptrtemplateoperatorderef} | |
51 | ||
52 | \constfunc{T *}{operator->}{\void} | |
53 | ||
54 | Returns pointer to object. If the pointer is NULL this method will | |
55 | cause an assert in debug mode. | |
56 | ||
57 | \membersection{wxScopedPtr<T>::release}\label{wxscopedptrtemplaterelease} | |
58 | ||
59 | \func{T*}{release}{\void} | |
60 | ||
61 | Returns pointer to object or NULL. | |
62 | ||
63 | \membersection{wxScopedPtr<T>::reset}\label{wxscopedptrtemplatereset} | |
64 | ||
65 | \func{void}{reset}{\param{T * }{ptr = NULL}} | |
66 | ||
67 | Reset pointer. Afterwards the caller is responsible for deleting | |
68 | the data contained in the scoped pointer before. | |
69 | ||
70 | \membersection{wxScopedPtr<T>::swap}\label{wxscopedptrtemplateswap} | |
71 | ||
72 | \func{void}{swap}{\param{wxScopedPtr<T> \& }{ot}} | |
73 | ||
74 | Swaps pointers. | |
75 |