public class FlowViewStateManager
extends javax.faces.application.StateManager
StateManager that manages the JSF component state in web flow's view scope.| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
SERIALIZED_VIEW_STATE |
FULL_STATE_SAVING_VIEW_IDS_PARAM_NAME, IS_BUILDING_INITIAL_STATE, IS_SAVING_STATE, PARTIAL_STATE_SAVING_PARAM_NAME, SERIALIZE_SERVER_STATE_PARAM_NAME, STATE_SAVING_METHOD_CLIENT, STATE_SAVING_METHOD_PARAM_NAME, STATE_SAVING_METHOD_SERVER| Constructor and Description |
|---|
FlowViewStateManager(javax.faces.application.StateManager delegate) |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.Object |
getComponentStateToSave(javax.faces.context.FacesContext context) |
protected java.lang.Object |
getTreeStructureToSave(javax.faces.context.FacesContext context) |
java.lang.String |
getViewState(javax.faces.context.FacesContext context) |
boolean |
isSavingStateInClient(javax.faces.context.FacesContext context) |
protected void |
restoreComponentState(javax.faces.context.FacesContext context,
javax.faces.component.UIViewRoot viewRoot,
java.lang.String renderKitId) |
protected javax.faces.component.UIViewRoot |
restoreTreeStructure(javax.faces.context.FacesContext context,
java.lang.String viewId,
java.lang.String renderKitId) |
javax.faces.component.UIViewRoot |
restoreView(javax.faces.context.FacesContext context,
java.lang.String viewId,
java.lang.String renderKitId)
In JSF 2 where a partial state saving algorithm is used, this method merely delegates to the next
ViewStateManager.
|
javax.faces.application.StateManager.SerializedView |
saveSerializedView(javax.faces.context.FacesContext context)
JSF 1.1 version of state saving
|
java.lang.Object |
saveView(javax.faces.context.FacesContext context)
JSF 1.2 (or higher) version of state saving.
|
void |
writeState(javax.faces.context.FacesContext context,
java.lang.Object state) |
void |
writeState(javax.faces.context.FacesContext context,
javax.faces.application.StateManager.SerializedView state) |
protected static final java.lang.String SERIALIZED_VIEW_STATE
public FlowViewStateManager(javax.faces.application.StateManager delegate)
protected java.lang.Object getComponentStateToSave(javax.faces.context.FacesContext context)
getComponentStateToSave in class javax.faces.application.StateManagerprotected java.lang.Object getTreeStructureToSave(javax.faces.context.FacesContext context)
getTreeStructureToSave in class javax.faces.application.StateManagerprotected void restoreComponentState(javax.faces.context.FacesContext context,
javax.faces.component.UIViewRoot viewRoot,
java.lang.String renderKitId)
restoreComponentState in class javax.faces.application.StateManagerprotected javax.faces.component.UIViewRoot restoreTreeStructure(javax.faces.context.FacesContext context,
java.lang.String viewId,
java.lang.String renderKitId)
restoreTreeStructure in class javax.faces.application.StateManagerpublic void writeState(javax.faces.context.FacesContext context,
javax.faces.application.StateManager.SerializedView state)
throws java.io.IOException
writeState in class javax.faces.application.StateManagerjava.io.IOExceptionpublic void writeState(javax.faces.context.FacesContext context,
java.lang.Object state)
throws java.io.IOException
writeState in class javax.faces.application.StateManagerjava.io.IOExceptionpublic boolean isSavingStateInClient(javax.faces.context.FacesContext context)
isSavingStateInClient in class javax.faces.application.StateManagerpublic javax.faces.application.StateManager.SerializedView saveSerializedView(javax.faces.context.FacesContext context)
saveSerializedView in class javax.faces.application.StateManagerpublic java.lang.Object saveView(javax.faces.context.FacesContext context)
JSF 1.2 (or higher) version of state saving.
In JSF 2, if partial state saving is enabled this method delegates in order to obtain the serialized view state.
During rendering JSF calls this method to prepare the state and then calls FlowViewResponseStateManager
which writes it to Web Flow's view scope.
Nevertheless this method always writes the serialized state to Web Flow's view scope to ensure it is up-to-date
for cases outside of rendering (e.g. ViewState.updateHistory()) or when the render phase doesn't call
FlowViewResponseStateManager such as when processing a partial request.
saveView in class javax.faces.application.StateManagerpublic javax.faces.component.UIViewRoot restoreView(javax.faces.context.FacesContext context,
java.lang.String viewId,
java.lang.String renderKitId)
In JSF 2 where a partial state saving algorithm is used, this method merely delegates to the next
ViewStateManager. Thus partial state saving is handled by the JSF 2 runtime. However, a
FlowViewResponseStateManager plugged in via FlowRenderKit will ensure the state is saved in a Web
Flow view-scoped variable.
restoreView in class javax.faces.application.StateManagerpublic java.lang.String getViewState(javax.faces.context.FacesContext context)
getViewState in class javax.faces.application.StateManager