java8 stream对list内容去重 userList = userList.stream().filter(u->Objects.nonNull(u)).collect(Collectors.collectingAndThen(Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(IUser::getUserId))), ArrayList::new));