public class ActionResponseWrapper extends StateAwareResponseWrapper implements ActionResponse
ActionResponseWrapper provides a convenient
implementation of the ActionResponse interface
that can be subclassed by developers.
This class implements the Wrapper or Decorator pattern.
Methods default to calling through to the wrapped response object.ActionResponse| Constructor and Description |
|---|
ActionResponseWrapper(ActionResponse response)
Creates an
ActionResponse adaptor
wrapping the given response object. |
| Modifier and Type | Method and Description |
|---|---|
RenderURL |
createRedirectURL(MimeResponse.Copy option)
call wrapped object.
|
ActionResponse |
getResponse()
Return the wrapped response object.
|
void |
sendRedirect(String location)
The default behavior of this method is to call
sendRedirect(location) on the wrapped response object. |
void |
sendRedirect(String location,
String renderUrlParamName)
The default behavior of this method is to call
sendRedirect(location, renderUrlParamName) on the wrapped response object. |
void |
setResponse(ActionResponse response)
Sets the response object being wrapped.
|
getPortletMode, getRenderParameterMap, getRenderParameters, getWindowState, removePublicRenderParameter, setEvent, setEvent, setPortletMode, setRenderParameter, setRenderParameter, setRenderParameters, setResponse, setWindowStateaddProperty, addProperty, addProperty, createElement, encodeURL, getNamespace, getProperty, getPropertyNames, getPropertyValues, setProperty, setResponseclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetRenderParameterMap, removePublicRenderParameter, setEvent, setEvent, setRenderParameter, setRenderParameter, setRenderParametersaddProperty, addProperty, addProperty, createElement, encodeURL, getNamespace, getProperty, getPropertyNames, getPropertyValues, setPropertygetRenderParameters, setPortletMode, setWindowStategetPortletMode, getWindowStatepublic ActionResponseWrapper(ActionResponse response)
ActionResponse adaptor
wrapping the given response object.response - the action response to wrapIllegalArgumentException - if the response is nullpublic ActionResponse getResponse()
getResponse in class StateAwareResponseWrapperpublic void setResponse(ActionResponse response)
response - the response to setIllegalArgumentException - if the response is null.public void sendRedirect(String location) throws IOException
sendRedirect(location) on the wrapped response object.sendRedirect in interface ActionResponselocation - the redirect location URLIOException - if an input or output exception occurs.public void sendRedirect(String location, String renderUrlParamName) throws IOException
sendRedirect(location, renderUrlParamName) on the wrapped response object.sendRedirect in interface ActionResponselocation - the redirect location URLrenderUrlParamName - name of the query parameter under which the portlet container should
store a render URL to this portletIOException - if an input or output exception occurs.public RenderURL createRedirectURL(MimeResponse.Copy option) throws IllegalStateException
createRedirectURL in interface ActionResponseoption - Specifies how current parameters are to be copied to the URLIllegalStateException - if the method is invoked after any of above mentioned methods of
the ActionResponse interface has been called.MimeResponse.CopyJava Portlet 3.0 API Specification. See the Copyright and License provided with this distribution. Use is subject to license terms.