实现了Interface Collector
提供了存放元素的容易
Collectors.toList()
Collectors.toSet()
Collectors.toMap
Collectors.toCollection(TreeSet::new)
Collectors.groupingBy()
其他的方法和Stream有重叠不建议使用
实现了Interface Collector
提供了存放元素的容易
Collectors.toList()
Collectors.toSet()
Collectors.toMap
Collectors.toCollection(TreeSet::new)
Collectors.groupingBy()
其他的方法和Stream有重叠不建议使用