public class ClassFileLoader
extends java.lang.Object
| Constructor and Description |
|---|
ClassFileLoader(java.lang.ClassLoader loader)
Create a new instance
|
| Modifier and Type | Method and Description |
|---|---|
void |
cache(ClassFile classFile)
Add a class file to the weak cache.
|
ClassFile |
get(java.lang.String className)
Get the ClassFile from cache or load it.
|
public ClassFileLoader(java.lang.ClassLoader loader)
loader - the classloader to find the *.class files@Nullable public ClassFile get(java.lang.String className) throws java.io.IOException
className - the class namejava.io.IOException - If any I/O error occurpublic void cache(@Nonnull
ClassFile classFile)
classFile - the class file