]> git.saurik.com Git - wxWidgets.git/blame_incremental - docs/doxygen/overviews/bufferclasses.h
Minor corrections to XRC format description.
[wxWidgets.git] / docs / doxygen / overviews / bufferclasses.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: bufferclasses.h
3// Purpose: topic overview
4// Author: wxWidgets team
5// Licence: wxWindows licence
6/////////////////////////////////////////////////////////////////////////////
7
8/**
9
10@page overview_bufferclasses Buffer Classes
11
12@tableofcontents
13
14wxWidgets uses two classes of classes for dealing with buffers in memory.
15
16The first is one for dealing with character buffers, namely wxCharBuffer for
17char pointer or multi-byte c strings and wxWCharBuffer for wchar_t pointer or
18wide character c strings.
19
20Secondly, wxWidgets uses, although only rarely currently, wxMemoryBuffer for
21dealing with raw buffers in memory.
22
23
24
25@section overview_bufferclasses_xcb wxXCharBuffer
26
27@subsection overview_bufferclasses_xcb_general General Usage
28
29As mentioned, wxCharBuffer and its wide character variant wxWCharBuffer deal
30with c strings in memory. They have two constructors, one in which you pass
31the c string you want them to have a copy of, and another where you specify the
32size of the buffer in memory in characters you want.
33
34wxCharBuffer and its variant only contain the c string as a member, so they can
35be used safely to c functions with variable arguments such as printf. They also
36contain standard assignment, character access operators and a copy constructor.
37
38@subsection overview_bufferclasses_xcb_destruct Destruction
39
40It should be noted that on destruction wxCharBuffer and its wide character
41variant delete the c string that hold onto. If you want to get the pointer to
42the buffer and don't want wxCharBuffer to delete it on destruction, use the
43member function release to do so.
44
45*/