Inspectopedia Help

Java 21

Explicit class declaration can be converted into implicitly declared class   New in this release

Reports ordinary classes, which can be converted into implicitly declared classes Example: public class Sample { public static void main(String[] args) { System.out.println("Hello, world!"); } } After the quick-fix is applied: public static void main(String[] args) { System.out.println("Hello, world!"); }.

Implicitly declared class can be replaced with ordinary class   New in this release

Reports implicitly declared classes and suggests replacing them with regular classes.

Record pattern can be used  

Reports patterns that can be replaced with record patterns.

SequencedCollection method can be used  

Reports collection API method calls that can be simplified using SequencedCollection methods.

String template can be used  

Reports String concatenations that can be simplified by replacing them with a string template.

Last modified: 18 June 2024