portals-pluto-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dettb...@apache.org
Subject svn commit: r609575 - in /portals/pluto/branches/1.1-286-trunk-merge: pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/ pluto-portal-driver/src/main/java/org/apache/pluto/driver/ pluto-testsuite/
Date Mon, 07 Jan 2008 11:39:18 GMT
Author: dettborn
Date: Mon Jan  7 03:39:17 2008
New Revision: 609575

URL: http://svn.apache.org/viewvc?rev=609575&view=rev
Log:
small changes for the pom.xml from the testsuite
and change PortalURLParserImpl, so that the parameter are UTF-8 encoded

Modified:
    portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/PortalURLParserImpl.java
    portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver/src/main/java/org/apache/pluto/driver/PortalDriverServlet.java
    portals/pluto/branches/1.1-286-trunk-merge/pluto-testsuite/pom.xml

Modified: portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/PortalURLParserImpl.java
URL: http://svn.apache.org/viewvc/portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/PortalURLParserImpl.java?rev=609575&r1=609574&r2=609575&view=diff
==============================================================================
--- portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/PortalURLParserImpl.java
(original)
+++ portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver-impl/src/main/java/org/apache/pluto/driver/url/impl/PortalURLParserImpl.java
Mon Jan  7 03:39:17 2008
@@ -17,6 +17,7 @@
 package org.apache.pluto.driver.url.impl;
 
 import java.io.UnsupportedEncodingException;
+import java.net.URLDecoder;
 import java.net.URLEncoder;
 import java.util.Iterator;
 import java.util.Map;
@@ -351,6 +352,12 @@
     private String encodeMultiValues(String[] values) {
     	StringBuffer buffer = new StringBuffer();
         for (int i = 0; i < values.length; i++) {
+        	try {
+				values[i] = URLEncoder.encode(values[i], "UTF-8");
+			} catch (UnsupportedEncodingException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
         	buffer.append(values[i] != null ? values[i] : "");
             if (i + 1 < values.length) {
             	buffer.append(VALUE_DELIM);
@@ -424,7 +431,14 @@
         
         // Split multiple values into a value array.
         String[] paramValues = value.split(VALUE_DELIM);
-        
+        for (int i = 0; i < paramValues.length;i++){
+        	try {
+        		paramValues[i] = URLDecoder.decode(paramValues[i], "UTF-8");
+			} catch (UnsupportedEncodingException e) {
+				// TODO Auto-generated catch block
+				e.printStackTrace();
+			}
+        }
         // Construct portal URL parameter and return.
         return new PortalURLParameter(windowId, paramName, paramValues);
     }
@@ -464,7 +478,7 @@
         	                             ENCODINGS[i][1],
         	                             ENCODINGS[i][0]);
         }
-        return string;
+		return string;
     }
 
 }

Modified: portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver/src/main/java/org/apache/pluto/driver/PortalDriverServlet.java
URL: http://svn.apache.org/viewvc/portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver/src/main/java/org/apache/pluto/driver/PortalDriverServlet.java?rev=609575&r1=609574&r2=609575&view=diff
==============================================================================
--- portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver/src/main/java/org/apache/pluto/driver/PortalDriverServlet.java
(original)
+++ portals/pluto/branches/1.1-286-trunk-merge/pluto-portal-driver/src/main/java/org/apache/pluto/driver/PortalDriverServlet.java
Mon Jan  7 03:39:17 2008
@@ -17,9 +17,7 @@
 package org.apache.pluto.driver;
 
 import java.io.IOException;
-import java.util.Collection;
 import java.util.Enumeration;
-import java.util.List;
 
 import javax.portlet.PortletException;
 import javax.servlet.RequestDispatcher;
@@ -28,33 +26,18 @@
 import javax.servlet.http.HttpServlet;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
-import javax.xml.namespace.QName;
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.pluto.PortletContainer;
 import org.apache.pluto.PortletContainerException;
-import org.apache.pluto.PortletWindow;
-import org.apache.pluto.descriptors.portlet.EventDD;
-import org.apache.pluto.descriptors.portlet.EventDefinitionDD;
-import org.apache.pluto.descriptors.portlet.PortletAppDD;
 import org.apache.pluto.descriptors.portlet.PortletDD;
-import org.apache.pluto.descriptors.portlet.PublicRenderParamDD;
 import org.apache.pluto.driver.config.DriverConfiguration;
 import org.apache.pluto.driver.core.PortalRequestContext;
 import org.apache.pluto.driver.core.PortletWindowImpl;
 import org.apache.pluto.driver.services.portal.PageConfig;
 import org.apache.pluto.driver.services.portal.PortletWindowConfig;
-import org.apache.pluto.driver.services.portal.SupportedModesService;
 import org.apache.pluto.driver.url.PortalURL;
-import org.apache.pluto.internal.InternalPortletWindow;
-import org.apache.pluto.internal.impl.InternalPortletWindowImpl;
-import org.apache.pluto.spi.EventProvider;
-import org.apache.pluto.spi.PublicRenderParameterProvider;
-import org.springframework.context.ApplicationContext;
-import org.springframework.web.context.WebApplicationContext;
-
-import com.sun.jmx.snmp.Enumerated;
 /**
  * The controller servlet used to drive the Portal Driver. All requests mapped
  * to this servlet will be processed as Portal Requests.

Modified: portals/pluto/branches/1.1-286-trunk-merge/pluto-testsuite/pom.xml
URL: http://svn.apache.org/viewvc/portals/pluto/branches/1.1-286-trunk-merge/pluto-testsuite/pom.xml?rev=609575&r1=609574&r2=609575&view=diff
==============================================================================
--- portals/pluto/branches/1.1-286-trunk-merge/pluto-testsuite/pom.xml (original)
+++ portals/pluto/branches/1.1-286-trunk-merge/pluto-testsuite/pom.xml Mon Jan  7 03:39:17
2008
@@ -150,7 +150,7 @@
                 -->
 					<property environment="env"/>
 					<property name="deploy.dir" value="${env.PORTLET_DEPLOY_DIR}"/>
-					<move file="target/${pom.build.finalName}.war" tofile="${deploy.dir}/testsuite.war"/>
+					<copy file="target/${pom.build.finalName}.war" tofile="${deploy.dir}/testsuite.war"/>
 =              </tasks>
             </configuration>
             <goals>



Mime
View raw message