- 1、本文档共63页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
The Java Language:
A White Paper Overview
Harry H. Porter III
Portland State University
May 5, 2002
harry@
Table of Contents
Abstract 4
Introduction 4
Charater Set 4
Comments 5
Identifiers 5
Reserved Words (Keywords) 6
Primitive Data Types 6
Boolean 7
Integers 8
Floating-Point 8
Numerical Operations 9
Character and String Literals 9
Implicit Type Conversion and Explicit Casting 10
Pointers are Strongly-Typed 12
Assignment and Equality Operators 14
Instanceof 15
Pointers in Java (References) 15
Operator Syntax 16
Expressions as Statements 18
Flow of Control Statements 19
Arrays 21
Strings 23
Classes 25
Object Creation 27
Interfaces 28
Declarations 30
Types: Basic Types, Classes, and Interfaces 32
More on Interfaces 33
Garbage Collection 34
Object Deletion and Finalize 35
Accessing Fields 35
Subclasses 36
Access Control / Member Visibility 37
Sending Messages 40
Arguments are Passed by Value 42
“this” and “super” 43
Invoking Static Methods 44
Method Overloading 45
Method Overriding 46
Overriding Fields in Subclasses 47
Final Methods and Final Classes 48
Anonymous Classes 49
The “main” Method 50
Methods in Class “Object” 51
Variables of Type Object 52
Casting Object References 52
The “null” Pointer 53
“Static Final” Constants 53
Abstract Methods and Classes 54
Throwing Exceptions 56
Contracts and Exceptions 62
Initialization Blocks 65
Static initialization blocks 66
Wrapper Classes 67
Packages 68
Threads 70
Locking Objects and Classes 71
Strict Floating-Point Evaluations 73
Online Web Resources 73
Please email any corrections to the author at: 74
Abstract
This document provides a quick, yet fairly complete overview of the Java language. It does not discuss the principles behind object-oriented programming or how to create good Java programs; instead it focuses only on describing the language.
Introduction
Java is a programming language developed by Sun Microsystems. It is spreading quickly due to a number of good decisions in its design. Java grew out of several la
您可能关注的文档
最近下载
- GB7231-2016《工业管道的基本识别色、识别符号和安全标识》 GB 7231-2003文档撰写.pptx VIP
- 八年级下册道德与法治教材课后习题参考答案(修改版).pdf VIP
- 化工公司综合应急预案.pdf
- 《中医诊断学》——四诊(课堂PPT).ppt
- 《企业架构分析》课件.ppt VIP
- TIA-604-18-2015 国外国际标准.pdf
- 运动营养学(第三版)课件全套 第1--10章 运动营养学基础、 健身运动的合理膳食营养---运动.pptx
- 钢琴谱 泰坦尼克号主题曲 原版 我心永恒 My heart will go on 五线谱 带指法.pdf VIP
- 英语说课稿(全英版)(精选范文).doc
- Lingumi单词卡level1-3(幼儿英语适合2-6岁幼儿).pdf VIP
文档评论(0)