org.apache.myfaces.application.jsp
Class JspStateManagerImpl

java.lang.Object
  |
  +--javax.faces.application.StateManager
        |
        +--org.apache.myfaces.application.MyfacesStateManager
              |
              +--org.apache.myfaces.application.jsp.JspStateManagerImpl

public class JspStateManagerImpl
extends MyfacesStateManager

Default StateManager implementation.

Version:
$Revision: 1.22 $ $Date: 2005/01/18 07:03:15 $, $Revision: 1.22 $ $Date: 2005/01/18 07:03:15 $ $Log: JspStateManagerImpl.java,v $ Revision 1.22 2005/01/18 07:03:15 matzew added patch form Sean Schofield to solve state saving issue on server side. (MyFaces-81) Revision 1.21 2004/10/13 11:50:59 matze renamed packages to org.apache Revision 1.20 2004/08/15 15:35:26 o_rossmueller fix #1008685: hold view state by viewId Revision 1.19 2004/08/15 15:31:09 o_rossmueller fix #1008685: hold view state by viewId Revision 1.18 2004/08/13 13:15:20 manolito FIXME comment Revision 1.17 2004/07/21 11:22:40 mwessendorf last modification in effect of Adam Winer bug-report. Revision 1.16 2004/07/01 22:05:20 mwessendorf ASF switch Revision 1.15 2004/05/18 08:29:38 manolito saveSerializedView now caches the SerializedView within the request, so that multiple calls only process the saveState methods of components once. Revision 1.14 2004/04/13 08:08:08 manolito NPE bug fix Revision 1.13 2004/04/06 10:26:03 royalts restoreView(...) returns null if restoredViewId != viewId Revision 1.12 2004/04/06 10:20:27 manolito no state restoring for different viewId Revision 1.11 2004/03/25 08:52:40 manolito fixed server state saving
Author:
Thomas Spiegl (latest modification by $Author: matzew $), Thomas Spiegl (latest modification by $Author: matzew $), Manfred Geiler

Field Summary
 
Fields inherited from class javax.faces.application.StateManager
STATE_SAVING_METHOD_CLIENT, STATE_SAVING_METHOD_PARAM_NAME, STATE_SAVING_METHOD_SERVER
 
Constructor Summary
JspStateManagerImpl()
           
 
Method Summary
protected  java.lang.Object getComponentStateToSave(javax.faces.context.FacesContext facesContext)
           
protected  javax.faces.render.RenderKitFactory getRenderKitFactory()
           
protected  javax.faces.application.StateManager.SerializedView getSerializedViewFromServletSession(javax.faces.context.ExternalContext externalContext, java.lang.String viewId)
           
protected  java.lang.Object getTreeStructureToSave(javax.faces.context.FacesContext facesContext)
           
protected  void removeSerializedViewFromServletSession(javax.faces.context.ExternalContext externalContext, java.lang.String viewId)
           
protected  void restoreComponentState(javax.faces.context.FacesContext facesContext, javax.faces.component.UIViewRoot uiViewRoot, java.lang.String renderKitId)
           
protected  javax.faces.component.UIViewRoot restoreTreeStructure(javax.faces.context.FacesContext facesContext, java.lang.String viewId, java.lang.String renderKitId)
           
 javax.faces.component.UIViewRoot restoreView(javax.faces.context.FacesContext facescontext, java.lang.String viewId, java.lang.String renderKitId)
           
 javax.faces.application.StateManager.SerializedView saveSerializedView(javax.faces.context.FacesContext facesContext)
           
protected  void saveSerializedViewInServletSession(javax.faces.context.ExternalContext externalContext, java.lang.String viewId, javax.faces.application.StateManager.SerializedView serializedView)
           
 void writeState(javax.faces.context.FacesContext facesContext, javax.faces.application.StateManager.SerializedView serializedView)
           
 void writeStateAsUrlParams(javax.faces.context.FacesContext facesContext, javax.faces.application.StateManager.SerializedView serializedView)
          MyFaces extension
 
Methods inherited from class javax.faces.application.StateManager
isSavingStateInClient
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JspStateManagerImpl

public JspStateManagerImpl()
Method Detail

getComponentStateToSave

protected java.lang.Object getComponentStateToSave(javax.faces.context.FacesContext facesContext)
Specified by:
getComponentStateToSave in class javax.faces.application.StateManager

getTreeStructureToSave

protected java.lang.Object getTreeStructureToSave(javax.faces.context.FacesContext facesContext)
Specified by:
getTreeStructureToSave in class javax.faces.application.StateManager

restoreComponentState

protected void restoreComponentState(javax.faces.context.FacesContext facesContext,
                                     javax.faces.component.UIViewRoot uiViewRoot,
                                     java.lang.String renderKitId)
Specified by:
restoreComponentState in class javax.faces.application.StateManager

restoreTreeStructure

protected javax.faces.component.UIViewRoot restoreTreeStructure(javax.faces.context.FacesContext facesContext,
                                                                java.lang.String viewId,
                                                                java.lang.String renderKitId)
Specified by:
restoreTreeStructure in class javax.faces.application.StateManager

restoreView

public javax.faces.component.UIViewRoot restoreView(javax.faces.context.FacesContext facescontext,
                                                    java.lang.String viewId,
                                                    java.lang.String renderKitId)
Specified by:
restoreView in class javax.faces.application.StateManager

saveSerializedView

public javax.faces.application.StateManager.SerializedView saveSerializedView(javax.faces.context.FacesContext facesContext)
                                                                       throws java.lang.IllegalStateException
Specified by:
saveSerializedView in class javax.faces.application.StateManager
java.lang.IllegalStateException

writeState

public void writeState(javax.faces.context.FacesContext facesContext,
                       javax.faces.application.StateManager.SerializedView serializedView)
                throws java.io.IOException
Specified by:
writeState in class javax.faces.application.StateManager
java.io.IOException

writeStateAsUrlParams

public void writeStateAsUrlParams(javax.faces.context.FacesContext facesContext,
                                  javax.faces.application.StateManager.SerializedView serializedView)
                           throws java.io.IOException
MyFaces extension

Specified by:
writeStateAsUrlParams in class MyfacesStateManager
Parameters:
facesContext -
serializedView -
Throws:
java.io.IOException

getRenderKitFactory

protected javax.faces.render.RenderKitFactory getRenderKitFactory()

saveSerializedViewInServletSession

protected void saveSerializedViewInServletSession(javax.faces.context.ExternalContext externalContext,
                                                  java.lang.String viewId,
                                                  javax.faces.application.StateManager.SerializedView serializedView)

getSerializedViewFromServletSession

protected javax.faces.application.StateManager.SerializedView getSerializedViewFromServletSession(javax.faces.context.ExternalContext externalContext,
                                                                                                  java.lang.String viewId)

removeSerializedViewFromServletSession

protected void removeSerializedViewFromServletSession(javax.faces.context.ExternalContext externalContext,
                                                      java.lang.String viewId)