Inspectopedia 2025.2 Help

Usage of API marked for removal

Reports usages of deprecated APIs (classes, fields, and methods) that are marked for removal with @Deprecated(forRemoval=true).

Locating this inspection

By ID

Can be used to locate inspection in e.g. Qodana configuration files, where you can quickly enable or disable it, or adjust its settings.

removal
Via Settings dialog

Path to the inspection settings via IntelliJ Platform IDE Settings dialog, when you need to adjust inspection settings directly from your IDE.

Settings or Preferences | Editor | Inspections | Java | Code maturity

The code that uses an API marked for removal may cause a runtime error with a future version of the API. That is why the recommended severity for this inspection is Error.

You can change the severity to Warning if you want to use the same code highlighting as in ordinary deprecation.

New in 2017.3

Inspection options

Here you can find the description of settings available for the Usage of API marked for removal inspection, and the reference of their default values.

Ignore in the same outermost class

Default value:

Selected

Suppressing Inspection

You can suppress this inspection by placing the following comment marker before the code fragment where you no longer want messages from this inspection to appear:

//noinspection removal

More detailed instructions as well as other ways and options that you have can be found in the product documentation:

Inspection Details

By default bundled with:

IntelliJ IDEA 2025.2, Qodana for JVM 2025.2,

Last modified: 18 September 2025