Class ReportProcessor

java.lang.Object
com.softwaremining.report.ReportProcessor

public class ReportProcessor extends Object
ReportProcessor is a dedicated engine for emulating COBOL REPORT SECTION behavior in Java, interpreting standard carriage-control codes (blank=single-space, '0'=double-space, '-'=triple-space, '1'=form-feed, '+'=overstrike) and translating ADVANCING n LINES clauses into the correct sequence of control records. It also recognizes higher-level report controls such as PAGE-CONTROL, CONTROL-FOOTER, GROUP-HEADING and GROUP-FOOTING to manage page breaks, headers and footers automatically, exposing a clean API (e.g. advanceLines(int), formFeed(), startNewPage(), emitFooter()) so that client code remains declarative and free of low-level printer logic. In addition, the translator generates an XML definition of the REPORT SECTION at reports/myeport.xml—capturing groups, headings, footings and spacing directives—for downstream tools or audit. For full COBOL REPORT SECTION semantics see IBM’s documentation (https://www.ibm.com/docs/) or the Micro Focus guide (https://www.microfocus.com/docs/).
  • Constructor Details

    • ReportProcessor

      public ReportProcessor(String reportName, BaseService owner)
      Parameters:
      reportName - - corresponds to a section of XML file relating to this report. E.g. <report ... name="WEEKLY_REPORT">
      owner -
  • Method Details

    • getReportName

      public String getReportName()
    • initiate

      public void initiate()
    • generate

      public void generate(String groupName)
    • isTerminated

      public boolean isTerminated()
    • terminate

      public void terminate()
    • assignReportName

      public void assignReportName(String reportName)
      Report-Name corresponds to a section of XML file relating to this report. E.g. <report ... name="WEEKLY_REPORT">
      Parameters:
      reportName -
    • assignFileName

      public void assignFileName(String fileName)
    • retrieveLineCounter

      public final int retrieveLineCounter()
    • retrievePageCounter

      public final int retrievePageCounter()
    • assignPageCounter

      public final void assignPageCounter(int newValue)