164 lines
8.8 KiB
ObjectPascal
164 lines
8.8 KiB
ObjectPascal
unit DataAbstract_IDE_Reg;
|
|
|
|
{----------------------------------------------------------------------------}
|
|
{ Data Abstract Library - IDE Library
|
|
{
|
|
{ compiler: Delphi 6 and up, Kylix 3 and up
|
|
{ platform: Win32, Linux
|
|
{
|
|
{ (c)opyright RemObjects Software. all rights reserved.
|
|
{
|
|
{ Using this code requires a valid license of the Data Abstract
|
|
{ which can be obtained at http://www.remobjects.com.
|
|
{----------------------------------------------------------------------------}
|
|
|
|
{$IFDEF MSWINDOWS}
|
|
{$I ..\DataAbstract.inc}
|
|
{$ENDIF MSWINDOWS}
|
|
{$IFDEF LINUX}
|
|
{$I ../DataAbstract.inc}
|
|
{$ENDIF LINUX}
|
|
|
|
interface
|
|
|
|
procedure Register;
|
|
|
|
implementation
|
|
|
|
uses
|
|
Classes, uDAClasses, uDADataTable, uDARemoteDataAdapter, uDARemoteDataAdapterRequests,
|
|
uDADataAbstractEditors, uDADriverManager, uDAInterfaces,
|
|
uDABusinessProcessor, uRODLGenTools, ColnEdit,
|
|
DB, SysUtils, uDADBSessionManagerEditor, uDADBSessionManager,
|
|
DARemoteService_Impl, DALoginService_Impl,
|
|
DataAbstractService_Impl, BaseLoginService_Impl, MultiDbLoginService_Impl, SimpleLoginService_Impl,
|
|
uDAClientDataModule, uDADesigntimeCall, uDADataTableReferenceCollection,
|
|
{$IFDEF MSWINDOWS}
|
|
uROProductVersionInfo, fROAbout,
|
|
{$ENDIF MSWINDOWS}
|
|
{$IFDEF DELPHI5}
|
|
DsgnIntf, DMDesigner,
|
|
{$ELSE}
|
|
DesignIntf, DesignEditors;
|
|
{$ENDIF}
|
|
|
|
procedure Register;
|
|
begin
|
|
RegisterComponentEditor(TDADriverManager, TDADriverManagerEditor);
|
|
RegisterComponentEditor(TDASchema, TDASchemaEditor);
|
|
RegisterComponentEditor(TDAConnectionManager, TDAConnectionManagerEditor);
|
|
RegisterComponentEditor(TDADataDictionary, TDADataDictionaryEditor);
|
|
RegisterComponentEditor(TDADataTable, TDADataTableEditor);
|
|
RegisterComponentEditor(TDARemoteDataAdapter, TDARemoteDataAdapterEditor);
|
|
RegisterComponentEditor(TDADesigntimeCall, TDADesigntimeCallEditor);
|
|
|
|
{$IFDEF MSWINDOWS}
|
|
//RegisterComponentEditor(TDAClientDataModule, TDAClientDataModuleEditor);
|
|
{$ENDIF MSWINDOWS}
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDARemoteRequest, 'MethodName', TDADataRequestCallMethodNameEditor);
|
|
|
|
{$IFDEF MSWINDOWS}
|
|
RegisterPropertyEditor(TypeInfo(string), TDADataTable, 'MasterFields', TDADataTableMasterDetailProps);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADataTable, 'DetailFields', TDADataTableMasterDetailProps);
|
|
RegisterPropertyEditor(TypeInfo(TStrings), TDADataTable, 'MasterRequestMappings', TDADataTableMasterDetailProps);
|
|
RegisterPropertyEditor(TypeInfo(TStrings), TDADataTable, 'MasterParamsMappings', TDADataTableMasterDetailProps);
|
|
{$ENDIF MSWINDOWS}
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDADriverManager, 'DriverDirectory', TDADriverManagerDirectory);
|
|
RegisterPropertyEditor(TypeInfo(TComponent), TDADataTableReference, 'DataTable', TDADataTableReferenceDataTable);
|
|
|
|
RegisterPropertyEditor(TypeInfo(TDataset), TDADataSource, 'Dataset', NIL);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDADataTable, 'LogicalName', TDADataTableLogicalNameEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADataTable, 'LocalConnection', TDADataTableLocalConnection);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDAUpdateRule, 'DatasetName', TDACollectionItemDatasetNameEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADatasetRelationship, 'DetailDatasetName', TDACollectionItemDatasetNameEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADatasetRelationship, 'MasterDatasetName', TDACollectionItemDatasetNameEditor);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDABusinessProcessor, 'InsertCommandName', TDABusinessProcessorCommandProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDABusinessProcessor, 'DeleteCommandName', TDABusinessProcessorCommandProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDABusinessProcessor, 'UpdateCommandName', TDABusinessProcessorCommandProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDABusinessProcessor, 'ReferencedDataset', TDABusinessProcessorRefDatasetProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDABusinessProcessor, 'RefreshDatasetName', TDABusinessProcessorRefDatasetProperty);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'InsertSessionCommand', TDASchemaCommandListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'UpdateSessionCommand', TDASchemaCommandListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'DeleteSessionCommand', TDASchemaCommandListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'ClearSessionsCommand', TDASchemaCommandListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'GetSessionCountDataSet', TDASchemaDataSetListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'GetAllSessionIDsDataset', TDASchemaDataSetListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'GetSessionDataSet', TDASchemaDataSetListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDADBSessionManager, 'Connection', TDASchemaConnectionsListEditor);
|
|
|
|
RegisterPropertyEditor(TypeInfo(TCollection), TDADataset, 'Fields', TCollectionProperty);
|
|
RegisterPropertyEditor(TypeInfo(TCollection), TDADataset, 'Params', TCollectionProperty);
|
|
RegisterPropertyEditor(TypeInfo(TCollection), TDADataset, 'Statements', TCollectionProperty);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDALoginService, 'LoginDataset', TDARemoteServiceDataSetListEditor);
|
|
RegisterPropertyEditor(TypeInfo(string), TDALoginService, 'LogoutCommand', TDARemoteServiceCommandListEditor);
|
|
|
|
RegisterPropertyEditor(TypeInfo(string), TDAField, 'KeyFields', TDALookupSourceProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDAField, 'LookupKeyFields', TDALookupDestProperty);
|
|
RegisterPropertyEditor(TypeInfo(string), TDAField, 'LookupResultField', TDALookupResultFieldProperty);
|
|
|
|
{$IFDEF VER140UP}
|
|
RegisterCustomModule(TDARemoteService, TCustomModule);
|
|
RegisterCustomModule(TDALoginService, TCustomModule);
|
|
RegisterCustomModule(TDataAbstractService, TCustomModule);
|
|
RegisterCustomModule(TBaseLoginService, TCustomModule);
|
|
RegisterCustomModule(TSimpleLoginService, TCustomModule);
|
|
RegisterCustomModule(TMultiDbLoginService, TCustomModule);
|
|
{$ELSE}
|
|
RegisterCustomModule(TDARemoteService, TDataModuleDesignerCustomModule);
|
|
RegisterCustomModule(TDALoginService, TDataModuleDesignerCustomModule);
|
|
RegisterCustomModule(TDataAbstractService, TDataModuleDesignerCustomModule);
|
|
RegisterCustomModule(TBaseLoginService, TDataModuleDesignerCustomModule);
|
|
RegisterCustomModule(TSimpleLoginService, TDataModuleDesignerCustomModule);
|
|
RegisterCustomModule(TMultiDbLoginService, TDataModuleDesignerCustomModule);
|
|
{$ENDIF}
|
|
|
|
RegisterRODataModuleClass(TDataAbstractService,
|
|
'&Data Abstract 4.0 Service',
|
|
'Data Abstract datamodule. '+
|
|
'This is the preferred server type when creating a Data Abstract version 4.0 or above server.',
|
|
'uRORemoteDataModule, uDAInterfaces, DataAbstractService_Impl, DataAbstract4_Intf'
|
|
);
|
|
|
|
RegisterRODataModuleClass(TDARemoteService,
|
|
'Data Abstract &3.0 Remote Service',
|
|
'Data Abstract datamodule. This is the preferred server type when creating backward-compatible version 3.0 Data Abstract server.',
|
|
'uRORemoteDataModule, uDAInterfaces, DARemoteService_Impl, DataAbstract3_Intf'
|
|
);
|
|
|
|
RegisterCustomModule(TDAClientDataModule,TCustomModule);
|
|
|
|
{ TDARemoteDataAdapter }
|
|
RegisterPropertiesInCategory('Dynamic Method Binding', TDARemoteDataAdapter, ['GetSchemaCall', 'GetDataCall', 'GetScriptsCall', 'UpdateDataCall']);
|
|
|
|
RegisterPropertiesInCategory('Legacy', TDAGetDataRequest, ['OutgoingParamsParameter', 'OutgoingIncludeSchemaParameter', 'OutgoingMaxRecordsParameter']);
|
|
|
|
{ TDADataTable }
|
|
//RegisterPropertiesInCategory('Legacy v3.0', TDADataTable, ['DataRequestCall', 'DataUpdateCall', 'SchemaCall', 'ScriptCall', 'Adapter']);
|
|
RegisterPropertiesInCategory('Master/Detail', TDADataTable, ['MasterFields', 'MasterMappingMode', 'MasterOptions', 'MasterParamsMappings', 'MasterRequestMappings', 'MasterSource', 'DetailFields', 'DetailOptions']);
|
|
RegisterPropertiesInCategory('Database', TDADataTable, ['Fields', 'Params', 'LogicalName', 'IndexDefs', 'IndexName', 'Active', 'StoreActive', 'LogChanges', 'MaxRecords']);
|
|
RegisterPropertiesInCategory('Business Rules', TDADataTable, ['BusinessRulesID', 'ScriptCode']);
|
|
RegisterPropertiesInCategory('Local Data', TDADataTable, ['LocalConnection', 'LocalSchema', 'LocalDataStreamer']);
|
|
|
|
{ DA Service }
|
|
|
|
{ Login Services }
|
|
RegisterPropertiesInCategory('Login', TBaseLoginService, ['OnLogout']);
|
|
RegisterPropertiesInCategory('Login', TSimpleLoginService, ['OnLogin']);
|
|
RegisterPropertiesInCategory('Login', TMultiDbLoginService, ['OnLogin']);
|
|
end;
|
|
|
|
{$IFDEF MSWINDOWS}
|
|
initialization
|
|
RegisterProduct('{261E7EA5-C380-42A4-90AC-1FA10ADB39D8}',VersionBuildNo(hInstance));
|
|
finalization
|
|
UnregisterProduct('{261E7EA5-C380-42A4-90AC-1FA10ADB39D8}');
|
|
{$ENDIF MSWINDOWS}
|
|
end.
|