public class PageRecorderImpl extends java.lang.Object implements IPageRecorder
Constructor and Description |
---|
PageRecorderImpl(java.lang.String pageName,
IRequestCycle requestCycle,
PropertyPersistenceStrategySource strategySource,
org.apache.hivemind.ErrorLog log) |
Modifier and Type | Method and Description |
---|---|
void |
commit()
Persists all changes that have been accumulated.
|
java.util.Collection |
getChanges() |
void |
observeChange(ObservedChangeEvent event)
Sent when the observed object changes a property.
|
void |
rollback(IPage page)
Rolls back the page to the currently persisted state.
|
public PageRecorderImpl(java.lang.String pageName, IRequestCycle requestCycle, PropertyPersistenceStrategySource strategySource, org.apache.hivemind.ErrorLog log)
public void commit()
IPageRecorder
After commiting, a page recorder automatically locks itself.
commit
in interface IPageRecorder
public java.util.Collection getChanges()
public void rollback(IPage page)
IPageRecorder
A page recorder can only rollback changes to properties which have changed at some point.
This can cause some minor problems, addressed by
PageDetachListener.pageDetached(org.apache.tapestry.event.PageEvent)
.
rollback
in interface IPageRecorder
public void observeChange(ObservedChangeEvent event)
ChangeObserver
observeChange
in interface ChangeObserver