Using Java JAR file in .NET.

What options / methods / software are available to convert a JAR file into a managed .NET assembly? Please provide all commercial and non-commercial methods in response. They do not include solutions requiring Java installation on the host machine.

+7
java jar managed
source share
2 answers

I could be wrong, but I'm sure this is impossible. The java byte code is different from the code created to run in the CLR.

Answer Snarky . Get the source code and put it.

EDIT: A little tailcoat comes up with http://sourceforge.net/projects/ikvm/ , an implementation of the Java virtual machine for .NET. Not quite what you asked for, but it will probably be the best thing you can do.

+9
source share

Last year, faced with this situation, I wrote a small wrapper (in java) that read the inputs from a temporary file, call the jar and put the output in the temther temp file. The .NET project will create an input file, invoke the JVM and start the shell, wait for it to finish and read the output file. Quick and dirty. at least in my case

-one
source share

All Articles