Solved

classes.zip

Posted on 2000-03-28
4
650 Views
Last Modified: 2011-10-03
Hi all

I am new to Java, so please enlighten me on this simple question about classpath.

I have read from documents that for JDK 1.x, the classpath points to the jdk1.x/lib/classes.zip.

However, for JDK2, there is no such zip file. What is the equivalent file, and additional files I should point to?

Keith
0
Comment
Question by:keithcsl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 1

Accepted Solution

by:
computerpunk earned 50 total points
ID: 2665932
From what I know ,
The files that you should point to are :
src.jar that is located at the root of your JDK2 directory
dt.jar,tools.jar located at the lib directory
Java has changed from the zip format to the jar (Java ARchive) format which is basically the same as before.
Hope this helps ;)

Just in case you wanted to know : The equivalent file of classes.zip is src.jar if I have not mistaken.
0
 
LVL 4

Expert Comment

by:jerch
ID: 2666121
Hi keithcsl...
The src.jar contains the source code of the core Java API. In JDK 1.2.x, you don't actually have to set the classpath. It will automatcally search the packages in <install directory>\jdk1.2.x\lib.

best regards...
Jerson
0
 
LVL 19

Expert Comment

by:Jim Cakalic
ID: 2666652
The class files are now packaged in rt.jar. You should find this in the jre/lib directory beneath wherever you chose to install the JDK. This should be all that the JDK itself requires. As Jerson notes, you should not have to explicitly add the runtime jar to your CLASSPATH.

Most vendors and even open source distributors are now packaging in jar files. For any such products you want to use, you will add an entry to CLASSPATH that provides a full path up to and including the jar file.

Best regards,
Jim Cakalic
0
 
LVL 1

Author Comment

by:keithcsl
ID: 2691490
ahhh, thank you all. and to jerch and jim_cakalic, yes, i do not need to explicitly load the class path. it's done automatically. thank you for that info.

Keith
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
The viewer will learn how to implement Singleton Design Pattern in Java.
Suggested Courses

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question