1.类注释模板
IntelliJ IDE --> Preferences --> Editor --> File and Code Templates --> Includes --> File Header
/** * ClassName: ${NAME} <br/> * Description: <br/> * date: ${DATE} ${TIME}<br/> * @author ${USER}<br/> * @version * @since JDK 1.8 */
2 方法注释
IntelliJ IDE --> Preferences --> Setting --> 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
原文地址:https://www.cnblogs.com/chenglc/p/9275593.html
时间: 2024-11-06 07:22:54