Author: julien(a)jboss.com
Date: 2007-11-19 18:49:13 -0500 (Mon, 19 Nov 2007)
New Revision: 9027
Modified:
modules/portlet/trunk/test/src/main/org/jboss/portal/portlet/test/PortletControllerContextImpl.java
Log:
update portlet 1.1 to latest changes in web module
Modified:
modules/portlet/trunk/test/src/main/org/jboss/portal/portlet/test/PortletControllerContextImpl.java
===================================================================
---
modules/portlet/trunk/test/src/main/org/jboss/portal/portlet/test/PortletControllerContextImpl.java 2007-11-19
23:03:47 UTC (rev 9026)
+++
modules/portlet/trunk/test/src/main/org/jboss/portal/portlet/test/PortletControllerContextImpl.java 2007-11-19
23:49:13 UTC (rev 9027)
@@ -23,7 +23,8 @@
package org.jboss.portal.portlet.test;
import org.jboss.portal.web.IllegalRequestException;
-import org.jboss.portal.web.RequestInfo;
+import org.jboss.portal.web.WebRequest;
+import org.jboss.portal.web.Body;
import org.jboss.portal.portlet.test.url.ParameterDecoder;
import org.jboss.portal.common.util.ParameterMap;
import org.jboss.portal.common.util.Tools;
@@ -69,7 +70,7 @@
{
targetId = StringCodec.decode(pathInfo.substring(1));
- RequestInfo ri = new RequestInfo(req);
+ WebRequest ri = new WebRequest(req);
ParameterDecoder decoder = PortletURLRenderer.builder.createDecoder();
decoder.decode(ri.getQueryParameterMap());
@@ -108,13 +109,21 @@
//
PortletController.Request request;
String type = metaParameters.getValue("type");
+
+ //
+ ParameterMap formParameters = null;
+ if (ri.getBody() instanceof Body.Form)
+ {
+ formParameters = ((Body.Form)ri.getBody()).getParameters();
+ }
+
if ("action".equals(type))
{
- request = new PortletController.Action(targetId, actualParameters,
ri.getBodyParameterMap(), mode, windowState);
+ request = new PortletController.Action(targetId, actualParameters,
formParameters, mode, windowState);
}
else
{
- request = new PortletController.Render(targetId, actualParameters,
ri.getBodyParameterMap(), mode, windowState);
+ request = new PortletController.Render(targetId, actualParameters,
formParameters, mode, windowState);
}
//