Are there any tools to convert Java to C#? [duplicate]
Possible Duplicate:
Where can I find a Java to C# converter?
Are there any free converters or tools that can convert java projects to C#? I hav开发者_JS百科e java code and I want to convert it to C#.
From Microsoft, have a look. The Java Language Conversion Assistant (JLCA)
There might be something that claims it can do it, but I would not trust it. This is a significant port and it takes a programmer to make sure it happens correctly.
I've used JNBridge in the past on some small to medium projects with success. This allows you to call a Java library from .NET and vice versa. If you are dealing with relatively simple types in your interfaces, it might be a good way to go.
Process.Start("java MyClass.java");
There is Sharpen, but I was unable to setup it properly http://developer.db4o.com/Projects/html/projectspaces/db4o_product_design/sharpen.html
If you just want it to RUN but not necessarily be converted to C# source code, you might find http://www.ikvm.net/ an interesting alternative.
It provides the facilities to run Java code on the .NET-runtime.
精彩评论