Rename Method

http://www.refactoring.com/catalog/renameMethod.html


I'm a new Smalltalk user (ex-C++, et al.). In DolphinSmalltalk, the way you rename a method is you click its name in the browser, press F2, then enter the new name.

That's it.

In IntellijIdea for Java you click on the method name in the editor, press Shift-F6, enter the new name, and if all the reported usages are okay you commit it with Alt-D. This UI is the same for renaming methods, fields, classes, packages, variables, and method parameters. Another very useful refactoring is ChangeMethodSignature?, which is a suped-up version of RenameMethod that allows you to change method visibility (private, public, etc.), add or remove parameters from the parameter list, reorder the parameters and also change their types.


EditText of this page (last edited November 26, 2014) or FindPage with title or text search