<!-- /* Font Definitions */ @font-face {font-family:Wingdings; panose-1:5 0 0 0 0 0 0 0 0 0; mso-font-charset:2; mso-generic-font-family:auto; mso-font-pitch:variable; mso-font-signature:0 268435456 0 0 -2147483648 0;} @font-face {font-family:新細明體; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-alt:PMingLiU; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} @font-face {font-family:"/@新細明體"; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:none; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:新細明體; mso-font-kerning:1.0pt;} h1 {mso-style-next:內文; margin-top:9.0pt; margin-right:0cm; margin-bottom:9.0pt; margin-left:0cm; line-height:300%; mso-pagination:none; page-break-after:avoid; mso-outline-level:1; font-size:26.0pt; font-family:Arial; mso-bidi-font-family:"Times New Roman"; mso-font-kerning:26.0pt;} /* Page Definitions */ @page {mso-page-border-surround-header:no; mso-page-border-surround-footer:no;} @page Section1 {size:612.0pt 792.0pt; margin:72.0pt 90.0pt 72.0pt 90.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.Section1 {page:Section1;} /* List Definitions */ @list l0 {mso-list-id:2003849803; mso-list-type:hybrid; mso-list-template-ids:-1461551198 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;} @list l0:level1 {mso-level-number-format:bullet; mso-level-text:; mso-level-tab-stop:24.0pt; mso-level-number-position:left; margin-left:24.0pt; text-indent:-24.0pt; font-family:Wingdings;} ol {margin-bottom:0cm;} ul {margin-bottom:0cm;} -->
第二章 一切都是對象
- 包名為什麼要大寫?
和OS有關,在Unix系統下A和a分別代表兩個目錄(同一根路徑下),而在windows 下是一個目錄。
- 執行new來創建對象時,數據存儲空間才被分配,其方法才供外界調用。
- Static修飾的變量和方法,被稱為類數據和類方法,代表那些數據和方法只是作為整個類,而不是類的某個特定對象而存在的。
- 所有的javadoc命令都只能在“/**”註釋中出現,註釋結束於“*/”。
javadoc只能為public和protected成員進行文檔註釋。Privatet和包內可訪問成員的註釋會被忽略。
在java SE5中,javadoc標籤@deprecated標籤已經被@Deprecated註解所替代。
注:warning - Tag @version cannot be used in method documentation. It can only be used in the following types of documentation: overview, package, class/interface.
warning - Tag @author cannot be used in method documentation. It can only be used in the following types of documentation: overview, package, class/interface.
/**
* {@link com.vs.ut.test.TestHasCode#hello 顯示的鏈接名稱}
*/
<!-- /* Font Definitions */ @font-face {font-family:新細明體; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-alt:PMingLiU; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} @font-face {font-family:"/@新細明體"; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:none; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:新細明體; mso-font-kerning:1.0pt;} /* Page Definitions */ @page {mso-page-border-surround-header:no; mso-page-border-surround-footer:no;} @page Section1 {size:612.0pt 792.0pt; margin:72.0pt 90.0pt 72.0pt 90.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.Section1 {page:Section1;} --> 鏈接到hello方法
/**
* {@link com.vs.ut.test.TestHasCode 顯示的鏈接名稱}
*/
<!-- /* Font Definitions */ @font-face {font-family:新細明體; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-alt:PMingLiU; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} @font-face {font-family:"/@新細明體"; panose-1:2 2 3 0 0 0 0 0 0 0; mso-font-charset:136; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:3 137232384 22 0 1048577 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:none; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:新細明體; mso-font-kerning:1.0pt;} /* Page Definitions */ @page {mso-page-border-surround-header:no; mso-page-border-surround-footer:no;} @page Section1 {size:612.0pt 792.0pt; margin:72.0pt 90.0pt 72.0pt 90.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.Section1 {page:Section1;} -->
鏈接到TestHasCode類