Reputation: 10058
I'm currently using NetBeans and want to rename all occurrence of a instance variable inside a method so that it will become a distinct local variable in its own right. I know how to refactor a variable using refactor -> rename, but I don't know how to limit the scope of change to a method.
Upvotes: 0
Views: 379
Reputation: 787
You can declare a local variable at the start of the method, then use the rename refactoring on it. Once done you can remove the local variable.
Upvotes: 1