Skip to content

TIndexDefs

A class to keep a list of index definitions.

Declaration

Source position: db.pas line 1277

type

  TIndexDefs = class(TDefCollection)
  public
    constructor Create; overload;
    procedure Add; overload;
    function AddIndexDef : TIndexDef;
    function Find : TIndexDef;
    function FindIndexForFields : TIndexDef;
    function GetIndexForFields : TIndexDef;
    procedure Update; overload;
    property Items[Index : Integer]: TIndexDef; {rw}
  end;

Description

TIndexDefs is used to keep a collection of index (sort order) definitions. It can be used by classes that provide in-memory or on-disk indexes to provide a list of available indexes.

Properties

Member Visibility Description
Items public Indexed access to the index definitions.
See all Properties

Methods

Member Visibility Description
Add public Add a new index definition with given name and options.
AddIndexDef public Add a new, empty, index definition.
Create public Create a new TIndexDefs instance.
Find public Find an index by name.
FindIndexForFields public Find index definition based on field names.
GetIndexForFields public Get index definition based on field names.
Update public Called whenever one of the items changes.
See all Methods

See also

Name Description
TIndexDef Index definition.
TIndexDefs.Items Indexed access to the index definitions.