Inspectopedia Help

'Collections.sort()' can be replaced with 'List.sort()'

Reports calls of Collections.sort(list, comparator) which can be replaced with list.sort(comparator).

Collections.sort is just a wrapper, so it is better to use an instance method directly.

This inspection only reports if the language level of the project or module is 8 or higher.

Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for JVM 2023.3

Plugin:

Java, 233.SNAPSHOT

Last modified: 13 July 2023