請用此 Handle URI 來引用此文件:
http://tdr.lib.ntu.edu.tw/jspui/handle/123456789/33751
標題: | Java語言靜態泛型成員之機制 A Mechanism of Static Generic Type Members for the Java Programming Language |
作者: | Li-Wei Cheng 鄭力瑋 |
指導教授: | 陳俊良(Chuen-Liang Chen) |
關鍵字: | 泛型,一般化,特殊化,一般化及共享,爪哇編譯器, Generics,Generalization,Specialization,Specialization and sharing,Java Compiler, |
出版年 : | 2006 |
學位: | 碩士 |
摘要: | 經過多年的研究,一個將Java語言加入泛型機制的解法已經在Java 5.0上發佈了。為了兼顧新舊版本的相容性以及新舊程式碼的交互使用,Sun採用了擦拭法來達成泛型機制。擦拭法通常也被稱為一般化方法。然而,在擦拭法下帶來最大的問題為執行期間與泛型相關的型別資訊將會漏失。本論文中,將提出擦拭法帶來的另一個問題,這問題將導致無法使用泛型的靜態成員。最後,提出一個可行的解法並實現於Java 5.0編譯器之上。 Through the research for many years, a solution for the problem of extending Java with parametric polymorphism (genericity) has released in Java 5.0. In order to have the capability of backward compatibility and the capability of interoperability with legacy code, Sun adopts the method of type erasure to achieve Java with parametric polymorphism. The method is also called Generalization. Run-time type information will be lost because of type erasure and it’s the major problem of the solution. In the thesis, we show that Java 5.0 can’t declare static variable whose type is type parameter of class due to type erasure and propose a solution for this problem. |
URI: | http://tdr.lib.ntu.edu.tw/jspui/handle/123456789/33751 |
全文授權: | 有償授權 |
顯示於系所單位: | 資訊工程學系 |
文件中的檔案:
檔案 | 大小 | 格式 | |
---|---|---|---|
ntu-95-1.pdf 目前未授權公開取用 | 946.09 kB | Adobe PDF |
系統中的文件,除了特別指名其著作權條款之外,均受到著作權保護,並且保留所有的權利。