/** * Blocks until the workflow run has finished and then reports if it was successful. * * <p>A workflow run is considered successful if it returns with a 0 result. * * @return True is and only if the workflow run ended with a 0. * @throws TavernaException Wrapper around any InterruptedException, or if the process was never * started. * @throws ProcessException If the process was not started. */ public boolean wasSuccessful() throws TavernaException, ProcessException { try { boolean result = runner.waitFor() == 0; if (outputFile == null) { saveOutput(); } return result; } catch (InterruptedException ex) { throw new TavernaException("Error checking if run was successfull", ex); } }