private void updateFileScenarioNoraUiCliFiles(Gson gson, NoraUiScenarioFile noraUiScenarioFile) {
        try (FileWriter fw = new FileWriter(CLI_FILES_DIR + File.separator + CLI_SCENARIOS_FILES_DIR + File.separator + noraUiScenarioFile.getName() + JSON)) {
            BufferedWriter bw = new BufferedWriter(fw);
            bw.write(gson.toJson(noraUiScenarioFile));
            bw.flush();
            bw.close();
        } catch (IOException e) {
            logger.error(TECHNICAL_IO_EXCEPTION, e.getMessage(), e);
        }
    }
private void updateFileScenarioNoraUiCliFiles ( Gson gson , NoraUiScenarioFile noraUiScenarioFile ) { try ( FileWriter fw = new FileWriter ( CLI_FILES_DIR + File . separator + CLI_SCENARIOS_FILES_DIR + File . separator + noraUiScenarioFile . getName ( ) + JSON ) ) { BufferedWriter bw = new BufferedWriter ( fw ) ; bw . write ( gson . toJson ( noraUiScenarioFile ) ) ; bw . flush ( ) ; bw . close ( ) ; } catch ( IOException e ) { logger . error ( TECHNICAL_IO_EXCEPTION , e . getMessage ( ) , e ) ; } }
@param gson
is singleton json tool.
@param noraUiScenarioFile
Object contain a scenario file from CLI Files.