* @throws java.io.IOException Error communicating with resulting process
* @throws InterruptedException Thread got interrupted waiting
*/
public static CommandHandle java(Command java)
throws IOException, InterruptedException {
CmdAgentImpl agent = CmdAgentImpl.getHandle();
if (agent != null) // Running on agent
return agent.java(java, Invoker.getContextLocation());
else // Running on master
return CmdService.getHandle().java(java,
Invoker.getContextLocation());
}