steam流对list集合分组

List<Student> list = this.list(queryWrapper); 
Map<Integer,List<Student>>map=list.stream().collect(
        Collectors.groupingBy(Student::getId));

你可能感兴趣的:(list)