(Note: to anyone downvoting, kindly tell me the reason so I can improve and not repeat it)
I followed the instructions given in Java Getting Started inside vscode, but it resulted in failure. I do not just want a, perhaps hacky, fix for this. I want to understand what is causing the problem.
I am on Ubuntu 19.04 64bit.
vscode version 1.38.1
I have all the basic java extensions included in the pack installed in vscode.
java --version returns :
java 12.0.2 2019-07-16
Java(TM) SE Runtime Environment (build 12.0.2+10)
Java HotSpot(TM) 64-Bit Server VM (build 12.0.2+10, mixed mode, sharing)
This is what I followed.

It first took me to the newly generated launch.json instead of directly running the code as stated in the procedure.
Here is my launch.json
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Launch) - Current File",
"request": "launch",
"mainClass": "${file}"
},
{
"type": "java",
"name": "Debug (Launch)-QuickStart",
"request": "launch",
"mainClass": "QuickStart"
}
]
}
I went ahead and hit F5 on my file again and this is what I was met with
user@machine:$ cd /home/user/test/java/proj ; /usr/lib/jvm/java-12-oracle/bin/java -agentlib:jdwp=transport=dt_socket,server=n,suspend=y,address=localhost:42535 --enable-preview -Dfile.encoding=UTF-8 -cp /home/user/.config/Code/User/workspaceStorage/db4b3a82ff379b93685473884410762c/redhat.java/jdt_ws/jdt.ls-java-project/bin QuickStart
Error: Could not find or load main class QuickStart
Caused by: java.lang.ClassNotFoundException: QuickStart
Please help me understand this and thereby fix it. If I have missed out any crucial information, please ask in the comments and I will promptly add it.
Thank you
public, shouldn't it?