[Overview][Constants][Types][Classes][Index] Reference for unit 'fgl' (#rtl)

TFPGMap

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

Generic map

Declaration

Source position: fgl.pp line 276

type generic TFPGMap <TKey,TData>= class(TFPSMap) end;

public

  constructor Create;

  

Create a new instance of the map

  function Add();

  

Add a key and value to the map

  function Find();

  

Find item based on key

  function IndexOf();

  

Find index of a key in the list.

  function IndexOfData();

  

Find index of data value in the list.

  procedure InsertKey();

  

Insert a new key in the list

  procedure InsertKeyData();

  

Insert a new key with associated data in the list

  function Remove();

  

Remove a key from the list

  property Keys: TKey; [rw]

  

Indexed access to the keys in the list.

  property Data: TData; [rw]

  

Indexed access to the data in the list

  property KeyData: TData; default; [rw]

  

Access to data based on key

  property OnCompare: TKeyCompareFunc; [rw]

  

Alias for OnKeyCompare

  property OnKeyCompare: TKeyCompareFunc; [rw]

  

Compare function for key values.

  property OnDataCompare: TDataCompareFunc; [rw]

  

Compare function for data values.

Inheritance

TFPGMap

  

Generic map

TFPSMap

  

Basic map object, used in generic maps

TFPSList

  

Basic list of memory blocks

TObject

  

Base class of all classes.

Description

TFPGMap is a generic map class. It can be used to specialize a map for any key type and data type that do not require manual reference counting: For reference counted interface objects, TFPGMapInterfacedObjectData must be used.

See also

TFPGMapInterfacedObjectData

  

Generic map for reference counted objects


Documentation generated on: Nov 14 2015