Package gw.internal.gosu.compiler
Class SingleServingGosuClassLoader
- java.lang.Object
-
- java.lang.ClassLoader
-
- gw.internal.gosu.compiler.SingleServingGosuClassLoader
-
- All Implemented Interfaces:
IGosuClassLoader
- Direct Known Subclasses:
DiscreteClassLoader
public class SingleServingGosuClassLoader extends ClassLoader implements IGosuClassLoader
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
assignParent(ClassLoader classLoader)
static void
clearCache()
static void
clearCache(String gosuClassName)
Class
defineClass(String name, byte[] bytes)
void
dumpAllClasses()
void
evictLoader(String packageName)
Class<?>
findClass(String strName)
ClassLoader
getActualLoader()
byte[]
getBytes(ICompilableType gsClass)
static Class
getCached(ICompilableType gsClass)
IJavaType
getFunctionClassForArity(boolean hasReturn, int length)
boolean
isDisposed()
protected Class<?>
loadClass(String name, boolean resolve)
protected void
unload(String gosuClassName)
boolean
waitForLoaderToUnload(String packageName, long millisToWait)
-
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findResource, findResources, findSystemClass, getClassLoadingLock, getDefinedPackage, getDefinedPackages, getName, getPackage, getPackages, getParent, getPlatformClassLoader, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, getUnnamedModule, isRegisteredAsParallelCapable, loadClass, registerAsParallelCapable, resolveClass, resources, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface gw.lang.reflect.gs.IGosuClassLoader
loadClass
-
-
-
-
Method Detail
-
getCached
public static Class getCached(ICompilableType gsClass)
-
clearCache
public static void clearCache()
-
clearCache
public static void clearCache(String gosuClassName)
-
findClass
public Class<?> findClass(String strName) throws ClassNotFoundException
- Specified by:
findClass
in interfaceIGosuClassLoader
- Overrides:
findClass
in classClassLoader
- Throws:
ClassNotFoundException
-
unload
protected void unload(String gosuClassName)
-
loadClass
protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
- Overrides:
loadClass
in classClassLoader
- Throws:
ClassNotFoundException
-
dumpAllClasses
public void dumpAllClasses()
- Specified by:
dumpAllClasses
in interfaceIGosuClassLoader
-
waitForLoaderToUnload
public boolean waitForLoaderToUnload(String packageName, long millisToWait)
- Specified by:
waitForLoaderToUnload
in interfaceIGosuClassLoader
-
evictLoader
public void evictLoader(String packageName)
- Specified by:
evictLoader
in interfaceIGosuClassLoader
-
getFunctionClassForArity
public IJavaType getFunctionClassForArity(boolean hasReturn, int length)
- Specified by:
getFunctionClassForArity
in interfaceIGosuClassLoader
-
getActualLoader
public ClassLoader getActualLoader()
- Specified by:
getActualLoader
in interfaceIGosuClassLoader
-
defineClass
public Class defineClass(String name, byte[] bytes)
- Specified by:
defineClass
in interfaceIGosuClassLoader
-
getBytes
public byte[] getBytes(ICompilableType gsClass)
- Specified by:
getBytes
in interfaceIGosuClassLoader
-
assignParent
public void assignParent(ClassLoader classLoader)
- Specified by:
assignParent
in interfaceIGosuClassLoader
-
isDisposed
public boolean isDisposed()
-
-