cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jo...@apache.org
Subject cvs commit: cocoon-2.1/src/blocks/portal/java/org/apache/cocoon/portal/acting ObjectModelAction.java
Date Mon, 04 Aug 2003 03:13:22 GMT
joerg       2003/08/03 20:13:22

  Modified:    src/blocks/portal/java/org/apache/cocoon/portal/acting
                        ObjectModelAction.java
  Log:
  replaced deprecated parameters.getParameterNames()
  
  Revision  Changes    Path
  1.3       +5 -7      cocoon-2.1/src/blocks/portal/java/org/apache/cocoon/portal/acting/ObjectModelAction.java
  
  Index: ObjectModelAction.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/blocks/portal/java/org/apache/cocoon/portal/acting/ObjectModelAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ObjectModelAction.java	10 Jul 2003 13:17:04 -0000	1.2
  +++ ObjectModelAction.java	4 Aug 2003 03:13:22 -0000	1.3
  @@ -50,7 +50,6 @@
   */
   package org.apache.cocoon.portal.acting;
   
  -import java.util.Iterator;
   import java.util.Map;
   
   import org.apache.avalon.framework.parameters.Parameters;
  @@ -69,13 +68,12 @@
   
   	public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters parameters) 
       throws Exception {
  -        Iterator names = parameters.getParameterNames();
  +        String[] names = parameters.getNames();
           String name;
  -        while (names.hasNext()) {
  -            name = (String)names.next();
  -            objectModel.put("cocoon-portal-"+name, parameters.getParameter(name));
  +        for(int i = 0; i < names.length; i++) {
  +            name = names[i];
  +            objectModel.put("cocoon-portal-" + name, parameters.getParameter(name));
           }
  -        
   		return EMPTY_MAP;
   	}
   }
  
  
  

Mime
View raw message