Author: sgoeschl Date: Tue Apr 8 06:05:34 2008 New Revision: 645893 URL: http://svn.apache.org/viewvc?rev=645893&view=rev Log: Changed the names of the system properties to turn on debugging support and using the constants instead of string literals
Modified: commons/sandbox/exec/trunk/src/main/java/org/apache/commons/exec/util/DebugUtils.java Modified: commons/sandbox/exec/trunk/src/main/java/org/apache/commons/exec/util/DebugUtils.java URL: http://svn.apache.org/viewvc/commons/sandbox/exec/trunk/src/main/java/org/apache/commons/exec/util/DebugUtils.java?rev=645893&r1=645892&r2=645893&view=diff ============================================================================== --- commons/sandbox/exec/trunk/src/main/java/org/apache/commons/exec/util/DebugUtils.java (original) +++ commons/sandbox/exec/trunk/src/main/java/org/apache/commons/exec/util/DebugUtils.java Tue Apr 8 06:05:34 2008 @@ -31,14 +31,14 @@ * exceptions found in the original code. The default value * is "true" */ - public static final String COMMONS_EXEC_LENIENT = "COMMONS_EXEC_LENIENT"; + public static final String COMMONS_EXEC_LENIENT = "org.apache.commons.exec.lenient"; /** * System property to determine how to dump an exception. When * set to "true" we print any exception to stderr. The default * value is "false" */ - public static final String COMMONS_EXEC_DEBUG = "COMMONS_EXEC_DEBUG"; + public static final String COMMONS_EXEC_DEBUG = "org.apache.commons.exec.debug"; /** * Handle an exception based on the system properties. @@ -70,7 +70,7 @@ * @return true if debug mode is enabled */ public static boolean isDebugEnabled() { - return "true".equalsIgnoreCase(System.getProperty("COMMONS_EXEC_DEBUG", "false")); + return "true".equalsIgnoreCase(System.getProperty(COMMONS_EXEC_DEBUG, "false")); } /** @@ -79,7 +79,7 @@ * @return true if lenient mode is enabled */ public static boolean isLenientEnabled() { - return "true".equalsIgnoreCase(System.getProperty("COMMONS_EXEC_LENIENT", "true")); + return "true".equalsIgnoreCase(System.getProperty(COMMONS_EXEC_LENIENT, "true")); } }