eclipse custom annotation templates

eclipse custom annotation templates

Note to Editors template method: Window-> preference-> Java-> Code Style-> Code Template  and then expand the Comments node is all set to be annotated element friends. Now on each element introduced one by one:

1. files (Files) comment tags:

Copy the code

/ **   
 * All Rights Reserved, the Designed By www.tydic.com 
 * @Title: $ {file_name}    
 * {$ @package package_name}    
 * @Description: TODO} {$ (sentence describing what the document do)    
 * @ author: XXX      
 * @date: $ $ {DATE}} {Time    
 * @version V1.0 
 * @Copyright:. $ {year} www.tydic.com Inc. All Rights Reserved 
 * Note: being limited to the present XXXX IT Ltd. circulated internally to prohibit leaks and for other commercial purposes 
 * /  

Copy the code

 

2. types (Types) comment tag (comment class):

Copy the code

/ **    
 * @ClassName: TYPE_NAME $ {}    
 * @Description: TODO} {$ (described herein sentence action of this class)    
 * @author: XXX 
 * @date: $ $ {DATE}} {Time    
 *    
 * $ Tags} {   
 * @Copyright:. $ {year} www.tydic.com Inc. All Rights Reserved 
 * Note: this content is limited to internal circulation XXX Information Technology Co., prohibit leaks and for other commercial purposes 
 * /  

Copy the code

3. Fields (Fields) comment tags:

/ **    
 * @Fields Field} {$: $ {TODO} (what is described in this variable represents the sentence)    
 * /   

4. Tags Constructor:

Copy the code

/ **    
 * @Title: enclosing_type $ {}    
 * @Description: TODO} {$ (this method described herein sentence role)    
 * @param: Tags} {$   
 * @throws    
 * /  

Copy the code

The method (Methods) Tags:

Copy the code

/ **    
 * @Title: enclosing_method $ {}    
 * @Description: TODO} {$ (sentence herein described effect of this method)    
 * @param: Tags $ {}       
 * @return: return_type $ {}       
 * @throws    
 * /  

Copy the code

6. A method of covering (Overriding Methods) Tags:

Copy the code

/**   
 * <p>Title: ${enclosing_method}</p>   
 * <p>Description: </p>   
 * ${tags}   
 * ${see_to_overridden}   
 */  

Copy the code

7. The method of representatives (Delegate Methods) Tags:

/**  
 * ${tags}  
 * ${see_to_target}  
 */  

8.getter method Tags:

/**  
 * @Title:  ${enclosing_method} <BR>  
 * @Description: please write your description <BR>  
 * @return: ${field_type} <BR>  
 */  

9.setter method Tags:

/**  
 * @Title:  ${enclosing_method} <BR>  
 * @Description: please write your description <BR>  
 * @return: ${field_type} <BR>  
 */  

Guess you like

Origin www.cnblogs.com/guanghuiqq/p/11422151.html