[Swingwt-developers] With Java 1.5 code...
Status: Beta
Brought to you by:
bobintetley
From: <jc...@um...> - 2005-07-06 19:37:23
|
Hi, My application uses JDNC (www.javadesktop.org) for Java 5.0 (Sun JVM internal ver. 1.5.0_03). I'm trying to avoid modifying the source code of JDNC, which uses Swing/AWT, and I want it to use SwingWT instead. A few of the libraries were compiled for Java 1.5, and thus they may use generics. Generics, I believe, are the source (no pun intended) of my woes. :-) In the absence of any new 1.5 types (generic types that have been specified, i.e. Map.Entry<String,Integer>) I assume the dynamic class loader would work fine with JVM 1.5. However, I have just tried using generics in my own project source, and I receive the same fatal error as I was getting out of JDNC 0.7. Does anyone have any insight as to how I could modify the custom ClassLoader that SwingWT uses, so that it would recognize generic types on the Java 5.0 platform? Thanks, Sean Exception trace follows: SwingWTBootstrap.main has been called 0 times. SwingWT BootStrap, Copyright(c)2004 R.Rawson-Tetley This program uses classloading code from the WebOnSwing (http://webonswing.sourceforge.net) and Apache BCEL projects. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public Licence for more details. java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at swingwt.classloader.SwingWTBootstrap.main(SwingWTBootstrap.java:75) at formEngine.Driver.main(Driver.java:23) Caused by: java.lang.ClassFormatError: LVTT entry for 'grook' //AUTHOR'S ANNOTATION: grook is a local variable of type //Map.Entry<Mapping,Mapping> where Mapping extends Object. in class file formEngine/BasicFormModel does not match any LVT entry at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(Unknown Source) at java.lang.ClassLoader.defineClass(Unknown Source) at swingwt.classloader.SwingWTClassLoader.transform(SwingWTClassLoader.java:93) at swingwt.classloader.SwingWTClassLoader.findClass(SwingWTClassLoader.java:64) at swingwt.classloader.SwingWTClassLoader.loadClass(SwingWTClassLoader.java:106) at swingwt.classloader.SwingWTClassLoader.loadClass(SwingWTClassLoader.java:74) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(Unknown Source) at java.lang.ClassLoader.defineClass(Unknown Source) at swingwt.classloader.SwingWTClassLoader.transform(SwingWTClassLoader.java:93) at swingwt.classloader.SwingWTClassLoader.findClass(SwingWTClassLoader.java:64) at swingwt.classloader.SwingWTClassLoader.loadClass(SwingWTClassLoader.java:106) at swingwt.classloader.SwingWTClassLoader.loadClass(SwingWTClassLoader.java:74) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at formEngine.SubDriver.main(SubDriver.java:23) ... 6 more |