I'm creating a small java program that use some special graphics to draw a picture to a certain format. The program will be run as a jar file, and needs some graphics definitions as arguments at initiation. These definitions exist in a small C# class, and should contain only small objects that tells which drawing method to be used (e.g. FillRect, DrawLine), and the coordinates.

I have my reasons for doing this cross-language, and without going into detail why, what would be the best way to achieve this? Since the definitions are so alike in the two languages, the coordinates are the same and the method names and signatures are very similar, I figured maybe there is a smart way to solve this with minimal code? Or would the easiest way just be to create an XML from the C# program and read it from the Java program?


5 Years
Discussion Span
Last Post by peter_budo

I (personally) would make some type of output from the C# -- either output a file or just standard-out output and read that from the java program.


Simple, when you call for JAR file include starting parameters on the same line as name of file you will execute. Then in Java app check for any arguments (args[])

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.