Java development environment configuration (win7_64bit)

Java development environment configuration (win7_64bit) 1. Overview

Building a Java development environment generally requires installing both the JDK and the JRE.

JDK: refers to the Java Development Kit Java Development Kit. It is required to develop Java programs. The JDK contains a part of the public JRE.

JRE: A Java runtime environment, the Java Runtime Environment, used when running a developed Java program.

2. Tools used in this article

Java SE basic toolkit: official website download

Test source

3. Installation

It is recommended to configure a separate folder for it as shown below.

Java development environment configuration (win7_64bit)

Download the JDK, see step 2.

Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)

Installation is very simple, pay attention to the JDK first, followed by JRE. .

Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)

4. Environment variable configuration

Java environment variables involve three nouns: JAVA_HOME, path, classpath.

JAVA_HOME represents the JDK installation home directory, path represents the JDK executable file directory, and classpath represents the directory where the class file needs to be found when running the java program.

According to the above installation steps:

JAVA_HOME should be set to: D:\DevelopTools\JAVA\JDK

Path should be set to: %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin; (note the semicolon)

The classpath should be set to:. ;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\libools.jar; (Note that the first point represents the current path, this is not required after JDK1.5)

The setting method is as follows:

Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)
Java development environment configuration (win7_64bit)

5. Test Program 5.0 There are many development tools for Java projects. Common ones are Eclipse, Myeclipse, IDEA, etc. The configuration method refers to the link in the relevant blog post.

5.1 Write a java program in the specified directory (test without IDE here):

Java development environment configuration (win7_64bit)

5.2 Start the command line window to run:

Java development environment configuration (win7_64bit)

5.3 It is cumbersome to switch directories every time. One solution is to add the directory where the code is stored to the environment variable, but set it if the code directory changes.

The method I recommend is to put the command window file directly into the directory with the code, which saves a lot of trouble.

Java development environment configuration (win7_64bit)

Java development environment configuration (win7_64bit)

6. Note 6.0 If the link involved in the article is swallowed or found to be in error, please contact QQ245176013.

6.1 The JDK version demonstrated in this article is as follows:

Java development environment configuration (win7_64bit)

6.2 When writing Java using the integrated development environment, environment variables are generally not explicitly set, and the IDE will do it for us.

6.3 About the compiler used to develop Java, this is a matter of opinion, the general compiler has EclipseSE version, EclipseEE version, MyEclipse, IDEA, etc., I personally recommend IDEA, because "smart"! See the related blog posts listed below for specific installation configurations.

7. Related blog posts

Fiber Optic Distribution Box

Fiber Optic Distribution Box,Fiber Optic Termination Box,Fiber Terminal Box,Optical Termination Box

CIXI LANGUANG PHOTOELECTRIC TECHNOLOGY CO..LTD , https://www.cxblueray.com