org.apache.tapestry5.internal.services
Class PersistentFieldManagerImpl

java.lang.Object
  extended by org.apache.tapestry5.internal.services.PersistentFieldManagerImpl
All Implemented Interfaces:
PersistentFieldManager

public class PersistentFieldManagerImpl
extends Object
implements PersistentFieldManager


Constructor Summary
PersistentFieldManagerImpl(MetaDataLocator locator, Map<String,PersistentFieldStrategy> strategies)
           
 
Method Summary
 void discardChanges(String pageName)
          Discards all changes for the indicated page.
 void discardChanges(String pageName, String strategyName)
          Discards changes on the indicated page for a specific strategy only.
 PersistentFieldBundle gatherChanges(String pageName)
          Locates all persistently stored changes to all properties within the page (for the current session and request) and gathers them together into a bundle.
 void postChange(String pageName, ComponentResources resources, String fieldName, Object newValue)
          Posts a change of a persistent property.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PersistentFieldManagerImpl

public PersistentFieldManagerImpl(MetaDataLocator locator,
                                  Map<String,PersistentFieldStrategy> strategies)
Method Detail

gatherChanges

public PersistentFieldBundle gatherChanges(String pageName)
Description copied from interface: PersistentFieldManager
Locates all persistently stored changes to all properties within the page (for the current session and request) and gathers them together into a bundle.

Specified by:
gatherChanges in interface PersistentFieldManager
Parameters:
pageName - the logical name of the page to gather changes for
Returns:
a bundle identifying all such changes

discardChanges

public void discardChanges(String pageName)
Description copied from interface: PersistentFieldManager
Discards all changes for the indicated page. This will not affect pages that have already been attached to this request, but will affect subsequent page attachments in this and later requests.

Specified by:
discardChanges in interface PersistentFieldManager
Parameters:
pageName - logical name of page whose persistent field data is to be discarded

discardChanges

public void discardChanges(String pageName,
                           String strategyName)
Description copied from interface: PersistentFieldManager
Discards changes on the indicated page for a specific strategy only. This will not affect pages that have already been attached to this request, but will affect subsequent page attachments in this and later requests.

Specified by:
discardChanges in interface PersistentFieldManager
Parameters:
pageName - logical name of page whose persistent field data is to be discarded
strategyName - name of the strategy of which field data is to be discarded

postChange

public void postChange(String pageName,
                       ComponentResources resources,
                       String fieldName,
                       Object newValue)
Description copied from interface: PersistentFieldManager
Posts a change of a persistent property.

Specified by:
postChange in interface PersistentFieldManager
Parameters:
pageName - the logical name of the page containing the component
resources - the resources for the component or mixin (used to determine the persistence strategy)
fieldName - the name of the field whose persistent value has changed
newValue - the new value for the field, possibly null


Copyright © 2003-2012 The Apache Software Foundation.