org.apache.myfaces.trinidad.change
Class SessionChangeManager

java.lang.Object
  extended by org.apache.myfaces.trinidad.change.ChangeManager
      extended by org.apache.myfaces.trinidad.change.SessionChangeManager

public class SessionChangeManager
extends ChangeManager

A ChangeManager implementation that manages persisting the added Changes at the session. This means the lifetime of Changes added such is within the session scope.

Version:
$Name: $ ($Revision: adfrt/faces/adf-faces-impl/src/main/java/oracle/adfinternal/view/faces/change/SessionChangeManager.java#0 $) $Date: 10-nov-2005.19:06:35 $

Constructor Summary
SessionChangeManager()
           
 
Method Summary
 void addComponentChange(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent uiComponent, ComponentChange change)
          Add a ComponentChange to this current request for a specified component.
protected  void addComponentChangeImpl(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent targetComponent, ComponentChange componentChange)
          Adds a ComponentChange and registers against the supplied component.
 void applyComponentChangesForCurrentView(javax.faces.context.FacesContext facesContext)
          Applies all the ComponentChanges added so far for the current view.
protected  org.w3c.dom.Document getDocument(javax.faces.context.FacesContext context)
          We don't support DocumentChange persistence
protected  void persistDocumentChanges(javax.faces.context.FacesContext facesContext)
           
protected  boolean supportsDocumentPersistence(javax.faces.context.FacesContext context)
          Returns true if we can support Document-based Persistence in this ChangeManager.
 
Methods inherited from class org.apache.myfaces.trinidad.change.ChangeManager
addDocumentChange, createDocumentChange, registerDocumentFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SessionChangeManager

public SessionChangeManager()
Method Detail

applyComponentChangesForCurrentView

public void applyComponentChangesForCurrentView(javax.faces.context.FacesContext facesContext)
Applies all the ComponentChanges added so far for the current view. Developers should not need to call this method. Internal implementation will call it as the component tree is built and is ready to take changes.

Overrides:
applyComponentChangesForCurrentView in class ChangeManager
Parameters:
facesContext - The FacesContext instance for the current request.

addComponentChangeImpl

protected void addComponentChangeImpl(javax.faces.context.FacesContext facesContext,
                                      javax.faces.component.UIComponent targetComponent,
                                      ComponentChange componentChange)
Adds a ComponentChange and registers against the supplied component. Changes added thus live at Session scope. Use applyComponentChangesForCurrentView() to apply these changes.

Parameters:
facesContext - The FacesContext instance for the current request.
targetComponent - The target component against which this change needs to be registered and applied later on.
componentChange - The ComponentChange to add.

getDocument

protected org.w3c.dom.Document getDocument(javax.faces.context.FacesContext context)
We don't support DocumentChange persistence


addComponentChange

public void addComponentChange(javax.faces.context.FacesContext facesContext,
                               javax.faces.component.UIComponent uiComponent,
                               ComponentChange change)
Add a ComponentChange to this current request for a specified component.

Specified by:
addComponentChange in class ChangeManager

persistDocumentChanges

protected void persistDocumentChanges(javax.faces.context.FacesContext facesContext)

supportsDocumentPersistence

protected boolean supportsDocumentPersistence(javax.faces.context.FacesContext context)
Returns true if we can support Document-based Persistence in this ChangeManager. Subclassers adding Document-based Persistence should override this method and must override getDocument in order to enable Document-based Persistence.

Parameters:
context -
Returns:
true if we can support Document-based Persistence


Copyright © 2001-2009 The Apache Software Foundation. All Rights Reserved.