You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by oh...@apache.org on 2013/01/16 21:52:09 UTC

svn commit: r1434383 - /commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java

Author: oheger
Date: Wed Jan 16 20:52:08 2013
New Revision: 1434383

URL: http://svn.apache.org/viewvc?rev=1434383&view=rev
Log:
Simplified implementation of JndiBuilderParametersImpl.

Modified:
    commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java

Modified: commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java
URL: http://svn.apache.org/viewvc/commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java?rev=1434383&r1=1434382&r2=1434383&view=diff
==============================================================================
--- commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java (original)
+++ commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/builder/JndiBuilderParametersImpl.java Wed Jan 16 20:52:08 2013
@@ -16,9 +16,6 @@
  */
 package org.apache.commons.configuration.builder;
 
-import java.util.HashMap;
-import java.util.Map;
-
 import javax.naming.Context;
 
 /**
@@ -51,38 +48,15 @@ public class JndiBuilderParametersImpl e
     /** Constant for the name of the prefix property. */
     private static final String PROP_PREFIX = "prefix";
 
-    /** A map for storing the properties. */
-    private final Map<String, Object> properties;
-
-    /**
-     * Creates a new instance of {@code JndiBuilderParametersImpl}.
-     */
-    public JndiBuilderParametersImpl()
-    {
-        properties = new HashMap<String, Object>();
-    }
-
     public JndiBuilderParametersImpl setContext(Context ctx)
     {
-        properties.put(PROP_CONTEXT, ctx);
+        storeProperty(PROP_CONTEXT, ctx);
         return this;
     }
 
     public JndiBuilderParametersImpl setPrefix(String p)
     {
-        properties.put(PROP_PREFIX, p);
+        storeProperty(PROP_PREFIX, p);
         return this;
     }
-
-    /**
-     * {@inheritDoc} This implementation adds this object's own properties to
-     * the map returned by the base class.
-     */
-    @Override
-    public Map<String, Object> getParameters()
-    {
-        Map<String, Object> result = super.getParameters();
-        result.putAll(properties);
-        return result;
-    }
 }