Enhancer.registerCallbacks(factory, new Callback[] { instance, null });
proxy = (KunderaProxy) factory.newInstance();
}
catch (IllegalAccessException e)
{
throw new LazyInitializationException(e);
}
catch (InstantiationException e)
{
throw new LazyInitializationException(e);
}
finally
{
Enhancer.registerCallbacks(factory, null);
}