Eclipse auto-completion and common shortcut keys

1. Eclipse auto-completion enhancement method

In Eclipse, from Window -> preferences ->  Java  -> Editor -> Content assist -> Auto-Activation, we can add the first subtitle we need to automatically prompt after the ".", such as "abc", you can put All uppercase and lowercase letters of the 26 letters are added

.abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_

Second, the commonly used shortcut keys

(1) Ctrl+Space 
Description: Content Assistant. Provide prompts for methods, variables, parameters, javadoc, etc., which 
should be used in many occasions. In short, you can press this shortcut key when you need prompts. 
Note: Avoid the input method switching settings conflict with this setting

(2) Ctrl+Shift+Space 
Description: Variable prompt

(3) Ctrl+/ 
Description: add/remove//comment, in eclipse2.0, remove the comment as Ctrl+\

(4) Ctrl+Shift+/ 
Description: add /* */ comment

(5) Ctrl+Shift+\ 
Description: remove /* */ comment

(6) Ctrl+Shift+F 
Description: Automatically format code

(7) Ctrl+1 
Description: Batch modify the variable names in the source code, and can also be used on the catch block.

(8) Ctrl+F6 
description: interface switching

(9) Ctrl+Shift+M 
Description: Find the required package

(10) Ctrl+Shift+O 
Description: Automatically import the required packages

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326400585&siteId=291194637