IDADriver

Overview

IDADriver is designed for providing access to Data Abstract driver from Schema Modeler via the TDADriverManager.

TDADriverManager loads drivers and gets this interface with the GetDriverObject exported function.

In runtime, this interface can be received like this:

var
  i: integer;
  drv: IDADriver;
begin
  for i := 0 to (DADriverManager.DriverCount - 1) do begin
    drv := DADriverManager.Drivers[i];
    ShowMessage(drv.DriverID);
  end;

Location

  • Unit: uDAServerInterfaces.pas
  • Ancestry: IDADriver


 

Description

Driver's description.

property Description: string read

DriverID

Returns the driver's ID.

property DriverID: string read

Finalize  safecall

Initializes the driver

procedure Finalize

GetAuxDrivers  safecall

Returns a list of available auxiliary drivers.

procedure GetAuxDrivers(out List: IROStrings)

Parameters:

  • List: List of auxiliary driver names

GetAuxParams  safecall

Returns a list of custom parameters for the specified driver.

procedure GetAuxParams(const AuxDriver: string; out List: IROStrings)

Parameters:

  • AuxDriver: Aux driver name in question
  • List: List of auxiliary parameters

GetAvailableDriverOptions  safecall

Returns a set of available driver options.

function GetAvailableDriverOptions: TDAAvailableDriverOptions

GetAvailableDriverOptionsEx  safecall

Returns a set of available driver options for specific provider.

function GetAvailableDriverOptionsEx(AuxDriver: string): TDAAvailableDriverOptions

Parameters:

  • AuxDriver: Aux driver name in question

GetDefaultConnectionType  safecall

Returns a default connection type of the specified provider.

function GetDefaultConnectionType(const AuxDriver: string): string

Parameters:

  • AuxDriver: Aux driver name in question

GetDefaultCustomParameters  safecall

Returns custom driver-dependent parameters. If the driver supports multiple providers, it should use the IDADriver40 instead.

function GetDefaultCustomParameters: string

Initialize  safecall

Initializes the driver

procedure Initialize

MajVersion

Driver's major version.

property MajVersion: Byte read

MinVersion

Driver's minor version.

property MinVersion: Byte read

NewConnection (IDAConnectionManager, TDAConnection): IDAConnection  safecall overload

Creates a new connection with gives parameters

function NewConnection(const aConnectionManager: IDAConnectionManager; aConnectionDefinition: TDAConnection): IDAConnection

Parameters:

  • aConnectionManager: Connection manager
  • aConnectionDefinition: Connection parameters

NewConnection (string, string): IDAConnection  safecall overload

Creates a new connection with gives parameters

function NewConnection(const aName: string; const aConnectionType: string): IDAConnection

Parameters:

  • aName: Connection name
  • aConnectionType: Connection type

SetTraceOptions  safecall

Sets trace options.

  TDATraceOption = (toPrepare, toExecute, toFetch, toError, toStmt, toConnect, toTransact, toBlob, toService, toMisc, toParams);
  TDATraceOptions = set of TDATraceOption;
  TDALogTraceEvent = procedure(Sender: TObject; const Text: string; Tag: integer) of object;
procedure SetTraceOptions(TraceActive: Boolean; TraceOptions: TDATraceOptions; Callback: TDALogTraceEvent)

Parameters:

  • TraceActive: Current mode
  • TraceOptions: Set of TDATraceOption
  • Callback: Method to call in various OnTraceEvent event handlers

 

Description

Driver's description.

property Description: string read

DriverID

Returns the driver's ID.

property DriverID: string read

MajVersion

Driver's major version.

property MajVersion: Byte read

MinVersion

Driver's minor version.

property MinVersion: Byte read

 

Finalize  safecall

Initializes the driver

procedure Finalize

GetAuxDrivers  safecall

Returns a list of available auxiliary drivers.

procedure GetAuxDrivers(out List: IROStrings)

Parameters:

  • List: List of auxiliary driver names

GetAuxParams  safecall

Returns a list of custom parameters for the specified driver.

procedure GetAuxParams(const AuxDriver: string; out List: IROStrings)

Parameters:

  • AuxDriver: Aux driver name in question
  • List: List of auxiliary parameters

GetAvailableDriverOptions  safecall

Returns a set of available driver options.

function GetAvailableDriverOptions: TDAAvailableDriverOptions

GetAvailableDriverOptionsEx  safecall

Returns a set of available driver options for specific provider.

function GetAvailableDriverOptionsEx(AuxDriver: string): TDAAvailableDriverOptions

Parameters:

  • AuxDriver: Aux driver name in question

GetDefaultConnectionType  safecall

Returns a default connection type of the specified provider.

function GetDefaultConnectionType(const AuxDriver: string): string

Parameters:

  • AuxDriver: Aux driver name in question

GetDefaultCustomParameters  safecall

Returns custom driver-dependent parameters. If the driver supports multiple providers, it should use the IDADriver40 instead.

function GetDefaultCustomParameters: string

Initialize  safecall

Initializes the driver

procedure Initialize

NewConnection (IDAConnectionManager, TDAConnection): IDAConnection  safecall overload

Creates a new connection with gives parameters

function NewConnection(const aConnectionManager: IDAConnectionManager; aConnectionDefinition: TDAConnection): IDAConnection

Parameters:

  • aConnectionManager: Connection manager
  • aConnectionDefinition: Connection parameters

NewConnection (string, string): IDAConnection  safecall overload

Creates a new connection with gives parameters

function NewConnection(const aName: string; const aConnectionType: string): IDAConnection

Parameters:

  • aName: Connection name
  • aConnectionType: Connection type

SetTraceOptions  safecall

Sets trace options.

  TDATraceOption = (toPrepare, toExecute, toFetch, toError, toStmt, toConnect, toTransact, toBlob, toService, toMisc, toParams);
  TDATraceOptions = set of TDATraceOption;
  TDALogTraceEvent = procedure(Sender: TObject; const Text: string; Tag: integer) of object;
procedure SetTraceOptions(TraceActive: Boolean; TraceOptions: TDATraceOptions; Callback: TDALogTraceEvent)

Parameters:

  • TraceActive: Current mode
  • TraceOptions: Set of TDATraceOption
  • Callback: Method to call in various OnTraceEvent event handlers