How to do a conversion

To do a migration, if you have the prn file and you have your configuration ready, you just need to go to C:\migrator\bin and execute the doMigrate.bat. Before executing this bat file, you need to configure the steps you want to execute. The contents of the doMigrate.bat file are:

doMigrate.bat content

Every set defined in the doMigrate file defines if the corresponding migration step must be executed or not. For example, in the previous image, you can see that the separatingEAE is set to false. This means that the conversion tool will skip this step and will start executing the parsingStage.

Another important part of this file is the call to the setupProject. The content of the setupProject is something that can be added directly in this file but for now, is in a separate .bat file. You can look around in the migrator/bin folder and watch different examples defined there.

The contents of the setup project file are:

setup project bat contents.

The setupProject is also part of the conversion tool configuration used when you execute a code conversion. This file includes important information:

  • module: name of the module to convert. This is the name of the prn/ldl that the conversion tool will look for in the ldl folder.

  • modulePackage: name of the module package used in the generated code.

  • specificationPath: root folder when the configs and ldl folders are included.

  • configDir: root path where the conversion tool will look for the configs folder.

  • baseTempDir: base temporary folder.

  • moduleMaping: the same name as the module. The name of the module to be converted.

  • reportFormat: format of the reports. Use always the value Eae.

  • EaeParser: Use always the value Eae

  • reportVersion: Use always the value Eae

  • customer: This is the customer's name.

When everything is already configured to run the conversion tool you just need to open a command prompt in the migrator/bin folder and execute the doMigrate.bat.

Executing doMigrate.bat to run the Linc2JEE conversion tool

After hitting Enter to execute doMigrate.bat, you will see some information in the command prompt.

Command prompt output after hitting Enter.

You can see that the last line in the output corresponds to the execution of the conversion tool with the configuration file LincConverter.xml as an argument. These binaries were generated by including a Console.In.Read inside the code, probably to give some time when you want to debug the conversion tool solution. Here you need to enter any character in the command prompt and hit enter again to start the conversion process.

Last updated