September 1, 2014
Hot Topics:
RSS RSS feed Download our iPhone app

Project Coin Languages Changes, Page 2

  • December 19, 2011
  • By Sridhar M S
  • Send Email »
  • More Articles »

NIO.2 Improvements Over NIO

Developers who use NIO can now use NIO.2 to access the file system. NIO.2 is enhanced with the java.nio.file package and its related package java.nio.file.attribute, which make it easy to work across operating systems or multi-file systems. A detailed tutorial is available on oracle.com.

The java.nio.file package has many classes and interfaces such as Path, Paths, FileSystem, FileSystems, and so on. Utility methods such as delete (e.g. delete(argPath) and deleteIfExists(argPath) in the Files class) were also added to avoid unnecessary problems.

However, existing code needs an overhaul to adapt to NIO.2. Developers will have to weigh the effort against the benefits of adopting NIO.2 for future portability and easy developmental support.

Rich GUI Deployment in Java 7

Those using Java Web Start for application launches can employ JDK 7 enhancements in the JNLP file syntax.

  • The OS attribute in the information and resources elements can now contain a specific version of Windows such as Windows Vista or Windows 7.
  • The codebase attribute can be ignored.
  • You can now embed a JNLP file into an HTML page.

A new class, JLayer, also has been added to enhance the capabilities of Java Swing. JLayer is used primarily to decorate Swing components. Oracle.com has a detailed JLayer tutorial for reference.

Other Swing changes include support for non-rectangular shapes and transparent windows, which make GUIs richer and more intuitive for end users.

Sockets Direct Protocol (SDP)

The Sockets Direct Protocol (SDP) provides access to high performance network connections, such as that provided by InfiniBand. Transferring data across networks quickly and efficiently is a requirement in high performance computing systems, where the conventional approach of transferring data using sockets is of little or no help. SDP is ideal in such environments and the throughput can be real-time.

Used effectively, these and all the other Java 7 changes/enhancements will make Java developers more productive.


Tags: JDK, Java 7

Originally published on http://www.developer.com.

Page 2 of 2



Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 


Sitemap | Contact Us

Rocket Fuel