Java虚拟机规范(Java SE 7 中文版)

4星(超过85%的资源)
所需积分/C币:2 2014-03-17 16:19:13 2.97MB PDF
1
收藏 收藏
举报

Java虚拟机规范(Java SE 7 中文版)
Java虚拟机规范—译者序 最后,请允许我再介绍一下本书三位译者的技术背景与分工 彐周志明(ww.icyfenix.com&weibo.com/icyfenix):远光软件平台开发部部门经理, 平台架构师,不愿意脱离编码的一线码农。著有《深入理解Java虚拟机:JM髙级特性与最 佳实践》。关注各种Jaτa应用,略懂osGi、Java虚拟机和上作流。在本书翻译⊥作中负责 全文统稿;前言和第1、2、6、7章的翻译;第3、4、5章的校审⊥作。 」吴璞渊( wuyuan, steve,ccm):就臥」西门子,偏向程序和工作流设汁,喜好Java各 种新技术并倒腾。在本书翻详工作中负责第3章以及第4章的1至7节 口冶秀刚( langyu. iteye,com):思科半台工程师,从事分布式系统的研究与开发,爱好Jaⅴa 平台技术且正在努力成长中。在本书翻译工作中负责第5章及第4章的9至11节。 周志明 年11月2日 第3页/共387页 Java虚拟机规范一版权声明 版权声明 1.本翻译工作完全基于个人兴趣爱好以及学术研究目的,不涉及出版或任何其他商业行为。本次 翻译与 Oracle或其他Java虚拟机厂商无关,译文是非官方的翻译 2.译者曾经尝试邮件联系过原文作者,但是一直未获得到回复。根据我国著作权法第22条规定 以教学、科研为目的,可以不经著作权人许可翻译其已经发表的作品,不向其攴付报酬,但应 当指明作者姓名、作品名称,且不得出版发行。因此本译文的传播,必须严格控制在学习与科 学研究沱围内,任何人木经原文作者和译者同意,不得将译文的全部或部分用于版或其他商 业行为。 3.在符合第2条的前提下,任何人都可任意方式传播、使用本译文的部分或全部内容,无须预 先知会译者,只要侏留作、译者联系信息即可。如果需要进行商业使用,则必须到原作者和译 者的授权。 附原文版权声明如下 Specification: JSR 000924 JavaTM Virtual Machine Specification (Specification) Version: 7 Status: Final release Release: July 2011 Copyright 2011 Oraclc America, Inc. and/or its affiliates. All rights reserved 500 Oracle Parkway M/s 5op7, California 94065, U.S.A LIMITED LICENSE GRANTS 1. License for Evaluation Purposes. Oracle hereby grants you a fully-paid, non exclusive, non- transferable, worldwi de, limited license (without the right to sublicense), under Oracle's applicable intellectual property rights to view, download, use and reproduce the Specification only for the purpose of internal evaluation. This includes (i) developing applications intended to run on an implementation of'the Specification, provided that such applications do not themselves implement any portion (s) of the Specification, and (ii) discussing the Specification with any third party; and (iii) excerpting brief port ions of the Specification in oral or written communications which discuss the Specification provided that such excerpts do not in the aggregate constitute significant portion of the Specification 2. License for the Distribution of Compliant Implementations. Oracle also grants you a perpetual, non-exclusive, non-transferable, worldwide, fully paid-up, royalty free, 第4页/共387页 Java虚拟机规范一版权声明 limited license (without the right to sublicense)under any applicable copyrights or subject to the provisions of subsection 4 below, patent rights it may have covering the Specification to create and/ or distribute an Independent Implementation of the Specification that: (a) fully implements the Specification including all its rcquired interfaces and functionality; (b)does not modify, subset, superset or otherwise extend the Licensor Name Space, or include any public or protected packages, classes, Java interfaces, fields or methods within the licensor Name Space other than those required/ authorized by the Specification or Specifications being implemented; and (c) passes the Technology Compatibility kit (including satisfying the requircments of the applicable TCK Users Guide) for such Specification ("Compliant Implementation).I addition, the foregoing license is expressly conditioned on your not acting outside its scope. No license is granted hereunder for any other purpose (including, for example modifying the Specification, other than to the extent of your fair use rights, or distributing the Specification to third parties). Also, no right, title, or interest in or to any trademarks, service marks, or trade names of Oracle or Oracle s licensors is granted hereunder. Java, and Java-related logos, marks and names are trademarks or registered trademarks of Oracle in the U. s. and other countries. Pass-through Conditions. You nced not include limitations (a)-(c) from the previous paragraph or any other particular pass through requirements in any license You grant concerning the use of your Independent Implementation or products derived from it. However except with respect to independent Implementations (and products derived from them)that othery wise pass through to your licensees any licenses under Oracle s applicable or satisfy limitations (a)-(c) from the previous paragraph, You may neither:(a)grant or intellectual property rights; nor (b) authorize your licensees to make any claims concerning their implementation s compliance with the Specification in question 4. Reciprocity concerning patent Licenses With respect to any patent claims covered by the license granted under subparagraph 2 above that would be fringed by all technically feasible implementations of the Specification, such license is conditioned upon your offering on fair, reasonable and non-discriminatory terms, to any party seeking it from You, a perpetual, non-exclusive, non transferable, worldwide license under Your patent rights which are or would be infringed by all technically feasible implementations of the Specification to develop distribute and use a compliant Implementation. b With respect to any patent claims owned by Oracle and covered by the license granted under subparagraph 2, whether or not their infringement can be avoided in a technically feasible manner when implementing the Specification, such license shall terminate with respect to such claims if You initiate a claim against Oracle that it has, in the course of performing its responsibilities as the Specification Lead, induced any other entity to infringe Your patent rights c Also with respect to any patent claims owned by oracle and covered by the license granted 第5页/共387页 Java虚拟机规范一版权声明 under subparagraph 2 above, where the infringement of such claims can be avoided in a technically feasible manner when implementing the Specification such license, with respect to such claims, shall terminate if You initiate a claim against Oracle that its making having made, using, offering to sell, selling or importing a Compliant Implementation infringes Your patent rights 5. Definitions. For the purposes of this agreement:Independent Implementation shall mean an implementation of the Specification that neither derives from any of Oracle s source code or binary code matcrials nor, cxcept with an appropriate and separate license from urac le includes any of Oracle s source code or binary code materials; Licensor Name Space shall mean the public class or interface declarations whose names begin with java,javax com. sun or their equivalents in any subsequent naming convention adopted by Oracle through the Java Community Process, or any recognized successors or replacements thereof and Technology Compatibility Kit or TCK shall mean the test suite and accompanying TCK USer s Guide provided by Oracle which corresponds to the Specification and that was available either (i) from Oracle 120 days before the first release of Your Independent Implementation that allows its use for commercial purposes, or (ii) more recently than 120 days from such release but against which You clect to test your implementation of the Specification This agreement will terminate immediately wi thout notice from Oracle if you breach the Agreement or act outside the scope of the licenses granted above DISCLAIMER OF WARRANTIES THE SPECIFICATION IS PROVIDED AS IS ORACLE MAKES NO REPRESENTATIONS OR WARRANTIES EITHER EXPRESS OR IMPLIED, INCLLDING BUT NOT LIMITED TO. WARRANTIES OF MERCHANTABILITY FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT (INCLUDING AS A CONSEQUENCE OF ANY PRACTICE OR IMPLEMENTATION OF THE SPECIFICATION, OR THAT THE CONTENTS OF THE SPECIFICATION ARE SUITABLE FOR ANY PURPOSE. This document does not represent any commi tment. to release or implement any portion of the Specification in any product. In addition, the Specification could include technical inaccuracies or typographical crrors LIMITATION OF LIABILITY TO THE EXTENT NOT PROHIBITED BY LAW IN NO EVENT WILL ORACLE OR ITS LICENSORS BE LIABLE FOR ANY DAMAGES. INCLUDING WITHOUT LLMITATION. LOST REVENUE. PROF ITS OR DATA, OR FOR SPECIAL, INDIRECT, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER CALSED AND REGARDLESS OF TIIE TIIEORY OF LIABILITY ARISING OUT OF OR RELATED IN ANY WAY TO YOUR IIAVING IMPLEMENTING OR OTHERWISE USING THE SPECIFICATION, EVEN IF ORACLE AND/OR ITS LICENSORS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES You will indemnify, hold harmless, and defend Oracle and its licensors from any claims arising or resulting from:(i) your use of the Specification;(ii) the use or distribution of your Java application, applet and or implementation; and/ or (iii) any claims that later versions or releases of any Specification furnished to you are incompatible with the 第6页/共387页 Java虚拟机规范一版权声明 Specification provided to you under this license RESTRICTED RIGHTS LEGEND U.S. Govcrnment: If this Specification is being acquired by or on behalf of the U.S. Government or by a U. S. Government prime contractor or subcontractor (at any tier),then the Government s rights in the Software and accompanying documentation shall be only as set forth in this license this is in accordance with 48 C F.R. 227. 7201 through 227. 7202-4 (for Depar tment of Defense(DoD) acquisitions)and with 48 C F.R. 2.101 and 12. 212(for non- DoD acquisitions REPORT you prov ide Oracle with any comments or suggestions concerning the Specification Fccdback"), you hereby: (i) agree that such Fccdback is provided on a non-proprictary and non confidential basis, and (ii) grant Oracle a perpetual, non exclusive, worldwide fully paid-up, irrevocable license, with the right to sublicense through multiple levels of sublicensees, to incorporate, disclose, and use without limi tation the feedback for anv purpose GENERAL TERMS Any action related to this agreement will be governed by California law and controlling U.S. federal law. The u. convent ion for the internationa sale of goods and the choice of law rules of any jurisdiction will not apply. The Specification is subject to U. s. export control laws and may be subject to export or import regulations in other countries. Licensee agrees to comply strictly with all such laws and regulations and acknowledges that it has the responsibility to obtain such licenses to export, re-export or import as may be required after delivery to Licensee. This agrecment is the parties' entire agrecment relating to its subject matter. It supersedes all prior or contemporaneous oral or written communications, proposals, conditions, representations and warranties and prevails over any conflicting or additional terms of any quote, order, acknowledgment, or other communication between the parties relating to its sub ject matter during the term of this Agrecment. No modification to this agreement will be binding, unless in writing and signed by an authorized representative of each part 第7页/共387页 Java虚拟机规范一日录 目录 译者序 版权声明 4 目录 中···申 ··· ···· 8 前言. 1 第二版说明 ·········.················ 春 15 Java se7版说明 15 第1章引言 18 1.1简史. 1.2Java虚拟机 · 1 1.3各章节提要....... 19 1.4说明 20 第2章Java虚拟机结构 .。,.,,,21 2.1C1ass文件格式. 21 2.2数据类型 2.3原始类型与值 ,,,22 2.3.1整型类型与整型值 23 2.3.2浮点类型、取值集合及浮点值 2.3.3 returnaddress类型和值 6 2.3.4 boolean类型.... 2.4引用类型与值... 2.5运行时数据区 2.5.1PC寄存器 28 2.5.2Java虚拟机栈 28 .5.3Java堆 29 2.5.4方法区 29 第8页/共387页 Java虚拟机规范一日录 2.5.5运行时常量池. 2.5.6本地方法栈 2.6栈帧 2.6.1局部变量表 ···· 32 2.6.2操作数栈 2.6.3动态链接 。,,,,,,,,,,34 2.6.4方法正常调用完成 34 2.6.5方法异常调用完成 2.7对象的表示 2.8浮点算法 35 2.8.1Java虚拟机和IEEE754中的浮点算法 2.8.2浮点模式 ·非· ·· 36 2.8.3数值集合转换 ·· ··· 2.9初始化方法的特殊命名 2.10异常 .,38 2.11字节码指令集简介. 2.11.1数据类型与Java虚拟机 2.11.2加载和存储指令 4∠ 2.11.3运算指令 45 2.11.4类犁转换指令,... 2.11.5对象创建与操作... 。,,,,,47 2.11.6操作数栈管理指令 48 2.11.7控制转移指令 .,,,,,.,.,.,48 2.11.8方法调用和返回指令. ...49 2.11.9抛出异常 4 2.11.10同步 49 2.12类库 2.13公有设计,私有实现.. 第3章为JAVA虚拟机编译. ,53 第9页/共387页 Java虚拟机规范一日录 3.1示例的格式说明 3.2常量、局部变量的使用和控制结构 算术运算 3.4访问运行时常量池 ········ ···· 3.5更多的控制结构示例. 61 3.6接收参数 。,,,,,,,,,,64 3.7方法调用 64 3.8使用类实例 3.9数组 69 3.10编译③ witch语句.... 3.11使用操作数栈.. 3.12抛出异常和处理异常..............7∠ 3.13编译fina11y语句块 ··· 3.14同步 ,非 31 3.15注解 第4章c1ass文件格式 ,,,,,,,,84 A.1C1assi1e结构 ,85 4.2各种内部表示名称. 90 4.2.1类和接口的二进制名称. 90 4.2.2非全限定名 4.3描述符和签名 4.3.1语法符号 4.3.2字段描述符 92 4.3.3方法描述符 .93 4.3.4签名 94 4.4常量池 4.4.1 consTanT Class info结构 ,.,,98 4.1.2 CONSTANT Fieldref info, CONSTANT Methodref info NH ONSTANT IntcrfaccMethodref info结构 第10页/共387页

...展开详情
试读 127P Java虚拟机规范(Java SE 7 中文版)
立即下载 身份认证后 购VIP低至7折
一个资源只可评论一次,评论内容不能少于5个字
regenadaster 挺不错的资料
2014-08-20
回复
您会向同学/朋友/同事推荐我们的CSDN下载吗?
谢谢参与!您的真实评价是我们改进的动力~
关注 私信
上传资源赚钱or赚积分
最新推荐
Java虚拟机规范(Java SE 7 中文版) 2积分/C币 立即下载
1/127
Java虚拟机规范(Java SE 7 中文版)第1页
Java虚拟机规范(Java SE 7 中文版)第2页
Java虚拟机规范(Java SE 7 中文版)第3页
Java虚拟机规范(Java SE 7 中文版)第4页
Java虚拟机规范(Java SE 7 中文版)第5页
Java虚拟机规范(Java SE 7 中文版)第6页
Java虚拟机规范(Java SE 7 中文版)第7页
Java虚拟机规范(Java SE 7 中文版)第8页
Java虚拟机规范(Java SE 7 中文版)第9页
Java虚拟机规范(Java SE 7 中文版)第10页
Java虚拟机规范(Java SE 7 中文版)第11页
Java虚拟机规范(Java SE 7 中文版)第12页
Java虚拟机规范(Java SE 7 中文版)第13页
Java虚拟机规范(Java SE 7 中文版)第14页
Java虚拟机规范(Java SE 7 中文版)第15页
Java虚拟机规范(Java SE 7 中文版)第16页
Java虚拟机规范(Java SE 7 中文版)第17页
Java虚拟机规范(Java SE 7 中文版)第18页
Java虚拟机规范(Java SE 7 中文版)第19页
Java虚拟机规范(Java SE 7 中文版)第20页

试读结束, 可继续阅读

2积分/C币 立即下载