Author: julien(a)jboss.com
Date: 2008-02-27 19:17:07 -0500 (Wed, 27 Feb 2008)
New Revision: 10146
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletControllerContext.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletRequestHandler.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletResourceRequestHandler.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestFactory.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterMapFactory.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterNames.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/state/StateControllerContextImpl.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/ControllerRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletActionRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletEventRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRenderRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletResourceRequest.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/response/PageUpdateResponse.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/PageNavigationalStateSerialization.java
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/StateControllerContext.java
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerContextSupport.java
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerTestCase.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/PortalServlet.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/AbstractPortletControllerContext.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/ControllerResponseRendererFactory.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PageRenderer.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PortletURLRenderer.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/TestPortletInvocationContext.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/ControllerFilter.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/PortalRenderResponse.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletMarkupTag.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletURLTag.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKRendererContext.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKServlet.java
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKStateControllerContext.java
modules/portlet/trunk/test/src/test/java/org/jboss/portal/portlet/controller/StateControllerContextTestCase.java
Log:
rename pageState to pageNavigationalState because this is what it really is
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletControllerContext.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletControllerContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletControllerContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -60,10 +60,10 @@
* Create a portlet invocation context for the specified window id.
*
* @param windowId the window id
- * @param pageState
+ * @param pageNavigationalState
* @return
*/
- PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageState);
+ PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageNavigationalState);
PortletInvocationResponse invoke( ActionInvocation actionInvocation) throws
PortletInvokerException;
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletRequestHandler.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletRequestHandler.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletRequestHandler.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -74,14 +74,14 @@
// The page navigational state we will operate on during the request
// Either we have nothing in the request so we create a new one
// Or we have one but we copy it as we should not modify the input state provided
- PageNavigationalState pageState = portletRequest.getPageState();
- if (pageState == null)
+ PageNavigationalState pageNavigationalState =
portletRequest.getPageNavigationalState();
+ if (pageNavigationalState == null)
{
- pageState = stateContext.createPageState(true);
+ pageNavigationalState = stateContext.createPageNavigationalState(true);
}
else
{
- pageState = stateContext.clonePageState(pageState, true);
+ pageNavigationalState =
stateContext.clonePageNavigationalState(pageNavigationalState, true);
}
//
@@ -92,7 +92,7 @@
{
// Update portlet NS
UpdateNavigationalStateResponse updateResponse =
(UpdateNavigationalStateResponse)response;
- updateNavigationalState(context, portletRequest.getWindowId(), updateResponse,
pageState);
+ updateNavigationalState(context, portletRequest.getWindowId(), updateResponse,
pageNavigationalState);
//
ResponseProperties update = updateResponse.getProperties();
@@ -222,7 +222,7 @@
}
//
- PortletInvocationResponse eventResponse = deliverEvent(context,
toConsumeEvent, pageState, requestProperties.getCookies());
+ PortletInvocationResponse eventResponse = deliverEvent(context,
toConsumeEvent, pageNavigationalState, requestProperties.getCookies());
// Now it is consumed we add it to the history
session.consumedEventHistory.addFirst(toConsumeEvent);
@@ -233,7 +233,7 @@
UpdateNavigationalStateResponse eventStateResponse =
(UpdateNavigationalStateResponse)eventResponse;
// Update ns
- updateNavigationalState(context, toConsumeEvent.getWindowId(),
eventStateResponse, pageState);
+ updateNavigationalState(context, toConsumeEvent.getWindowId(),
eventStateResponse, pageNavigationalState);
// Add events to source event queue
for (UpdateNavigationalStateResponse.Event portletEvent :
eventStateResponse.getEvents())
@@ -263,7 +263,7 @@
}
//
- return new PageUpdateResponse(updateResponse, requestProperties, pageState,
eventDistributionStatus);
+ return new PageUpdateResponse(updateResponse, requestProperties,
pageNavigationalState, eventDistributionStatus);
}
else
{
@@ -292,7 +292,7 @@
PortletActionRequest portletActionRequest =
(PortletActionRequest)portletRequest;
//
- PageNavigationalState pageState = portletActionRequest.getPageState();
+ PageNavigationalState pageNavigationalState =
portletActionRequest.getPageNavigationalState();
//
Mode mode = portletActionRequest.getWindowNavigationalState().getMode();
@@ -310,12 +310,12 @@
//
ParameterMap publicNS = null;
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- publicNS =
pageState.getPublicNavigationalState(portletRequest.getWindowId());
+ publicNS =
pageNavigationalState.getPublicNavigationalState(portletRequest.getWindowId());
}
- PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(portletRequest.getWindowId(), pageState);
+ PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(portletRequest.getWindowId(),
pageNavigationalState);
ActionInvocation actionInvocation = new
ActionInvocation(portletInvocationContext);
//
@@ -332,10 +332,10 @@
}
private PortletInvocationResponse deliverEvent(PortletControllerContext context, Event
event,
- PageNavigationalState pageState,
List<Cookie> requestCookies)
+ PageNavigationalState
pageNavigationalState, List<Cookie> requestCookies)
throws PortletInvokerException
{
- WindowNavigationalState windowNS =
pageState.getWindowNavigationalState(event.getWindowId());
+ WindowNavigationalState windowNS =
pageNavigationalState.getWindowNavigationalState(event.getWindowId());
//
if (windowNS == null)
@@ -344,10 +344,10 @@
}
//
- ParameterMap publicNS = pageState.getPublicNavigationalState(event.getWindowId());
+ ParameterMap publicNS =
pageNavigationalState.getPublicNavigationalState(event.getWindowId());
//
- PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(event.getWindowId(), pageState);
+ PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(event.getWindowId(), pageNavigationalState);
EventInvocation eventInvocation = new EventInvocation(portletInvocationContext);
//
@@ -366,10 +366,10 @@
PortletControllerContext context,
String windowId,
UpdateNavigationalStateResponse update,
- PageNavigationalState pageState)
+ PageNavigationalState pageNavigationalState)
throws PortletInvokerException
{
- WindowNavigationalState windowNS = pageState.getWindowNavigationalState(windowId);
+ WindowNavigationalState windowNS =
pageNavigationalState.getWindowNavigationalState(windowId);
//
if (windowNS == null)
@@ -394,13 +394,13 @@
portletNS = update.getNavigationalState();
}
windowNS = new WindowNavigationalState(portletNS, mode, windowState);
- pageState.setWindowNavigationalState(windowId, windowNS);
+ pageNavigationalState.setWindowNavigationalState(windowId, windowNS);
// Now update shared state scoped at page
Map<String, String[]> publicNS = update.getPublicNavigationalStateUpdates();
if (publicNS != null)
{
- pageState.setPublicNavigationalState(windowId, publicNS);
+ pageNavigationalState.setPublicNavigationalState(windowId, publicNS);
}
}
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletResourceRequestHandler.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletResourceRequestHandler.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/PortletResourceRequestHandler.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -60,7 +60,7 @@
//
Mode mode = null;
WindowState windowState = null;
- PageNavigationalState pageState = null;
+ PageNavigationalState pageNavigationalState = null;
ParameterMap publicNS = null;
StateString portletNS = null;
CacheLevel cacheability;
@@ -79,13 +79,13 @@
if (scope instanceof PortletResourceRequest.PageScope)
{
PortletResourceRequest.PageScope pageScope =
(PortletResourceRequest.PageScope)scope;
- pageState = pageScope.getPageState();
+ pageNavigationalState = pageScope.getPageNavigationalState();
cacheability = CacheLevel.PAGE;
//
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- publicNS =
pageState.getPublicNavigationalState(portletResourceRequest.getWindowId());
+ publicNS =
pageNavigationalState.getPublicNavigationalState(portletResourceRequest.getWindowId());
}
}
else
@@ -109,7 +109,7 @@
}
//
- PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(portletResourceRequest.getWindowId(), pageState);
+ PortletInvocationContext portletInvocationContext =
context.createPortletInvocationContext(portletResourceRequest.getWindowId(),
pageNavigationalState);
ResourceInvocation resourceInvocation = new
ResourceInvocation(portletInvocationContext);
//
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestFactory.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestFactory.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestFactory.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -63,12 +63,12 @@
// The nav state provided with the request
// Unmarshall portal navigational state if it is provided
- PageNavigationalState pageState = null;
- String context = req.getParameter(ControllerRequestParameterNames.PAGE_STATE);
+ PageNavigationalState pageNavigationalState = null;
+ String context =
req.getParameter(ControllerRequestParameterNames.PAGE_NAVIGATIONAL_STATE);
if (context != null)
{
byte[] bytes = Base64.decode(context, true);
- pageState = IOTools.unserialize(serialization, SerializationFilter.COMPRESSOR,
bytes);
+ pageNavigationalState = IOTools.unserialize(serialization,
SerializationFilter.COMPRESSOR, bytes);
}
// Get the window id
@@ -127,7 +127,7 @@
scope = new PortletResourceRequest.PortletScope(windowNavigationalState);
break;
case PAGE:
- scope = new PortletResourceRequest.PageScope(windowNavigationalState,
pageState);
+ scope = new PortletResourceRequest.PageScope(windowNavigationalState,
pageNavigationalState);
break;
default:
throw new AssertionError();
@@ -160,7 +160,7 @@
interactionState,
formParameters,
windowNavigationalState,
- pageState);
+ pageNavigationalState);
}
else
{
@@ -172,7 +172,7 @@
windowId,
windowNavigationalState,
publicNavigationalStateChanges,
- pageState);
+ pageNavigationalState);
}
}
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterMapFactory.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterMapFactory.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterMapFactory.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -82,11 +82,11 @@
//
- String pageState = null;
+ String pageNavigationalState = null;
if (pageNS != null)
{
byte[] bytes = IOTools.serialize(serialization, SerializationFilter.COMPRESSOR,
pageNS);
- pageState = Base64.encodeBytes(bytes, true);
+ pageNavigationalState = Base64.encodeBytes(bytes, true);
}
//
@@ -106,9 +106,9 @@
}
//
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- parameters.put(ControllerRequestParameterNames.PAGE_STATE, pageState);
+ parameters.put(ControllerRequestParameterNames.PAGE_NAVIGATIONAL_STATE,
pageNavigationalState);
}
//
@@ -183,9 +183,9 @@
parameters.put(ControllerRequestParameterNames.WINDOW_STATE,
resourceURL.getWindowState().toString());
}
- if (cacheability == CacheLevel.PAGE && pageState != null)
+ if (cacheability == CacheLevel.PAGE && pageNavigationalState !=
null)
{
- parameters.put(ControllerRequestParameterNames.PAGE_STATE, pageState);
+ parameters.put(ControllerRequestParameterNames.PAGE_NAVIGATIONAL_STATE,
pageNavigationalState);
}
}
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterNames.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterNames.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/request/ControllerRequestParameterNames.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -46,7 +46,7 @@
/** The portlet interaction state for lifecycle of type
<code>ACTION_LIFECYCLE</code>. */
public static final String INTERACTION_STATE = "interactionstate";
/** The page state for any kind of lifecycle. */
- public static final String PAGE_STATE = "pagestate";
+ public static final String PAGE_NAVIGATIONAL_STATE =
"pageNavigationalState";
/** The public navigational state changes of a portlet for lifecycle of type
<code>RENDER_LIFECYCLE</code>. */
public static final String PUBLIC_NAVIGATIONAL_STATE_CHANGES =
"publicnavigationalstatechanges";
/** The resource id for lifecycle of type <code>RESOURCE_LIFECYCLE</code>.
*/
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/state/StateControllerContextImpl.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/state/StateControllerContextImpl.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/impl/state/StateControllerContextImpl.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -48,12 +48,12 @@
this.portletControllerContext = portletControllerContext;
}
- public PageNavigationalState clonePageState(PageNavigationalState pageState, boolean
modifiable)
+ public PageNavigationalState clonePageNavigationalState(PageNavigationalState
pageNavigationalState, boolean modifiable)
{
- return new PageNavigationalStateImpl((PageNavigationalStateImpl)pageState,
modifiable);
+ return new
PageNavigationalStateImpl((PageNavigationalStateImpl)pageNavigationalState, modifiable);
}
- public PageNavigationalState createPageState(boolean modifiable)
+ public PageNavigationalState createPageNavigationalState(boolean modifiable)
{
return new PageNavigationalStateImpl(this, modifiable);
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/ControllerRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/ControllerRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/ControllerRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -36,11 +36,11 @@
}
/**
- * Returns the page state or null if that kind of request cannot have one.
+ * Returns the page navigational state or null if that kind of request cannot have
one.
*
* @return the page state
*/
- public PageNavigationalState getPageState()
+ public PageNavigationalState getPageNavigationalState()
{
return null;
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletActionRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletActionRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletActionRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -45,9 +45,9 @@
StateString interactionState,
ParameterMap bodyParameters,
WindowNavigationalState windowNavigationalState,
- PageNavigationalState pageState)
+ PageNavigationalState pageNavigationalState)
{
- super(windowId, windowNavigationalState, pageState);
+ super(windowId, windowNavigationalState, pageNavigationalState);
//
this.interactionState = interactionState;
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletEventRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletEventRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletEventRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -47,11 +47,11 @@
public PortletEventRequest(
String windowId,
WindowNavigationalState windowNavigationalState,
- PageNavigationalState pageState,
+ PageNavigationalState pageNavigationalState,
QName name,
Serializable payload)
{
- super(windowId, windowNavigationalState, pageState);
+ super(windowId, windowNavigationalState, pageNavigationalState);
//
this.name = name;
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRenderRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRenderRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRenderRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -42,9 +42,9 @@
String windowId,
WindowNavigationalState windowNavigationalState,
Map<String, String[]> publicNavigationalStateChanges,
- PageNavigationalState pageState)
+ PageNavigationalState pageNavigationalState)
{
- super(windowId, windowNavigationalState, pageState);
+ super(windowId, windowNavigationalState, pageNavigationalState);
//
this.publicNavigationalStateChanges = publicNavigationalStateChanges;
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -22,7 +22,6 @@
******************************************************************************/
package org.jboss.portal.portlet.controller.request;
-import org.jboss.portal.portlet.controller.PortletControllerContext;
import org.jboss.portal.portlet.controller.state.PageNavigationalState;
import org.jboss.portal.portlet.controller.state.WindowNavigationalState;
@@ -34,7 +33,7 @@
{
/** . */
- private final PageNavigationalState pageState;
+ private final PageNavigationalState pageNavigationalState;
/** . */
private final WindowNavigationalState windowNavigationalState;
@@ -42,18 +41,18 @@
PortletRequest(
String windowId,
WindowNavigationalState windowNavigationalState,
- PageNavigationalState pageState)
+ PageNavigationalState pageNavigationalState)
{
super(windowId);
//
this.windowNavigationalState = windowNavigationalState;
- this.pageState = pageState;
+ this.pageNavigationalState = pageNavigationalState;
}
- public PageNavigationalState getPageState()
+ public PageNavigationalState getPageNavigationalState()
{
- return pageState;
+ return pageNavigationalState;
}
public WindowNavigationalState getWindowNavigationalState()
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletResourceRequest.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletResourceRequest.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/request/PortletResourceRequest.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -28,9 +28,6 @@
import org.jboss.portal.portlet.controller.state.PageNavigationalState;
import org.jboss.portal.portlet.cache.CacheLevel;
-import java.util.HashMap;
-import java.util.Map;
-
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
* @version $Revision: 630 $
@@ -132,19 +129,19 @@
{
/** . */
- private final PageNavigationalState pageState;
+ private final PageNavigationalState pageNavigationalState;
- public PageScope(WindowNavigationalState windowNavigationalState,
PageNavigationalState pageState)
+ public PageScope(WindowNavigationalState windowNavigationalState,
PageNavigationalState pageNavigationalState)
{
super(windowNavigationalState);
//
- this.pageState = pageState;
+ this.pageNavigationalState = pageNavigationalState;
}
- public PageNavigationalState getPageState()
+ public PageNavigationalState getPageNavigationalState()
{
- return pageState;
+ return pageNavigationalState;
}
public CacheLevel getCacheability()
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/response/PageUpdateResponse.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/response/PageUpdateResponse.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/response/PageUpdateResponse.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -37,19 +37,19 @@
private ResponseProperties properties;
/** . */
- private PageNavigationalState pageState;
+ private PageNavigationalState pageNavigationalState;
public PageUpdateResponse(
UpdateNavigationalStateResponse update,
ResponseProperties properties,
- PageNavigationalState pageState,
+ PageNavigationalState pageNavigationalState,
int eventCycleStatus)
{
super(update, eventCycleStatus);
//
this.properties = properties;
- this.pageState = pageState;
+ this.pageNavigationalState = pageNavigationalState;
}
public ResponseProperties getProperties()
@@ -57,8 +57,8 @@
return properties;
}
- public PageNavigationalState getPageState()
+ public PageNavigationalState getPageNavigationalState()
{
- return pageState;
+ return pageNavigationalState;
}
}
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/PageNavigationalStateSerialization.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/PageNavigationalStateSerialization.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/PageNavigationalStateSerialization.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -87,16 +87,16 @@
this.context = context;
}
- public void serialize(PageNavigationalState pageState, OutputStream out) throws
IOException, IllegalArgumentException
+ public void serialize(PageNavigationalState pageNavigationalState, OutputStream out)
throws IOException, IllegalArgumentException
{
DataOutputStream data = out instanceof DataOutputStream ? (DataOutputStream)out :
new DataOutputStream(out);
//
- data.writeInt(pageState.getWindowIds().size());
- for (String windowId : pageState.getWindowIds())
+ data.writeInt(pageNavigationalState.getWindowIds().size());
+ for (String windowId : pageNavigationalState.getWindowIds())
{
data.writeUTF(windowId);
- WindowNavigationalState windowNS =
pageState.getWindowNavigationalState(windowId);
+ WindowNavigationalState windowNS =
pageNavigationalState.getWindowNavigationalState(windowId);
byte header = 0;
int decision = 0;
if (windowNS.getPortletNavigationalState() != null)
@@ -146,13 +146,13 @@
}
//
- Set<QName> publicNames = pageState.getPublicNames();
+ Set<QName> publicNames = pageNavigationalState.getPublicNames();
data.writeInt(publicNames.size());
- for (QName name : pageState.getPublicNames())
+ for (QName name : pageNavigationalState.getPublicNames())
{
data.writeUTF(name.getNamespaceURI());
data.writeUTF(name.getLocalPart());
- String[] values = pageState.getPublicNavigationalState(name);
+ String[] values = pageNavigationalState.getPublicNavigationalState(name);
int length = values.length;
data.writeInt(length);
for (String value : values)
@@ -171,7 +171,7 @@
DataInputStream data = in instanceof DataInputStream ? (DataInputStream)in : new
DataInputStream(in);
//
- PageNavigationalState pageNS = context.createPageState(true);
+ PageNavigationalState pageNS = context.createPageNavigationalState(true);
//
int size = data.readInt();
Modified:
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/StateControllerContext.java
===================================================================
---
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/StateControllerContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/main/java/org/jboss/portal/portlet/controller/state/StateControllerContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -34,11 +34,10 @@
/**
* Clone an existing page state object.
*
- * @param pageState the page state to clone
- * @param modifiable set the modifiable status
- * @return the page state clone
+ * @param pageNavigationalState
+ *@param modifiable set the modifiable status @return the page state clone
*/
- PageNavigationalState clonePageState(PageNavigationalState pageState, boolean
modifiable);
+ PageNavigationalState clonePageNavigationalState(PageNavigationalState
pageNavigationalState, boolean modifiable);
/**
* Create a new page state object.
@@ -46,6 +45,6 @@
* @param modifiable set the modifiable status
* @return the new page state
*/
- PageNavigationalState createPageState(boolean modifiable);
+ PageNavigationalState createPageNavigationalState(boolean modifiable);
}
Modified:
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerContextSupport.java
===================================================================
---
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerContextSupport.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerContextSupport.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -77,7 +77,7 @@
}
//
- public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageState)
+ public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageNavigationalState)
{
if (windowId == null)
{
@@ -85,7 +85,7 @@
}
//
- return new PortletInvocationContextSupport(windowId, pageState);
+ return new PortletInvocationContextSupport(windowId, pageNavigationalState);
}
private PortletInvocationResponse invoke(PortletInvocation invocation) throws
PortletInvokerException
Modified:
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerTestCase.java
===================================================================
---
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerTestCase.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/controller/src/test/java/org/jboss/portal/portlet/controller/PortletControllerTestCase.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -93,14 +93,14 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
ControllerResponse response = controller.process(context, request);
PageUpdateResponse pageUpdate = assertInstanceOf(response,
PageUpdateResponse.class);
- PageNavigationalState pageNS = assertNotNull(pageUpdate.getPageState());
+ PageNavigationalState pageNS =
assertNotNull(pageUpdate.getPageNavigationalState());
assertEquals(Tools.toSet("foo"), pageNS.getWindowIds());
@@ -127,7 +127,7 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
try
@@ -165,7 +165,7 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
//
@@ -260,7 +260,7 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
EventProducerActionHandler eventProducerActionHandler = new
EventProducerActionHandler(srcName);
@@ -301,7 +301,7 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
//
@@ -339,7 +339,7 @@
new OpaqueStateString(""),
new ParameterMap(),
new WindowNavigationalState(),
- context.getStateControllerContext().createPageState(false)
+ context.getStateControllerContext().createPageNavigationalState(false)
);
//
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/PortalServlet.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/PortalServlet.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/PortalServlet.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -95,7 +95,7 @@
true,
true,
context.getStateControllerContext(),
- request.getPageState());
+ request.getPageNavigationalState());
//
Renderer renderer = rendererFactory.getRenderer(response);
@@ -106,7 +106,7 @@
else
{
- PageRenderer renderer = new PageRenderer(new ResponseProperties(),
context.getStateControllerContext().createPageState(false));
+ PageRenderer renderer = new PageRenderer(new ResponseProperties(),
context.getStateControllerContext().createPageNavigationalState(false));
//
renderer.render(new RendererContextImpl(context));
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/AbstractPortletControllerContext.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/AbstractPortletControllerContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/AbstractPortletControllerContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -184,8 +184,8 @@
return invoke((PortletInvocation)resourceInvocation);
}
- public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageState)
+ public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageNavigationalState)
{
- return new TestPortletInvocationContext(getPageNavigationalStateSerialization(),
req, resp, windowId, pageState, MARKUP_INFO);
+ return new TestPortletInvocationContext(getPageNavigationalStateSerialization(),
req, resp, windowId, pageNavigationalState, MARKUP_INFO);
}
}
\ No newline at end of file
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/ControllerResponseRendererFactory.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/ControllerResponseRendererFactory.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/ControllerResponseRendererFactory.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -49,7 +49,7 @@
private boolean sendErrorOnProcessActionError;
/** The page navigational state if there is one in the request. */
- private PageNavigationalState requestPageState;
+ private PageNavigationalState requestPageNavigationalState;
/** . */
private StateControllerContext stateControllerContext;
@@ -58,12 +58,12 @@
boolean sendNoContentResponseOnEmptyResource,
boolean sendErrorOnProcessActionError,
StateControllerContext stateControllerContext,
- PageNavigationalState requestPageState)
+ PageNavigationalState requestPageNavigationalState)
{
this.sendNoContentResponseOnEmptyResource = sendNoContentResponseOnEmptyResource;
this.sendErrorOnProcessActionError = sendErrorOnProcessActionError;
this.stateControllerContext = stateControllerContext;
- this.requestPageState = requestPageState;
+ this.requestPageNavigationalState = requestPageNavigationalState;
}
public Renderer getRenderer(ControllerResponse response)
@@ -73,7 +73,7 @@
PageUpdateResponse pageUpdate = (PageUpdateResponse)response;
//
- return new PageRenderer(pageUpdate.getProperties(), pageUpdate.getPageState());
+ return new PageRenderer(pageUpdate.getProperties(),
pageUpdate.getPageNavigationalState());
}
else if (response instanceof PortletResponse)
{
@@ -112,7 +112,7 @@
}
else
{
- return new PageRenderer(new ResponseProperties(), requestPageState != null ?
requestPageState : stateControllerContext.createPageState(false));
+ return new PageRenderer(new ResponseProperties(),
requestPageNavigationalState != null ? requestPageNavigationalState :
stateControllerContext.createPageNavigationalState(false));
}
}
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PageRenderer.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PageRenderer.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PageRenderer.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -64,14 +64,14 @@
protected FragmentRenderer fragmentRenderer = new SimpleFragmentRenderer();
protected List<FragmentResponse> fragments;
protected List<ErrorResponse> errors;
- protected PageNavigationalState pageState;
+ protected PageNavigationalState pageNavigationalState;
- public PageRenderer(ResponseProperties properties, PageNavigationalState pageState)
+ public PageRenderer(ResponseProperties properties, PageNavigationalState
pageNavigationalState)
{
super(properties);
//
- this.pageState = pageState;
+ this.pageNavigationalState = pageNavigationalState;
}
public void setFragmentRenderer(FragmentRenderer fragmentRenderer)
@@ -141,7 +141,7 @@
for (Portlet portlet : portlets)
{
- WindowNavigationalState windowNS =
pageState.getWindowNavigationalState(portlet.getContext().getId());
+ WindowNavigationalState windowNS =
pageNavigationalState.getWindowNavigationalState(portlet.getContext().getId());
//
Mode mode = Mode.VIEW;
@@ -166,9 +166,9 @@
}
//
- ParameterMap publicNS =
pageState.getPublicNavigationalState(portlet.getContext().getId());
+ ParameterMap publicNS =
pageNavigationalState.getPublicNavigationalState(portlet.getContext().getId());
- RenderInvocation render = createRenderInvocation(context, properties, pageState,
portlet, windowNS, mode, windowState, portletNS, publicNS);
+ RenderInvocation render = createRenderInvocation(context, properties,
pageNavigationalState, portlet, windowNS, mode, windowState, portletNS, publicNS);
//
try
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PortletURLRenderer.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PortletURLRenderer.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/PortletURLRenderer.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -112,18 +112,18 @@
public String renderURL(URLFormat format)
{
- String pageState = null;
+ String pageNavigationalState = null;
if (pageNS != null)
{
byte[] bytes = IOTools.serialize(serialization, SerializationFilter.COMPRESSOR,
pageNS);
- pageState = Base64.encodeBytes(bytes, true);
+ pageNavigationalState = Base64.encodeBytes(bytes, true);
}
//
Map<String, String> parameters;
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- parameters =
Collections.singletonMap(ControllerRequestParameterNames.PAGE_STATE, pageState);
+ parameters =
Collections.singletonMap(ControllerRequestParameterNames.PAGE_NAVIGATIONAL_STATE,
pageNavigationalState);
}
else
{
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/TestPortletInvocationContext.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/TestPortletInvocationContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/controller/TestPortletInvocationContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -61,7 +61,7 @@
HttpServletRequest clientRequest,
HttpServletResponse clientResponse,
String windowId,
- PageNavigationalState pageState,
+ PageNavigationalState pageNavigationalState,
MarkupInfo markupInfo)
{
super(markupInfo);
@@ -70,7 +70,7 @@
this.clientRequest = clientRequest;
this.clientResponse = clientResponse;
this.windowId = windowId;
- this.urlRenderer = new PortletURLRenderer(pageState, clientRequest, clientResponse,
serialization);
+ this.urlRenderer = new PortletURLRenderer(pageNavigationalState, clientRequest,
clientResponse, serialization);
//
addResolver(PortletInvocation.PRINCIPAL_SCOPE, new
PrincipalAttributeResolver(clientRequest));
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/ControllerFilter.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/ControllerFilter.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/ControllerFilter.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -109,7 +109,7 @@
// Process only portlet type
// The request decoded if not null
- PageNavigationalState pageState = null;
+ PageNavigationalState pageNavigationalState = null;
if (URLParameterConstants.PORTLET_TYPE.equals(type))
{
WebRequest wr = new WebRequest(req);
@@ -136,7 +136,7 @@
{
//
PortletURLRenderer renderer = new PortletURLRenderer(
- pageUpdate.getPageState(),
+ pageUpdate.getPageNavigationalState(),
context.getClientRequest(),
context.getClientResponse(),
context.getPageNavigationalStateSerialization());
@@ -152,7 +152,7 @@
}
else
{
- pageState = pageUpdate.getPageState();
+ pageNavigationalState = pageUpdate.getPageNavigationalState();
}
}
else if (controllerResponse instanceof ResourceResponse)
@@ -250,17 +250,17 @@
PageNavigationalStateSerialization serialization = new
PageNavigationalStateSerialization(context.getStateControllerContext());
// The nav state provided with the request
// Unmarshall portal navigational state if it is provided
- pageState = null;
- String blah = req.getParameter(ControllerRequestParameterNames.PAGE_STATE);
+ pageNavigationalState = null;
+ String blah =
req.getParameter(ControllerRequestParameterNames.PAGE_NAVIGATIONAL_STATE);
if (blah != null)
{
byte[] bytes = Base64.decode(blah, true);
- pageState = IOTools.unserialize(serialization,
SerializationFilter.COMPRESSOR, bytes);
+ pageNavigationalState = IOTools.unserialize(serialization,
SerializationFilter.COMPRESSOR, bytes);
}
}
//
- PortalRenderResponse renderResponse = new PortalRenderResponse(req, resp, context,
pageState, prepareResponse);
+ PortalRenderResponse renderResponse = new PortalRenderResponse(req, resp, context,
pageNavigationalState, prepareResponse);
//
chain.doFilter(req, renderResponse);
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/PortalRenderResponse.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/PortalRenderResponse.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/PortalRenderResponse.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -57,7 +57,7 @@
{
/** . */
- private PageNavigationalState pageState;
+ private PageNavigationalState pageNavigationalState;
/** . */
private PagePortletControllerContext portletControllerContext;
@@ -69,7 +69,7 @@
HttpServletRequest request,
HttpServletResponse response,
PagePortletControllerContext portletControllerContext,
- PageNavigationalState pageState,
+ PageNavigationalState pageNavigationalState,
PortalPrepareResponse prepareResponse) throws PortletInvokerException
{
super(request, response);
@@ -78,17 +78,17 @@
Set<QName> pageParameterNames = prepareResponse.getPageParameterNames();
if (pageParameterNames.size() > 0)
{
- if (pageState == null)
+ if (pageNavigationalState == null)
{
- pageState =
portletControllerContext.getStateControllerContext().createPageState(true);
+ pageNavigationalState =
portletControllerContext.getStateControllerContext().createPageNavigationalState(true);
}
for (QName parameterName : pageParameterNames)
{
PageParameterDef parameterDef =
prepareResponse.getPageParameterDef(parameterName);
- boolean update = parameterDef.isFrozen() ? true :
pageState.getPublicNavigationalState(parameterName) == null;
+ boolean update = parameterDef.isFrozen() ? true :
pageNavigationalState.getPublicNavigationalState(parameterName) == null;
if (update)
{
- pageState.setPublicNavigationalState(parameterName, new
String[]{parameterDef.getValue()});
+ pageNavigationalState.setPublicNavigationalState(parameterName, new
String[]{parameterDef.getValue()});
}
}
}
@@ -96,7 +96,7 @@
//
this.portletControllerContext = portletControllerContext;
this.windowResults = new HashMap<String, WindowResult>();
- this.pageState = pageState;
+ this.pageNavigationalState = pageNavigationalState;
//
render(prepareResponse);
@@ -107,9 +107,9 @@
*
* @return the page state
*/
- public PageNavigationalState getPageState()
+ public PageNavigationalState getPageNavigationalState()
{
- return pageState;
+ return pageNavigationalState;
}
public Set<String> getWindowIds()
@@ -130,16 +130,16 @@
private PortletInvocationResponse render(Portlet portlet, String windowId) throws
PortletInvokerException
{
WindowNavigationalState windowNS = null;
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- windowNS = pageState.getWindowNavigationalState(windowId);
+ windowNS = pageNavigationalState.getWindowNavigationalState(windowId);
}
//
ParameterMap publicNS = null;
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- publicNS = pageState.getPublicNavigationalState(windowId);
+ publicNS = pageNavigationalState.getPublicNavigationalState(windowId);
}
//
@@ -165,7 +165,7 @@
}
//
- PortletInvocationContext renderContext =
portletControllerContext.createPortletInvocationContext(windowId, pageState);
+ PortletInvocationContext renderContext =
portletControllerContext.createPortletInvocationContext(windowId, pageNavigationalState);
RenderInvocation render = new RenderInvocation(renderContext);
render.setClientContext(new
AbstractClientContext(portletControllerContext.getClientRequest()));
render.setServerContext(new
AbstractServerContext(portletControllerContext.getClientRequest(),
portletControllerContext.getClientResponse()));
@@ -229,11 +229,11 @@
public String getMaximizedWindowId()
{
- if (pageState != null)
+ if (pageNavigationalState != null)
{
- for (String windowId : pageState.getWindowIds())
+ for (String windowId : pageNavigationalState.getWindowIds())
{
- WindowNavigationalState windowNS =
pageState.getWindowNavigationalState(windowId);
+ WindowNavigationalState windowNS =
pageNavigationalState.getWindowNavigationalState(windowId);
if (WindowState.MAXIMIZED.equals(windowNS.getWindowState()))
{
return windowId;
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletMarkupTag.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletMarkupTag.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletMarkupTag.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -53,9 +53,9 @@
{
FragmentResponse fragment = (FragmentResponse)portletResp;
WindowNavigationalState windowNS = null;
- if (renderResponse.getPageState() != null)
+ if (renderResponse.getPageNavigationalState() != null)
{
- windowNS =
renderResponse.getPageState().getWindowNavigationalState(portletTag.result.getWindowDef().getWindowId());
+ windowNS =
renderResponse.getPageNavigationalState().getWindowNavigationalState(portletTag.result.getWindowDef().getWindowId());
}
if (windowNS == null ||
!windowNS.getWindowState().equals(WindowState.MINIMIZED))
{
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletURLTag.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletURLTag.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/jsp/taglib/PortletURLTag.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -94,7 +94,7 @@
}
PortletURLRenderer renderer = new PortletURLRenderer(
- renderResponse.getPageState(),
+ renderResponse.getPageNavigationalState(),
context.getClientRequest(),
context.getClientResponse(),
context.getPageNavigationalStateSerialization());
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKRendererContext.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKRendererContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKRendererContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -42,7 +42,7 @@
public TCKRendererContext(
TCKPortletControllerContext portletControllerContext,
- TCKPageNavigationalState pageState) throws PortletInvokerException
+ TCKPageNavigationalState tckPageNavigationalState) throws PortletInvokerException
{
super(portletControllerContext);
@@ -50,9 +50,9 @@
Collection<Portlet> involvedPortlets = new ArrayList<Portlet>();
// Page state could be null for some requests
- if (pageState != null)
+ if (tckPageNavigationalState != null)
{
- for (String involvedPortletId : pageState.getInvolvedPortlets())
+ for (String involvedPortletId : tckPageNavigationalState.getInvolvedPortlets())
{
try
{
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKServlet.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKServlet.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKServlet.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -95,7 +95,7 @@
ControllerRequest request = factory.createRequest(wr);
// We must have one!!!
- TCKPageNavigationalState tckPageState =
(TCKPageNavigationalState)request.getPageState();
+ TCKPageNavigationalState tckPageNavigationalState =
(TCKPageNavigationalState)request.getPageNavigationalState();
//
ControllerResponse response = controller.process(context, request);
@@ -105,13 +105,13 @@
false,
false,
context.getStateControllerContext(),
- request.getPageState());
+ request.getPageNavigationalState());
//
Renderer renderer = rendererFactory.getRenderer(response);
//
- renderer.render(new TCKRendererContext(context, tckPageState));
+ renderer.render(new TCKRendererContext(context, tckPageNavigationalState));
}
else
{
@@ -140,13 +140,13 @@
throw new IllegalStateException("Portlets requested by TCK were not
found");
}
- TCKPageNavigationalState tckPageState = new
TCKPageNavigationalState(context.getStateControllerContext().createPageState(false),
involvedPortlets);
+ TCKPageNavigationalState tckPageNavigationalState = new
TCKPageNavigationalState(context.getStateControllerContext().createPageNavigationalState(false),
involvedPortlets);
//
- PageRenderer renderer = new PageRenderer(new ResponseProperties(),
tckPageState);
+ PageRenderer renderer = new PageRenderer(new ResponseProperties(),
tckPageNavigationalState);
//
- renderer.render(new TCKRendererContext(context, tckPageState));
+ renderer.render(new TCKRendererContext(context, tckPageNavigationalState));
}
}
}
Modified:
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKStateControllerContext.java
===================================================================
---
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKStateControllerContext.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/main/java/org/jboss/portal/portlet/test/tck/TCKStateControllerContext.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -41,18 +41,18 @@
this.defaultStateControllerContext = defaultStateControllerContext;
}
- public PageNavigationalState clonePageState(PageNavigationalState pageState, boolean
modifiable)
+ public PageNavigationalState clonePageNavigationalState(PageNavigationalState
pageNavigationalState, boolean modifiable)
{
- TCKPageNavigationalState tckPageState = (TCKPageNavigationalState)pageState;
+ TCKPageNavigationalState tckPageNavigationalState =
(TCKPageNavigationalState)pageNavigationalState;
//
return new TCKPageNavigationalState(
- defaultStateControllerContext.clonePageState(tckPageState.defaultState,
modifiable),
- new HashSet<String>(tckPageState.involvedPortlets));
+
defaultStateControllerContext.clonePageNavigationalState(tckPageNavigationalState.defaultState,
modifiable),
+ new HashSet<String>(tckPageNavigationalState.involvedPortlets));
}
- public PageNavigationalState createPageState(boolean modifiable)
+ public PageNavigationalState createPageNavigationalState(boolean modifiable)
{
- return new
TCKPageNavigationalState(defaultStateControllerContext.createPageState(modifiable), new
HashSet<String>());
+ return new
TCKPageNavigationalState(defaultStateControllerContext.createPageNavigationalState(modifiable),
new HashSet<String>());
}
}
Modified:
modules/portlet/trunk/test/src/test/java/org/jboss/portal/portlet/controller/StateControllerContextTestCase.java
===================================================================
---
modules/portlet/trunk/test/src/test/java/org/jboss/portal/portlet/controller/StateControllerContextTestCase.java 2008-02-28
00:05:49 UTC (rev 10145)
+++
modules/portlet/trunk/test/src/test/java/org/jboss/portal/portlet/controller/StateControllerContextTestCase.java 2008-02-28
00:17:07 UTC (rev 10146)
@@ -63,7 +63,7 @@
@Test
public void testMarshalling1()
{
- PageNavigationalState pageNS = cc.createPageState(true);
+ PageNavigationalState pageNS = cc.createPageNavigationalState(true);
assertMarshallable(pageNS);
}
@@ -90,7 +90,7 @@
private void test(StateString portletNavigationalState, Mode mode, WindowState
windowState)
{
- PageNavigationalState pageNS = cc.createPageState(true);
+ PageNavigationalState pageNS = cc.createPageNavigationalState(true);
pageNS.setWindowNavigationalState("foo", new
WindowNavigationalState(portletNavigationalState, mode, windowState));
assertMarshallable(pageNS);
}
@@ -127,7 +127,7 @@
throw new NotYetImplemented();
}
- public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageState)
+ public PortletInvocationContext createPortletInvocationContext(String windowId,
PageNavigationalState pageNavigationalState)
{
throw new NotYetImplemented();
}