Detailed explanation of Eclipse Java annotation template settings and copyright notice

How to edit the comment template: Window->Preference->Java->Code Style->Code Template and expand Comments

1. File (Files) comment label:

/**  
 * All rights Reserved, Designed By www.ts.com
 * @Title:${file_name}   
 * @Package${package_name}   
 * @Description:${todo} (describe what the file does in one sentence)   
 * @author:yh     
 * @date:${date} ${time}   
 * @version V1.0
 * @Copyright:${year} www.ts.com Inc. All rights reserved.
 * Note: This content is only for internal circulation, and it is forbidden to leak and use for other commercial purposes
 */

2. Types annotation tags (class annotations):

/**   
 * @ClassName:${type_name}   
 * @Description:${todo} (here describes the role of this class in one sentence)   
 * @author:yh
 * @date:${date} ${time}  
 * ${tags}  
 * @Copyright:${year} www.ts.com Inc. All rights reserved.
 * Note: This content is only for internal circulation within the company, and it is forbidden to leak it and use it for other commercial purposes.
 */

3. Fields annotation label:

/**   
 * @Fields ${field}:${all}  
 */

4. Constructor label:

/**   
 * @Title:${enclosing_type}   
 * @Description: $ {all}   
 * @param:${tags}  
 * @throws   
 */

5. Methods (Methods) label:

/**   
 * @Title:${enclosing_method}   
 * @Description: $ {all}   
 * @param:${tags}      
 * @return:${return_type}      
 * @throws   
 */

6. Overriding Methods tab:

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

7. Delegate Methods label:

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

8. getter method label:

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

9.setter method label:

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

The rest are defaults.


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325626606&siteId=291194637