特级做A爰片毛片免费69,永久免费AV无码不卡在线观看,国产精品无码av地址一,久久无码色综合中文字幕

java技術(外文文獻翻譯).doc

約20頁DOC格式手機打開展開

java技術(外文文獻翻譯),網絡編程歷史上的網絡編程都傾向于困難、復雜,而且極易出錯。程序員必須掌握與網絡有關的大量細節(jié),有時甚至要對硬件有深刻的認識。一般地,我們需要理解連網協(xié)議中不同的“層”(layer)。而且對于每個連網庫,一般都包含了數(shù)量眾多的函數(shù),分別涉及信息塊的連接、打包和拆包;這些塊的來回運輸;以及握手等等。這是一項令人痛苦的工作。...
編號:10-206278大小:69.00K
分類: 論文>外文翻譯

內容介紹

此文檔由會員 wanli1988go 發(fā)布

網絡編程
歷史上的網絡編程都傾向于困難、復雜,而且極易出錯。
程序員必須掌握與網絡有關的大量細節(jié),有時甚至要對硬件有深刻的認識。一般地,我們需要理解連網協(xié)議中不同的“層”(Layer)。而且對于每個連網庫,一般都包含了數(shù)量眾多的函數(shù),分別涉及信息塊的連接、打包和拆包;這些塊的來回運輸;以及握手等等。這是一項令人痛苦的工作。
Java最出色的一個地方就是它的“無痛苦連網”概念。有關連網的基層細節(jié)已被盡可能地提取出去,并隱藏在JVM以及Java的本機安裝系統(tǒng)里進行控制。我們使用的編程模型是一個文件的模型;事實上,網絡連接(一個“套接字”)已被封裝到系統(tǒng)對象里,所以可象對其他數(shù)據(jù)流那樣采用同樣的方法調用。除此以外,在我們處理另一個連網問題——同時控制多個網絡連接——的時候,Java內建的多線程機制也是十分方便的。
Network programming
Historically, programming across multiple machines has been error-prone, difficult, and complex.
The programmer had to know many details about the network and sometimes even the hardware. You usually needed to understand the various “l(fā)ayers” of the networking protocol, and there were a lot of different functions in each different networking library concerned with connecting, packing, and unpacking blocks of information; shipping those blocks back and forth; and handshaking. It was a daunting task.
One of Java’s great strengths is painless networking. The Java network library designers have made it quite similar to reading and writing files, except that the “file” exists on a remote machine and the remote machine can decide exactly what it wants to do about the information you’re requesting or sending. As much as possible, the underlying details of networking have been abstracted away and taken care of within the JVM and local machine installation of Java. The programming model you use is that of a file; in fact, you actually wrap the network connection (a “socket”) with stream objects, so you end up using the same method calls as you do with all other streams. In addition, Java’s built-in multithreading is exceptionally handy when dealing with another networking issue: handling multiple connections at once.