• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
3<title>OsclErrorAllocator class Reference</title>
4<link href="doxygen.css" rel="stylesheet" type="text/css">
5</head><body>
6<!-- Generated by Doxygen 1.2.18 -->
7<center>
8<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="modules.html">Modules</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="annotated.html">Data Structures</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Data Fields</a> &nbsp; <a class="qindex" href="globals.html">Globals</a> &nbsp; </center>
9<hr><h1>OsclErrorAllocator Class Reference<br>
10<small>
11[<a class="el" href="group__osclerror.html">OSCL Error</a>]</small>
12</h1>This class provides static methods to invoke the user defined memory allocation routines.
13<a href="#_details">More...</a>
14<p>
15<code>#include &lt;<a class="el" href="oscl__error__allocator_8h-source.html">oscl_error_allocator.h</a>&gt;</code>
16<p>
17<table border=0 cellpadding=0 cellspacing=0>
18<tr><td></td></tr>
19<tr><td colspan=2><br><h2>Public Methods</h2></td></tr>
20<tr><td nowrap align=right valign=top>&nbsp;</td><td valign=bottom><a class="el" href="classOsclErrorAllocator.html#a0">OsclErrorAllocator</a> (<a class="el" href="classOscl__DefAlloc.html">Oscl_DefAlloc</a> *<a class="el" href="classallocator.html">allocator</a>)</td></tr>
21<tr><td>&nbsp;</td><td><font size=-1><em>constructor method</em> <a href="#a0"></a><em></em></font><br><br></td></tr>
22<tr><td nowrap align=right valign=top>void *&nbsp;</td><td valign=bottom><a class="el" href="classOsclErrorAllocator.html#a1">operator new</a> (uint32 size, <a class="el" href="group__osclbase.html#a25">OsclAny</a> *aPtr)</td></tr>
23<tr><td>&nbsp;</td><td><font size=-1><em>placement new operator that allocates memory using the user defined methods</em> <a href="#a1"></a><em></em></font><br><br></td></tr>
24<tr><td nowrap align=right valign=top>void&nbsp;</td><td valign=bottom><a class="el" href="classOsclErrorAllocator.html#a2">operator delete</a> (<a class="el" href="group__osclbase.html#a25">OsclAny</a> *aPtr, <a class="el" href="group__osclbase.html#a25">OsclAny</a> *aPtr2)</td></tr>
25<tr><td>&nbsp;</td><td><font size=-1><em>delete operator that doesn't do anything, user has to deallocate manually</em> <a href="#a2"></a><em></em></font><br><br></td></tr>
26<tr><td colspan=2><br><h2>Static Public Methods</h2></td></tr>
27<tr><td nowrap align=right valign=top><a class="el" href="group__osclbase.html#a25">OsclAny</a> *&nbsp;</td><td valign=bottom><a class="el" href="classOsclErrorAllocator.html#d0">allocate</a> (uint32 aSize)</td></tr>
28<tr><td>&nbsp;</td><td><font size=-1><em>static method to allocate a block of memory on heap</em> <a href="#d0"></a><em></em></font><br><br></td></tr>
29<tr><td nowrap align=right valign=top><a class="el" href="group__osclbase.html#a25">OsclAny</a>&nbsp;</td><td valign=bottom><a class="el" href="classOsclErrorAllocator.html#d1">deallocate</a> (<a class="el" href="group__osclbase.html#a25">OsclAny</a> *aPointer)</td></tr>
30<tr><td>&nbsp;</td><td><font size=-1><em>static method to deallocate a block of memory on heap</em> <a href="#d1"></a><em></em></font><br><br></td></tr>
31</table>
32<hr><a name="_details"></a><h2>Detailed Description</h2>
33This class provides static methods to invoke the user defined memory allocation routines.
34<p>
35This class must be instantiated before the static methods are called, else asserts will happen
36<p>
37<hr><h2>Constructor &amp; Destructor Documentation</h2>
38<a name="a0" doxytag="OsclErrorAllocator::OsclErrorAllocator"></a><p>
39<table width="100%" cellpadding="2" cellspacing="0" border="0">
40  <tr>
41    <td class="md">
42      <table cellpadding="0" cellspacing="0" border="0">
43        <tr>
44          <td class="md" nowrap valign="top"> OsclErrorAllocator::OsclErrorAllocator </td>
45          <td class="md" valign="top">(&nbsp;</td>
46          <td class="md" nowrap valign="top"><a class="el" href="classOscl__DefAlloc.html">Oscl_DefAlloc</a> *&nbsp;</td>
47          <td class="mdname1" valign="top" nowrap>&nbsp; <em>allocator</em>          </td>
48          <td class="md" valign="top">)&nbsp;</td>
49          <td class="md" nowrap><code> [inline]</code></td>
50        </tr>
51
52      </table>
53    </td>
54  </tr>
55</table>
56<table cellspacing=5 cellpadding=0 border=0>
57  <tr>
58    <td>
59      &nbsp;
60    </td>
61    <td>
62
63<p>
64constructor method
65<p>
66<dl compact><dt><b>Parameters: </b></dt><dd>
67<table border=0 cellspacing=2 cellpadding=0>
68<tr><td valign=top><em>allocator</em>&nbsp;</td><td>
69- a pointer to the concrete object that provides the allocator/deallocator </td></tr>
70</table>
71</dl>    </td>
72  </tr>
73</table>
74<hr><h2>Member Function Documentation</h2>
75<a name="d0" doxytag="OsclErrorAllocator::allocate"></a><p>
76<table width="100%" cellpadding="2" cellspacing="0" border="0">
77  <tr>
78    <td class="md">
79      <table cellpadding="0" cellspacing="0" border="0">
80        <tr>
81          <td class="md" nowrap valign="top"> <a class="el" href="group__osclbase.html#a25">OsclAny</a>* OsclErrorAllocator::allocate </td>
82          <td class="md" valign="top">(&nbsp;</td>
83          <td class="md" nowrap valign="top">uint32&nbsp;</td>
84          <td class="mdname1" valign="top" nowrap>&nbsp; <em>aSize</em>          </td>
85          <td class="md" valign="top">)&nbsp;</td>
86          <td class="md" nowrap><code> [inline, static]</code></td>
87        </tr>
88
89      </table>
90    </td>
91  </tr>
92</table>
93<table cellspacing=5 cellpadding=0 border=0>
94  <tr>
95    <td>
96      &nbsp;
97    </td>
98    <td>
99
100<p>
101static method to allocate a block of memory on heap
102<p>
103<dl compact><dt><b>Parameters: </b></dt><dd>
104<table border=0 cellspacing=2 cellpadding=0>
105<tr><td valign=top><em>aSize</em>&nbsp;</td><td>
106- number of bytes to allocate </td></tr>
107</table>
108</dl>    </td>
109  </tr>
110</table>
111<a name="d1" doxytag="OsclErrorAllocator::deallocate"></a><p>
112<table width="100%" cellpadding="2" cellspacing="0" border="0">
113  <tr>
114    <td class="md">
115      <table cellpadding="0" cellspacing="0" border="0">
116        <tr>
117          <td class="md" nowrap valign="top"> <a class="el" href="group__osclbase.html#a25">OsclAny</a> OsclErrorAllocator::deallocate </td>
118          <td class="md" valign="top">(&nbsp;</td>
119          <td class="md" nowrap valign="top"><a class="el" href="group__osclbase.html#a25">OsclAny</a> *&nbsp;</td>
120          <td class="mdname1" valign="top" nowrap>&nbsp; <em>aPointer</em>          </td>
121          <td class="md" valign="top">)&nbsp;</td>
122          <td class="md" nowrap><code> [inline, static]</code></td>
123        </tr>
124
125      </table>
126    </td>
127  </tr>
128</table>
129<table cellspacing=5 cellpadding=0 border=0>
130  <tr>
131    <td>
132      &nbsp;
133    </td>
134    <td>
135
136<p>
137static method to deallocate a block of memory on heap
138<p>
139<dl compact><dt><b>Parameters: </b></dt><dd>
140<table border=0 cellspacing=2 cellpadding=0>
141<tr><td valign=top><em>aPointer</em>&nbsp;</td><td>
142- pointer to block of memory to be deallocated </td></tr>
143</table>
144</dl>    </td>
145  </tr>
146</table>
147<a name="a2" doxytag="OsclErrorAllocator::operator delete"></a><p>
148<table width="100%" cellpadding="2" cellspacing="0" border="0">
149  <tr>
150    <td class="md">
151      <table cellpadding="0" cellspacing="0" border="0">
152        <tr>
153          <td class="md" nowrap valign="top"> void OsclErrorAllocator::operator delete </td>
154          <td class="md" valign="top">(&nbsp;</td>
155          <td class="md" nowrap valign="top"><a class="el" href="group__osclbase.html#a25">OsclAny</a> *&nbsp;</td>
156          <td class="mdname" nowrap>&nbsp; <em>aPtr</em>, </td>
157        </tr>
158        <tr>
159          <td></td>
160          <td></td>
161          <td class="md" nowrap><a class="el" href="group__osclbase.html#a25">OsclAny</a> *&nbsp;</td>
162          <td class="mdname" nowrap>&nbsp; <em>aPtr2</em></td>
163        </tr>
164        <tr>
165          <td></td>
166          <td class="md">)&nbsp;</td>
167          <td class="md" colspan="2"><code> [inline]</code></td>
168        </tr>
169
170      </table>
171    </td>
172  </tr>
173</table>
174<table cellspacing=5 cellpadding=0 border=0>
175  <tr>
176    <td>
177      &nbsp;
178    </td>
179    <td>
180
181<p>
182delete operator that doesn't do anything, user has to deallocate manually
183<p>
184    </td>
185  </tr>
186</table>
187<a name="a1" doxytag="OsclErrorAllocator::operator new"></a><p>
188<table width="100%" cellpadding="2" cellspacing="0" border="0">
189  <tr>
190    <td class="md">
191      <table cellpadding="0" cellspacing="0" border="0">
192        <tr>
193          <td class="md" nowrap valign="top"> void* OsclErrorAllocator::operator new </td>
194          <td class="md" valign="top">(&nbsp;</td>
195          <td class="md" nowrap valign="top">uint32&nbsp;</td>
196          <td class="mdname" nowrap>&nbsp; <em>size</em>, </td>
197        </tr>
198        <tr>
199          <td></td>
200          <td></td>
201          <td class="md" nowrap><a class="el" href="group__osclbase.html#a25">OsclAny</a> *&nbsp;</td>
202          <td class="mdname" nowrap>&nbsp; <em>aPtr</em></td>
203        </tr>
204        <tr>
205          <td></td>
206          <td class="md">)&nbsp;</td>
207          <td class="md" colspan="2"><code> [inline]</code></td>
208        </tr>
209
210      </table>
211    </td>
212  </tr>
213</table>
214<table cellspacing=5 cellpadding=0 border=0>
215  <tr>
216    <td>
217      &nbsp;
218    </td>
219    <td>
220
221<p>
222placement new operator that allocates memory using the user defined methods
223<p>
224    </td>
225  </tr>
226</table>
227<hr>The documentation for this class was generated from the following file:<ul>
228<li><a class="el" href="oscl__error__allocator_8h-source.html">oscl_error_allocator.h</a></ul>
229<hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small>
230<address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small>
231</small></address>
232</body>
233</html>
234