Interface ClassInfoLoader
- All Known Implementing Classes:
ClassFileLoader, JarFileCommitter
public interface ClassInfoLoader
ClassInfoLoader provides an interface for loading classes. Implementing
classes can load classes from a file, from the JVM, or elsewhere.
-
Method Summary
Modifier and TypeMethodDescriptionLoad a class.newClass(int modifiers, int classIndex, int superClassIndex, int[] interfaceIndexes, List constants) Creates a new class or interface.outputStreamFor(ClassInfo info) Returns anOutputStreamto which a class should be written.
-
Method Details
-
loadClass
Load a class.- Parameters:
name- The name of the class to load, including the package name.- Returns:
- A ClassInfo for the class.
- Throws:
ClassNotFoundException- The class cannot be found in the class path.- See Also:
-
newClass
ClassInfo newClass(int modifiers, int classIndex, int superClassIndex, int[] interfaceIndexes, List constants) Creates a new class or interface.- Parameters:
modifiers- The modifiers describing the newly-created classclassIndex- The index of the name of the newly-created class in its constant poolsuperClassIndex- The index of the name of the newly-created class's superclass in its constant poolinterfaceIndexes- The indexes of the names of the interfaces that the newly-created class implementsconstants- The constant pool for the newly created class (a list ofConstants).
-
outputStreamFor
Returns anOutputStreamto which a class should be written.- Throws:
IOException
-