Foreword
Preface
Part I.Introducing java
1.Introduction to the Java Environment
The Language, the IVM, and the Ecosystem
A Brief History of Java and the JVM
The Lifecycle of a Java Program
Java Security
Comparing Java to Other Languages
Answering Some Criticisms of Java
2.Java Syntax from the Ground Up
Java Programs from the Top Down
Lexical Structure
Primitive Data Types
Expressions and Operators
Statements
Methods
Introduction to Classes and Objects
Arrays
Reference Types
Packages and the Java Namespace
Java File Structure
Defining and Running Java Programs
Summary
3.Object-Oriented Programming in Java
Overview of Classes
Fields and Methods
Creating and Initializing Objects
Subclasses and Inheritance
Data Hiding and Encapsulation
Abstract Classes and Methods
Modifier Summary
4.The Java Type System
Interfaces
Java Generics
Enums and Annotations
Nested Types
Lambda Expressions
Conclusion
5.Introduction to Object-Oriented Design in Java
Java Values
Important Methods of java.lang.Object
Aspects of Object-Oriented Design
Exceptions and Exception Handling
Safe Java Programming
6.Java's approach to Memory and Concurrency
Basic Concepts of Java Memory Management
How the JVM Optimizes Garbage Collection
The HotSpot Heap
Finalization
lava's Support for Concurrency
Working with Threads
Summary
Part II.Working with the Java Platform
7.Programming and Documentation Conventions..
Naming and Capitalization Conventions
Practical Naming
Java Documentation Comments
Conventions for Portable Programs
8.Working with Java Collections
Introduction to Collections API
Lambda Expressions in the Java Collections
Conclusion
9.Handling Common Data Formats
Text
Numbers and Math
Java 8 Date and Time
Conclusion
10.File Handling and I/0
Classic Java I/O
Modern Java I/O
NIO Channels and Buffers
Async I/O
NETworking
11.Classloading, Refleaion, and Method Handles
Class Files, Class Ob)ects, and Metadata
Phases of Classloading
Secure Programming and Classloading
Applied Classloading
Reflection
Dynamic Proxies
Method Handles
12.Nashorn
Introduction to Nashorn
Executing Javascript with Nashom
Nashorn and )avax.script
Advanced Nashorn
Conclusion
13.Platform Tools and Profiles
Command-Line Tools
VisualVM
Java 8 Profiles
Conclusion
Index