org.sakaiproject.cheftool
Class VelocityPortletStateAction

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by org.sakaiproject.vm.ComponentServlet
              extended by org.sakaiproject.vm.VmServlet
                  extended by org.sakaiproject.cheftool.VmServlet
                      extended by org.sakaiproject.cheftool.ToolServlet
                          extended by org.sakaiproject.cheftool.VelocityPortletPaneledAction
                              extended by org.sakaiproject.cheftool.VelocityPortletStateAction
All Implemented Interfaces:
Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

public abstract class VelocityPortletStateAction
extends VelocityPortletPaneledAction

VelocityPortletStateAction is an extension of VelocityPortletAction which provides a way to associate Controller state with each instances of the portlet using this action.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.sakaiproject.cheftool.VelocityPortletPaneledAction
VelocityPortletPaneledAction.MyLogger
 
Field Summary
 
Fields inherited from class org.sakaiproject.cheftool.VelocityPortletPaneledAction
ATTR_CONFIG, ATTR_CONTEXT, ATTR_FRAME_FOCUS, ATTR_FRAME_REFRESH, ATTR_PORTLET, ATTR_RUNDATA, ATTR_TOP_REFRESH, BUTTON, CONTEXT_SITE_COLLECTION_ID, CONTEXT_SITE_COLLECTION_URL, HELPER_LINK_MODE, HELPER_MODE_DONE, LAYOUT_MAIN, Log, MODE_OPTIONS, SAKAI_CSRF_TOKEN, STATE_ACTION, STATE_FLOAT, STATE_HELPER, STATE_MESSAGE, STATE_MODE, STATE_NEW_PANEL, STATE_OBSERVER, STATE_OBSERVER2, STATE_PRESENCE_OBSERVER, STATE_TOOL
 
Fields inherited from class org.sakaiproject.cheftool.ToolServlet
ALERT_ATTR, ALERT_STATE_INITED, HELPER_ID, MAIN_PANEL, MENU_ATTR, PARAM_ACTION, PARAM_ACTION_COMBO, TITLE_PANEL, TOOL_MODE_ATTR, TOOL_MODE_DEFAULT
 
Fields inherited from class org.sakaiproject.cheftool.VmServlet
m_validator
 
Fields inherited from class org.sakaiproject.vm.ComponentServlet
ATTR_PARAMS
 
Constructor Summary
VelocityPortletStateAction()
           
 
Method Summary
protected  ControllerState getState(Context context, RunData rundata, Class stateClass)
          Get the proper state for this instance (if portlet is not known, only context).
protected  ControllerState getState(String peid, RunData rundata, Class stateClass)
          Get the proper state for this instance (if portlet id is known).
protected  ControllerState getState(VelocityPortlet portlet, RunData rundata, Class stateClass)
          Get the proper state for this instance (if portlet is known).
protected  void releaseState(Context context, RunData rundata)
          Release the proper state for this instance (if portlet is not known, only context).
protected  void releaseState(String peid, RunData rundata)
          Release the proper state for this instance (if portlet id is known).
protected  void releaseState(VelocityPortlet portlet, RunData rundata)
          Release the proper state for this instance (if portlet is known).
 
Methods inherited from class org.sakaiproject.cheftool.VelocityPortletPaneledAction
actionDispatch, addAlert, addOptionsMenu, allowedToOptions, cancelOptions, clientWindowId, disableObservers, doGet, doOptions, doReset, enableObservers, getContext, getDateFormatString, helperActionDispatch, initState, initState, justDelivered, mainPanelUpdateId, panelMethodName, processAction, resetTool, saveOptions, scheduleFocusRefresh, schedulePeerFrameRefresh, scheduleTopRefresh, setVmCourier, setVmStdRef, switchPanel, titlePanelUpdateId, toolModeDispatch, updateState
 
Methods inherited from class org.sakaiproject.cheftool.ToolServlet
doPost, getAlert, getAlert, getMenu, getPid, getState, getToolMode, prepState, sendToHelper, setToolMode, startHelper, startHelper
 
Methods inherited from class org.sakaiproject.vm.VmServlet
getActionURL, getVmReference, includeVm, setVmReference
 
Methods inherited from class org.sakaiproject.vm.ComponentServlet
sendParentRedirect, service, setNoCacheHeaders
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service
 
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VelocityPortletStateAction

public VelocityPortletStateAction()
Method Detail

getState

protected ControllerState getState(Context context,
                                   RunData rundata,
                                   Class stateClass)
Get the proper state for this instance (if portlet is not known, only context).

Parameters:
context - The Template Context (it contains a reference to the portlet).
rundata - The Jetspeed (Turbine) rundata associated with the request.
stateClass - The Class of the ControllerState to find / create.
Returns:
The proper state object for this instance.

getState

protected ControllerState getState(VelocityPortlet portlet,
                                   RunData rundata,
                                   Class stateClass)
Get the proper state for this instance (if portlet is known).

Parameters:
portlet - The portlet being rendered.
rundata - The Jetspeed (Turbine) rundata associated with the request.
stateClass - The Class of the ControllerState to find / create.
Returns:
The proper state object for this instance.

getState

protected ControllerState getState(String peid,
                                   RunData rundata,
                                   Class stateClass)
Get the proper state for this instance (if portlet id is known).

Parameters:
peid - The portlet id.
rundata - The Jetspeed (Turbine) rundata associated with the request.
stateClass - The Class of the ControllerState to find / create.
Returns:
The proper state object for this instance.

releaseState

protected void releaseState(Context context,
                            RunData rundata)
Release the proper state for this instance (if portlet is not known, only context).

Parameters:
context - The Template Context (it contains a reference to the portlet).
rundata - The Jetspeed (Turbine) rundata associated with the request.

releaseState

protected void releaseState(VelocityPortlet portlet,
                            RunData rundata)
Release the proper state for this instance (if portlet is known).

Parameters:
portlet - The portlet being rendered.
rundata - The Jetspeed (Turbine) rundata associated with the request.

releaseState

protected void releaseState(String peid,
                            RunData rundata)
Release the proper state for this instance (if portlet id is known).

Parameters:
peid - The portlet id being rendered.
rundata - The Jetspeed (Turbine) rundata associated with the request.


Copyright © 2003-2012 The Sakai Foundation. All Rights Reserved.