The Java Language Specification, 3/e (Paperback)
內容描述
Descriptions:
Written by the inventors of the technology, The Java™ Language Specification, Third Edition, is the definitive technical reference for the Java™ programming language. If you want to know the precise meaning of the language's constructs, this is the source for you.
The book provides complete, accurate, and detailed coverage of the Java programming language. It provides full coverage of all new features added since the previous edition, including generics, annotations, asserts, autoboxing, enums, for-each loops, variable arity methods, and static import clauses.
Table of Contents:
Preface.
Preface to the Second Edition.
Preface to the Third Edition.
- Introduction.
Example Programs.
Notation.
Relationship to Predefined Classes and Interfaces.
References. - Grammars.
Context-Free Grammars.
The Lexical Grammar.
The Syntactic Grammar.
Grammar Notation. - Lexical Structure.
Unicode.
Lexical Translations.
Unicode Escapes.
Line Terminators.
Input Elements and Tokens.
White Space.
Comments.
Identifiers.
Keywords.
Literals.
Separators.
Operators. - Types, Values, and Variables.
The Kinds of Types and Values.
Primitive Types and Values.
Reference Types and Values.
Type Variables.
Parameterized Types.
Type Erasure.
Reifable Types.
Raw Types.
Intersection Types.
Subtyping.
Where Types Are Used.
Variables. - Conversions and Promotions.
Kinds of Conversion.
Assignment Conversion.
Method Invocation Conversion.
String Conversion.
Casting Conversion.
Numeric Promotions. - Names.
Declarations.
Names and Identifiers.
Scope of a Declaration.
Members and Inheritance.
Determining the Meaning of a Name.
Access Control.
Fully Qualified Names and Canonical Names.
Naming Conventions. - Packages.
Package Members.
Host Support for Packages.
Compilation Units.
Package Declarations.
Import Declarations.
Top Level Type Declarations.
Unique Package Names. - Classes.
Class Declaration.
Class Members.
Field Declarations.
Method Declarations.
Member Type Declarations.
Instance Initializers.
Static Initializers.
Constructor Declarations.
Enums. - Interfaces.
Interface Declarations.
Interface Members.
Field (Constant) Declarations.
Abstract Method Declarations.
Member Type Declarations.
Annotation Types.
Annotations. - Arrays.
Array Types.
Array Variables.
Array Creation.
Array Access.
Arrays: A Simple Example.
Array Initializers.
Array Members.
Class Objects for Arrays.
An Array of Characters is Not a String.
Array Store Exception. - Exceptions.
The Causes of Exceptions.
Compile-Time Checking of Exceptions.
Handling of an Exception.
An Example of Exceptions.
The Exception Hierarchy. - Execution.
Virtual Machine Start-Up.
Loading of Classes and Interfaces.
Linking of Classes and Interfaces.
Initialization of Classes and Interfaces.
Creation of New Class Instances.
Finalization of Class Instances.
Unloading of Classes and Interfaces.
Program Exit. - Binary Compatibility.
The Form of a Binary.
What Binary Compatibility Is and Is Not.
Evolution of Packages.
Evolution of Classes.
Evolution of Interfaces. - Blocks and Statements.
Normal and Abrupt Completion of Statements.
Blocks.
Local Class Declarations.
Local Variable Declaration Statements.
Statements.
The Empty Statement.
Labeled Statements.
Expression Statements.
The if Statement.
The assert Statement.
The switch Statement.
The while Statement.
The do Statement.
The for Statement.
The break Statement.
The continue Statement.
The return Statement.
The throw Statement.
The synchronized Statement.
The try statement.
Unreachable Statements. - Expressions.
Evaluation, Denotation, and Result.
Variables as Values.
Type of an Expression.
FP-strict Expressions.
Expressions and Run-Time Checks.
Normal and Abrupt Completion of Evaluation.
Evaluation Order.
Primary Expressions.
Class Instance Creation Expressions.
Array Creation Expressions.
Field Access Expressions.
Method Invocation Expressions.
Array Access Expressions.
Postfix Expressions.
Unary Operators.
Cast Expressions.
Multiplicative Operators.
Additive Operators.
Shift Operators.
Relational Operators.
Equality Operators.
Bitwise and Logical Operators.
Conditional-And Operator &&.
Conditional-Or Operator ||.
Conditional Operator ? :.
Assignment Operators.
Expression.
Constant Expression. - Definite Assignment.
Definite Assignment and Expressions.
Definite Assignment and Statements.
Definite Assignment and Parameters.
Definite Assignment and Array Initializers.
Definite Assignment and Enum Constants.
Definite Assignment and Anonymous Classes.
Definite Assignment and Member Types.
Definite Assignment and Static Initializers.
Definite Assignment, Constructors, and Instance Initializers. - Threads and Locks.
Locks.
Notation in Examples.
Incorrectly Synchronized Programs Exhibit Surprising Behaviors.
Memory Model.
Final Field Semantics.
Word Tearing.
Non-atomic Treatment of double and long.
Wait Sets and Notification.
Sleep and Yield. - Syntax.
The Grammar of the Java Programming Language.
Index.
Credits.
Colophon.