Sina -- how does git work? Perhaps I should grab a client myself and check it out. The brailleblaster source is set up for version control in mercurial, but as yet no one has added their source. It appears JohnB is digging his way out of the snow dumped on Wisconsin, which was apparently worse than the snow dump here. Hopefully he won't have to restore too much. Meanwhile perhaps I'll check out a git client. --le ----- Original Message ----- From: "Sina Bahram" <sbahram@xxxxxxxxx> To: <brailleblaster@xxxxxxxxxxxxx> Sent: Tuesday, December 14, 2010 12:58 AM Subject: [brailleblaster] Re: the source Laura, Can you commit this to git, so we can start working in version control. After the posts on here, I grabbed a git client and am ready to go. Take care, Sina -----Original Message----- From: brailleblaster-bounce@xxxxxxxxxxxxx [mailto:brailleblaster-bounce@xxxxxxxxxxxxx] On Behalf Of qubit Sent: Tuesday, December 14, 2010 1:08 AM To: brailleblaster@xxxxxxxxxxxxx Subject: [brailleblaster] the source Ok, attached you'll find the first cut of the JSpawn class and tests. irst of all, the method java.util.Arrays.asList doesn't work here because of type mismatches. I stared at it and concluded I still need the loop. What a pain. (see line 13 of Tests.java.) Note: This is not complete or in any way finished. I expect it to be shot full of holes by the java people, but that is actually helpful, so bring it on... I am still getting used to the good, the bad and the ugly of java. I have spent more time over the past few days on this than I care to contemplate. If the interface is awkward, I only followed the most convenient way of using the Process and ProcessBuilder classes. I expect this to change. JohnB: what do you need the subprocesses to do? do you want to be able to start itex2MML and keep it resident while the editor is running? or do you want it to make a single swoop through the entire document to translate all the math? As I said, if I am to make itex2MML run itex2MML has global variables that I really should clear between each translation if you want it to be resident, so it won't get into a bad state. That wouldn't be hard. I'd at least welcome the escape from java...;) Coming additions: is there any reason to make writes to the child process asynchronous, so it wouldn't block the editor? How about getting the error messages and output data from the process? A user of the editor might find it useful to fire off a long read and do other things while it loads. I'm thinking of the general usage of this class. The intended usage: fire off a filter program by passing a command with options to JSpawn's constructor. Then you call the various read and write methods in JSpawn to do the reads and writes. You have access to 3 streams: an output stream to write to the process's input, and 2 input streams to read the process's standard out and err. You can then do whatever you want with the data. The finalizer closes the streams and kills the JSpawn object. Anyway, comments welcome. I think I'll take a chocolate break. --le