Can I inspect java code and determine what runtime it will be able to run on? For instance I want to make sure all applications in our environment are using Sun SE6 and JDK 1.6.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
When you run the “javap -verbose” on any class, you will get a major and a minor version numbers. Following is a mapping between major+minor to an actual java jre version.
If you want to programatically get the class version, you can follow this link:
Java API to find out the JDK version a class file is compiled for?