using Kaffe with VisualAge, incompatability with Sun JDK
grunwald at pa.dec.com
Tue Feb 2 12:54:44 PST 1999
IBM VisualAge for Java uses the following idiom to launch create a
Class iiCls = Class.forName("ProjectDemo");
ClassLoader iiClsLoader = iiCls.getClassLoader();
aProjectDemo = (ProjectDemo)java.beans.Beans.instantiate(iiClsLoader,"ProjectDemo");
The JDK documentation (chan, lee & kramer) state that
Class.getClassLoader() should either return the loader for this class
or null if the default loader was used.
This is what Kaffe does. Note that IBM VA doesn't check for this
condition (their fault). However, the Sun JDK on my DEC Alpha sez..
iiClsLoader = sun.misc.Launcher$AppClassLoader at 1d8c8e58
when I print the value of iiClsLoader.
I think it would be useful to conform to this convention, otherside
you can't run IBM VA-based applications w/o changes.
Dirk Grunwald, visiting Compaq-WRL from Univ. of Colorado
More information about the kaffe