Mark
Mark

Reputation: 18777

eclipse, how to change method call without the addition of new brackets?

Is it posible, with eclipse, to change the called method name using of auto completion (ctrl + space) but without creating a new brackets. Otherwise I have double brackets:

person.hello()();

and must manually delete new brackets.

~thx

Upvotes: 1

Views: 546

Answers (2)

FrVaBe
FrVaBe

Reputation: 49341

You can change the preference

Java -> Editor -> Content Assist -> Insert

form "Completion inserts" to "Completion overwrites". You can also toggle the settings while the content assist is active - thus if you do not want to change the global setting just hold down the Ctrl key while pressing enter on the new method on the provided method list which you opened with Ctrl-Space.

Upvotes: 3

Matt K
Matt K

Reputation: 6709

Double-click on the method name, hit Ctrl+F, fill in "Replace with" field with new method name, hit "Replace/Find" to do it one by one or "Replace All".

Upvotes: -1

Related Questions