第一种 :根据三个字段去重 getWerks getResDate getZcar " ;" 隔开
List<TClSchedulingInfoEntity> distinctClass = listTClSchedulingInfoEntitys.stream().collect(Collectors.collectingAndThen(Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getWerks() + ";" + o.getResDate()+";"+o.getZcar()))), ArrayList::new));
参考地址:https://blog.csdn.net/zh15732621679/article/details/80483617