List<UserInfo> userInfoList = userInfoService.getUserInfoList(userInfoListQuery);
Map<Long, UserInfo> userInfoMap = userInfoList.stream().collect(Collectors.toMap(UserInfo::getId, Function.identity()));
List<Shift> shiftList = shiftService.getAllShift();
Map<Long, Shift> shiftMap = shiftList.stream().collect(Collectors.toMap(Shift::getId, Function.identity()));
List<GroupPersonRelation> groupPersonRelationAllList = groupPersonRelationService.getList();
Map<Long, List<GroupPersonRelation>> groupPersonRelationMap = groupPersonRelationAllList.stream().collect(Collectors.groupingBy(GroupPersonRelation::getGroupId));
stream
最新推荐文章于 2024-06-05 18:48:00 发布