Java on Visual Studio Code Update – March 2021
It’s blogging time again. Welcome to VS Code update for Java. In the last couple of months, our engineers have been working on a few very important things. Now, it’s time to uncover. Let’s start.
VS Code has already supported call hierarchy for Java, so what about type hierarchy? Together with Red Hat, we are very happy to announce type hierarchy is publicly available from the latest release of Language Support for Java published by Red Hat.
The feature allows you to view type hierarchy in class, supertype, or subtype view.
Package refactoring when moving file
We know a lot of developers waiting for this feature, when a .java file is moved from one folder to another, VS Code can automatically update package declaration and importing statements. The latest release of Language Support for Java published by Red Hat now supports this feature. In addition to automatic updating, the feature also allows you to review and undo package changes.
Managing path for source code, output, runtime, and libraries is an important project management task, almost every Java developer will perform. For those using build tool like Maven or Gradle, the tool allows managing these paths through its configuration file. However, for those not using the build tool, especially like students, they need rely on IDE/editor tool to manage. Responding to that need, we released classpath configuration feature.
You can launch the classpath configuration from “JAVA PROJECTS” explorer or by clicking Ctrl+Shift+P to open command palette and then typing “configure classpath” on the palette.
This feature is released as part of Java Extension Pack. Please, make sure you have installed the latest version of the pack.
Maven lifecycle support
In the latest Maven for Java extension release, Maven lifecycle is supported. Now, you can directly execute common lifecycle phases from Maven explorer view by clicking the run icon next to a phase.
Try it out
Please don’t hesitate to give it a try! Your feedback and suggestions are very important to us and will help shape our product in future.
- Learn more about Java on Visual Studio Code.
- Explore our step by step Java Tutorials on Visual Studio Code.