• Post Reply Bookmark Topic Watch Topic
  • New Topic

How can we get the file version  RSS feed

 
saikrishna cinux
Ranch Hand
Posts: 689
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey i have 2 files in which one of files compiled by jdk1.4 version and the other jdk 1.5 versions the 2 files has same name..
my fnd uses jdk1.5

when i give him class file which was compiled by jdk 1.5 version he gets an error msg when ran with jdk1.4 version..
so is there any way to see the compiler version of a class file by which it is compiled???

thanking u all in advace
cinux
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24217
38
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The "javap" program (in the JDK) can tell you this: try

javap -verbose com.package.ClassName

The class file version will be on one of the first few lines.
 
saikrishna cinux
Ranch Hand
Posts: 689
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey it is displaying these line swhen i run tha javaprofiler tool

minor version: 0
major version: 0

is there nay other way to get the files version

thanx
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!