class ReporterParameterParser {

    static String getOutputFormat(Map<String, String> parameters) {
        final String outputLong = parameters.get(OUTPUT_FORMAT_PREFIX_LONG);
        if (outputLong != null) {
            return outputLong;
        } else {
            return Optional.ofNullable(parameters.get(OUTPUT_FORMAT_PREFIX_SHORT))
                    .orElseGet(() -> {
                        LOGGER.warn("No output format is given.");
                        return DEFAULT_OUTPUT_FORMAT;
                    });
        }
    }

    private  ReporterParameterParser();

}