Quickly add your own custom methods in IDEA

1,File-Settings-Editor-Live Templaters 

2, click the +, a new group (the group may be in another) named java

3, select java, click the + sign, the new rules

As shown in FIG contents, main was shortcuts

Wherein S T A R & lt T cursor position after the start of shortcuts

4, the last step, the template used in java: main- Right -change context 

 

Enter the main, click IDEA pop-up prompt, full main method will complement, empathy can set up multiple shortcuts.

And the other setting method is similar to reference this method to set their own needs.

Guess you like

Origin www.cnblogs.com/shishaohui/p/11928403.html