Author: simonetripodi
Date: Sun Jan 30 19:51:19 2011
New Revision: 1065361

URL: http://svn.apache.org/viewvc?rev=1065361&view=rev
Log:
no needs to build the Formatter, String.format() is enough

Modified:
    
commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/SetNestedPropertiesRule.java

Modified: 
commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/SetNestedPropertiesRule.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/SetNestedPropertiesRule.java?rev=1065361&r1=1065360&r2=1065361&view=diff
==============================================================================
--- 
commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/SetNestedPropertiesRule.java
 (original)
+++ 
commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/SetNestedPropertiesRule.java
 Sun Jan 30 19:51:19 2011
@@ -19,7 +19,6 @@ package org.apache.commons.digester3;
 
 import java.beans.PropertyDescriptor;
 import java.util.ArrayList;
-import java.util.Formatter;
 import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
@@ -281,11 +280,9 @@ public class SetNestedPropertiesRule ext
             // Populate the corresponding properties of the top object
             Object top = this.getDigester().peek();
             if (debug) {
-                Formatter formatter =
-                    new Formatter().format("[SetNestedPropertiesRule]{%s} Set 
", this.getDigester().getMatch())
-                                   .format("%s properties", (top != null ? 
top.getClass().getName() : "NULL"));
-
-                this.getDigester().getLog().debug(formatter.toString());
+                
this.getDigester().getLog().debug(String.format("[SetNestedPropertiesRule]{%s} 
Set %s properties",
+                        this.getDigester().getMatch(),
+                        (top != null ? top.getClass().getName() : "NULL")));
             }
  
             if (trimData) {


Reply via email to