You are on page 1of 24

Java 2 SDK

Sun Microsystems Java Java 2 SDK Java


JDK(Java
Development Kit)
:Java

Personal Personal Personal


Java 1.0 Java 1.1 Java 1.2

Java Platform(JDK) Java 2 Platform(Java 2 SDK)

OAK Java 1.0 Java 1.1 Java 1.2 Java 1.3 Java 1.4

Embedded
Java

JDK Java 2 Platform Java Platform (


JDK Java 2 SDK)
Java Developer Killer Sun

Java 1995 JDK

JDK
JDK
JDK Borland JBuilder Forte for Java
JDK Borland JBuilder
Borland JBuilder JBuilder Java

1
2 SDK:
:Borland JBuilder Java 2 SDK

JDK Java
JDK J2SEJ2EEJ2ME
Java Card
JDK
: Java Java 2 SDK

2
J2EE SDK J2ME SDK Java Card
SDK

J2SE(Java SDK)

JDK ?
JDK
JDK Java JDK
Java java xxx.java
java xxx Java ?
?

JDK !

java.exe
JDK java.exe
:
Java 2 SDK 1.3.x :
Java 2 SDK 1.3.x
java.exe:

3
hotspot
:
path=c:\jdk1.3.1\bin
(: Java 2 SDK 1.3.x c:\jdk1.3.1 )
java.exe:

4
hotspot-server-classic
hotspot-server
-classic path
!
Java 2 SDK JDK 1.4.x :
Java 2 SDK 1.4.x
java.exe:

java.exe client-server-hotspot(-client
) Java
Java

java version
:

5
:
java server -version
:
Error: no `server' JVM at `C:\Program
Files\Java\j2re1.4.0-rc\bin\server\jvm.dll`.
server

:
path=d:\j2sdk1.4.0\bin
(: JDK 1.4.x d:\j2sdk1.4.0 )
:
java server
:

java server -version


:

-server path
!

6
JDK 1.3.x (JDK 1.4.x

):
? ?
Java 2 SDK Java
:
Java 2 SDK Java 2
SDK java.exe :

1.4 1.3

JDKJREJVM
JDK(Java )JRE(Java
Java Runtime Environment) JVM(Java Java
Virtual Machine)
http://www.javasoft.com JDK
JDK JRE
JDK JRE Sun
Microsystems JDK JRE
:
:JDK 1.3.x JRE 1.3.x

7
JDK 1.3.x JRE 1.3.x

JDK
JRE
(
Java Program Files\
JavaSoft
(javac.exe,jar.exe) )

JRE
(JDK
\jre)

JRE
(
Program Files\JavaSoft
)

JDK 1.4.x JDK 1.3.x :


:JDK 1.4.x JRE 1.4.x
JDK 1.4.x JRE 1.4.x

JDK
JRE
(
Java Program Files\
Java
(javac.exe,jar.exe) )

JRE
(JDK
\jre)

JRE
(
Program Files\JavaSoft
)

JDK JRE
<jdk >\jre (JDK 1.3.x 1.4.x )
C:\Program File\JavaSoft (JDK 1.4.x C:\Program
File\Java )
!

8
JDK 1.3.x
JRE
JDK 1.4.x JDK
C:\Program File\Java JRE<jdk >\jre
JRE JDK 1.4.x
JRE JRE C:\Program
File\Java JRE<jdk >\jre JRE

JDK 1.4.x :
: JDK 1.4.x (1)

9

: JDK 1.4.x (2)

10

)
JRE JDK C:\Program
File\JavaSoft (JRE 1.4.x C:\Program File\Java )
JRE
JRE ? JRE :
:JRE PC
JREPC

JRE PC

Java

(.class)

Win32 API
(.dll) (.dll)
Java
CPU
(jvm.dll)

(.dll)

JRE PC Win32
Java
JRE JDK
JRE Java PC
Java Java JRE
Java JRE

JRE
Java (Windows XP Java Windows
XP JRE JRESun
Windows XP JREJDK 1.4.x/JRE 1.4.x Windows
XP)
Sun JDK
JRE ?
? - JDK
Java ( javac.exejar.exe )

11
<jdk >\lib\tools.jar
? Java javac.exe Java ? javac.exe
Java .class
:
javac.exe :

<jdk >\lib\ tools.jar tools1.jar


javac.exe:

javac.exe
java -classpath d:\j2sdk1.4.0\lib\tools.jar com.sun.tools.javac.Main
tools1.jar tools.jar:

12
javac.exe javac.exe
(wrapper)
:
:

1.

2.

JRE
+ (javac.exe)
Tools.jar

3.

java -classpath d:\j2sdk1.4.0\lib\tools.jar com.sun.tools.javac.Main

J2ME Palm
JAR PRC
Java (native).NET
.NET

13

javac.exe JDK
<jdk >\bin
29 KB:
:bin

: JDK Java
JDK Java JDK Java
JRE <jdk >\jre
JRE Program File\ JRE
Java JRE
Java JDK (.exe)
<jdk >\jre JRE
JRE(
Borland JBuilder TogetherJ Java
JRE) JRE
PATH :
java.exe

java.exe ?
JRE JRE ?
java.exe

java XXX

14
java.exe JRE java.exe
JRE:
1. JRE (
JDK )
2. JRE
3. Windows
Registry(HKEY_LOCAL_MACHINE\Software\JavaSoft\Java
Runtime Environment\)
java.exe java.exe
JRE Java
Windows java.exe?
java.exe:
: java.exe

java.exe d:\j2sdk1.4.0\bin java.exe


java.exe (d:\j2sdk1.4.0) JRE(d:\j2sdk1.4.0\jre)
d:\j2sdk1.4.0\jre\bin client server
jvm.dll Java

: Java (hotspot client)

15
: Java (hotspot server)

( : path=d:\jdk1.3.1\bin
d:\jdk1.3.1\jre\bin classichotspot server
jvm.dll)
java server java.exe
d:\j2sdk1.4.0\jre\bin\server JVM java classic
java.exe d:\jdk1.3.1\jre\bin\classic
JVM path=c:\jdk1.3.1\bin

path=d:\j2sdk1.4.0\bin java server

PATH
PATH :

16
java.exe c:\winnt\system32 JRE c:\winnt
JRE Windows Registry
:
:Windows Registry

17
Windows Registry JRE C:\Programm
Foles\Java\j2re1.4.0-rc bin client
server :

java.exe JRE bin


server JDK 1.3.x
java.exe Registry 1.3.x JRE
bin client
java.exe JRE
java.exe JRE

18
1.3.x JDK java.exe java.exe 1.4.x JRE
:

Java
Java :
1. java.exe
2. java.exe JRE

JRE PC JRE Java


JRE Java
:
PC Notebook Notebook DirectX
PC DirectX PC DirectX
PC ()
Notebook
Notebook -

Java JRE
JRE A JRE
Java B JRE

java.exe java.exe
JRE
:
Java PATH
PATH <jdk >\bin\
java.exe Windows NT/2000/XP :

19

:

JDK 1.3.1 D
d:\jdk1.3.1\bin Java

20
JRE
Java
( JAR )<JRE >\lib\ext
<jdk >\jre\lib\ext :

Java Java
<JRE >\lib\security
JVM <jdk
>\jre\lib\security :

Java
Java (

21
ClassNotFoundException)
Java

(
)
java.exe(? C:\winnt\system32 d:\jdk1.3.1\bin
java.exe) Java d:\jdk1.3.1\bin
javac.exe javac.exe JDK
JRE<jdk >\jre\lib\ext
JVM
PATH java XXX
c:\winnt\system32 java.exe
c:\program files JRE Java
c:\program files JRE
lib\ext Java
c:\program files JRE
lib\security
PATH :

javac.exe java.exe JDK


JDK JRE
:

22

JDKJRE JVM

23
Java

JDKJRE JVM

24