MEMVisitAllocatedForExpHeap

Syntax

#include <cafe/mem.h>

void MEMVisitAllocatedForExpHeap(
                    	MEMHeapHandle    heap,
                    	MEMHeapVisitor   visitor,
                    	u32              userParam );

Parameters

heap Expanded heap handle.
visitor Function called for each memory block (explained below).
userParam User-specified parameters to pass to the visitor function (explained below).

Return Values

None.

Description

This function causes the user-specified visitor function to be called for all memory blocks allocated from the expanded heap.

The visitor type, MEMHeapVisitor, is defined as follows.

typedef void (*MEMHeapVisitor)( 
                void*           memBlock, 
                MEMHeapHandle   heap, 
                u32             userParam );

The first argument is a pointer to the memory block. The second argument is the handle to the heap that allocated the memory block. The value specified by userParam is passed to the third argument without any changes; any value can be passed.

The visitor function is called for memory blocks in the same order in which the blocks were allocated.

Do Not Call From

Callbacks Do not call this function from any callback function.

See Also

MEMAllocFromExpHeap
MEMAllocFromExpHeapEx
MEMCreateExpHeap
MEMCreateExpHeapEx

Revision History

2013/05/08 Automated cleanup pass.
2010/11/01 Initial version.


CONFIDENTIAL