Unit 'Contnrs' Package
[Overview][Constants][Types][Classes][Procedures and functions][Index] [#fcl]

TFPHashObjectList.Add

Add a new key/data pair to the list.

Declaration

Source position: contnrs.pp line 318

public function TFPHashObjectList.Add(

  const AName: shortstring;

  AObject: TObject

):Integer;

Arguments

AName

  

Key name associated with object instance.

AObject

  

object instance.

Function result

Position of the new object in the list.

Description

Add adds a new object instance (AObject) with key AName to the list. It returns the position of the object in the list.

Errors

If not enough memory is available to hold the key and data, an exception may be raised. If an object with this name already exists in the list, an exception is raised.

See also

TFPHashObjectList.Extract

  

Extract a object instance from the list.

TFPHashObjectList.Remove

  

Remove first occurrence of a object instance.

TFPHashObjectList.Delete

  

Delete an object from the list.


Documentation generated on: Nov 22 2024