Sign in Join
FPDoc Onlineexperiment

TStrings.Capacity property

Member of TStringspublicIn unit Classes

Capacity of the list, i.e. number of strings that the list can currently hold before it tries to expand.

Declaration

pascal
property Capacity: Integer read GetCapacity write SetCapacity;

Description

Capacity is the number of strings that the list can hold before it tries to allocate more memory.

TStrings returns Count when read. Trying to set the capacity has no effect. Descendant classes such as TStringlist can override this property such that it actually sets the new capacity.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.