On Fri, 2006-03-10 at 16:30 -0600, Wayne Fay wrote: > I have a solution... Everyone should just use JDK 1.5. ;-) > > PS Sanjay, you can find out what version a given class was compiled if > you look at the unsigned short integers starting at byte offset 4, > right after 0xCAFEBABE in every class file. See this Javaworld article > for more details, page 2: > http://www.javaworld.com/javaqa/2003-05/02-qa-0523-version.html
An easier way to find the classfile version is to run javap -classpath {jarfile} -verbose {classname} eg javap -verbose java.lang.String For javap v1.4 or later the output includes: ... minor version: 0 major version: 49 ... These versions mean this particular String can only be run with java 1.5 or later. I did see an official document somewhere that listed the actual versions (the vm spec?) but this doc has enough info: http://alumnus.caltech.edu/~leif/opensource/bcver/BcVerApp.html Cheers, Simon --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]