Re: [Ikvm-developers] Run java code on no-java environment
Brought to you by:
jfrijters
|
From: Maxim D. <Ma...@so...> - 2012-11-08 11:36:22
|
Quentin, thanks a lot. This worked perfect. Maxim From: Quentin Anciaux [mailto:all...@gm...] Sent: Tuesday, November 06, 2012 12:01 PM To: Maxim Donde Cc: ikv...@li... Subject: Re: [Ikvm-developers] Run java code on no-java environment Then add a jar with that file in the META-INF/services, the content of the file should be the classname of the transformer factory you whish to use. Or set the system property "javax.xml.transform.TransformerFactory"with the classname of the transformer factory you whish to use. (-Djavax.xml.transform.TransformerFactory=classname) Regards, Quentin 2012/11/6 Maxim Donde <Ma...@so...> Thanks Quentin, But unfortunately there is no jar with this file found. What else could be done? Thanks, Maxim From: Quentin Anciaux [mailto:all...@gm...] Sent: Tuesday, November 06, 2012 11:43 AM To: Maxim Donde Cc: ikv...@li... Subject: Re: [Ikvm-developers] Run java code on no-java environment The file is META-INF/services/javax.xml.transform.TransformerFactory not transform. Regards, Quentin Anciaux 2012/11/6 Quentin Anciaux <all...@gm...> Hi, simply check if one jar that you are using has a META-INF/services/javax.xml.parsers.transform file in it. If so, it is the culprit that contains the class not found., remove the file from the jar and it should then work. Regards, Quentin Anciaux 2012/11/6 Maxim Donde <Ma...@so...> Thank Michael, I checked my code and I don’t have any reference to specific Sun JDK classes but it is very possible that 3rd party libraries that I’m using like XStream or apache.commons.configuration do. What can be done in this case? Thanks, Maxim From: Michael Kay [mailto:mi...@sa...] Sent: Tuesday, November 06, 2012 10:50 AM To: ikv...@li... Subject: Re: [Ikvm-developers] Run java code on no-java environment I would need to check the detail, but it's possible that your code has an explicit reference to a class that's present in the Sun JDK but not in the OpenJDK. If you use the standard TraX TransformerFactory mechanism to load your XSLT engine it should work fine. Of course a better alternative might be to switch from Xalan to Saxon, which supports XSLT 2.0, is faster, and already exists as an IKVM-compiled assembly, with additional code designed to provide an interface to the .NET world (for example, Saxon lets you transform a Microsoft DOM, which you won't be able to do with Xalan). Michael Kay Saxonica On 05/11/2012 22:15, Maxim Donde wrote: Hi all, I’m using IKVM successfully to call my Java code from C# and vice versa. Everything works fine on the computer where I have JDK installed but when I try to run the same application on the computer without JDK I get exception that “Provider com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl not found”. I added rt.jar to be compiled as part of my dll (I compile all jars into single dll) but the problem persists. What can be done without installing JDK? Thanks in advance, Maxim ------------------------------------------------------------------------------ LogMeIn Central: Instant, anywhere, Remote PC access and management. Stay in control, update software, and manage PCs from one command center Diagnose problems and improve visibility into emerging IT issues Automate, monitor and manage. Do more in less time with Central http://p.sf.net/sfu/logmein12331_d2d _______________________________________________ Ikvm-developers mailing list Ikv...@li... https://lists.sourceforge.net/lists/listinfo/ikvm-developers ------------------------------------------------------------------------------ LogMeIn Central: Instant, anywhere, Remote PC access and management. Stay in control, update software, and manage PCs from one command center Diagnose problems and improve visibility into emerging IT issues Automate, monitor and manage. Do more in less time with Central http://p.sf.net/sfu/logmein12331_d2d _______________________________________________ Ikvm-developers mailing list Ikv...@li... https://lists.sourceforge.net/lists/listinfo/ikvm-developers -- All those moments will be lost in time, like tears in rain. -- All those moments will be lost in time, like tears in rain. -- All those moments will be lost in time, like tears in rain. |