Convert(Source: IRdsDictionary): IRdsDictionary;
Convert(Source: Prognoz.Platform.Interop.Rds.IRdsDictionary): Prognoz.Platform.Interop.Rds.IRdsDictionary;
Source. MDM dictionary to be converted.
The Convert method converts an MDM dictionary to a table MDM dictionary.
After executing the example the method returns the table MDM dictionary received after conversion.
Executing the example requires that the repository contains an MDM repository with the RDS identifier that includes an MDM dictionary with the DICT identifier.
Add links to the Metabase, Rds system assemblies.
Sub UserProc;
Var
MB: IMetabase;
RdsKey: Integer;
MObj: IMetabaseObject;
Dict: IRdsDictionary;
Converter: IRdsDictionaryConverter;
Result: IRdsDictionary;
Begin
MB := MetabaseClass.Active;
RdsKey := MB.GetObjectKeyById("RDS");
MObj := MB.ItemByIdNamespace("DICT", RdsKey).Bind;
Dict := MObj As IRdsDictionary;
Converter := New RdsDictionaryConverter.Create;
result := Converter.Convert(Dict);
End Sub UserProc;
After executing the example the MDM dictionary is converted to a table MDM dictionary.
Executing the example requires that the repository contains an MDM repository with the RDS identifier that includes an MDM dictionary with the DICT identifier.
Imports Prognoz.Platform.Interop.Rds;
…
[STAThread]
Public Shared Sub Main(Params: StartParams);
Var
MB: IMetabase;
RdsKey: uinteger;
MObj: IMetabaseObject;
Dict: IRdsDictionary;
Converter: IRdsDictionaryConverter;
Result: IRdsDictionary;
Begin
MB := Params.Metabase;
RdsKey := MB.GetObjectKeyById("RDS");
MObj := MB.ItemByIdNamespace["DICT", RdsKey].Bind();
Dict := MObj As IRdsDictionary;
Converter := New RdsDictionaryConverter.Create();
result := Converter.Convert(Dict);
End Sub;
After executing the example the MDM dictionary is converted to a table MDM dictionary.
See also: