Red Hat Adds Java Features to Visual Studio Code

The latest update to Java on Visual Studio Code gets new functionality provided by Red Hat via its language support extension.

Java tooling for the open source-based, cross-platform code editor is supplied by a host of extensions, all bundled together in the Java Extension Pack, which includes Language Support for Java by Red Hat. The Red Hat tool has actually been installed more times (9.7 million) than the Java Extension Pack (7.6 million).

In the March update to Java on Visual Studio Code (actually announced on April 20), Red Hat contributed a couple of "very important things" that engineers have been working on, uncovered this week by Yaojin Yang, senior program manager in the Developer Division at Microsoft:

  • Type hierarchy: This adds to previous VS Code support for call hierarchy for Java. The Microsoft team worked with Red Hat to provide type hierarchy in the latest release of the latter's popular extension. It lets developers view type hierarchy in class, supertype or subtype view.
    Type Hierarchy in Animated Action
    [Click on image for larger, animated GIF view.] Type Hierarchy in Animated Action (source: Microsoft).
  • Package refactoring when moving file: Yaojin Yang said many developers have waiting for this feature that now comes in the Red Hat tool. It lets VS Code automatically update package declaration and import statements when a .java file is moved from one folder to another, while allowing developers to review and undo package changes.

Yet more functionality was added in the extension pack's Maven for Java tool, with more than 8 million installs. It adds support for Maven lifecycle, meaning developers can use the Maven explorer view to directly execute common lifecycle phases with a click on a phase's "run" icon.

Finally, classpath configuration has been improved. "Managing path for source code, output, runtime, and libraries is an important project management task, almost every Java developer will perform," Yaojin Yang explained. "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."

Full Java on Visual Studio Code documentation provides more on using the popular programming language with the popular code editor, along with tutorials.

About the Author

David Ramel is an editor and writer for Converge360.

comments powered by Disqus


  • Creating Reactive Applications in .NET

    In modern applications, data is being retrieved in asynchronous, real-time streams, as traditional pull requests where the clients asks for data from the server are becoming a thing of the past.

  • AI for GitHub Collaboration? Maybe Not So Much

    No doubt GitHub Copilot has been a boon for developers, but AI might not be the best tool for collaboration, according to developers weighing in on a recent social media post from the GitHub team.

  • Visual Studio 2022 Getting VS Code 'Command Palette' Equivalent

    As any Visual Studio Code user knows, the editor's command palette is a powerful tool for getting things done quickly, without having to navigate through menus and dialogs. Now, we learn how an equivalent is coming for Microsoft's flagship Visual Studio IDE, invoked by the same familiar Ctrl+Shift+P keyboard shortcut.

  • .NET 9 Preview 3: 'I've Been Waiting 9 Years for This API!'

    Microsoft's third preview of .NET 9 sees a lot of minor tweaks and fixes with no earth-shaking new functionality, but little things can be important to individual developers.

  • Data Anomaly Detection Using a Neural Autoencoder with C#

    Dr. James McCaffrey of Microsoft Research tackles the process of examining a set of source data to find data items that are different in some way from the majority of the source items.

Subscribe on YouTube