6.eclipse文檔注釋設(shè)置-如何在編寫(xiě)的代碼中顯示程序員的相關(guān)信息
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?文章目錄

視頻地址:視頻地址
????????????????1.文件(Files)注釋標(biāo)簽
????????????????2.類型(Types)注釋標(biāo)簽(類的注釋)
????????????????3.字段(Fields)注釋標(biāo)簽
????????????????4.構(gòu)造函數(shù)(Constructor)標(biāo)簽
????????????????5.方法(Methods)標(biāo)簽
????????????????6.覆蓋方法(Overriding Methods)標(biāo)簽
????????????????7.代理方法(Delegate Methods)標(biāo)簽
????????????????8.getter方法標(biāo)簽
????????????????9.setter方法標(biāo)簽
1.設(shè)置注釋模板的入口:Window->Preference->Java->Code Style->Code Template 然后展開(kāi)Comments節(jié)點(diǎn)就是所有需設(shè)置注釋的元素。本文將每一個(gè)元素逐一給大家介紹一下。


.1.文件(Files)注釋標(biāo)簽
/**
@Title: ${file_name}
@Description:
@author Redamancy
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/
2.類型(Types)注釋標(biāo)簽(類的注釋)
/**
@ClassName: ${type_name}
@Description:
@author Redamancy
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}
*/
3.字段(Fields)注釋標(biāo)簽
/**
@Fields ${field}
@Description:
@author Redamancy
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')} */
4.構(gòu)造函數(shù)(Constructor)標(biāo)簽
/**
@Constructor: ${enclosing_type}
@Description: ${enclosing_type}構(gòu)造函數(shù)
@author Redamancy
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}/ */
5.方法(Methods)標(biāo)簽/*
@MethodName: ${enclosing_method}
@Description: ${todo}
@author Redamancy
@return ${return_type}
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}/
6.覆蓋方法(Overriding Methods)標(biāo)簽/*
@MethodName: ${enclosing_method}
@Description: ${todo}
@author Redamancy
${tags}
${see_to_overridden}
@date ${currentDate:date('yyyy-MM-dd hh:mm:ss')}/
?*/
大家快點(diǎn)去嘗試一下,促成自己的新成就吧