public abstract class ClassLoaderFactory
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private static InternalAopClassLoaderFactory |
aopClassLoaderFactory
plug-able, private, class loader factory
|
private static BundleClassLoaderFactory |
bundleClassLoaderFactory
plug-able, private, bundle loader factory
|
| Constructor and Description |
|---|
ClassLoaderFactory() |
| Modifier and Type | Method and Description |
|---|---|
static ChainedClassLoader |
getAopClassLoaderFor(java.lang.ClassLoader classLoader)
Returns the standard, extended AOP class loader based on the given class
loader.
|
static java.lang.ClassLoader |
getBundleClassLoaderFor(org.osgi.framework.Bundle bundle)
Returns the wrapped class loader for the given bundle.
|
private static InternalAopClassLoaderFactory aopClassLoaderFactory
private static BundleClassLoaderFactory bundleClassLoaderFactory
public static ChainedClassLoader getAopClassLoaderFor(java.lang.ClassLoader classLoader)
classLoader - base class loaderpublic static java.lang.ClassLoader getBundleClassLoaderFor(org.osgi.framework.Bundle bundle)
getAopClassLoaderFor(ClassLoader)
but considers the BundleDelegatingClassLoader associated with a
bundle. Namely, the implementation will check if there is a wrapping
class loader associated with the given bundle, creating one if none if
found.
Useful when creating importers/exporters programmatically.bundle - OSGi bundle