intellj idea 如何设置类头注释和方法注释
打开 IDEA 的 Settings
,点击 Editor-->File and Code Templates
模板
/**
* @author hjh
* @date ${YEAR}年${MONTH}月${DAY}日 ${TIME}
*/
或者
/**
* @description
* @author: hjh
* @create: ${YEAR}-${MONTH}-${DAY} ${HOUR}:${MINUTE}
**/
自己做点补充:
Live Tempplate 方法注释
Ctrl +Shift + A 搜索Live Templates 回车 (或者在 Settings 中点击 Editor-->Live Templates)
解释 : 类里面 输入 ps , 在自动弹出 的窗口上找到 之前做的标识“ public String ” 回车
自动补全 : public String (鼠标停留位置1) = (鼠标停留位置2) ;
(当鼠标标停留1 编辑完了 —— 回车 ——》 到达 鼠标标停留2)
- 另推荐一个视频 让你真正会使用idea