questionnaireRiskEOList = questionnaireRiskEOList.stream().collect(Collectors.collectingAndThen(Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(QuestionnaireRiskEO :: getQuestionnaireCode))), ArrayList::new));
https://blog.csdn.net/gsls200808/article/details/86501905