ycl-common/src/main/java/constant/ApiConstants.java
@@ -60,4 +60,6 @@ //自贡行政编码 public final static String AreaNo = "5103"; //省厅前缀 public final static String Province = "Province_"; } ycl-common/src/main/java/constant/CalculationStrategyConstants.java
@@ -53,6 +53,10 @@ /** * 一机一档合格率 */ public static final String Video_MonitorQualify = "videoMonitorQualify"; /** * 视频点位在线率 */ public static final String Video_SiteOnline = "videoSiteOnline"; @@ -60,4 +64,8 @@ * 视频录像可用率 */ public static final String Video_Usability = "videoUsability"; /** * 平台在线率 */ public static final String Video_PlatformOnline = "videoPlatformOnline"; } ycl-server/src/main/java/com/ycl/calculate/CarClockAccuracyCalculation.java
@@ -73,7 +73,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/CarDataIntegrityCalculation.java
@@ -68,7 +68,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result, importantIds); } } ycl-server/src/main/java/com/ycl/calculate/CarDeviceSampleCalculation.java
@@ -74,7 +74,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result, importantIds); } } ycl-server/src/main/java/com/ycl/calculate/CarInFoAccuracyCalculation.java
@@ -70,7 +70,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/CarSnapshopDataCalculation.java
@@ -73,7 +73,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } @@ -137,7 +137,7 @@ BigDecimal siteOnline = siteOnline(siteOnlineParam); checkIndexCar.setSiteOnline(siteOnline); //视图库对接稳定性 BigDecimal avgCount = key.startsWith("Province_") ? cityCountAvg : countyCountAvg; BigDecimal avgCount = key.startsWith(ApiConstants.Province) ? cityCountAvg : countyCountAvg; Map<String, Object> viewConnectParam = new HashMap<>(); viewConnectParam.put("totalDataSum", stats.totalDataSum); viewConnectParam.put("avgCount", avgCount); ycl-server/src/main/java/com/ycl/calculate/CarSnapshotDelayCalculation.java
@@ -75,7 +75,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/FaceClockAccuracyCalculation.java
@@ -68,7 +68,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/FaceDeviceSampleCalculation.java
@@ -66,7 +66,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/FaceInFoAccuracyCalculation.java
@@ -67,7 +67,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/FaceSnapshotDataCalculation.java
@@ -74,7 +74,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } @@ -132,7 +132,7 @@ BigDecimal siteOnline = siteOnline(siteOnlineParam); checkIndexFace.setSiteOnline(siteOnline); //视图库对接稳定性 BigDecimal avgCount = key.startsWith("Province_") ? cityCountAvg : countyCountAvg; BigDecimal avgCount = key.startsWith(ApiConstants.Province) ? cityCountAvg : countyCountAvg; Map<String, Object> viewConnectParam = new HashMap<>(); viewConnectParam.put("totalDataSum", stats.totalDataSum); viewConnectParam.put("avgCount", avgCount); ycl-server/src/main/java/com/ycl/calculate/FaceSnapshotDelayCalculation.java
@@ -71,7 +71,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } ycl-server/src/main/java/com/ycl/calculate/IndexCalculationServe.java
@@ -4,6 +4,7 @@ import com.ycl.platform.base.CheckIndex; import com.ycl.platform.domain.entity.YwPoint; import com.ycl.platform.mapper.YwPointMapper; import constant.ApiConstants; import constant.CheckConstants; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; @@ -25,6 +26,13 @@ public class IndexCalculationServe { @Autowired private YwPointMapper pointMapper; //一机一档合格率 public BigDecimal monitorQualify(Map<String, Object> param) { BigDecimal totalMonitors = new BigDecimal((Integer) param.get("totalMonitors")); BigDecimal qualifyMonitor = new BigDecimal((Integer) param.get("qualifyMonitor")); return qualifyMonitor.divide(totalMonitors, 4, RoundingMode.HALF_UP); } //点位在线率 public BigDecimal siteOnline(Map<String, Object> param) { @@ -136,7 +144,7 @@ // 检查是否已存在今日数据 Optional<T> existingIndex = checkIndexList.stream() .filter(index -> key.equals(index.getDeptId().toString()) && (key.startsWith("Province_") ? CheckConstants.Examine_Tag_Province.equals(index.getExamineTag()) (key.startsWith(ApiConstants.Province) ? CheckConstants.Examine_Tag_Province.equals(index.getExamineTag()) : CheckConstants.Examine_Tag_County.equals(index.getExamineTag()))) .findFirst(); @@ -145,8 +153,8 @@ } else { try { checkIndex = clazz.getDeclaredConstructor().newInstance(); checkIndex.setDeptId(key.startsWith("Province_") ? Long.parseLong(key.split("_")[1]) : Long.parseLong(key)); checkIndex.setExamineTag(key.startsWith("Province_") ? CheckConstants.Examine_Tag_Province : CheckConstants.Examine_Tag_County); checkIndex.setDeptId(key.startsWith(ApiConstants.Province ) ? Long.parseLong(key.split("_")[1]) : Long.parseLong(key)); checkIndex.setExamineTag(key.startsWith(ApiConstants.Province ) ? CheckConstants.Examine_Tag_Province : CheckConstants.Examine_Tag_County); checkIndex.setCreateTime(new Date()); } catch (Exception e) { checkIndex = null; ycl-server/src/main/java/com/ycl/calculate/MonitorQualifyCalculation.java
New file @@ -0,0 +1,138 @@ package com.ycl.calculate; import com.ycl.platform.domain.entity.CheckIndexVideo; import com.ycl.platform.domain.result.UY.MonitorQualifyResult; import com.ycl.platform.domain.result.UY.QueryVqdResult; import com.ycl.platform.domain.vo.TMonitorVO; import com.ycl.platform.mapper.CheckIndexVideoMapper; import com.ycl.platform.mapper.TMonitorMapper; import com.ycl.platform.service.ICheckIndexVideoService; import constant.ApiConstants; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import org.springframework.util.CollectionUtils; import utils.DateUtils; import java.math.BigDecimal; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.function.Function; import java.util.stream.Collectors; /** * 计算一机一档合格率 * 获取分省厅、区域的map<k,v> k为deptId或者Province_deptId * 循环map计算数据上传及时性 * 更新或新增 */ @Component public class MonitorQualifyCalculation extends IndexCalculationServe implements CalculationStrategy<MonitorQualifyResult> { @Autowired private CheckIndexVideoMapper checkIndexVideoMapper; @Autowired private TMonitorMapper monitorMapper; @Autowired private ICheckIndexVideoService checkIndexVideoService; //区域视频在线率的内部类 private static class AreaStats { //总档案数 int totalMonitors = 0; //合格档案数 int qualifyMonitor = 0; } @Override public void calculate(List<MonitorQualifyResult> list) { if (CollectionUtils.isEmpty(list)) { return; } //获得国标码为key的设备map Map<String, TMonitorVO> monitorMap = monitorMapper.selectListByIds(list.stream().map(result -> result.getSerialNumber().getValue()).collect(Collectors.toList())) .stream().collect(Collectors.toMap(TMonitorVO::getSerialNumber, Function.identity())); //获取省厅国标码集合 List<String> provinceIds = getProvince(); Map<String, AreaStats> areaStatsMap = new HashMap<>(); for (MonitorQualifyResult result : list) { TMonitorVO monitor = monitorMap.get(result.getSerialNumber().getValue()); if (monitor == null) continue; String deptId = monitor.getDeptId().toString(); updateAreaStats(areaStatsMap, deptId, result); // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result); } } // 查询是否index表已经存在今日数据 List<CheckIndexVideo> checkIndexVideoList = checkIndexVideoMapper.selectToday(DateUtils.getDate()); List<CheckIndexVideo> checkIndexVideos = new ArrayList<>(); areaStatsMap.forEach((deptId, stats) -> { if (stats.totalMonitors > 0) { CheckIndexVideo CheckIndexVideo = createOrUpdateCheckIndexVideo(deptId, stats, checkIndexVideoList); if (CheckIndexVideo != null) { checkIndexVideos.add(CheckIndexVideo); } } }); checkIndexVideoService.saveOrUpdateBatch(checkIndexVideos); } /** * 累计总档案数和合格档案数 */ private void updateAreaStats(Map<String, AreaStats> areaStatsMap, String key, MonitorQualifyResult result) { //返回对象的引用,如果不存在会放入新的key,value AreaStats stats = areaStatsMap.computeIfAbsent(key, k -> new AreaStats()); stats.totalMonitors++; if (result != null && correct(result)){ stats.qualifyMonitor++; } } //全对返ture private boolean correct(MonitorQualifyResult result) { return checkError(result.getName()) && checkError(result.getCivilCode()) && checkError(result.getIp()) && checkError(result.getSerialNumber()) && checkError(result.getMacdz()) && checkError(result.getLatitude()) && checkError(result.getLongitude()) && checkError(result.getSbzt()) && checkError(result.getSxjcjqy()) && checkError(result.getSxjgnlx()) && checkError(result.getJkdwlx()) && checkError(result.getIntegrated_device()) ; } //检查指标,正常返回true private boolean checkError(MonitorQualifyResult.QualifyResult result) { return result.getError() != null && !result.getError(); } /** * 一机一档合格率 */ private CheckIndexVideo createOrUpdateCheckIndexVideo(String key, AreaStats stats, List<CheckIndexVideo> checkIndexVideoList) { CheckIndexVideo checkIndexVideo = getCheckIndex(key, checkIndexVideoList, CheckIndexVideo.class); if (checkIndexVideo == null) { return null; } //调用一机一档合格率计算方法 Map<String, Object> param = new HashMap<>(); param.put("totalMonitors", stats.totalMonitors); param.put("qualifyMonitor", stats.qualifyMonitor); BigDecimal index = monitorQualify(param); checkIndexVideo.setMonitorQualification(index); return checkIndexVideo; } } ycl-server/src/main/java/com/ycl/calculate/PlatformOnlineCalculation.java
@@ -1,13 +1,67 @@ package com.ycl.calculate; import com.ycl.platform.domain.entity.CheckIndexVideo; import com.ycl.platform.domain.result.UY.QueryVqdResult; import com.ycl.platform.domain.vo.PlatformOnlineVO; import com.ycl.platform.mapper.CheckIndexVideoMapper; import com.ycl.platform.service.ICheckIndexVideoService; import com.ycl.system.mapper.SysDeptMapper; import constant.ApiConstants; import constant.CheckConstants; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import org.springframework.util.CollectionUtils; import utils.DateUtils; import java.math.BigDecimal; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; public class PlatformOnlineCalculation extends IndexCalculationServe implements CalculationStrategy<QueryVqdResult> { /** * 平台在线率计算 * 离线时长每超过30分钟扣百分之十 * 不区分区域 */ @Component public class PlatformOnlineCalculation extends IndexCalculationServe implements CalculationStrategy<PlatformOnlineVO> { @Autowired private SysDeptMapper deptMapper; @Autowired private CheckIndexVideoMapper videoMapper; @Autowired private ICheckIndexVideoService checkIndexVideoService; @Override public void calculate(List<QueryVqdResult> list) { public void calculate(List<PlatformOnlineVO> list) { if (!CollectionUtils.isEmpty(list)) { //总离线时长 int time = list.stream().map(PlatformOnlineVO::getTodayOutlineSed).reduce(0, Integer::sum); //离线时长转换位分钟然后取模 int num = (time / 60) % 30; double score = Math.max(1 - num * 0.1, 0); //是否已经存在当日数据 List<CheckIndexVideo> checkIndexVideos = videoMapper.selectToday(DateUtils.getDate()); //所有区域部门 List<Long> deptIds = deptMapper.selectByParentId(207L); List<String> keys = new ArrayList<>(); //准备区分省厅、区域的deptId list for (Long deptId : deptIds) { keys.add(deptId + ""); keys.add(ApiConstants.Province + deptId); } List<CheckIndexVideo> videos = new ArrayList<>(); keys.forEach(key -> { //如果不存在就新增如果存在则复用 CheckIndexVideo checkIndex = getCheckIndex(key, checkIndexVideos, CheckIndexVideo.class); if (checkIndex != null) { checkIndex.setPlatformOnline(new BigDecimal(score)); videos.add(checkIndex); } }); checkIndexVideoService.saveOrUpdateBatch(videos); } } } ycl-server/src/main/java/com/ycl/calculate/VideoOnlineCalculation.java
@@ -74,7 +74,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result, important); } } ycl-server/src/main/java/com/ycl/calculate/VideoUsabilityCalculation.java
@@ -72,7 +72,7 @@ // 处理省厅数据 if (!CollectionUtils.isEmpty(provinceIds) && provinceIds.contains(monitor.getSerialNumber())) { String provinceKey = "Province_" + deptId; String provinceKey = ApiConstants.Province + deptId; updateAreaStats(areaStatsMap, provinceKey, result, important); } } ycl-server/src/main/java/com/ycl/factory/IndexCalculationFactory.java
@@ -1,6 +1,7 @@ package com.ycl.factory; import com.ycl.calculate.*; import com.ycl.platform.domain.result.UY.VideoQualityResult; import constant.CalculationStrategyConstants; import java.util.HashMap; @@ -36,11 +37,14 @@ calculators.put(CalculationStrategyConstants.Face_ClockAccuracy, new FaceClockAccuracyCalculation()); //TODO:人脸目录一致 //一机一档合格率 calculators.put(CalculationStrategyConstants.Video_MonitorQualify, new MonitorQualifyCalculation()); //视频点位在线率 calculators.put(CalculationStrategyConstants.Video_SiteOnline, new VideoOnlineCalculation()); //视频录像可用率 calculators.put(CalculationStrategyConstants.Video_Usability, new VideoUsabilityCalculation()); //平台在线率 calculators.put(CalculationStrategyConstants.Video_PlatformOnline,new PlatformOnlineCalculation()); } public static CalculationStrategy getCalculator(String indexName) { ycl-server/src/main/java/com/ycl/task/MonitorTask.java
@@ -54,7 +54,7 @@ Query query = new Query(Criteria.where("mongoCreateTime").gte(DateUtils.getDayStart(new Date())).lt(DateUtils.getDayEnd(new Date()))); List<OneMachineFileResult> oneMachineFileResults = mongoTemplate.find(query, OneMachineFileResult.class); //数据库monitor表数据 List<String> serialNumberInBase = monitorService.selectTMonitorList(null).stream().map(TMonitorVO::getSerialNumber).collect(Collectors.toList()); Map<String, TMonitorVO> monitorVOMap = monitorService.selectTMonitorList(null).stream().collect(Collectors.toMap(TMonitorVO::getSerialNumber, Function.identity())); //准备插入设备表的数据 List<TMonitor> monitorList = new ArrayList<>(); //准备插入点位表的数据 @@ -68,24 +68,27 @@ sysDictData.setDictType("platform_important_site"); List<SysDictData> DictDataList = dictDataService.selectDictDataList(sysDictData); List<String> importantSite = DictDataList.stream().map(SysDictData::getDictValue).collect(Collectors.toList()); //TODO:全年留存还是单次留存 for (OneMachineFileResult result : oneMachineFileResults) { TMonitor monitor = getMonitor(result); TMonitor monitor = getMonitor(result,monitorVOMap); YwPoint point = getPoint(result, pointMap, importantSite); monitorList.add(monitor); ywPointList.add(point); //比对筛选出新的数据 if (!CollectionUtils.isEmpty(serialNumberInBase) && !serialNumberInBase.contains(result.getSBBM())) { if (!CollectionUtils.isEmpty(monitorVOMap) && !monitorVOMap.containsKey(result.getSBBM())) { newMonitorList.add(monitor); } } //插入数据库 if (!CollectionUtils.isEmpty(monitorList)) { monitorService.deleteTMonitorById(null); monitorService.saveBatch(monitorList); monitorService.saveOrUpdateBatch(monitorList); } if(!CollectionUtils.isEmpty(ywPointList)){ ywPointService.saveOrUpdateBatch(ywPointList); } //新的数据放入Redis中等待考核指标任务使用 redisTemplate.opsForValue().set(RedisConstant.New_Monitor_Set, JSONArray.toJSONString(newMonitorList)); } private YwPoint getPoint(OneMachineFileResult result, Map<String, YwPoint> pointMap, List<String> importantSite) { @@ -108,15 +111,22 @@ //解析deptId //区域行政编码 String areaCode = result.getSBBM().substring(0, 6); Integer deptId = AreaDeptEnum.fromCode(areaCode).getDeptId(); if (deptId != null) { ywPoint.setDeptId(Long.valueOf(deptId + "")); AreaDeptEnum areaDeptEnum = AreaDeptEnum.fromCode(areaCode); //如果解析不出区域deptId为-1 Integer deptId = -1; if(areaDeptEnum!=null){ deptId = areaDeptEnum.getDeptId(); } ywPoint.setDeptId(Long.valueOf(deptId + "")); return ywPoint; } private TMonitor getMonitor(OneMachineFileResult result) { private TMonitor getMonitor(OneMachineFileResult result, Map<String, TMonitorVO> monitorVOMap) { TMonitor monitor = new TMonitor(); if (monitorVOMap.containsKey(result.getSBBM())) { monitor.setId(monitorVOMap.get(result.getSBBM()).getId()); } monitor.setSerialNumber(result.getSBBM()); monitor.setName(result.getSBMC()); monitor.setSiteType(Long.valueOf(result.getJKDWLX())); ycl-server/src/main/java/com/ycl/task/VideoTask.java
@@ -6,6 +6,7 @@ import com.ycl.platform.domain.entity.CheckIndexVideo; import com.ycl.platform.domain.param.UY.RecordMetaDSumParam; import com.ycl.platform.domain.result.HK.SnapshotDataMonitorResult; import com.ycl.platform.domain.result.UY.MonitorQualifyResult; import com.ycl.platform.domain.result.UY.QueryVqdResult; import com.ycl.platform.domain.vo.PlatformOnlineVO; import com.ycl.platform.mapper.CheckIndexVideoMapper; @@ -41,14 +42,11 @@ private MongoTemplate mongoTemplate; @Autowired private PlatformOnlineMapper platformOnlineMapper; @Autowired private CheckIndexVideoMapper videoMapper; @Autowired private SysDeptMapper deptMapper; public void siteOnlineTask() { Date yesterday = DateUtils.addDays(new Date(), -1); //计算点位在线率和重点点位在线率 //TODO:计算点位在线率和重点点位在线率 Query query = new Query(); query.addCriteria(Criteria .where("mongoCreateTime").gte(DateUtils.getDayStart(yesterday)).lt(DateUtils.getDayEnd(yesterday))); @@ -71,31 +69,26 @@ } public void oneMonitorFileTask() { //计算一机一档注册率、一机一档合格率、档案考核比 //计算一机一档注册率、档案考核比 } public void oneMonitorQualifyTask(){ //计算一机一档合格率 Date yesterday = DateUtils.addDays(new Date(), -1); Query query = new Query(); query.addCriteria(Criteria .where("mongoCreateTime").gte(DateUtils.getDayStart(yesterday)).lt(DateUtils.getDayEnd(yesterday))); List<MonitorQualifyResult> results = mongoTemplate.find(query, MonitorQualifyResult.class); CalculationStrategy calculator = IndexCalculationFactory.getCalculator(CalculationStrategyConstants.Video_MonitorQualify); calculator.calculate(results); } public void platformOnlineTask() { //计算平台在线率 //拿到今日离线时长数据 List<PlatformOnlineVO> list = platformOnlineMapper.sumYesterday(DateUtils.getMouthStart(new Date()), DateUtils.getMouthEnd(new Date())); // int num = (time / 60) % 30; // double score = Math.max(1 - num * 0.1, 0); // List<CheckIndexVideo> checkIndexVideos = videoMapper.selectToday(DateUtils.getDate()); // List<Long> deptIds = deptMapper.selectByParentId(207L); // Map<String, CheckIndexVideo> map = new HashMap<>(); // for (Long deptId : deptIds) { // CheckIndexVideo video = new CheckIndexVideo(); // video.setExamineTag(CheckConstants.Examine_Tag_County); // map.put(deptId + "", video); // CheckIndexVideo provinceVideo = new CheckIndexVideo(); // provinceVideo.setExamineTag(CheckConstants.Examine_Tag_Province); // map.put("Province_" + deptId, new CheckIndexVideo()); // } // map.forEach((deptId, video) -> { // // }); CalculationStrategy calculator = IndexCalculationFactory.getCalculator(CalculationStrategyConstants.Video_PlatformOnline); calculator.calculate(list); } }