1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<HTML> 3 4<HEAD> 5<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 6<META http-equiv="Content-Style-Type" content="text/css"> 7<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 8.0.0.0 for Windows"> 8 9<LINK rel="stylesheet" type="text/css" href="../../CSS/revolution.css"> 10 11 <TITLE>MEMVisitAllocatedForExpHeap</TITLE> 12 13</HEAD> 14 15 16<BODY> 17 18 19<H1>MEMVisitAllocatedForExpHeap</H1> 20 21 22<H2>C Specification</H2> 23<PRE class="construction">#include <revolution/mem.h> 24 25void MEMVisitAllocatedForExpHeap( 26 MEMHeapHandle heap, 27 MEMHeapVisitor visitor, 28 u32 userParam );</PRE> 29 30 31<H2>Arguments</H2> 32<TABLE border="1"> 33 34 <TR> 35 <TD><STRONG><EM><CODE>heap</CODE></EM></STRONG></TD> 36 <TD>Expanded heap handle.</TD> 37</TR> 38 <TR> 39<TD><STRONG><EM><CODE>visitor</CODE></EM></STRONG></TD> 40<TD>Function called for each memory block (explained below).</TD> 41 </TR> 42 <TR> 43<TD><STRONG><EM><CODE>userParam</CODE></EM></STRONG></TD> 44<TD>Parameters of the user settings to pass to the <code>visitor</code> function (explained below).</TD> 45 </TR> 46 </TABLE> 47 48 49<H2>Return Values</H2> 50<P>None.</P> 51<H2>Description</H2> 52<P>This function causes the <code>visitor</code> function that the user set to be called for all memory blocks allocated from the expanded heap.</P> 53<P>The <CODE>visitor</CODE> type <CODE>MEMHeapVisitor</CODE> is defined as follows.</P> 54<BLOCKQUOTE> 55<PRE><CODE>typedef void (*MEMHeapVisitor)( 56void* memBlock, 57MEMHeapHandle heap, 58u32 userParam);</CODE></PRE> 59</BLOCKQUOTE> 60<P>The first argument (<STRONG><EM><code>memBlock</code></EM></STRONG>) is a pointer to the memory block. The second argument (<STRONG><EM><code>heap</code></EM></STRONG>) is the heap handle that allocated the memory block. The value specified by <STRONG><EM><CODE>userParam</CODE></EM></STRONG> is passed to the third argument without any changes; any value can be passed. </P> 61<P>The memory blocks are called by the <code>visitor</code> function in allocation order.</P> 62<H2>See Also</H2> 63<P><code><A href="MEMAllocFromExpHeap.html">MEMAllocFromExpHeap</A>, <A href="MEMAllocFromExpHeapEx.html">MEMAllocFromExpHeapEx</A>, <A href="MEMCreateExpHeap.html">MEMCreateExpHeap</A>, <A href="MEMCreateExpHeapEx.html">MEMCreateExpHeapEx</A></code></P> 64<H2>Revision History</H2> 65<P>03/01/2006 Initial version.</P> 66 67 68</BODY> 69</HTML> 70