Java Reference
In-Depth Information
Root directory
Contains a jar file
containing source
jdk 1.4
bin
demo
include
include-old
jre
lib
Compiler
Interpreter
+
other
executives
Subdirectories
containing
demo code
C header files
for native
code
Executeable for runtime
Class libraries
lib
bin
ext
jar files containing
extensions
Security
classic
JVM DLL
hotspot
applet
Hotspot JVM
DLL
The jdk1.4 directory in the diagram is sometimes referred to as the root directory for Java. In some
contexts it is also referred to as the Java home directory . If you want the documentation installed in the
hierarchy shown above, then you should now extract the documentation from the archive to the
jdk1.4 directory. This corresponds to C:\jdk1.4 if you installed the SDK to your C: drive. This will
create a new subdirectory, docs , to the jdk1.4 root directory, and install the documentation files in
that. To look at the documentation you just open the index.html file that is in the docs subdirectory.
You don't need to worry about the contents of most of these directories, at least not when you get
started, but you should add the path for the jdk1.4\bin directory to the paths defined in your PATH
environment variable. That way you will be able to run the compiler and the interpreter from anywhere
without having to specify supplying the path to it. If you installed the SDK to C: , then you need to add
the path C:\jdk1.4\bin . A word of warning - if you have previously installed a commercial Java
development product, check that it has not modified your PATH environment variable to include the
path to its own Java executables.
If it has, when you try to run the Java compiler or interpreter, you are likely to get the versions supplied
with the commercial product rather that those that came with the SDK. One way to fix this is to remove
the path or paths that cause the problem. If you don't want to remove the paths that were inserted for
the commercial product, you will have to use the full path specification when you want to run the
compiler or interpreter from the SDK. The jre directory contains the Java Runtime facilities that are
used when you execute a Java program. The classes in the Java libraries are stored in the jre\lib
directory. They don't appear individually though. They are all packaged up in the archive, rt.jar .
Leave this alone. The Java Runtime takes care of retrieving what it needs from the archive when your
program executes.
Search WWH ::




Custom Search