public class JdkProxyFactory implements ProxyFactory {
public Object createProxy(final Bundle bundle,
final Class[] classes,
final Callable<Object> dispatcher) {
return Proxy.newProxyInstance(new BundleToClassLoaderAdapter(bundle), classes,
new InvocationHandler() {
public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
try {
return method.invoke(dispatcher.call(), args);
} catch (InvocationTargetException ite) {