1

Java 19 support

 1 year ago
source link: https://devm.io/java/eclipse-ide-java-19
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Improvements to Maven, Git, and more

Eclipse IDE Adds Java 19 Support With 2022-12 Release

Sarah Schlothauer

08. Dec 2022


Java’s fast-paced six-month release cycle saw the general availability of Java 19 on September 20, 2022. Keeping up with the pace and ending 2022 on a high note, the open source Eclipse IDE now supports Java 19 with the latest release, Eclipse 2022-12.

This release largely adds Java improvements to the IDE and supports some newly implemented Java 19 features like Record Patterns and Pattern Matching for Switch. Developers can now test these out in their projects before they become stable.

Java 19 support

When you create a new Java project, you can now select Java 19 from the dropdown list (provided that you have Java 19 properly installed on your machine, as it is not the current long term release). If Eclipse 2022-12 adds the following Java 19 enhancements:

  • JEP 405: Record Patterns (Preview)
  • JEP 427: Pattern Matching for Switch (Third Preview)

Record patterns are used to deconstruct record values. According to JEP 427’s summary, pattern matching for switch “allows an expression to be tested against a number of patterns, each with a specific action, so that complex data-oriented queries can be expressed concisely and safely.”

Take note that these Java 19 features are currently still in preview. They are not recommended to use in production and should be used for testing purposes and familiarizing yourself with upcoming changes in the language.

Maven update

Some smaller improvements have also been added. Now, Maven can automatically be set to update project configurations. This feature was experimental in previous releases, but is now considered stable and is on by default.

This way, you no longer need to manually update the Maven project, streamlining your process and saving you time.

Managed versions for dependencies are now also shown by hovering over them.

XML changes

In the new update, when you are using XML files, the Eclipse IDE will automatically add an end tag when you start typing a start tag. The same is true for removing end tags.

You can also change formatting to fit your specific needs under Preferences > XML > Formatting.

Git improvements

Eclipse 2022-12 also adds an improvement for Git. Now, in the staging view, users can choose two files, then right-click on them, and compare one another.

View a full list of everything new and noteworthy included in the 2022-12 Simultaneous Release train. Apart from the Eclipse IDE, this release also includes new updates for the Eclipse Platform and Equinox, new APIs, and upgrades for various projects under the Eclipse umbrella such as LSP4J, Eclipse CDT, EGit, and more.

If you’re more of a visual learner, watch this informative video from Holger Voormann about all the changes.

Upgrading your IDE

Follow the Eclipse release plan to stay up to date with their multi-project simultaneous release schedule. The next release, platform version 4.27, is scheduled to release on March 15, 2023.

You can download the open source IDE and get started with Java 19 now. The Eclipse Installer for the 2022-12 release is available here for macOS, Windows, and Linux devices.

You can also view the full documentation for the Eclipse IDE 2022-12 version here.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK