Contribute a Java Extension · redhat-developer/vscode-java Wiki · GitHub | Latest TMZ Celebrity News & Gossip | Watch TMZ Live
Skip to content

Contribute a Java Extension

Fred Bricon edited this page Sep 30, 2020 · 4 revisions

You can contribute a VSCode Java Extension to enhance the existing VSCode Java features. Follow these steps to contribute an extension.

Server Bundle

Authoring VSCode Extension

You can follow the tutorial here to start your own VSCode extension

Modify package.json

Put a server bundle together with your current VS Code extension (in a ./server subfolder, for example), and add the following code snippet to the contributes section of your extension's package.json. Thus, the language server will discover your plugin for later usage.

"contributes": {
    "javaExtensions": ["./server/my.java.plugin.jar"],
}

Execute command

If you want to communicate with the plugin, add the following code in your extension:

// This should be your command ("my.java.command") corresponding to your server plug-in extension point registration:
function sendMyCommandToJavaLanguageServer(arg) {
    return executeJavaLanguageServerCommand("my.java.command", arg);
}

// This is the VSCode Java command for language server protocol workspace/executeCommand: 
function executeJavaLanguageServerCommand(...rest) {
    return vscode.commands.executeCommand("java.execute.workspaceCommand", ...rest);
}
Clone this wiki locally

TMZ Celebrity News – Breaking Stories, Videos & Gossip

Looking for the latest TMZ celebrity news? You've come to the right place. From shocking Hollywood scandals to exclusive videos, TMZ delivers it all in real time.

Whether it’s a red carpet slip-up, a viral paparazzi moment, or a legal drama involving your favorite stars, TMZ news is always first to break the story. Stay in the loop with daily updates, insider tips, and jaw-dropping photos.

🎥 Watch TMZ Live

TMZ Live brings you daily celebrity news and interviews straight from the TMZ newsroom. Don’t miss a beat—watch now and see what’s trending in Hollywood.