Java

About

Java Java is a general-purpose programming language that is class-based, object-oriented, and designed to have a few implementation dependencies as possible.

Installation

Change enable from False to True in the java section (cf module installation).

vscode-anywhere:
    java:
        enabled: True

You can also take a look at the VSCode-Anywhere java module configuration.

For more details read the official documentation.

Requirements

No requirements.

VSCode

VSCode extensions

redhat.java

This extension provides Java language support.

vscjava.vscode-java-debug

This extension provides a lightweight Java debugger for Visual Studio Code.

vscjava.vscode-java-test

This extension allow to run and debug Java test cases in Visual Studio Code.

vscjava.vscode-maven

This extension allows to manage Maven projects, execute goals, generate a project from the archetype, improve the user experience for Java developers.

vscjava.vscode-java-dependency

This extension manages Java Dependencies in VSCode.

VisualStudioExptTeam.vscodeintellicode

This extension provides AI-assisted development features for Java.

shengchen.vscode-checkstyle

This extension provides real-time feedback about Checkstyle violations and quick fix actions.

redhat.vscode-xml

This extension provides support for creating and editing XML documents, based on the LSP4XML Language Server, running with Java.

pivotal.vscode-spring-boot

This extension provides validation and content assist for Spring Boot application.properties, application.yml properties files. As well as Boot-specific support for .java files.

This extension will be installed only if you had set spring_boot to True in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
    enabled: True
    spring_boot: True

vscjava.vscode-spring-initializr

This extension quickly generates a Spring Boot project in Visual Studio Code (VS Code). It helps you to customize your projects with configurations and manage Spring Boot dependencies.

This extension will be installed only if you had set spring_boot to True in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
        enabled: True
        spring_boot: True

vscjava.vscode-spring-boot-dashboard

Spring Boot Dashboard is an explorer in the side bar, you can view and manage all available Spring Boot projects in your workspace. It also supports the features to quickly start, stop or debug a Spring Boot project.

This extension will be installed only if spring_boot is enabled in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
        enabled: True
        spring_boot: True

redhat.vscode-quarkus

This extension provides support for Quarkus development.

This extension will be installed only if quarkus is enabled in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
        enabled: True
        quarkus: True

SummerSun.vscode-jetty

This extension allows to start and run or debug your war package on Jetty.

This extension will be installed only if jetty is enabled in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
        enabled: True
        jetty: True

adashen.vscode-tomcat

This extension allows to debug or run your java war package in Apache Tomcat.

This extension will be installed only if jetty is enabled in your vscode-anywhere.sls file:

vscode-anywhere:
    java:
        enabled: True
        tomcat: True

VSCode settings

Global settings

{
    "java.semanticHighlighting.enabled": true
}

Windows settings

{
    "java.home": "C:\\VSCode-Anywhere\\apps\\scoop\\apps\\openjdk\\current",
    "xml.java.home": "C:\\VSCode-Anywhere\\apps\\scoop\\apps\\openjdk\\current"
}

Assuming you have installed in the default directory C:\VSCode-Anywhere.

Linux settings

{
    "java.home": "/home/linuxbrew/.linuxbrew/opt/openjdk/libexec",
    "xml.java.home": "/home/linuxbrew/.linuxbrew/opt/openjdk/libexec"
}

MacOS settings

{
    "java.home": "/home/linuxbrew/.linuxbrew/opt/openjdk/libexec",
    "xml.java.home": "/home/linuxbrew/.linuxbrew/opt/openjdk/libexec"
}

VSCode keybindings

No keybindings.

Software

Windows software

scoop

This package will be installed only if tomcat is enabled in your vscode-anywhere.sls file.

This package will be installed only if quarkus is enabled in your vscode-anywhere.sls file.

chocolatey

This package will be installed only if you had set jetty is enabled in your vscode-anywhere.sls file.

Linux software

brew

This package will be installed only if jetty is enabled in your vscode-anywhere.sls file.

This package will be installed only if tomcat is enabled in your vscode-anywhere.sls file.

nix

This package will be installed only if quarkus is enabled in your vscode-anywhere.sls file.

MacOS software

brew

This package will be installed only if jetty is enabled in your vscode-anywhere.sls file.

This package will be installed only if tomcat is enabled in your vscode-anywhere.sls file.

Documentation

VSCode-Anywhere

Environment

Windows environment

PATH: C:\VSCode-Anywhere\apps\scoop\apps\openjdk\current\bin;C:\VSCode-Anywhere\apps\scoop\apps\maven\current\bin
JAVA_HOME: C:\VSCode-Anywhere\apps\scoop\apps\openjdk\current
JDK_HOME: C:\VSCode-Anywhere\apps\scoop\apps\openjdk\current

If quarkus is enabled, the following PATH will be append:

C:\VSCode-Anywhere\apps\scoop\apps\graalvm\current\bin

If jetty is enabled the following environment will be set:

JETTY_HOME: C:\SCode-Anywhere\apps\scoop\apps\Chocolatey\lib\jetty\tools\jetty

Assuming you have installed in the default directory C:\VSCode-Anywhere.

Linux environment

PATH: /home/linuxbrew/.linuxbrew/opt/openjdk/bin
JAVA_HOME: /home/linuxbrew/.linuxbrew/opt/openjdk/libexec
JDK_HOME: /home/linuxbrew/.linuxbrew/opt/openjdk/libexec

If tomcat is enabled the following environment will be set:

CATALINA_BASE: /home/linuxbrew/.linuxbrew/opt/tomcat/libexec
CATALINA_HOME: /home/linuxbrew/.linuxbrew/opt/tomcat/libexec

If jetty is enabled the following environment will be set:

JETTY_HOME: /home/linuxbrew/.linuxbrew/opt/jetty/libexec

MacOS environment

PATH: /home/linuxbrew/.linuxbrew/opt/openjdk/bin
JAVA_HOME: /home/linuxbrew/.linuxbrew/opt/openjdk/libexec
JDK_HOME: /home/linuxbrew/.linuxbrew/opt/openjdk/libexec

If tomcat is enabled the following environment will be set:

CATALINA_BASE: /home/linuxbrew/.linuxbrew/opt/tomcat/libexec
CATALINA_HOME: /home/linuxbrew/.linuxbrew/opt/tomcat/libexec

If jetty is enabled the following envrionment will be set:

JETTY_HOME: /home/linuxbrew/.linuxbrew/opt/jetty/libexec

Specific settings

spring_boot

If set to True, it will install additional components for Spring Boot:

vscode-anywhere:
    java:
        enabled: True
        spring_boot: True

quarkus

If set to True, it will install additional components for Quarkus:

vscode-anywhere:
    java:
        enabled: True
        quarkus: True

tomcat

If set to True, it will install additional components for Tomcat:

vscode-anwyhere:
    java:
        enabled: True
        tomcat: True

jetty

If set to True, it will install additional components for Jetty:

vscode-anwyhere:
    java:
        enabled: True
        jetty: True

Last updated