From e8e730c2cd8b43975c1843029e86dd7fbaa7756f Mon Sep 17 00:00:00 2001 From: Stephen Enders Date: Wed, 1 Jan 2020 10:32:28 -0500 Subject: Added a table of contents to java setup --- www/java-setup.html | 49 ++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 38 insertions(+), 11 deletions(-) diff --git a/www/java-setup.html b/www/java-setup.html index 99ec942..3edd949 100644 --- a/www/java-setup.html +++ b/www/java-setup.html @@ -7,8 +7,35 @@ Java Setup for Windows -
-

Installing Java

+

Java Setup - Windows

+ +
+

Installing Java

To install Java you need to install the Java Development Kit (JDK). It can be downloaded from here: https://jdk.java.net/13

You will want to select the zip download for Windows.
@@ -23,7 +50,7 @@

When I did this myself, it unzipped into a folder jdk-13.0.1. By the end you should have the following folder structure: C:\Program Files\Java\jdk-13.0.1

-

Setting up your environment

+

Setting up your environment

In order to make the JDK discoverable by your programs you need to add the JDK folder to your PATH environment varible. This is best done by first setting up a varible for the java directory JAVA_HOME that points directly to the directory you copied the unzipped files into.


@@ -36,19 +63,19 @@
Hover to zoom

Optionally, if you want to test that this worked, you can open up the command prompt (or powershell) by opening the start menu and typing/looking for cmd.exe. Then you can type java -version which will output the version and some additional information. You should see java version 13.0.1.

-

IntelliJ Community Edition

+

IntelliJ Community Edition

I recommend using IntelliJ Community Edition instead of Eclipse. They're both open source but I use IntelliJ at my job daily and its a fantastic, out of the box editor. Where Eclipse requires a lot more setup steps and plugins to get it to be "complete". Feature wise they do the same things, so everything they do in Udemy via Eclipse should work in IntelliJ.

-

Downloading

+

Downloading

To Download go to www.jetbrians.com/idea/download and click the Exe download for community edition.



Hover to zoom

Once the download is complete you can run the installer. You should select your theme, then just use the "Install defaults" option at the bottom, or just Next through the rest of setup, as you shouldn't need any additional plugins. And if you do they all can be installed later

You're Done! You can start Udemy now just ignoring their install/setup instructions. I have some additional steps below to help verify everything works and do some basic operatoins in IntelliJ (Create a Project, Create a class, Run/Debug) but you can refer back to here once you get there in Udemy

-

Using IntelliJ

+

Using IntelliJ

Jetbrains actually has a whole FAQ/Tutorial section that can help you with any questions too. But here is a brief overview of the core functions of IntelliJ

-

Creating a project

+

Creating a project

When you first open IntelliJ it shows a splash screen where you can open an existing project or create a new one. You will at first want to create a new project.


@@ -66,7 +93,7 @@

Hover to zoom -

Creating a class

+

Creating a class

To create a class in IntelliJ you should expand the projects menu on th left side and right click the src folder. You then select "create class". This will add it directly into your src folder.


@@ -75,17 +102,17 @@

Hover to zoom -

Running a Program

+

Running a Program

Java code is executed from the main method public static void main(String[] args). You can run your main method by either right clicking within it and selecting run. Or when the file containing your main method is open using the Run button at the top right of the editor.



Hover to zoom -

Debugging a Program

+

Debugging a Program

To debug you can set breakpoints in your code by selecting the left hand side by the line numbers. This will add a red dot which tells the program to pause executing when it reaches the code at that line. To do this you need to run in debug mode (rather than plain run mode) by right clicking your main method and choosing Debug, or by using the debug icon at the top right of the editor window.



Hover to zoom -

Additional Help

+

Additional Help

If you need any help at all feel free to text or email. If its a code issue, either a screenshot of the code or the code itself will help!

-- cgit v1.2.3-54-g00ecf