Java A number of people have asked how would use Isis2 from Java. This article can help:

As you will see, one option is to use a system called J#. With it your Java code runs without changes on .NET. On the other hand, you end up with a solution that won't port back to Linux because Mono lacks a J# compiler. You would probably end up using the Tangible translation tool (see below) at that stage, and hence starting in J# but ending up in C#.

For this reason, the "best" option is to use a package called the JLCA. Microsoft no longer actively supports this, but you can find old Windows images with JLCA on them. You only need to use it once. You run it on the Java code, and it magically generates C# code that calls the native .NET library methods. This gives better performance and better interoperability. But the resulting code behaves in the identical manner to the original Java. In fact it even looks nearly identical: JLCA works because C# and Java are really almost identical languages. Thus not that many things need to be changed, and JLCA can do the necessary edits with surprisingly little impact on the look and feel of your code.

But one limit with the JLCA approach is that it may be a bit old and lacking support for modern features of Java. So a second good option to consider is the tool made by Tangible Software Solutions, available at Java to C# Converter. This allows you to code in Java and then covert it to high quality C# with proper library calls already in place. I've worked with these people and the tool is remarkably good. So this can kind of bootstrap you from Java to C# at which point continuing to work in C# would be easy.

Last edited Mar 2, 2015 at 2:06 PM by birman, version 3


No comments yet.