Class ResourceStoreClassLoader
java.lang.Object
java.lang.ClassLoader
org.nuxeo.ecm.webengine.loader.store.ResourceStoreClassLoader
- All Implemented Interfaces:
Cloneable
The class loader allows modifying the stores (adding/removing). Mutable operations are thread safe.
- Author:
- Bogdan Stefanescu
-
Constructor Summary
ModifierConstructorDescriptionResourceStoreClassLoader
(ClassLoader pParent) protected
ResourceStoreClassLoader
(ClassLoader pParent, LinkedHashSet<ResourceStore> cp) -
Method Summary
Modifier and TypeMethodDescriptionboolean
addStore
(ResourceStore store) clone()
static String
convertClassToResourcePath
(String pName) org.my.Class -> org/my/Class.classprotected void
doDefinePackage
(String name) Without this method getPackage() returns nullprotected Class<?>
fastFindClass
(String name) protected Class<?>
protected URL
findResource
(String name) protected Enumeration<URL>
findResources
(String name) protected String
getId()
getResource
(String name) getResources
(String name) Class<?>
boolean
removeStore
(ResourceStore store) Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findSystemClass, getClassLoadingLock, getDefinedPackage, getDefinedPackages, getName, getPackage, getPackages, getParent, getPlatformClassLoader, getResourceAsStream, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, getUnnamedModule, isRegisteredAsParallelCapable, loadClass, registerAsParallelCapable, resolveClass, resources, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
-
Constructor Details
-
ResourceStoreClassLoader
-
ResourceStoreClassLoader
-
-
Method Details
-
addStore
-
removeStore
-
clone
-
getStores
-
fastFindClass
-
doDefinePackage
Without this method getPackage() returns null -
findResource
- Overrides:
findResource
in classClassLoader
-
findResources
- Overrides:
findResources
in classClassLoader
- Throws:
IOException
-
loadClass
- Overrides:
loadClass
in classClassLoader
- Throws:
ClassNotFoundException
-
findClass
- Overrides:
findClass
in classClassLoader
- Throws:
ClassNotFoundException
-
getResources
- Overrides:
getResources
in classClassLoader
- Throws:
IOException
-
getResource
- Overrides:
getResource
in classClassLoader
-
getId
-
convertClassToResourcePath
org.my.Class -> org/my/Class.class
-