Community
Participate
Working Groups
I am using a translator, if something is not clear, ask. I would like to ask the developers to improve the auto-complete feature in Eclipse Java SE. For example, dial the code: e.getSource().toString(); , the cursor is positioned between the "e." and ".getSource().toString();" and at this moment call autocompletion dropdown list. Chose from his example, "getID()". As a result, today it would turn "e.getID()getSource().toString();". And i suggest that there is an automatic removal of the last part up to the point or to the end of the expression, and so we would have: e.getID().toString();. Still, you can immediately check whether the toString() method of the inserted item and if it is not, it can be removed before the end of the expression (it would turn out e.getID();). If we would not have inserted between "e.getSource ()." and "toString ();", but now it would be e.getSource().getID()toString ();, but as I suggest: e.getSource().getID();. It lacks this feature! Or so at least it was possible to include such a mode in the settings. It would be very convenient!
"e.getSource().toString();" can be converted to "e.getId().toString();" in the following way: Place the caret between "e." and "getSource().toString();" and invoke the content assist to select getId(). While the proposal is selected in the popup, press "Ctrl" and then "Enter" to overwrite "getSource()". To change the default behavior, see: Preferences > Java > Editor > Content Assist > Insertion > Completion Inserts / Completion overwrites. The information required to check the other part i.e. whether the toString() method is applicable to the inserted item is not available at the time of text replacement.
> To change the default behavior, see: Preferences> Java> Editor> Content Assist> Insertion> Completion Inserts / Completion overwrites. Well, that's what I need! I have not yet fully translated into my language settings in eclipse and perhaps I thought it some other settings. Thank you very much for your help! > The information required to check the other part i.e. whether the toString () method is applicable to the inserted item is not available at the time of text replacement. It is a pity that it can not be done, it would be more convenient.