@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 String generateURL(final XYDataset dataset, final int series, final int item) { return getRootUrl() + (int)dataset.getXValue(series, item) + getPluginName(); } }
/** {@inheritDoc} */ public String generateURL(final XYDataset dataset, final int series, final int item) { return getRootUrl() + (int)dataset.getXValue(series, item) + getPluginName(); } }