Class BundleDelegatingClassLoader

java.lang.Object
java.lang.ClassLoader
org.eclipse.jetty.osgi.util.BundleDelegatingClassLoader
All Implemented Interfaces:
org.osgi.framework.BundleReference

public class BundleDelegatingClassLoader extends ClassLoader implements org.osgi.framework.BundleReference
BundleDelegatingClassLoader

A ClassLoader that delegates to an OSGi Bundle using the standard OSGi specification API methods (Bundle.loadClass, Bundle.getResource, Bundle.getResources) instead of using reflection to access internal container-specific classloaders.

When the first class is loaded, this classloader obtains the real bundle classloader from that class and delegates to it for subsequent operations, providing better compatibility and performance for classloader-specific operations.