public class PluginClassLoader extends URLClassLoader
PluginClassLoader is a child-first classloader that only
contains classes of the runtime libraries setuped in the plugin manifest file
and exported libraries of plugins that are required plugins. Libraries can be
exported or not. Not exported libraries are only used in the plugin own
PluginClassLoader. Exported libraries are available for
PluginClassLoader of plugins that depends on these plugins.| Constructor and Description |
|---|
PluginClassLoader(URL[] urls,
ClassLoader parent)
Construtor
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
URL |
getResource(String name) |
InputStream |
getResourceAsStream(String name) |
Enumeration<URL> |
getResources(String name) |
int |
hashCode() |
protected Class<?> |
loadClass(String name,
boolean resolve) |
addURL, close, definePackage, findClass, findResource, findResources, getPermissions, getURLs, newInstance, newInstancedefineClass, defineClassclearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSignerspublic PluginClassLoader(URL[] urls, ClassLoader parent)
urls - Array of urls with own libraries and all exported libraries of
plugins that are required to this pluginparent - protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException
loadClass in class ClassLoaderClassNotFoundExceptionpublic URL getResource(String name)
getResource in class ClassLoaderpublic Enumeration<URL> getResources(String name) throws IOException
getResources in class ClassLoaderIOExceptionpublic InputStream getResourceAsStream(String name)
getResourceAsStream in class URLClassLoaderCopyright © 2021 The Apache Software Foundation