velocity-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nbu...@apache.org
Subject svn commit: r563626 - /velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java
Date Tue, 07 Aug 2007 19:12:18 GMT
Author: nbubna
Date: Tue Aug  7 12:12:17 2007
New Revision: 563626

URL: http://svn.apache.org/viewvc?view=rev&rev=563626
Log:
delegate properly within the generic clean() method

Modified:
    velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java

Modified: velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java
URL: http://svn.apache.org/viewvc/velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java?view=diff&rev=563626&r1=563625&r2=563626
==============================================================================
--- velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java
(original)
+++ velocity/tools/branches/2.x/src/main/java/org/apache/velocity/tools/config/ConfigurationCleaner.java
Tue Aug  7 12:12:17 2007
@@ -109,7 +109,19 @@
 
     public void clean(Configuration config)
     {
-        cleanProperties(config);
+        // delegate to the appropriate method...
+        if (config instanceof FactoryConfiguration)
+        {
+            clean((FactoryConfiguration)config);
+        }
+        else if (config instanceof ToolboxConfiguration)
+        {
+            clean((ToolboxConfiguration)config);
+        }
+        else
+        {
+            cleanProperties(config);
+        }
     }
 
     public void cleanProperties(Configuration config)



Mime
View raw message