stevel 01/11/30 12:43:03
Modified: src/main/org/apache/tools/ant/taskdefs Execute.java
Log:
new method, killedProcess() which returns true if there is a watchdog and it
killed the process
Revision Changes Path
1.26 +14 -0
jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Execute.java
Index: Execute.java
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Execute.java,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- Execute.java 2001/11/15 08:02:40 1.25
+++ Execute.java 2001/11/30 20:43:03 1.26
@@ -419,10 +419,24 @@
exitValue = value;
}
+ /**
+ * query the exit value of the process.
+ * @return the exit value, 1 if the process was killed,
+ * or Project.INVALID if no exit value has been received
+ */
public int getExitValue() {
return exitValue;
}
+ /**
+ * test for an untimely death of the process
+ * @return true iff a watchdog had to kill the process
+ * @since 1.5
+ */
+ public boolean killedProcess() {
+ return watchdog!=null && watchdog.killedProcess();
+ }
+
/**
* Patch the current environment with the new values from the user.
* @return the patched environment
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>