@Test(expected = NullPointerException.class) public void generateSeries_NullYSettings() { seriesService.generateSeries(mock(JudgmentSeriesCriteria.class), mock(XSettings.class), null); }
@Override public Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings) { checkArguments(criteria, xsettings, ysettings); Series<Object, Integer> series = seriesGenerator.generateSeries(criteria, xsettings); @SuppressWarnings("unchecked") Series<Object, Number> recalcSeries = (Series<Object, Number>)seriesYRecalculatorManager.getSeriesYRecalculator(ysettings.getValueType()).recalculateSeries(series, criteria, xsettings, ysettings); return recalcSeries; }
SolrSeriesService implements SeriesService { @Override public Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings) { checkArguments(criteria, xsettings, ysettings); Series<Object, Integer> series = seriesGenerator.generateSeries(criteria, xsettings); @SuppressWarnings("unchecked") Series<Object, Number> recalcSeries = (Series<Object, Number>)seriesYRecalculatorManager.getSeriesYRecalculator(ysettings.getValueType()).recalculateSeries(series, criteria, xsettings, ysettings); return recalcSeries; } }
SolrSeriesService implements SeriesService { @Override public Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings) { checkArguments(criteria, xsettings, ysettings); Series<Object, Integer> series = seriesGenerator.generateSeries(criteria, xsettings); @SuppressWarnings("unchecked") Series<Object, Number> recalcSeries = (Series<Object, Number>)seriesYRecalculatorManager.getSeriesYRecalculator(ysettings.getValueType()).recalculateSeries(series, criteria, xsettings, ysettings); return recalcSeries; }  }
SolrSeriesService implements SeriesService { @Override public Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings) { checkArguments(criteria, xsettings, ysettings); Series<Object, Integer> series = seriesGenerator.generateSeries(criteria, xsettings); @SuppressWarnings("unchecked") Series<Object, Number> recalcSeries = (Series<Object, Number>)seriesYRecalculatorManager.getSeriesYRecalculator(ysettings.getValueType()).recalculateSeries(series, criteria, xsettings, ysettings); return recalcSeries; }  @Override Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings); @Autowired void setSeriesGenerator(SeriesGenerator seriesGenerator); @Autowired void setSeriesYRecalculatorManager(SeriesYRecalculatorManager seriesYRecalculatorManager); }
SolrSeriesService implements SeriesService { @Override public Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings) { checkArguments(criteria, xsettings, ysettings); Series<Object, Integer> series = seriesGenerator.generateSeries(criteria, xsettings); @SuppressWarnings("unchecked") Series<Object, Number> recalcSeries = (Series<Object, Number>)seriesYRecalculatorManager.getSeriesYRecalculator(ysettings.getValueType()).recalculateSeries(series, criteria, xsettings, ysettings); return recalcSeries; }  @Override Series<Object, Number> generateSeries(JudgmentSeriesCriteria criteria, XSettings xsettings, YSettings ysettings); @Autowired void setSeriesGenerator(SeriesGenerator seriesGenerator); @Autowired void setSeriesYRecalculatorManager(SeriesYRecalculatorManager seriesYRecalculatorManager);  }