|
JBoss ClassPool Parent POM 1.0.0.GA | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavassist.ClassPool
org.jboss.classpool.scoped.ScopedClassPool
public class ScopedClassPool
A scoped class pool.
Field Summary | |
---|---|
protected WeakReference<ClassLoader> |
classLoader
|
protected javassist.LoaderClassPath |
classPath
|
protected ScopedClassPoolRepository |
repository
|
protected SoftValueHashMap |
softcache
|
Fields inherited from class javassist.ClassPool |
---|
childFirstLookup, classes, doPruning, parent, releaseUnmodifiedClassFile, source |
Constructor Summary | |
---|---|
protected |
ScopedClassPool(ClassLoader cl,
javassist.ClassPool src,
ScopedClassPoolRepository repository,
boolean isTemp)
Creates a new ScopedClassPool. |
Method Summary | |
---|---|
protected void |
cacheCtClass(String classname,
javassist.CtClass c,
boolean dynamic)
Caches a class |
void |
close()
Closes the class pool |
void |
flushClass(String classname)
Flushes a class. |
protected javassist.CtClass |
getCached(String classname)
Get the cached class |
protected javassist.CtClass |
getCachedLocally(String classname)
Returns the class if it is cached in this pool. |
ClassLoader |
getClassLoader()
Gets the class loader |
protected ClassLoader |
getClassLoader0()
|
javassist.CtClass |
getLocally(String classname)
Gets any local copy of the class |
boolean |
isUnloadedClassLoader()
Whether the classloader is loader |
void |
lockInCache(javassist.CtClass c)
Locks a class into the cache |
void |
soften(javassist.CtClass clazz)
Softens a class |
Class<?> |
toClass(javassist.CtClass ct,
ClassLoader loader,
ProtectionDomain domain)
Converts a javassist class to a java class |
Methods inherited from class javassist.ClassPool |
---|
appendClassPath, appendClassPath, appendPathList, appendSystemPath, clearImportedPackages, createCtClass, find, get, get, get0, getAndRename, getCtClass, getDefault, getImportedPackages, getMethod, getOrNull, importPackage, insertClassPath, insertClassPath, lookupCflow, makeClass, makeClass, makeClass, makeClass, makeClassIfNew, makeInterface, makeInterface, recordInvalidClassName, removeCached, removeClassPath, toClass, toClass, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected ScopedClassPoolRepository repository
protected WeakReference<ClassLoader> classLoader
protected javassist.LoaderClassPath classPath
protected SoftValueHashMap softcache
Constructor Detail |
---|
protected ScopedClassPool(ClassLoader cl, javassist.ClassPool src, ScopedClassPoolRepository repository, boolean isTemp)
cl
- the classloadersrc
- the original class poolrepository
- the repositoryisTemp
- whether this is a temporary pool used to
resolve referencesMethod Detail |
---|
public ClassLoader getClassLoader()
getClassLoader
in class javassist.ClassPool
protected ClassLoader getClassLoader0()
public void close()
public void flushClass(String classname)
classname
- the class to flushpublic void soften(javassist.CtClass clazz)
clazz
- the classpublic boolean isUnloadedClassLoader()
protected javassist.CtClass getCached(String classname)
getCached
in class javassist.ClassPool
classname
- the class name
protected void cacheCtClass(String classname, javassist.CtClass c, boolean dynamic)
cacheCtClass
in class javassist.ClassPool
classname
- the class namec
- the ctClassdynamic
- whether the class is dynamically generatedpublic void lockInCache(javassist.CtClass c)
c
- the classprotected javassist.CtClass getCachedLocally(String classname)
classname
- the class name
public javassist.CtClass getLocally(String classname) throws javassist.NotFoundException
classname
- the class name
javassist.NotFoundException
- when the class is not foundpublic Class<?> toClass(javassist.CtClass ct, ClassLoader loader, ProtectionDomain domain) throws javassist.CannotCompileException
toClass
in class javassist.ClassPool
ct
- the javassist classloader
- the loader
javassist.CannotCompileException
- for any error
|
JBoss ClassPool Parent POM 1.0.0.GA | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |