1、自动添加
顾名思义就是在创建Class文件时候自动添加注释操作如下:
找到Window
找到Java------然后找到Code Style ------在找到Code Templates------最后找到Code目录下的New Java files
双击New Java flies
复制以下代码
/**
*@author 作者:杨鑫
*@version 创作时间:{date}{time}
*
*/
然后点击Apply and Close 就可以了。
示例

2、快捷键添加
同第一种方式找到Window目录下Preferences点击进去------找到Java------然后找到Code Style ------在找到Code Templates------然后不一样的是找Comments下的Types
复制代码
/**
* 作者:yangxin
* 时间:{date}{time}
* ${tags}
*/
然后点击Apply and Close 就可以了。
3、效果
