Eclipse Refactoring Menu
Using Eclipse Refactoring
In project development, we often need to change class names, but when other classes depend on this class, we have to spend a lot of time modifying the class names.
However, Eclipse's refactoring feature can automatically detect class dependencies and modify class names, saving us a lot of time.
You can open the refactoring menu through the following methods:
Right-click the Java element in the Package Explorer view and select the Refactor menu item.
Right-click the Java element in the Java editor and select the Refactor menu item.
Select the Java element in the Package Explorer view and press Shift + Alt + T.
In the image below, we have selected the HelloWorld class in the Java editor:
After selecting Rename, you will be prompted to enter the new class name and press Enter to finish the modification:
After pressing the Enter key upon completion, the class that will be modified will pop up:
You just need to click the Continue button to complete the operation.