Home > Dreamtech Books, In Simple Steps Book Series > Exploring Features of Java SE 7

Exploring Features of Java SE 7

Free excerpt from Chapter 01 of Java 7 In Simple Steps by Kogent Learning Solutions Inc.

Java SE 7 is a major release that has brought many new features and enhancements in Java programming. A brief introduction to the noteworthy features of Java SE 7 is as follows:

Swing enhancements: Introduce various enhancements in the javax.swing package. Some of such enhancements are as follows:

  • Providing the JLayer class to decorate the swing components
  • Moving Nimbus look and feel from the com.sun.java.swing package to the javax.swing.plaf.nimbus package
  • Allowing mix up of heavyweight and lightweight components
  • Allowing you to create translucent and shaped windows
  • Adding the selection of Hue-Saturation-Luminance (HSL) color in the JColorChooser class

Enhancements in Java Input/Output (I/O): Introduce various enhancements in implementing I/O operations using Java programming. Some of the Java I/O enhancements in Java SE 7 are as follows:

  • Allowing non-blocking I/O (NIO) 2.0
  • Allowing you to develop customized file system provider
  • Allowing you to manipulate contents of the Java Archive (JAR) file
  • Introducing the new APIs in the java.nio.file package

Networking enhancements: Add the close() method in the URLClassLoader class. The introduction of this method has overcome the problem of supporting the updated implementations of resources that are taken up from a specific codebase. Moreover, the Sockets Direct Protocol (SDP) specifies the accessibility to high-performance network connections.

Security enhancements: Add the following security features in Java SE 7:

  • Introducing Elliptic Curve Cryptography (ECC) as a new native provider that contains various ECC-based algorithms
  • Allowing you to disable weak cryptographic algorithms

Multithreaded custom class loaders: Modify the locking mechanism to prevent deadlock situation, as the custom class loaders were initially prone to deadlocks

Enhancements in Java programming language: Introduce the following various enhancements in Java SE 7 as a programming language:

  • Allowing you to specify the integral types, such as byte, short, int, and long, using the binary number system by adding the 0b or 0B prefix
  • Allowing the use of underscores in the numerical literals
  • Allowing the use of strings in the switch statements
  • Improving the compiler warning that occurs while using non-reifiable formal parameters with the Varargs methods

XGPGY7BED8MF

Advertisement
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.