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>OsclMemBasicAllocator 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> <a class="qindex" href="modules.html">Modules</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Data Structures</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Data Fields</a> <a class="qindex" href="globals.html">Globals</a> </center> 9<hr><h1>OsclMemBasicAllocator Class Reference<br> 10<small> 11[<a class="el" href="group__osclmemory.html">OSCL Memory</a>, <a class="el" href="group__osclmemory.html">OSCL Memory</a>]</small> 12</h1><code>#include <<a class="el" href="oscl__mem_8h-source.html">oscl_mem.h</a>></code> 13<p> 14<p>Inheritance diagram for OsclMemBasicAllocator: 15<p><center><img src="classOsclMemBasicAllocator.png" usemap="#OsclMemBasicAllocator_map" border="0" alt=""></center> 16<map name="OsclMemBasicAllocator_map"> 17<area href="classOscl__DefAlloc.html" alt="Oscl_DefAlloc" shape="rect" coords="78,56,225,80"> 18<area href="classOscl__Alloc.html" alt="Oscl_Alloc" shape="rect" coords="0,0,147,24"> 19<area href="classOscl__Dealloc.html" alt="Oscl_Dealloc" shape="rect" coords="157,0,304,24"> 20</map> 21<table border=0 cellpadding=0 cellspacing=0> 22<tr><td></td></tr> 23<tr><td colspan=2><br><h2>Public Methods</h2></td></tr> 24<tr><td nowrap align=right valign=top><a class="el" href="group__osclbase.html#a25">OsclAny</a> * </td><td valign=bottom><a class="el" href="classOsclMemBasicAllocator.html#a0">allocate</a> (const uint32 n)</td></tr> 25<tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classOsclMemBasicAllocator.html#a1">deallocate</a> (<a class="el" href="group__osclbase.html#a25">OsclAny</a> *p)</td></tr> 26</table> 27<hr><a name="_details"></a><h2>Detailed Description</h2> 28A simple allocator class that does not use the memory management. 29<p> 30Note: this allocator is for internal use by Oscl only. Higher level code should use <a class="el" href="classOsclMemAllocator.html">OsclMemAllocator</a>. 31<p> 32<hr><h2>Member Function Documentation</h2> 33<a name="a0" doxytag="OsclMemBasicAllocator::allocate"></a><p> 34<table width="100%" cellpadding="2" cellspacing="0" border="0"> 35 <tr> 36 <td class="md"> 37 <table cellpadding="0" cellspacing="0" border="0"> 38 <tr> 39 <td class="md" nowrap valign="top"> <a class="el" href="group__osclbase.html#a25">OsclAny</a>* OsclMemBasicAllocator::allocate </td> 40 <td class="md" valign="top">( </td> 41 <td class="md" nowrap valign="top">const uint32 </td> 42 <td class="mdname1" valign="top" nowrap> <em>n</em> </td> 43 <td class="md" valign="top">) </td> 44 <td class="md" nowrap><code> [inline, virtual]</code></td> 45 </tr> 46 47 </table> 48 </td> 49 </tr> 50</table> 51<table cellspacing=5 cellpadding=0 border=0> 52 <tr> 53 <td> 54 55 </td> 56 <td> 57 58<p> 59This API throws an exception when malloc returns NULL. n must be greater than 0. 60<p> 61<dl compact><dt><b>Returns: </b></dt><dd> 62pointer (or Leave with OsclErrNoMemory ) </dl> 63<p> 64Implements <a class="el" href="classOscl__DefAlloc.html#a0">Oscl_DefAlloc</a>. </td> 65 </tr> 66</table> 67<a name="a1" doxytag="OsclMemBasicAllocator::deallocate"></a><p> 68<table width="100%" cellpadding="2" cellspacing="0" border="0"> 69 <tr> 70 <td class="md"> 71 <table cellpadding="0" cellspacing="0" border="0"> 72 <tr> 73 <td class="md" nowrap valign="top"> void OsclMemBasicAllocator::deallocate </td> 74 <td class="md" valign="top">( </td> 75 <td class="md" nowrap valign="top"><a class="el" href="group__osclbase.html#a25">OsclAny</a> * </td> 76 <td class="mdname1" valign="top" nowrap> <em>p</em> </td> 77 <td class="md" valign="top">) </td> 78 <td class="md" nowrap><code> [inline, virtual]</code></td> 79 </tr> 80 81 </table> 82 </td> 83 </tr> 84</table> 85<table cellspacing=5 cellpadding=0 border=0> 86 <tr> 87 <td> 88 89 </td> 90 <td> 91 92<p> 93 94<p> 95Implements <a class="el" href="classOscl__DefAlloc.html#a2">Oscl_DefAlloc</a>. </td> 96 </tr> 97</table> 98<hr>The documentation for this class was generated from the following file:<ul> 99<li><a class="el" href="oscl__mem_8h-source.html">oscl_mem.h</a></ul> 100<hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small> 101<address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small> 102</small></address> 103</body> 104</html> 105