This week's book giveaway is in the Java 8 forum.
We're giving away four copies of Java 8 in Action and have Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Regarding Current Version? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Regarding Current Version?" Watch "Regarding Current Version?" New topic
Author

Regarding Current Version?

Edward Durai
Ranch Hand

Joined: Oct 09, 2004
Posts: 223
Hello,

1) Could you tell me anyone which is the current version of JDK Version
2) Where can I get recent updates regarding JAVA?

3) Currently i am using JDK1.5. Is any possibility to write a program to know what are the classes and interfaces available in the JDK1.5 Version.

Thank You for answering.
Regards,
Edward


Thank You<br />Edward
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39576
    
  27
You may want to browse around this web page, particularly its "Reference" tab -which leads you to the API documentation- and the "Downloads" tab, from where you can get the latest Java version (which is Java 6).

Information and documentation regarding older Java releases (such as Java 5 a.k.a. 1.5) can be found here.


Ping & DNS - updated with new look and Ping home screen widget
Edward Durai
Ranch Hand

Joined: Oct 09, 2004
Posts: 223
Is it possible to write a java program to listout all the interfaces and classes?

thanks.
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

Is it possible to write a java program to listout all the interfaces and classes?

I do not think any JDK provide such method , but you can try File class which reads javadocs directory , which list all the files which included into Jdk doc directory ,
I am providing a jdk 5 doc directory structure , a which find you all the classes and interfaces !! " F:\jdk-6-doc\docs\api\java " , this is definitely not a optimum solution , but as you need it , this ll help !!


[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39576
    
  27
The JRE comes with all classes bundled in a jar file (it's called classes.jar in my installation). You can open that using the classes in the java.util.jar package and iterate recursively through all the files it contains.

With the bytes you read from the file you can then let a ClassLoader construct Class objects for all classes/interfaces. That allows you to get a wealth of information about each class.

That's definitely not beginner's stuff, though. What are you trying to achieve by knowing which classes exist?
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19556
    
  16

classes.jar? Not rt.jar?

You're not using a Sun JRE / JDK, are you?


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39576
    
  27
Originally posted by Rob Prime:
classes.jar? Not rt.jar?

You're not using a Sun JRE / JDK, are you?

No, I'm not. But the file size (> 20 MB) should distinguish it in any case.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Regarding Current Version?
 
Similar Threads
AXIOM and Jboss4.0.2
Unistall Jdk1.4 in linux machine
Help Axiom jboss 4.0.2
Error in using "assert" in java program....
NoClassDefFoundError