[jboss-svn-commits] JBL Code SVN: r15589 - labs/jbossrules/trunk/drools-core/src/main/java/org/drools/base/mvel.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Thu Oct 4 20:19:40 EDT 2007
Author: pombredanne
Date: 2007-10-04 20:19:40 -0400 (Thu, 04 Oct 2007)
New Revision: 15589
Modified:
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/base/mvel/MVELDebugHandler.java
Log:
Set MVEL debugging verbosity to false
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/base/mvel/MVELDebugHandler.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/base/mvel/MVELDebugHandler.java 2007-10-04 22:01:47 UTC (rev 15588)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/base/mvel/MVELDebugHandler.java 2007-10-05 00:19:40 UTC (rev 15589)
@@ -6,23 +6,23 @@
/**
* Debug Handler for MVEL dialect.
- *
+ *
* Takes care of registering breakpoints and calling required methods
- * to trigger eclipse debugger to keep breakpoints in sync etc.
- *
+ * to trigger eclipse debugger to keep breakpoints in sync etc.
+ *
* @author Ahti Kitsik
*
*/
public final class MVELDebugHandler {
private static int onBreakReturn = Debugger.CONTINUE;
-
+
public final static String DEBUG_LAUNCH_KEY="mvel.debugger";
-
+
private static Boolean debugMode = null;
-
- public static final boolean verbose = true;
-
+
+ public static final boolean verbose = false;
+
static {
MVELRuntime.setThreadDebugger(new MVELDebugger());
}
@@ -57,26 +57,26 @@
}
MVELRuntime.registerBreakpoint( sourceName, lineNumber );
}
-
+
protected final static void clearAllBreakpoints() {
if (verbose) {
System.out.println("Clearing all breakpoints");
}
MVELRuntime.clearAllBreakpoints();
}
-
+
protected final static void removeBreakpoint(String sourceName, int lineNumber) {
if (verbose) {
System.out.println("Removing breakpoint from "+sourceName+":"+lineNumber);
}
MVELRuntime.removeBreakpoint( sourceName, lineNumber );
}
-
+
private static class MVELDebugger implements Debugger {
public MVELDebugger() {
}
-
+
public int onBreak(Frame frame) {
if (verbose) {
System.out.println("onBreak call for "+frame.getSourceName()+":"+frame.getLineNumber());
@@ -90,7 +90,7 @@
protected final static void setOnBreakReturn(int value) {
onBreakReturn = value;
}
-
+
/**
* Do nothing for now. ensures that class is loaded prior debug handler
*/
@@ -118,12 +118,12 @@
* Updates local MVELDebugHandler property and System property "mvel.debugger"<br/>
* <br/>
* There's no need to ever call this method unless you write junit tests!<br/>
- *
+ *
* @param b is Debug enabled?
*/
public static void setDebugMode(boolean b) {
debugMode = Boolean.valueOf( b );
System.setProperty( DEBUG_LAUNCH_KEY, debugMode.toString());
}
-
+
}
More information about the jboss-svn-commits
mailing list