Overview  Package   Class  Tree  Serialized  Deprecated  Index  Help 

com.ibm.wps.portlets.struts
Class WpsStrutsViewTilesCommand

java.lang.Object
  extended bycom.ibm.wps.portlets.struts.WpsStrutsViewCommand
      extended bycom.ibm.wps.portlets.struts.WpsStrutsViewJspCommand
          extended bycom.ibm.wps.portlets.struts.WpsStrutsViewTilesCommand
All Implemented Interfaces:
IViewCommand, java.io.Serializable

public class WpsStrutsViewTilesCommand
extends WpsStrutsViewJspCommand

The WpsStrutsViewTilesCommand class is a command-pattern class used to provide a mechanism to encapsulate the information needed to redisplay a view for dynamic content that uses Struts Tiles. A Tiles definition may have a controller tied to the JSP that needs to be invoked each time the JSP is rendered.

Since:
4.2
See Also:
Serialized Form

Field Summary
protected static java.lang.String IncludeURL
          Name of the request attribute for whether or not to include the URI.
protected static org.apache.struts.util.MessageResources messages
          The message resources for the Struts Portlet Framework.
 

Fields inherited from class com.ibm.wps.portlets.struts.WpsStrutsViewJspCommand
QUERY, URI
 

Fields inherited from class com.ibm.wps.portlets.struts.WpsStrutsViewCommand
LAST_MODIFIED, PREFIX
 

Constructor Summary
WpsStrutsViewTilesCommand(java.lang.String uri, org.apache.jetspeed.portlet.PortletRequest request)
          Constructs the View command.
 

Method Summary
static void addAttributeNameToSave(java.lang.String attributeName)
          Adds the name of an attribute from the object request that needs to be saved if present for the execution of the IViewCommand in Portal's render phase.
static void addAttributeTypeToSave(java.lang.Class attributeType)
          Adds the class type of an attribute from the request that needs to be saved if present for the execution of the IViewCommand in Portal's render phase.
 void execute(org.apache.jetspeed.portlet.PortletRequest request, org.apache.jetspeed.portlet.PortletResponse response, ViewCommandExecutionContext executionContext)
          Executes the given command given the request and response objects.
protected  void includeURL(java.lang.String url, org.apache.jetspeed.portlet.PortletRequest request, org.apache.jetspeed.portlet.PortletResponse response, ViewCommandExecutionContext executionContext)
          Includes the URL.
static void removeAttributeNameToSave(java.lang.String attributeName)
          Removes the name of an attribute from the list of attribute names to save.
static void removeAttributeTypeToSave(java.lang.Class attributeType)
          Removes the class type of the request attribute from the list of attributes to save.
 void saveAttributes(javax.servlet.http.HttpServletRequest request, ViewCommandExecutionContext executionContext)
          Saves the attributes related to Tiles rendering.
 

Methods inherited from class com.ibm.wps.portlets.struts.WpsStrutsViewJspCommand
addQueryParameters, getQueryString, getUri, setQueryString, setUri
 

Methods inherited from class com.ibm.wps.portlets.struts.WpsStrutsViewCommand
java.util.List)">addAttribute, addParameterNameToSave, execute, getLastModified, getPrefix, getRemoveOnModeChange, getSavedAttributes, getSavedCommand, removeAttribute, removeParameterNameToSave, repopulateRequest, saveAsAttribute, saveAsParameter, saveAttribute, saveAttributes, saveCommand, saveCommand, saveParameter, saveParameters, setLastModified, setPrefix, setRemoveOnModeChange, java.util.Map)">setSavedAttributes
 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IncludeURL

protected static final java.lang.String IncludeURL
Name of the request attribute for whether or not to include the URI.

See Also:
Constant Field Values

messages

protected static org.apache.struts.util.MessageResources messages
The message resources for the Struts Portlet Framework.

Constructor Detail

WpsStrutsViewTilesCommand

public WpsStrutsViewTilesCommand(java.lang.String uri,
                                 org.apache.jetspeed.portlet.PortletRequest request)
Constructs the View command.

Parameters:
uri - the uri path to the JSP
request - The request object to save context information from

Method Detail

execute

public void execute(org.apache.jetspeed.portlet.PortletRequest request,
                    org.apache.jetspeed.portlet.PortletResponse response,
                    ViewCommandExecutionContext executionContext)
             throws org.apache.jetspeed.portlet.PortletException
Executes the given command given the request and response objects.

Specified by:
execute in interface IViewCommand
Overrides:
execute in class WpsStrutsViewJspCommand
Parameters:
request - The request object
response - The response object
executionContext - the execution context object
Throws:
org.apache.jetspeed.portlet.PortletException - if the request cannot be fulfilled

includeURL

protected void includeURL(java.lang.String url,
                          org.apache.jetspeed.portlet.PortletRequest request,
                          org.apache.jetspeed.portlet.PortletResponse response,
                          ViewCommandExecutionContext executionContext)
                   throws org.apache.jetspeed.portlet.PortletException
Includes the URL.

Overrides:
includeURL in class WpsStrutsViewJspCommand
Parameters:
request - the request object
response - the reponse object
executionContext - the execution context
url - the uri to include
Throws:
org.apache.jetspeed.portlet.PortletException - if the file cannot be included

saveAttributes

public void saveAttributes(javax.servlet.http.HttpServletRequest request,
                           ViewCommandExecutionContext executionContext)
Saves the attributes related to Tiles rendering.

Overrides:
saveAttributes in class WpsStrutsViewJspCommand
Parameters:
request - the request object
executionContext - the context object

addAttributeNameToSave

public static void addAttributeNameToSave(java.lang.String attributeName)
Adds the name of an attribute from the object request that needs to be saved if present for the execution of the IViewCommand in Portal's render phase.

Parameters:
attributeName - the name of the attribute

removeAttributeNameToSave

public static void removeAttributeNameToSave(java.lang.String attributeName)
Removes the name of an attribute from the list of attribute names to save.

Parameters:
attributeName - the name of the attribute

addAttributeTypeToSave

public static void addAttributeTypeToSave(java.lang.Class attributeType)
Adds the class type of an attribute from the request that needs to be saved if present for the execution of the IViewCommand in Portal's render phase.

Parameters:
attributeType - the attribute type

removeAttributeTypeToSave

public static void removeAttributeTypeToSave(java.lang.Class attributeType)
Removes the class type of the request attribute from the list of attributes to save.

Parameters:
attributeType - the attribute type

Overview  Package   Class  Tree  Serialized  Deprecated  Index  Help 

 

WebSphere is a trademark of the IBM Corporation in the United States, other countries, or both.

 

IBM is a trademark of the IBM Corporation in the United States, other countries, or both.