Return-Path: Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: (qmail 88490 invoked from network); 6 Jun 2010 21:22:53 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 6 Jun 2010 21:22:53 -0000 Received: (qmail 17139 invoked by uid 500); 6 Jun 2010 21:22:53 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 17095 invoked by uid 500); 6 Jun 2010 21:22:53 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 17088 invoked by uid 99); 6 Jun 2010 21:22:53 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Jun 2010 21:22:53 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Jun 2010 21:22:51 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 0DE5F2388ABB; Sun, 6 Jun 2010 21:22:30 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r951982 - /commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java Date: Sun, 06 Jun 2010 21:22:30 -0000 To: commits@commons.apache.org From: sgoeschl@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20100606212230.0DE5F2388ABB@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: sgoeschl Date: Sun Jun 6 21:22:29 2010 New Revision: 951982 URL: http://svn.apache.org/viewvc?rev=951982&view=rev Log: [EXEC-42] improving javadoc Modified: commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java Modified: commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java URL: http://svn.apache.org/viewvc/commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java?rev=951982&r1=951981&r2=951982&view=diff ============================================================================== --- commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java (original) +++ commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/Executor.java Sun Jun 6 21:22:29 2010 @@ -50,7 +50,7 @@ public interface Executor { int INVALID_EXITVALUE = 0xdeadbeef; /** - * Define the exit code of the process to considered + * Define the exit code of the process to be considered * successful. * * @param value the exit code representing successful execution @@ -58,7 +58,7 @@ public interface Executor { void setExitValue(final int value); /** - * Define the exit code of the process to considered + * Define the exit code of the process to be considered * successful. The caller can pass one of the following values *
    *
  • an array of exit values to be considered successful
  • @@ -83,7 +83,7 @@ public interface Executor { /** * Get the StreamHandler used for providing input and - * retriving the output. + * retrieving the output. * * @return the StreamHandler */ @@ -91,9 +91,12 @@ public interface Executor { /** * Set the StreamHandler used for providing input and - * retriving the output. + * retrieving the output. If you don't provide a stream + * handler the executed process might block when writing + * to stdout and/or stderr (see {@link java.lang.Process + * Process}). * - * @param streamHandler the StreamHandler + * @param streamHandler the stream handler */ void setStreamHandler(ExecuteStreamHandler streamHandler); @@ -151,7 +154,9 @@ public interface Executor { * * @param command the command to execute * @return process exit value - * @throws ExecuteException execution of subprocess failed + * @throws ExecuteException execution of subprocess failed or the + * subprocess returned a exit value indicating a failure + * {@link Executor#setExitValue(int)}. */ int execute(CommandLine command) throws ExecuteException, IOException; @@ -163,7 +168,9 @@ public interface Executor { * @param environment The environment for the new process. If null, the * environment of the current process is used. * @return process exit value - * @throws ExecuteException execution of subprocess failed + * @throws ExecuteException execution of subprocess failed or the + * subprocess returned a exit value indicating a failure + * {@link Executor#setExitValue(int)}. */ int execute(CommandLine command, Map environment) throws ExecuteException, IOException;