public class NonDelegatingClassLoader extends PathClassLoader
The name for this class is not quite correct; it will delegate to its parent if it doesn't find a given class.
Constructor and Description |
---|
NonDelegatingClassLoader(String path,
ClassLoader parent) |
Modifier and Type | Method and Description |
---|---|
Class |
findClass(String name)
Find the given class in the search path.
|
protected Class |
loadClass(String name,
boolean resolve)
Load the given class, but attempt to load before the parent if
shouldDelegate returns false for the given class.
|
protected boolean |
shouldDelegate(String name)
Returns whether the given class should be given to the parent class
loader to try before this one does.
|
convertPathToFilenames, convertPathToFilenames, convertPathToFiles, getClassPath, getURLs, toString
addURL, close, definePackage, findResource, findResources, getPermissions, getResourceAsStream, getURLs, newInstance, newInstance
defineClass, defineClass
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
public NonDelegatingClassLoader(String path, ClassLoader parent)
protected boolean shouldDelegate(String name)
public Class findClass(String name) throws ClassNotFoundException
findClass
in class URLClassLoader
ClassNotFoundException
protected Class loadClass(String name, boolean resolve) throws ClassNotFoundException
loadClass
in class PathClassLoader
ClassNotFoundException
Abbot is hosted on