How to Perform Mass Variable Replacements in NetBeans IDE

How to do mass variable substitution in a specific class in NetBeans IDE?

For example, I have int myNumber = 2;, and I have int mySecondNumber = 4;.

If a myNumberlot of places are common in my class. I want to be able to replace all of them with mySecondNumber.

Thanks for the help in advance!

+4
source share
2 answers

You are looking for a process called refactoring.

http://wiki.netbeans.org/Refactoring

+5
source

Right-click on any mention myNumberand select "Refractor-> Rename" from the pop-up menu.

myNumber Ctrl-R.

+1

All Articles