Thursday, 7 June 2007


for NATURAL to JAVAJ2EE program conversion
by Ali Riza SARAL

Input may be a single SYSTRANS file which includes all the NATURAL batch, online programs, maps and data structure definitions. In other cases input may be a single folder where the programs to be converted reside as members of that directory.

The conversion program is supposed to convert the input file(s) and produce output programs in JAVA (or in other language). The output programs may reside in an output folder as members of that directory.

All of the above requires directory and member handling both for reading and writing. This requires that you take the names of these directories etc. from a decent setup file. This means, there must be an XML file where the program accesses through functions that use XML utilities. The same XML file and utilities may be used to write the setup part of the program which may give the user to choose specific directories for input, etc. as he/she wishes.

A small warning: The conversion process may not be a straight forward single run process. There may not be a single monolithic conversion program either. For example, a special conversion program may be run to convert local variables, global variables, DDM data structures first… Only after that, the program conversion process may be used because tprogram conversion includes the conversion of the names of the variables in the programs. The new names of the variables will be taken from the tables generated by the data structure conversion processes.

Also, program conversion process may be comprised of more than one runs according to how you implement parsing and conversion.