question: private List < ValidationResult > orderedList ( Collection < ValidationResult > results ) { List < ValidationResult > resultList = new ArrayList < > ( results ) ; Collections . sort ( resultList ) ; return resultList ; }
target:  Returns a naturally ordered list of ValidationResults. <p> When comparing two collections, this assures that all the items are in the same order for comparison. It also means that when there are different values for the same period/rule/source, etc., the results are more likely to be in the same order to make it easier to see the difference. <p> By making this a List instead of, say a TreeSet, duplicate values (if any should exist by mistake!) are preserved.