public ReportGenerator(boolean advancedMode, File baseDir, final GenerationProgress gp) {
        super();
        Logger.getLogger(ReportGenerator.class.getName()).entering(ReportGenerator.class.getName(), "ReportGenerator", new Object[] {advancedMode, baseDir, gp});
        try {
            this.advancedMode = advancedMode;
            this.baseDir = baseDir;
            this.generationProgressDialog = gp;
            Logger.getLogger(ReportGenerator.class.getName()).log(Level.INFO, "Starting the html report");
            String homeFolder = OSBasics.getHomeDir();
            homeFolder = homeFolder.concat(File.separatorChar + "HTMLReport");
            deleteHTMLReportDirectory(new File(homeFolder));
            new File(homeFolder).mkdir();
            reportFolder = homeFolder + File.separatorChar;
            if (advancedMode) {
                new File(reportFolder + "thumbnails").mkdir();
            }
            addPropertyChangeListener((PropertyChangeEvent evt) -> {
                if("progress".equals(evt.getPropertyName())) {
                    int newValue = (Integer) evt.getNewValue();
                    if (gp.getActionProgressBarValue() > newValue) {
                        return;
                    }
                    gp.setActionProgressBarValue(newValue);
                }
            });
        } catch (Exception ex) {
            Logger.getLogger(ReportGenerator.class.getName()).log(Level.SEVERE, "Unknown exception", ex);
            new InfoInterface(InfoInterface.InfoLevel.ERROR, "unknown");
        }
        Logger.getLogger(ReportGenerator.class.getName()).exiting(ReportGenerator.class.getName(), "ReportGenerator");
    }