CobolPreprocessor.CobolSourceFormatEnum format = CobolPreprocessor.CobolSourceFormatEnum.FIXED;
String preProcessedInput = new CobolPreprocessorImpl().process(inputFile, copyBookFiles,format);
File preprocessedFile = new File(cobolFileName + "_preprocessed.cbl");
FileUtils.writeStringToFile(preprocessedFile, preProcessedInput);
and checking the output, it's a bit unusal that the wrong sequence for an inline comment ist used:
>* instead of the ANSI-2005 *>
I would recommend to use the ANSI-inline comment format and additionally position the Asterisk ( ) into the 7th column. Currently the '>' sign is in column 7 and '' in column 8 ... thus a compilation of the preprocessed inputfile fails.
DATE-WRITTEN. >*CE 06.1993.
>*CE =================================================================
>*CE Dieses Programm liest die allgemeinen Vorlaufanweisungen, *
>*CE die ein Programm benötigt. *
...etc...
Writing the preprocessed Cobolfiles to disk
and checking the output, it's a bit unusal that the wrong sequence for an inline comment ist used:
>*
instead of the ANSI-2005*>
I would recommend to use the ANSI-inline comment format and additionally position the Asterisk ( ) into the 7th column. Currently the '>' sign is in column 7 and '' in column 8 ... thus a compilation of the preprocessed inputfile fails.referring to inline comments of MF-documentation: http://documentation.microfocus.com/help/index.jsp?topic=%2Fcom.microfocus.eclipse.infocenter.studee60ux%2FHRLHLHCPRO01U990.html