PDA

View Full Version : Calling java program from Cocoa




satyam90
Jun 3, 2009, 01:52 AM
I have java program "Test.java", and it is compiled to "Test". I will run this from terminal using "java Test". This is available in my home directory of my Mac.
Now, using Cocoa framework and Obj C application, I want to run "Test". How can I do it?



garethlewis2
Jun 3, 2009, 03:04 AM
NSTask is the easiest.

mathcolo
Jun 3, 2009, 02:59 PM
http://developer.apple.com/DOCUMENTATION/Cocoa/Reference/Foundation/Classes/NSTask_Class/Reference/Reference.html#//apple_ref/doc/uid/20000317-BJFCEEHH