avatar

Eclipse中添加注释模板

一名菜鸟学习编程技术,记录所学知识并分享给大家,希望大家多多支持

Eclipse中添加注释模板

在写代码的时候会对相关文件进行说明和描述,因此在代码中添加注释模板是必要的。下面是我整理的注释模板,欢迎使用!
在这里插入图片描述

步骤

1、选中Eclipse的Windows——>Preferences——>Java——>Code Style——>Code Template——>Comments
选中Edit进行编辑
在这里插入图片描述

Files

/**  
* @Title: ${file_name}
* @Description: TODO(描述)
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/

Types

/**  
* @ClassName: ${type_name}
* @Description: TODO(描述)
* ${tags}
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/

Fields

/**  
* @Fields ${field} : TODO(描述)
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/

Constructors

/**  
* @Title: ${enclosing_type}
* @Description: ${enclosing_type}构造函数
* ${tags}
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/

Methods

/**  
* @Title: ${enclosing_method}
* @Description: TODO(描述)
* ${tags}
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/

Overriding methods

/**  
* @Title: ${enclosing_method}
* @Description: TODO(描述)
* ${tags}
* ${see_to_overridden}
* @author OriginalCoder
* @date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/
文章作者: Davion
文章链接: https://originalcoder.gitee.io/2020-0920-Eclipse/
版权声明: 本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 菜鸟站站
打赏
  • 微信
    微信
  • 支付宝
    支付宝