Java Development Environment
The Java developement Kit--java Development Kit, or JDK, is a free Java development tool provided by Sun that allows programmers and end users to compile and run Java programs using this tool. The current versions are JDK1.0, JDK1.1, JDK1.2, JDK1.3, JDK1.4, JDK1.5 (J2SE5.0), JDK1.6 (j2se6.0), JDK1.7 (j2se7.0), JDK1.8.
JDK Architecture: JDK
|--Development tools (Tools) Commands: Java, Javac, jar, rmic ...
|--JRE (java Basic operating environment)
|--System API library, System class library
| Standard library of systems, standard API
|--J VM Java Virtual machine
Execution environment for the Java language
Java Development Environment Configuration
After installing the JDK, you cannot use it immediately and you need to set the environment variable:
1) Set Path:d:\java\jdk1.6.0\bin (point to the Bin folder in the JDK with various compilation commands).
2) CLASSPATH: Tell the Java program where to find third-party and custom classes, if the. class file and the class source file are in the same folder, you do not need to configure CLASSPATH, and subsequent packages are required.
Windows: Executing at the command line
Set Classpath=e:\workspace\1304\bin (Staging environment configuration)
Java day02. Demo1
E:\ set classpath = c \ (The current path is not found without semicolons)
= . ; C: \; D:\; (Find Classpath First, if none, then find the current path)
C, D two disks have the same name. class file, Classpath is set to D, and the command line window is currently drive letter C, the JVM is now looking for the classpath path, and then the current path is found.
Linux: Executing in console
① Set the CLASSPATH environment variable, pointing to the directory where the package resides, typically the bin directory in the project folder.
② executes the Java package. ClassName (package name must be written).
Export Classpath=/home/soft01/workspace/1304/bin (Temporary environment configuration)
Java day01. HelloWorld
Java-cp/home/soft01/workspace/1304/bin Day01. HelloWorld (two in Unity)
Precautions:
The Windows root directory is a backslash: \
The Linux root directory is a slash:/
Java Development Environment Configuration