@Override public JFreeChart create(final GraphConfiguration configuration, final ResultAction<? extends BuildResult> resultAction, final String pluginName) { ArrayList<Pair<Integer, Integer>> fixedWarnings = new ArrayList<Pair<Integer, Integer>>(); ArrayList<Pair<Integer, Integer>> newWarnings = new ArrayList<Pair<Integer, Integer>>(); extractPoints(configuration, resultAction, fixedWarnings, newWarnings); XYSeriesCollection xySeriesCollection = computeDifferenceSeries(fixedWarnings, newWarnings); JFreeChart chart = createXYChart(xySeriesCollection); chart.getXYPlot().getRenderer().setURLGenerator(new XyUrlBuilder(getRootUrl(), pluginName)); NumberAxis axis = new NumberAxis(); axis.setVerticalTickLabels(true); axis.setNumberFormatOverride(new HudsonBuildFormat()); axis.setAutoRange(true); axis.setAutoRangeIncludesZero(false); axis.setLowerMargin(0.0); axis.setUpperMargin(0.0); axis.setTickUnit(new NumberTickUnit(1.0)); chart.getXYPlot().setDomainAxis(axis); return chart; }
@Override public JFreeChart create(final GraphConfiguration configuration, final ResultAction<? extends BuildResult> resultAction, final String pluginName) { ArrayList<Pair<Integer, Integer>> fixedWarnings = new ArrayList<Pair<Integer, Integer>>(); ArrayList<Pair<Integer, Integer>> newWarnings = new ArrayList<Pair<Integer, Integer>>(); extractPoints(configuration, resultAction, fixedWarnings, newWarnings); XYSeriesCollection xySeriesCollection = computeDifferenceSeries(fixedWarnings, newWarnings); JFreeChart chart = createXYChart(xySeriesCollection); chart.getXYPlot().getRenderer().setURLGenerator(new XyUrlBuilder(getRootUrl(), pluginName)); NumberAxis axis = new NumberAxis(); axis.setVerticalTickLabels(true); axis.setNumberFormatOverride(new HudsonBuildFormat()); axis.setAutoRange(true); axis.setAutoRangeIncludesZero(false); axis.setLowerMargin(0.0); axis.setUpperMargin(0.0); axis.setTickUnit(new NumberTickUnit(1.0)); chart.getXYPlot().setDomainAxis(axis); return chart; }
@Override public StringBuffer format(final double number, final StringBuffer toAppendTo, final FieldPosition pos) { return format((long)number, toAppendTo, pos); }
/** {@inheritDoc} */ @Override public StringBuffer format(final double number, final StringBuffer toAppendTo, final FieldPosition pos) { return format((long)number, toAppendTo, pos); }