org.apache.myfaces.lifecycle
Interface RestoreViewSupport

All Known Implementing Classes:
DefaultRestoreViewSupport

public interface RestoreViewSupport

Support class for restore view phase

Version:
$Revision: 887436 $ $Date: 2009-12-04 18:11:25 -0500 (Fri, 04 Dec 2009) $
Author:
Mathias Broekelmann (latest modification by $Author: lu4242 $)

Method Summary
 String calculateViewId(FacesContext facesContext)
           Calculates the view id from the given faces context by the following algorithm
 String deriveViewId(FacesContext context, String viewId)
          Derive a view id retrieved from calling calculateViewId(FacesContext), but do not check if a resource with this name exists.
 boolean isPostback(FacesContext facesContext)
           Determine if the current request is a post back by the following algorithm.
 void processComponentBinding(FacesContext facesContext, UIComponent component)
          Processes the component tree.
 

Method Detail

calculateViewId

String calculateViewId(FacesContext facesContext)

Calculates the view id from the given faces context by the following algorithm


deriveViewId

String deriveViewId(FacesContext context,
                    String viewId)
Derive a view id retrieved from calling calculateViewId(FacesContext), but do not check if a resource with this name exists. This method is useful to retrieve a VDL instance, but note there are some cases (TCK test) where it is expected in Restore View algorithm a null or dummy viewId is passed.

Parameters:
context -
viewId -
Returns:

processComponentBinding

void processComponentBinding(FacesContext facesContext,
                             UIComponent component)
Processes the component tree. For each component (including the given one) in the tree determine if a value expression for the attribute "binding" is defined. If the expression is not null set the component instance to the value of this expression

Parameters:
facesContext -
component - the root component

isPostback

boolean isPostback(FacesContext facesContext)

Determine if the current request is a post back by the following algorithm.

Find the render-kit-id for the current request by calling calculateRenderKitId() on the Application’s ViewHandler. Get that RenderKit’s ResponseStateManager and call its isPostback() method, passing the given FacesContext.

Parameters:
facesContext -
Returns:


Copyright © 2014 The Apache Software Foundation. All Rights Reserved.