In this post:
- Show available Templates
- Short Solution
- sout - print string
- psvm - main method declaration
- Customizing syso as shortcut
Shortcut for templates:
System.out.println()
and
public static void main(String[] args) {
}
Show available Templates in Intellij
Press CTRL+J in order to open list of available templates for the context. So in class you have:
- psvm - main method declaration:
public static void main(String[] args) {
}
and in method:
- sout - print string
System.out.println();
You can also start writing and the to press CTRL+J in order to see what templates are available i.e.
so and CTRL+J produce:
Short Solution
System.out.println();
- CTRL+J
- sout
- TAB
public static void main(String[] args) {
}
- CTRL+J
- psvm
- TAB
Note customizing syso as shortcut
- open Settings
- Live Templates
- abbreviation - syso
- template - System.out.println($END$);