Parameters and Constructors

Figure 121. Compare Report Constructor

public CompareReport(String filename,           1
                     String title,              2
                     ReportWriter ReportWriter, 3
                     Vector list,               4  
                     String[] filenames,        5
                     String[] expression)       6



filename - The basename to be used for output from this Comparison Report. This name must be unique compared to all other reports and must contain NO file extension as three files will be automatically created with this filename (.html, .png, .csv).


title - The title to be displayed in the HTML and PNG sub-reports, as well as the name to appear in the Comparison Writer directory tree.


ReportWriter - By specifying 'ReportWriter' the Comparison Writer will look to the Report writer to get the CURRENT scenario that is running at the moment. Without specifying 'ReportWriter' the current scenario will not be included in the report, only those reports in saved scenario folders. Always specify 'ReportWriter'.


list - This parameter allows you to specify which scenarios are to be compared with the CURRENT scenario. This list would include scenario names, or could refer to a predefined array of scenario folders.


filenames - This is the actual report filename that the Comparison Writer will search out in each specified scenario folder. This string parameter must be enclosed in "" and include the CSV file extension. If a report is part of a sub-folder in the scenario be sure to include the entire directory path (folder/sub-folder/filename.csv).


expression - This parameter defines the expression to be used to isolate information in each scenario report specified. The expression could be a simple column name ("TOTAL") or it can be an expression such as ("product.Area.managed.LA" + "product.Area.managed.DF").


Due to the method in which the Comparison Report Writer searches for reports to compare, it is extremely important that a consistent nomenclature system is used when defining reports to the Report Writer. Each report that is to be compared between scenarios needs an identical 'path' or filename.csv. Changes to the nomenclature between scenarios will result in the Comparison Writer being unable to find the required file.