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 voidassignParent(ClassLoader classLoader)static voidclearCache()static voidclearCache(String gosuClassName)ClassdefineClass(String name, byte[] bytes)voiddumpAllClasses()voidevictLoader(String packageName)Class<?>findClass(String strName)ClassLoadergetActualLoader()byte[]getBytes(ICompilableType gsClass)static ClassgetCached(ICompilableType gsClass)IJavaTypegetFunctionClassForArity(boolean hasReturn, int length)booleanisDisposed()protected Class<?>loadClass(String name, boolean resolve)protected voidunload(String gosuClassName)booleanwaitForLoaderToUnload(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:
findClassin interfaceIGosuClassLoader- Overrides:
findClassin classClassLoader- Throws:
ClassNotFoundException
-
unload
protected void unload(String gosuClassName)
-
loadClass
protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
- Overrides:
loadClassin classClassLoader- Throws:
ClassNotFoundException
-
dumpAllClasses
public void dumpAllClasses()
- Specified by:
dumpAllClassesin interfaceIGosuClassLoader
-
waitForLoaderToUnload
public boolean waitForLoaderToUnload(String packageName, long millisToWait)
- Specified by:
waitForLoaderToUnloadin interfaceIGosuClassLoader
-
evictLoader
public void evictLoader(String packageName)
- Specified by:
evictLoaderin interfaceIGosuClassLoader
-
getFunctionClassForArity
public IJavaType getFunctionClassForArity(boolean hasReturn, int length)
- Specified by:
getFunctionClassForArityin interfaceIGosuClassLoader
-
getActualLoader
public ClassLoader getActualLoader()
- Specified by:
getActualLoaderin interfaceIGosuClassLoader
-
defineClass
public Class defineClass(String name, byte[] bytes)
- Specified by:
defineClassin interfaceIGosuClassLoader
-
getBytes
public byte[] getBytes(ICompilableType gsClass)
- Specified by:
getBytesin interfaceIGosuClassLoader
-
assignParent
public void assignParent(ClassLoader classLoader)
- Specified by:
assignParentin interfaceIGosuClassLoader
-
isDisposed
public boolean isDisposed()
-
-