You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

245 lines
13 KiB

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.9.1"/>
<title>Xerces-C++: MemoryManager Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">Xerces-C++
&#160;<span id="projectnumber">3.1.2</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.9.1 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="classes.html"><span>Class&#160;Index</span></a></li>
<li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classMemoryManager-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">MemoryManager Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div> </div>
</div><!--header-->
<div class="contents">
<p>Configurable memory manager.
<a href="classMemoryManager.html#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a6587b83bc36e193c35b33d8f45836a54"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classMemoryManager.html">MemoryManager</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classMemoryManager.html#a6587b83bc36e193c35b33d8f45836a54">getExceptionMemoryManager</a> ()=0</td></tr>
<tr class="memdesc:a6587b83bc36e193c35b33d8f45836a54"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method is called to obtain the memory manager that should be used to allocate memory used in exceptions. <a href="#a6587b83bc36e193c35b33d8f45836a54">More...</a><br /></td></tr>
<tr class="separator:a6587b83bc36e193c35b33d8f45836a54"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr><td colspan="2"><div class="groupHeader">Destructor</div></td></tr>
<tr class="memitem:a069aa716f72688713e925ddcfd712b83"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classMemoryManager.html#a069aa716f72688713e925ddcfd712b83">~MemoryManager</a> ()</td></tr>
<tr class="memdesc:a069aa716f72688713e925ddcfd712b83"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default destructor. <a href="#a069aa716f72688713e925ddcfd712b83">More...</a><br /></td></tr>
<tr class="separator:a069aa716f72688713e925ddcfd712b83"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr><td colspan="2"><div class="groupHeader">The pure virtual methods in this interface.</div></td></tr>
<tr class="memitem:a4955a5c169b701c6106c1541bbb96f17"><td class="memItemLeft" align="right" valign="top">virtual void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classMemoryManager.html#a4955a5c169b701c6106c1541bbb96f17">allocate</a> (<a class="el" href="Xerces__autoconf__config_8borland_8hpp.html#ac0f7e36996cd03eb43bcee10321f77cd">XMLSize_t</a> size)=0</td></tr>
<tr class="memdesc:a4955a5c169b701c6106c1541bbb96f17"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method allocates requested memory. <a href="#a4955a5c169b701c6106c1541bbb96f17">More...</a><br /></td></tr>
<tr class="separator:a4955a5c169b701c6106c1541bbb96f17"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af7dce9eab3a2a41e5b887ba735180e67"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classMemoryManager.html#af7dce9eab3a2a41e5b887ba735180e67">deallocate</a> (void *p)=0</td></tr>
<tr class="memdesc:af7dce9eab3a2a41e5b887ba735180e67"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method deallocates memory. <a href="#af7dce9eab3a2a41e5b887ba735180e67">More...</a><br /></td></tr>
<tr class="separator:af7dce9eab3a2a41e5b887ba735180e67"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Constructor</div></td></tr>
<tr class="memitem:ae925e8ad4d8fe6f0565e9d5729f59593"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classMemoryManager.html#ae925e8ad4d8fe6f0565e9d5729f59593">MemoryManager</a> ()</td></tr>
<tr class="memdesc:ae925e8ad4d8fe6f0565e9d5729f59593"><td class="mdescLeft">&#160;</td><td class="mdescRight">Protected default constructor. <a href="#ae925e8ad4d8fe6f0565e9d5729f59593">More...</a><br /></td></tr>
<tr class="separator:ae925e8ad4d8fe6f0565e9d5729f59593"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Configurable memory manager. </p>
<p>This interface allows outside applications to plug in their own memory manager to be used by Xerces for memory allocation/deallocation.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a069aa716f72688713e925ddcfd712b83"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual MemoryManager::~MemoryManager </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Default destructor. </p>
</div>
</div>
<a class="anchor" id="ae925e8ad4d8fe6f0565e9d5729f59593"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">MemoryManager::MemoryManager </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Protected default constructor. </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a4955a5c169b701c6106c1541bbb96f17"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void* MemoryManager::allocate </td>
<td>(</td>
<td class="paramtype"><a class="el" href="Xerces__autoconf__config_8borland_8hpp.html#ac0f7e36996cd03eb43bcee10321f77cd">XMLSize_t</a>&#160;</td>
<td class="paramname"><em>size</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>This method allocates requested memory. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">size</td><td>The requested memory size</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A pointer to the allocated memory </dd></dl>
<p>Referenced by <a class="el" href="classXMLString.html#ae53122c8ed75c1c59976b0554bf0515b">XMLString::replicate()</a>, and <a class="el" href="classXMLDateTime.html#a79db81ad75eeb4e77753c973a76d4df8">XMLDateTime::setBuffer()</a>.</p>
</div>
</div>
<a class="anchor" id="af7dce9eab3a2a41e5b887ba735180e67"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void MemoryManager::deallocate </td>
<td>(</td>
<td class="paramtype">void *&#160;</td>
<td class="paramname"><em>p</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>This method deallocates memory. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">p</td><td>The pointer to the allocated memory to be deleted </td></tr>
</table>
</dd>
</dl>
<p>Referenced by <a class="el" href="classXMLNotationDecl.html#afa084135cb99a692ae4354f14a02fb9d">XMLNotationDecl::setBaseURI()</a>, <a class="el" href="classXMLEntityDecl.html#aa452395af27f5786026d7fe817f80c56">XMLEntityDecl::setBaseURI()</a>, <a class="el" href="classXMLDateTime.html#a79db81ad75eeb4e77753c973a76d4df8">XMLDateTime::setBuffer()</a>, <a class="el" href="classXMLEntityDecl.html#a99b264254c9e3dfa96936f06cd903233">XMLEntityDecl::setNotationName()</a>, <a class="el" href="classXMLNotationDecl.html#a149194ac235a4ba43577faeeb341e0ec">XMLNotationDecl::setPublicId()</a>, <a class="el" href="classXMLEntityDecl.html#a358e1c34ad0ffd22dc699f7aba8d833c">XMLEntityDecl::setPublicId()</a>, <a class="el" href="classXMLNotationDecl.html#ae05b88c8c4d7a8d46a794e7d180cff9a">XMLNotationDecl::setSystemId()</a>, <a class="el" href="classXMLEntityDecl.html#ac8f4fc94cac11ad5a9f8dbf0d3ae86fb">XMLEntityDecl::setSystemId()</a>, <a class="el" href="classXMLEntityDecl.html#ad4e0af0e1b309b00f78aa45d6373dc13">XMLEntityDecl::setValue()</a>, <a class="el" href="classAbstractDOMParser.html#a5f62285b535e3b52051d2a17c420200f">AbstractDOMParser::useImplementation()</a>, and <a class="el" href="classPSVIAttribute.html#a20adb671b19d89a5cc6f0f39c402087c">PSVIAttribute::~PSVIAttribute()</a>.</p>
</div>
</div>
<a class="anchor" id="a6587b83bc36e193c35b33d8f45836a54"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classMemoryManager.html">MemoryManager</a>* MemoryManager::getExceptionMemoryManager </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>This method is called to obtain the memory manager that should be used to allocate memory used in exceptions. </p>
<p>If the same memory manager can be used, simply return 'this' from this function. Note, however, that if there is a possibility that an exception thrown can outlive the memory manager (for example, because the memory manager object is allocated on the stack or is managed by a stack-bound object), it is recommended that you return <a class="el" href="classXMLPlatformUtils.html#a97eff0d9fff3567bea3acd3ca4d95252" title="The configurable memory manager. ">XMLPlatformUtils::fgMemoryManager</a>.</p>
<dl class="section return"><dt>Returns</dt><dd>A pointer to the memory manager </dd></dl>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="MemoryManager_8hpp_source.html">MemoryManager.hpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Wed Mar 18 2015 10:43:38 for Xerces-C++ by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.9.1
</small></address>
</body>
</html>