1.类注释模板
IntelliJ IDE --> Preferences --> Editor --> File and Code Templates --> Includes --> File Header
![](https://img2018.cnblogs.com/blog/1155586/201911/1155586-20191120151034966-251635199.png)
/** * ClassName: ${NAME} <br/> * Description: <br/> * date: ${DATE} ${TIME}<br/> * @author ${USER}<br/> * @version * @since JDK 1.8 */
2 方法注释
IntelliJ IDE --> Preferences --> Editor --> LiveTemplates
1) 点击右边的+号,选择Template Group点击 新建的Template Group eg:MyGroup
2) 选择MyGroup,再次点击右面的加号,选择第一个选项 live Template
注意:addrebiation :快捷键
3) 设置change 选中 java相关(否则快捷键无效)
/**
* Description: <br/>
* @author: $USER$<br/>
* @date: $DATE$ $TIME$<br/>
* @param:$param$<br/>
* @return:$return$
*/
变量定义
user --> user()
date-->date()
time-->time()
param-->methodParameters()
return-->methodReturnType()
https://www.cnblogs.com/MurasakiSeiFu/p/7891355.html