IntelliJ IDEA 2022.1 Help

Convert to Instance Method dialog

Refactor | Convert to Instance Method

Item

Description

Select an instance parameter

Select the class you want the method to belong to after the conversion. All the usages of this class inside the method are replaced with this.

Visibility

In this area you can change the visibility scope of the converted method. By default the converted method will have no scope declaration (equivalent to public).

Last modified: 10 August 2022