public class ClassVersionSetter extends java.lang.Object implements ClassVisitor
ClassVisitor
sets the version number of the program classes that it visits.Constructor and Description |
---|
ClassVersionSetter(int classVersion)
Creates a new ClassVersionSetter.
|
ClassVersionSetter(int classVersion,
java.util.Set<java.lang.Integer> newerClassVersions)
Creates a new ClassVersionSetter that also stores any newer class version numbers that it
encounters while visiting program classes.
|
Modifier and Type | Method and Description |
---|---|
void |
visitAnyClass(Clazz clazz)
Visits any Clazz instance.
|
void |
visitProgramClass(ProgramClass programClass) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
visitLibraryClass
public ClassVersionSetter(int classVersion)
classVersion
- the class version number.public ClassVersionSetter(int classVersion, java.util.Set<java.lang.Integer> newerClassVersions)
classVersion
- the class version number.newerClassVersions
- the Set
in which newer class version numbers can be
collected.public void visitAnyClass(Clazz clazz)
ClassVisitor
visitAnyClass
in interface ClassVisitor
public void visitProgramClass(ProgramClass programClass)
visitProgramClass
in interface ClassVisitor