If you're an experienced programmer, you already have a rock-solid foundation for learning Java. All you need is a resource that takes your experience into account and explains Java's key principles and techniques in an intelligent, efficient way. Java: Practical Guide for Programmers is precisely that resource. Here, you won't have to wade through hundreds of pages of overly simplistic material to learn the basics of Java programming. Instead, you get highly focused instruction in the core elements of Java 1. 4, accompanied by carefully chosen examples and line-by-line analyses that are right to the point. You'll be astonished at how soon you can begin productive coding in Java, and how quickly your skills will progress.
- Written expressly for people who already know a procedural or object-oriented programming language.
- Takes a concise approach designed to make the most of the experience you already have.
- Covers the core elements of Java 1. 4, including language syntax, OO features, collections, exception handling, input/output, threads, event handling, and Swing components.
- Filled with incisive coding examples and line-by-line analyses.
Inhaltsverzeichnis
1;Front Cover;1 2;Java Practical Guide for Programmers;4 3;Copyright Page;5 4;Contents;8 5;Preface;12 6;Chapter 1. Introduction;14 6.1;1.1 Simple Java Application;14 6.2;1.2 Java Tools;17 6.3;1.3 Language Features;18 7;Chapter 2. Basic Language Syntax;20 7.1;2.1 Comments;21 7.2;2.2 Statements;21 7.3;2.3 Variables;22 7.4;2.4 Constants;22 7.5;2.5 Data Types;23 7.6;2.6 Arithmetic Operations;30 7.7;2.7 Data Type Conversion;31 8;Chapter 3. Flow Control;34 8.1;3.1 Conditional Statements;34 8.2;3.2 Relational and Logical Operators;39 8.3;3.3 Iteration Statements;41 9;Chapter 4. Classes and Objects;46 9.1;4.1 Class and Object with No Methods;46 9.2;4.2 Class with Methods;48 9.3;4.3 Constructors;50 9.4;4.4 Method Overloading;52 9.5;4.5 Argument Passing in Java;52 9.6;4.6 Instance and Static Variables;55 9.7;4.7 Instance and Static Methods;57 9.8;4.8 this Keyword;58 9.9;4.9 StringBuffer;59 9.10;4.10 Vectors;60 9.11;4.11 Object Wrappers;60 10;Chapter 5. Inheritance and Access Control;62 10.1;5.1 Creating Subclasses;62 10.2;5.2 The Object Class;66 10.3;5.3 Abstract Classes and Methods;70 10.4;5.4 Interfaces;72 10.5;5.5 Packages;73 10.6;5.6 Access Control;76 10.7;5.7 Inner Classes;80 11;Chapter 6. Exceptions;84 11.1;6.1 Exception Handling;84 11.2;6.2 Java Exception Classes;87 11.3;6.3 Creating Exception Classes;88 11.4;6.4 Propagation of Exceptions;89 11.5;6.5 Runtime Exceptions;92 11.6;6.6 Assertions;93 12;Chapter 7. Input/Output;96 12.1;7.1 Terminal I/O Example;98 12.2;7.2 FileReader and FileWriter Streams;99 12.3;7.3 FileInputStream and FileOutputStream;105 12.4;7.4 Buffered Input and Output Streams;106 12.5;7.5 DataInputStream and DataOutputStream;108 12.6;7.6 Random Access Fries;111 12.7;7.7 Object Serialization;114 13;Chapter 8. Developing GUIs;120 13.1;8.1 Introduction;120 13.2;8.2 Swing Components;121 13.3;8.3 Component Methods;128 13.4;8.4 Swing Containers;130 13.5;8.5 Layouts;133 13.6;8.6 Specifying Look and Feel;136 13.7;8.7 Event Handling;137 13.8;8.8 Painting with S
wing;142 13.9;8.9 CustomerDetails Example;143 13.10;8.10 Applets;148 14;Chapter 9. Collections;156 14.1;9.1 Set Interface;156 14.2;9.2 List Interface;164 14.3;9.3 Map Interface;165 14.4;9.4 The Collections Class;167 15;Chapter 10. Threads;170 15.1;10.1 The Thread Class;170 15.2;10.2 Multithreaded Application Example;171 15.3;10.3 Thread Priorities;173 15.4;10.4 The Runnable Interface;173 15.5;10.5 Synchronizing Threads;177 15.6;10.6 Thread States;179 16;Appendix A: Operator Precedence;180 17;Appendix B: Swing Events;182 18;Index;186