Skip to content

TPooledMemManager

Pooled memory manager.

Declaration

Source position: pooledmm.pp line 47

type

  TPooledMemManager = class
  public
    property MinimumFreeCount: Integer; {rw}
    property MaximumFreeCountRatio: Integer; {rw}
    property Count: Integer; {r}
    property FreeCount: Integer; {r}
    property AllocatedCount: Int64; {r}
    property FreedCount: Int64; {r}
    procedure Clear;
    constructor Create;
    destructor Destroy;
  end;

Description

TPooledMemManager is a class which maintains a linked list of blocks, represented by the TPooledMemManagerItem record. It should not be used directly, but should be descended from and the descendent should implement the actual memory manager.

Properties

Member Visibility Description
AllocatedCount read only public Total number of allocated items in the list.
Count read only public Number of items in the list.
FreeCount read only public Number of free items in the list.
FreedCount read only public Total number of freed items in the list.
MaximumFreeCountRatio public Maximum ratio of free items over total items.
MinimumFreeCount public Minimum count of free items in the list.

Methods

Member Visibility Description
Clear public Clears the list.
Create public Creates a new instance of the TPooledMemManager class.
Destroy public Removes an instance of TPooledMemManager class from memory.

See also

Name Description
TPooledMemManagerItem Item used in a linked list.