Yesterday evening, I've tried to replace the application classloader (the one used to load the application) by one that use an anymous class loader to load the class. And i've tested by launching SwingSet2.
And it doesn't work because UI program like SwingSet lookup their resources like image, icons etc. using getResource()/getResourceAsStream(). getResource() makes the assumption that if getClassLoader() returns null the class is loaded by the bootstrap classloader. In my opinion, getResource() is not the only method that makes this assumption so an anonymous class should be able to specify an external classloader when defined i.e. Unsafe.defineAnonymousClass should take a classloader as argument. Rémi _______________________________________________ mlvm-dev mailing list [email protected] http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
