public class YURLClassLoader extends URLClassLoader
| Modifier and Type | Class and Description |
|---|---|
protected static class |
YURLClassLoader.TYPE |
| Constructor and Description |
|---|
YURLClassLoader(URL[] urls) |
YURLClassLoader(URL[] urls,
ClassLoader parent) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addClassPathURLs(List<URL> urls,
String classpath) |
protected URL |
buildURL(File f,
YURLClassLoader.TYPE type) |
void |
clearAllReferences()
Null out any static or final fields from loaded classes, as a workaround for apparent garbage collection bugs
|
URL |
findResource(String name) |
protected Class<?> |
loadClass(String name,
boolean resolve)
overridden to maintain a list of classes that are loaded by this (or a child) Classloader to be able to clear
references of this classes (during stop() ) In addition to that we hold a list of ALL loaded classes as a cache.
|
void |
start() |
void |
stop()
Stops this classloader.
|
addURL, close, definePackage, findClass, findResources, getPermissions, getResourceAsStream, getURLs, newInstance, newInstancedefineClass, defineClassclearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSignerspublic YURLClassLoader(URL[] urls)
public YURLClassLoader(URL[] urls, ClassLoader parent)
protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
loadClass in class ClassLoaderClassNotFoundExceptionpublic URL findResource(String name)
findResource in class URLClassLoaderpublic void start()
public void stop()
public void clearAllReferences()
protected void addClassPathURLs(List<URL> urls, String classpath) throws MalformedURLException
MalformedURLExceptionprotected URL buildURL(File f, YURLClassLoader.TYPE type) throws MalformedURLException
MalformedURLExceptionCopyright © 2017 SAP SE. All Rights Reserved.