| | |
| | | import constant.ApiConstants; |
| | | import constant.CheckConstants; |
| | | import constant.RedisConstant; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.data.redis.core.RedisTemplate; |
| | | import org.springframework.stereotype.Component; |
| | |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * 计算车辆目录一致率 |
| | | * 计算人脸目录一致率 |
| | | * 获取分省厅、区域的map<k,v> k为deptId或者Province_deptId |
| | | * 更新或新增 |
| | | */ |
| | | @Component |
| | | @Slf4j |
| | | public class FaceConsistentCalculation extends IndexCalculationServe implements CalculationStrategy<TMonitorVO> { |
| | | @Autowired |
| | | private CheckIndexFaceMapper checkIndexFaceMapper; |
| | |
| | | @Override |
| | | public void calculate(List<TMonitorVO> list) { |
| | | if (CollectionUtils.isEmpty(list)) { |
| | | log.info("数据为空"); |
| | | return; |
| | | } |
| | | //返回以国标码为key的设备map |
| | |
| | | } |
| | | //获取省厅国标码集合 |
| | | List<String> provinceIds = getProvince(); |
| | | //未注册车辆设备 |
| | | //未注册人脸设备 |
| | | Map<String,TMonitor> newMonitorMap = new HashMap<>(); |
| | | //Mongo一机一档同步Mysql时放入Redis 筛选出车辆档案 |
| | | String json = (String) redisTemplate.opsForValue().get(RedisConstant.New_Monitor_Set); |