Posted: 22 Aug 2017
We’re a month away from the release of Java 9. Java’s latest instalment, which will be fully available to the public on September 21st, has had a variety of setbacks since it was first rumoured to be in development but is set to finally be released.
Three years since the last instalment of the programming software, Java 9 will see some massive changes to the system. Java 9 will see updates rolled across several different areas, including tools, security, deployment and language, as well as enhancements in other key aspects of the platform.
So, what are some features that you should be prepared for? We’ve compiled a list of some of the most important features that you should be aware of.
Perhaps the biggest improvement is the modularity function of the platform. It has been suggested that the function was originally intended to be rolled out with the release of Java 8, but developers have instead decided that modules in Java 9 will replace the Monolithic Jars architecture.
One of the reasons that this function will come in useful when using the platform is due to the ability to separate code. Ordinarily, the code will not have the ability to be encapsulated, which means that every public class can be accessed. The use of the new Java module platform means that there can be an addition to the JAR files that can include a module descriptor. This means that not every part of the package necessarily will be exported, keeping sections of the code private and inaccessible to others. You can find the JAR file in the root directory as module-info.class
The new programming component of Java 9 also introduces a new optional phase – link time. In the latest version of Java, you will notice that each module now has the ability to state their dependencies, so the new jlink tool offers the chance to create a minimal runtime environment for your application.
Javadoc, the documentation generator, has been previously included on older versions of Java. However, Java 9 will see the generator able to create API documentation using HTML5. With Javadoc supporting HTML5, and not just the standard HTML 4.01, there will be an improved level of search capability and Doclint.
The new search box on Javadoc means that elements of programs, words and phrases can be found in the documentation easily, and the –Xdoclint element means that any bad references in the code are spotted, and recommended changes are made.
One of the new tools in the latest installation, Jshell, has been described by Oracle as providing “an interactive command-line interface for evaluating declarations, statements, and expressions of the Java programming language”.
What this means is that Java 9 will include a new line of command tools. This will make the code easier to use, as it will eliminate the need to wrap a few lines of the Java language in a separate project or method if you wish to run a few lines.
Perhaps not one of the most noticeable changes for most users of Java, but still something worth mentioning is the updated string scheme, JEP 223. The new string scheme allows patch updates to become more recognisable. This has been done by encoding minor, major and critical patch updates with a separate numerical component, allowing Java users to distinguish the level of the patch faster.
Those within Java developer jobs will have to be aware of the latest version of the Java software and adapt to its exciting new changes.Previous Page