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

Eclipse中添加注释模板_构造函数

 

步骤

1、选中Eclipse的Windows——>Preferences——>Java——>Code Style——>Code Template——>Comments

选中Edit进行编辑

 

 

 

 Eclipse中添加注释模板_注释模板_02

 

 

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')}
*/


  

 


有任何需要沟通交流的联系QQ群:276483863 加好友备注【博客园技术交流】