Sign in Join
FPDoc Onlineexperiment

TObjectList.Add function

Member of TObjectListpublicIn unit Contnrs

Add an object to the list.

Declaration

pascal
function Add(AObject: TObject): Integer

Arguments

AObject

Object to add to the list.

Function result

Position at which the object was added.

Description

Add overrides the TList implementation to accept objects ( AObject) instead of pointers.

The function returns the index of the position where the object was added.

Errors

If the list must be expanded, and not enough memory is available, an exception may be raised.

See also

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