TApolloEngine

<< Click to Display Table of Contents >>

Navigation:  Apollo VCL Components > Apollo VCL Component Reference > TApolloEngine >

TApolloEngine

 

TApolloEngine is a non-visual class that is defined in ApolloEngInt.PAS. This system class makes the management of the various collation settings supported by Apollo easy to use. The various methods may be called to quickly set ordering and collation throughout an application. Settings are global, so changes will affect all tables. Collation sequences can have additional rules applied such as Duden support or even user-defined rules. This feature makes Apollo versatile in allowing develoeprs to control sort orders with a high degree of precision.

See the Collation Sample application to see how collation sequencing can be used. This sample should be located in ..\Engine\Collation. Delphi source code is included.

image\tip.gif You must add ApolloEngInt to the uses section of your units before you can use TApolloEngine.

Properties

None.

Methods

function LoadDLLs: boolean stdcall; // Do not call directy

procedure FreeDLLs; // Do not call directly

procedure SetSystemCollation;

procedure SetMachineCollation;

procedure AddDudenCollation;

procedure AddEtecCollation;

function GetSystemLocale: PChar stdcall;

function ViewSystemCharOrder: String stdcall;

 

International, Duden and Spanish Defines

There are three new defines available In ApolloEngInt.PAS that allow developers to set International, Duden and Spanish collation sequences.

 

The defines are located on line 15-18 as follows:

 

// {$define INTL_LANG} // Uncomment to force machine collation

// {$define SPAN_LANG} // Uncomment to add Spanish collation

// {$define DUDN_LANG} // Uncomment to add Duden collation

 

Uncomment the desired define and recompile the Apollo VCL Package. For example, to enable Duden support, do the following:

 

// {$define INTL_LANG} // Uncomment to force machine collation

// {$define SPAN_LANG} // Uncomment to add Spanish collation

{$define DUDN_LANG} // Uncomment to add Duden collation

Sample Usage

// view Windows ordered charset

edWindows.Text := ApolloEngine.ViewSystemCharOrder;

 

// view system locale

edLanguage.Text := ApolloEngine.GetSystemLocale;

 

See Also

Collation Support Summary