2023年全國碩士研究生考試考研英語一試題真題(含答案詳解+作文范文)_第1頁
已閱讀1頁,還剩11頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

1、- 1 -外文原文An Introduction to Java ProgrammingWhat Is Java?Java is an object-oriented programming language developed by Sun Microsystems, a company best known for its high-end Unix workstations. Modeled after C++, the Java

2、 language was designed to be small, simple, and portable across platforms and operating systems, both at the source and at the binary level (more about this later).Java is often mentioned in the same breath as HotJava, a

3、 World Wide Web browser from Sun like Netscape or Mosaic (see Figure 1.1). What makes HotJava different from most other browsers is that, in addition to all its basic Web features, it can also download and play applets

4、on the reader’s system. Applets appear in a Web page much in the same way as images do, but unlike images, applets are dynamic and interactive. Applets can be used to create animations, figures, or areas that can respond

5、 to input from the reader, games, or other interactive effects on the same Web pages among the text and graphics.Although HotJava was the first World Wide Web browser to be able to play Java applets, Java support is rapi

6、dly becoming available in other browsers. Netscape 2.0 provides support for Java applets, and other browser developers have also announced support for Java in forthcoming products.Java’s Past, Present, and FutureThe Java

7、 language was developed at Sun Microsystems in 1991 as part of a research project to develop software for consumer electronics devices—television sets, VCRs, toasters, and the other sorts of machines you can buy at any d

8、epartment store. Java’s goals at that time were to be small, fast, efficient, and easily portable to a wide range of hardware devices. It is those same goals that made Java an ideal language for distributing executable p

9、rograms via the World Wide Web, and also a general-purpose programming language for developing programs that are easily usable and portable across different platforms.The Java language was used in several projects within

10、 Sun, but did not get very much commercial attention until it was paired with HotJava. HotJava was written in 1994 in a matter of months, both as a vehicle for downloading and running applets and also as an example of th

11、e sort of complex application that can be written in Java.At the time this book is being written, Sun has released the beta version of the Java - 3 -Platform independence is one of the most significant advantages that Ja

12、va has over other programming languages, particularly for systems that need to work on many different platforms. Java is platform-independent at both the source and the binary level.NEW TERM: Platform-independence is a p

13、rogram’s capability of moving easily from one computer system to another.At the source level, Java’s primitive data types have consistent sizes across all development platforms. Java’s foundation class libraries make it

14、easy to write code that can be moved from platform to platform without the need to rewrite it to work with that platform.Platform-independence doesn’t stop at the source level, however. Java binary files are also platfor

15、m-independent and can run on multiple problems without the need to recompile the source. How does this work? Java binary files are actually in a form called bytecodes.NEW TERM: Bytecodes are a set of instructions that lo

16、oks a lot like some machine codes, but that is not specific to any one processor.Normally, when you compile a program written in C or in most other languages, the compiler translates your program into machine codes or pr

17、ocessor instructions. Those instructions are specific to the processor your computer is running—so, for example, if you compile your code on a Pentium system, the resulting program will run only on other Pentium systems.

18、 If you want to use the same program on another system, you have to go back to your original source, get a compiler for that system, and recompile your code. Figure 1.2 shows the result of this system: multiple executabl

19、e programs for multiple systems.Things are different when you write code in Java. The Java development environment has two parts: a Java compiler and a Java interpreter. The Java compiler takes your Java program and inst

20、ead of generating machine codes from your source files, it generates bytecodes.Java Is Object-OrientedTo some, object-oriented programming (OOP) technique is merely a way of organizing programs, and it can be accomplishe

21、d using any language. Working with a real object-oriented language and programming environment, however, enables you to take full advantage of object-oriented methodology and its capabilities of creating flexible, modula

22、r programs and reusing code.Many of Java’s object-oriented concepts are inherited from C++, the language on which it is based, but it borrows many concepts from other object-oriented languages as well. Like most object-o

23、riented programming languages, Java includes a set of class libraries that provide basic data types, system input and output capabilities, and other utility functions. These basic classes are part of the Java development

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 眾賞文庫僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論