Revision: 1207
          http://stripes.svn.sourceforge.net/stripes/?rev=1207&view=rev
Author:   bengunter
Date:     2009-10-27 19:27:08 +0000 (Tue, 27 Oct 2009)

Log Message:
-----------
Applied fix for STS-677 from trunk

Modified Paths:
--------------
    
branches/1.5.x/stripes/src/net/sourceforge/stripes/controller/AnnotatedClassActionResolver.java
    branches/1.5.x/stripes/src/net/sourceforge/stripes/util/Log.java

Modified: 
branches/1.5.x/stripes/src/net/sourceforge/stripes/controller/AnnotatedClassActionResolver.java
===================================================================
--- 
branches/1.5.x/stripes/src/net/sourceforge/stripes/controller/AnnotatedClassActionResolver.java
     2009-10-27 19:24:28 UTC (rev 1206)
+++ 
branches/1.5.x/stripes/src/net/sourceforge/stripes/controller/AnnotatedClassActionResolver.java
     2009-10-27 19:27:08 UTC (rev 1207)
@@ -148,14 +148,16 @@
             // Put the event->method mapping for the class into the set of 
mappings
             this.eventMappings.put(clazz, classMappings);
 
-            // Print out the event mappings nicely
-            for (Map.Entry<String, Method> entry : classMappings.entrySet()) {
-                String event = entry.getKey();
-                Method handler = entry.getValue();
-                boolean isDefault = DEFAULT_HANDLER_KEY.equals(event);
+            if (log.getRealLog().isDebugEnabled()) {
+                // Print out the event mappings nicely
+                for (Map.Entry<String, Method> entry : 
classMappings.entrySet()) {
+                    String event = entry.getKey();
+                    Method handler = entry.getValue();
+                    boolean isDefault = DEFAULT_HANDLER_KEY.equals(event);
 
-                log.debug("Bound: ", clazz.getSimpleName(), ".", 
handler.getName(), "() ==> ",
-                        binding, isDefault ? "" : "?" + event);
+                    log.debug("Bound: ", clazz.getSimpleName(), ".", 
handler.getName(), "() ==> ",
+                            binding, isDefault ? "" : "?" + event);
+                }
             }
         }
     }

Modified: branches/1.5.x/stripes/src/net/sourceforge/stripes/util/Log.java
===================================================================
--- branches/1.5.x/stripes/src/net/sourceforge/stripes/util/Log.java    
2009-10-27 19:24:28 UTC (rev 1206)
+++ branches/1.5.x/stripes/src/net/sourceforge/stripes/util/Log.java    
2009-10-27 19:27:08 UTC (rev 1207)
@@ -29,6 +29,10 @@
 public final class Log {
     private org.apache.commons.logging.Log realLog;
 
+    public org.apache.commons.logging.Log getRealLog() {
+        return realLog;
+    }
+
     /**
      * Get a Log instance to perform logging within the Class specified.  
Returns an instance
      * of this class which wraps an instance of the commons logging Log class.


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development

Reply via email to