Class TFilterList (unit FilterList)

Inherits from

TStringList

TTable pointer TFilterList sisemiseks kasutamiseks

Constructors


constructor Create(Filter : PDB);

Parameter @TTable.


Functions

function Add(const S: string): Integer;

Adds one or more filter conditions.

procedure AssignTable(Filter : PDB);

Assigns different TTable to FilterList f.

procedure Build;

ReBuilds the filter.

procedure Clear;

Clears the filter } { Teeb filtri tühjaks

procedure DeleteF(S: string);

Removes the condition specified by S parameter, very useful } { Kustutab filtrist tingimuse S kujul 'väli tehe tingimus' } { ntx 'nr <> 6'

procedure DeleteIndex(Index: Integer);

Removes the condition specified by the Index parameter } { Kustutab filtrist index-nda tingimuse.

function FilterToStr : string;

Returns the current filter.

procedure Insert(Index: Integer; const S: string);

Inserts the condition to position specified by Index parameter } { Lisab filtrisse soovitud kohale soovitud tingimuse

function CheckLeft(s : string) : integer;

TFilterList

function CheckRight(s : string) : integer;


procedure ReBuild;


procedure TrimBoth(var s : string);


procedure TrimLeft(var s : string);


procedure TrimRight(var s : string);


Properties

property AutoBuild : boolean


Events

Variables

FAutoBuild : boolean;


FFilter : PDB;


Fs : string;



Constructors


constructor Create(Filter : PDB);

Parameter @TTable. f.e.: F.Create(@Table1); nil if no table } { Parameetriks @TTable, mille filtrit hakkab muutma, nil kui ei


Functions


function Add(const S: string): Integer;

Adds one or more filter conditions. If condition is already in the } { filter then nothing happens } { Lisab filtrisse tingimuse S kujul 'väli tehe tingimus' ntx 'nr <> 6'} { operaatoreid and, or etc. ei tohi kasutada tingimuse otstes } { ntx 'nr <> 6 and nr <> 7' => lubatud } { ntx ' and nr <> 6 and ' => keelatud


procedure AssignTable(Filter : PDB);

Assigns different TTable to FilterList f.e.: F.AssignTable(@Table1)


procedure Build;

ReBuilds the filter. No need if AutoBuild is true } { Buildib terve filtri. Kui AutoBuild = true, siis pole vaja kasutada


procedure Clear;

Clears the filter } { Teeb filtri tühjaks


procedure DeleteF(S: string);

Removes the condition specified by S parameter, very useful } { Kustutab filtrist tingimuse S kujul 'väli tehe tingimus' } { ntx 'nr <> 6'


procedure DeleteIndex(Index: Integer);

Removes the condition specified by the Index parameter } { Kustutab filtrist index-nda tingimuse. Lõppuser ei kasuta eriti } { vt. DeleteF


function FilterToStr : string;

Returns the current filter. Build must be executed before if } { AutoBuild is false } { Tagastab terve filtri stringina } { Võib kasutada ntx koos Create(nil)-ga muutes TTable.Filtrit oma } { tahtmise järgi: TTable.Filter:= TFilterList.FilterToStr


procedure Insert(Index: Integer; const S: string);

Inserts the condition to position specified by Index parameter } { Lisab filtrisse soovitud kohale soovitud tingimuse


function CheckLeft(s : string) : integer;

TFilterList


function CheckRight(s : string) : integer;


procedure ReBuild;


procedure TrimBoth(var s : string);


procedure TrimLeft(var s : string);


procedure TrimRight(var s : string);


Properties


property AutoBuild : boolean


Events


Variables


FAutoBuild : boolean;


FFilter : PDB;


Fs : string;