java precisely.pdf
(
874 KB
)
Pobierz
Java Precisely
Java Precisely
Peter Sestoft
The MIT Press
Cambridge, , Massachusetts London, England
Copyright © 2002 Massachusetts Institute of Technology
All rights reserved. No part of this book may be reproduced in any form by any electronic or mechanical
means (including photocopying, recording, or information storage and retrieval) without permission in
writing from the publisher.
This book was set in Times by the author using
.
Printed and bound in the United States of America.
Library of Congress Cataloging-in-Publication Data
Sestoft, Peter.
Java precisely/Peter Sestoft.
p. cm.
Includes bibliographic references and index.
ISBN 0-262-69276-7 (pbk. : alk. paper)
1. Java (Computer program language) I. Title.
QA76.73.J38 S435 2002
005.13'3
—
dc21 2002016516
Table of Contents
Preface .................................................................................. 4
Notational Conventions ............................................................ 5
Chapter 1 - Running Java: Compilation, Loading, and Execution ... 6
Chapter 2
- Names and Reserved Names .................................. 7
Chapter 3
- Java Naming Conventions ....................................... 8
Chapter 4
- Comments and Program Layout ............................... 9
Chapter 5
- Types .................................................................. 11
Chapter 6
- Variables, Parameters, Fields, and Scope ................. 13
Chapter 7
-Strings ................................... 16
Chapter 8
- Arrays ................................................................. 19
Chapter 9
-Classes ................................... 23
Chapter 10
- Classes and Objects in the Computer ....................... 35
Chapter 11
- Expressions .......................................................... 37
Chapter 12
- Statements ........................................................... 51
Chapter 13 -Interfaces ................................. 61
Chapter 14
- Exceptions, Checked and Unchecked ........................ 63
Chapter 15
- Threads, Concurrent Execution, and Synchronization .. 66
Chapter 16
- Compilation, Source Files, Class Names, and Class Files . 73
Chapter 17 - Packages and Jar Files ........................................... 74
Chapter 18 - Mathematical Functions .......................................... 76
Chapter 19
-String Buffers ............................... 79
Chapter 20 - Collections and Maps .............................................. 81
Chapter 21 - Input and Output ................................................... 95
References .............................................................................. 119
Preface
This book gives a concise description of the Java 2 programming language, versions 1.3 and 1.4. It is a
quick reference for the reader who has already learned (or is learning) Java from a standard textbook
and who wants to know the language in more detail. The book presents the entire Java programming
language and essential parts of the class libraries: the collection classes and the input-output classes.
General rules are shown on left-hand pages mostly, and corresponding examples are shown on right-
hand pages only. All examples are fragments of legal Java programs. The complete ready-to-run
example programs are available from the book Web site
<
http://www.dina.kvl.dk/~sestoft/javaprecisely/
>
.
The book does not cover garbage collection, finalization and weak references, reflection, details of
IEEE754 floating-point numbers, or Javadoc.
Acknowledgments
Thanks to Rasmus Lund, Niels Hallenberg, Hans Henrik L
ø
vengreen, Christian
Gram, Jan Clausen, Anders Peter Ravn, Bruce Conrad, Brendan Humphreys, Hans Rischel and Ken
Friis Larsen for their useful comments, suggestions, and corrections. Special thanks to Rasmus Lund
for letting me adapt his collections diagram for this book. Thanks also to the Royal Veterinary and
Agricultural University and the IT University of Copenhagen, Denmark, for their support.
4
Notational Conve
ntions
Symbol
Meaning
v
Value of any type
x
Variable or parameter or field or array element
e
Expression
t
Type (primitive type or reference type)
s
Expression of type String
m
Method
f
Field
C
Class
E
Exception type
I
Interface
a
Expression or value of array type
i
Expression or value of integer type
o
Expression or value of object type
sig
Signature of method or constructor
p
Package
u
Expression or value of thread type
5
Plik z chomika:
musli_com
Inne pliki z tego folderu:
Big Java Late Objects [Horstmann 2012-02-01].pdf
(167477 KB)
Data Structures_ Abstraction and Design using Java (2nd ed.) [Koffman & Wolfgang 2010-01-26].pdf
(190252 KB)
Big Java Early Objects (5th ed.) [Horstmann 2013-01-04].pdf
(145099 KB)
Data Abstraction and Problem Solving with Java_ Walls and Mirrors (3rd ed.) [Prichard & Carrano 2010-10-30] (photocopier quality).pdf
(110506 KB)
A Little Java, a Few Patterns [Felleisen & Friedman 1997-12-19].pdf
(14847 KB)
Inne foldery tego chomika:
3D Design - Programming
ActionScript
Actionscript - Flash - Flex - Air
Ada
ADO
Zgłoś jeśli
naruszono regulamin