How to determe JRE build using Java?

M

Mickey Segal

Is there a way to determine the Java build from within Java?

I can do so from the Windows command line using:
java -version
For the latest Sun JRE build I get:
build 1.6.0-rc-b68

However, using "java.version" inside a Java program all I get it:
1.6.0-rc

Is there some way to get the full information from inside Java?
 
C

Chris Uppal

Mickey said:
Is there a way to determine the Java build from within Java?

I don't know how universal it is, but on my 1.5.0.x machines the standard
system property "java.vm.version" is the same as that printed by:
java -fullversion

-- chris
 
M

Mickey Segal

Chris Uppal said:
I don't know how universal it is, but on my 1.5.0.x machines the standard
system property "java.vm.version" is the same as that printed by:
java -fullversion

Thanks. That works. It was not on the list I have of System properties,
but all I need is for it to work on my computers.
 
R

Roedy Green

I can do so from the Windows command line using:
java -version
For the latest Sun JRE build I get:
build 1.6.0-rc-b68

However, using "java.version" inside a Java program all I get it:
1.6.0-rc

Is there some way to get the full information from inside Java?

I think you want the property java.vm.version.

see http://mindprod.com/applets/wassup.html

to browse what's available.
 
M

Mickey Segal

Roedy Green said:
oh dear. What does the console say.

The messages seem to focus on problems finding files. I emailed the full
output to your feedback email address.
 
R

Roedy Green

The messages seem to focus on problems finding files. I emailed the full
output to your feedback email address.

What appears to be happening is URL.getConnection is failing to find a
file and return with null without raising an IOException. I am in the
process of posting a version that checks for that and raises the
exception. However that does not explain why you can't see the files.
From the log you sent, you can see some, but not others. I checked
with ftp. They are there. I can see them from here. I gather something
interferes between you and mindprod.com

It would be interesting to see if this has to do with your connection
or with JRE 1.6.

Has any one else noticed the JDisplay colourised
java/bat/html/sql/ini... listings failing with null pointer exceptions
at mindprod.com?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top