axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From veit...@apache.org
Subject svn commit: r775279 - /webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java
Date Fri, 15 May 2009 18:30:14 GMT
Author: veithen
Date: Fri May 15 18:30:14 2009
New Revision: 775279

URL: http://svn.apache.org/viewvc?rev=775279&view=rev
Log:
Some code simplifications.

Modified:
    webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java

Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java?rev=775279&r1=775278&r2=775279&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java
(original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/description/ParameterIncludeImpl.java
Fri May 15 18:30:14 2009
@@ -39,7 +39,6 @@
 import java.io.ObjectInput;
 import java.io.ObjectOutput;
 import java.util.ArrayList;
-import java.util.Collection;
 import java.util.HashMap;
 import java.util.Iterator;
 
@@ -181,20 +180,11 @@
      * @return Returns parameter.
      */
     public Parameter getParameter(String name) {
-        return (Parameter) parameters.get(name);
+        return parameters.get(name);
     }
 
     public ArrayList<Parameter> getParameters() {
-        Collection<Parameter> col = parameters.values();
-        ArrayList<Parameter> para_list = new ArrayList<Parameter>();
-
-        for (Iterator<Parameter> iterator = col.iterator(); iterator.hasNext();) {
-            Parameter parameter = (Parameter) iterator.next();
-
-            para_list.add(parameter);
-        }
-
-        return para_list;
+        return new ArrayList<Parameter>(parameters.values());
     }
 
     // to check whether the parameter is locked at any level



Mime
View raw message