IMetabaseDefinitions.ReadFromFile

Syntax

ReadFromFile(FileName: String);

Parameters

FileName - a path to the file in which the descriptions of the repositories are contained.

Description

The ReadFromFile method reads the description of repositories from the file.

Comments

The structure of the file is described in the Setting Up Repositories and Autoupdate Using File section.

Example

Executing the example requires the c:\Def.xml file that contains the description of repositories. The descriptions that are contained in the file, are not present in the manager of repositories.

Sub UserProc;
Var
    Man: IMetabaseManager;
    Defs: IMetabaseDefinitions;
    Def: IMetabaseDefinition;
Begin
    Man := MetabaseManagerFactory.Active;
    Defs := Man.Definitions;
    Defs.ReadFromFile("c:\Def.xml");
    For Each Def In Defs Do
        Def.Save;
    End For;
End Sub UserProc;

The descriptions of repositories are loaded from the Def.xml file after executing this example. These descriptions will be saved and in further can be used on working with the platform.

See also:

IMetabaseDefinitions