RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
System.GetHeapStatus Function

Returns the current status of the memory manager.

Pascal
function GetHeapStatus: THeapStatus; deprecated; platform;
C++
THeapStatus GetHeapStatus();

GetHeapStatus returns the current status of the memory manager in a THeapStatus type. If the ShareMem unit is not included in the current project, GetHeapStatus returns information about the global heap. If the ShareMem unit is included, GetHeapStatus returns information about memory that can be shared between between the current project and other binary modules (such as DLLs) that also make use of the ShareMem unit. GetHeapStatus can only return useful information if the built-in memory manager is used. For example, when using CodeGuard, the memory manager is replaced and GetHeapStatus always returns nil (Delphi) or NULL (C++). 

If you want information about the memory manager that is shared between modules, make sure to call the function GetHeapStatus provided in the ShareMem unit. The function GetHeapStatus in the System unit returns no values for a project that uses shared memory.

Note: Since GetHeapStatus is deprecated, use GetMemoryManagerState routine instead.
Warning: ShareMem must be the first unit included in the project file to prevent mixing of memory management models.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!