public abstract class AbstractArtifactClassLoader extends FineGrainedControlClassLoader implements ArtifactClassLoader
GoodCitizenClassLoader.NonCachingURLStreamHandlerFactory
Modifier and Type | Field and Description |
---|---|
protected Log |
logger |
protected List<ShutdownListener> |
shutdownListeners |
appName, blocked, overrides, systemPackages
Constructor and Description |
---|
AbstractArtifactClassLoader(URL[] urls,
ClassLoader parent) |
AbstractArtifactClassLoader(URL[] urls,
ClassLoader parent,
Set<String> overrides) |
Modifier and Type | Method and Description |
---|---|
void |
addShutdownListener(ShutdownListener listener)
Adds a shutdown listener to the class loader.
|
protected ResourceReleaser |
createResourceReleaserInstance() |
void |
dispose()
Disposes the
ClassLoader by closing all the resources opened by this ClassLoader . |
URL |
findLocalResource(String resourceName)
This method finds a resource in the local environment for this artifact, if the resource is not found and the
artifact has a parent artifact then the operation is resolved by that parent, if there is no parent, the resources
is searched in the global environment.
|
protected abstract String[] |
getLocalResourceLocations() |
void |
setResourceReleaserClassLocation(String resourceReleaserClassLocation) |
findClass, findParentClass, isBlocked, isOverridden, loadClass, processOverrides
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
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
findResource, getArtifactName, getClassLoader
protected Log logger
protected List<ShutdownListener> shutdownListeners
public AbstractArtifactClassLoader(URL[] urls, ClassLoader parent)
public AbstractArtifactClassLoader(URL[] urls, ClassLoader parent, Set<String> overrides)
public void addShutdownListener(ShutdownListener listener)
ArtifactClassLoader
addShutdownListener
in interface ArtifactClassLoader
public void dispose()
GoodCitizenClassLoader
ClassLoader
by closing all the resources opened by this ClassLoader
.
See URLClassLoader.close()
.dispose
in interface DisposableClassLoader
dispose
in class GoodCitizenClassLoader
public void setResourceReleaserClassLocation(String resourceReleaserClassLocation)
protected ResourceReleaser createResourceReleaserInstance()
public URL findLocalResource(String resourceName)
LocalResourceLocator
findLocalResource
in interface LocalResourceLocator
resourceName
- name of the resource to find.protected abstract String[] getLocalResourceLocations()
Copyright © 2003–2016 MuleSoft, Inc.. All rights reserved.