/**
* The major version number of class files created
- * from scratch. The value is 45 (JDK 1.1).
+ * from scratch. The value is 47 (JDK 1.3).
*/
- public static final int MAJOR_VERSION = 45;
+ public static final int MAJOR_VERSION = 47;
/**
* Constructs a class file from a byte stream.
*/
public ClassFile(boolean isInterface, String classname, String superclass) {
major = MAJOR_VERSION;
- minor = 3; // JDK 1.1 or later
+ minor = 0; // JDK 1.3 or later
constPool = new ConstPool(classname);
thisClass = constPool.getThisClassInfo();
if (isInterface)
/* Code generator methods depending on javassist.* classes.
*/
public class MemberCodeGen extends CodeGen {
- public static final int JAVA1_VER = 45;
public static final int JAVA5_VER = 49;
- public static final int JAVA6_VER = 50;
protected MemberResolver resolver;
protected CtClass thisClass;
public int getMajorVersion() {
ClassFile cf = thisClass.getClassFile2();
if (cf == null)
- return JAVA1_VER;
+ return ClassFile.MAJOR_VERSION; // JDK 1.3
else
return cf.getMajorVersion();
}