/** * @param dowCallMap * @param perDayCallMap * @param dowCategory * @param dateCategory * @param roamingTrend */ private void populateVoiceCallChart( final Map<VoiceType, Map<DayOfWeek, Double>> dowCallMap, final Map<VoiceType, Map<Long, Double>> perDayCallMap, final Set<DayOfWeek> dowCategory, final Set<Long> dateCategory, final RoamingTrend roamingTrend, final long startDate) { final List<ChartSeries> dowCallSeriesList = new ArrayList<ChartSeries>(); for (final VoiceType voiceType : dowCallMap.keySet()) { final ChartSeries series = new ChartSeries(); series.setName(voiceType.name()); series.setData(dowCallMap.get(voiceType).values()); dowCallSeriesList.add(series); } final List<ChartSeries> perDayCallSeriesList = new ArrayList<ChartSeries>(); for (final VoiceType voiceType : perDayCallMap.keySet()) { final PerDaySeries series = new PerDaySeries(); series.setName(voiceType.name()); series.setPointStart(startDate); series.setData(perDayCallMap.get(voiceType).values()); perDayCallSeriesList.add(series); } final RoamingTrendChart voiceChart = new RoamingTrendChart(); voiceChart.setDowCategoryList(dowCategory); // voiceChart.setPerDayCategoryList(dateCategory); voiceChart.setDowSeriesList(dowCallSeriesList); voiceChart.setPerDaySeriesList(perDayCallSeriesList); roamingTrend.setRoamersMTMOChart(voiceChart); }
/** * @param dowCountMap * @param perDayCountMap * @param dowCategory * @param dateCategory * @param roamingTrend */ private void populateRoamerCountChart( final Map<RoamerType, Map<DayOfWeek, Double>> dowCountMap, final Map<RoamerType, Map<Long, Double>> perDayCountMap, final Set<DayOfWeek> dowCategory, final Set<Long> dateCategory, final RoamingTrend roamingTrend, final long startDate) { final List<ChartSeries> dowCountSeriesList = new ArrayList<ChartSeries>(); for (final RoamerType roamerType : dowCountMap.keySet()) { final ChartSeries series = new ChartSeries(); series.setName(roamerType.getDisplayName()); series.setData(dowCountMap.get(roamerType).values()); dowCountSeriesList.add(series); } final List<ChartSeries> perDayCountSeriesList = new ArrayList<ChartSeries>(); for (final RoamerType roamerType : perDayCountMap.keySet()) { final PerDaySeries series = new PerDaySeries(); series.setName(roamerType.getDisplayName()); series.setPointStart(startDate); series.setData(perDayCountMap.get(roamerType).values()); perDayCountSeriesList.add(series); } final RoamingTrendChart roamerCountChart = new RoamingTrendChart(); roamerCountChart.setDowCategoryList(dowCategory); // roamerCountChart.setPerDayCategoryList(dateCategory); roamerCountChart.setDowSeriesList(dowCountSeriesList); roamerCountChart.setPerDaySeriesList(perDayCountSeriesList); roamingTrend.setRoamersCountChart(roamerCountChart); }
/** * @param dowCallMap * @param perDayCallMap * @param dowCategory * @param dateCategory * @param roamingTrend */ private void populateDataChart( final Map<DayOfWeek, Double> dowDataMap, final Map<Long, Double> perDayDataMap, final Set<DayOfWeek> dowCategory, final Set<Long> dateCategory, final RoamingTrend roamingTrend, final long startDate) { final List<ChartSeries> dowDataSeriesList = new ArrayList<ChartSeries>(); if (!dowDataMap.values().isEmpty()) { final ChartSeries dowSeries = new ChartSeries(); dowSeries.setName("Data"); dowSeries.setShowInLegend(false); dowSeries.setData(dowDataMap.values()); dowDataSeriesList.add(dowSeries); } final List<ChartSeries> perDayDataSeriesList = new ArrayList<ChartSeries>(); if (!perDayDataMap.values().isEmpty()) { final PerDaySeries dateSeries = new PerDaySeries(); dateSeries.setName("Data"); dateSeries.setShowInLegend(false); dateSeries.setData(perDayDataMap.values()); dateSeries.setPointStart(startDate); perDayDataSeriesList.add(dateSeries); } final RoamingTrendChart dataChart = new RoamingTrendChart(); dataChart.setDowCategoryList(dowCategory); // dataChart.setPerDayCategoryList(dateCategory); dataChart.setDowSeriesList(dowDataSeriesList); dataChart.setPerDaySeriesList(perDayDataSeriesList); roamingTrend.setRoamersDataChart(dataChart); }