0%

Book Description

New Java releases continue to arrive at a rapid pace. The community now receives a new Java version with features and bug fixes about every two months. The latest edition of this ebook examines many added and removed items in Java 12, including a new preview feature that lets you try out functionality not yet ready for production.

Software engineer and consultant Benjamin Muschko uses code examples to explore new features such as the teeing collector, the string indentation and transformation APIs, and support for Unicode 11. With this ebook, you can determine whether it’s worthwhile to upgrade now or wait until the next Java release.

This edition covers:

  • Latest features and API enhancements: Using compact number formatting and exploring new methods for comparing files are just two examples.
  • Preview features: Evaluate the proposed switch expressions feature and provide feedback to the Java team.
  • Removed APIs and deprecations: Learn about several features and APIs that have been removed in this release.
  • Performance and security: Discover why improvements to the G1 garbage collector are among Java 12’s biggest selling points.

Table of Contents

  1. What’s New in Java 12?
    1. Introduction
    2. New Features
      1. Teeing Collectors
      2. String API Enhancements
      3. Comparing Files
      4. Compact Number Formatting
      5. Adoption of Unicode 11
    3. Preview Features
      1. The Traditional Way to Define Switch Statements
      2. Switch Expressions
      3. Enabling Preview Features from Build Tools
      4. Enabling Preview Features in the IDE
    4. Removed Features and APIs
      1. Compiler Support for Java 6
      2. Removal of finalize Methods
      3. Deprecated Features and APIs
    5. Performance and Security
      1. Microbenchmark Suite for the JDK Source Code
      2. Shenandoah: A Low-Pause-Time Garbage Collector
      3. Improvements to the G1 Garbage Collector
      4. Security Enhancements
      5. Summary and Further Reading
34.204.52.16