Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Chapter 1. Java Language Improvements

Chapter 1. Java Language Improvements

In this chapter, we will cover the following:

  • Using string literals in switch statements

  • Using underscores in literals to improve code readability

  • Using the try-with-resources block to improve exception handling code

  • Creating a resource that can be used with the try-with-resources technique

  • Catching multiple exception types to improve type checking

  • Re-throwing exceptions in Java 7

  • Using the diamond operator for constructor type inference

  • Using the @SafeVarargs annotation


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial