Package org.apache.tapestry5
Class BaseOptimizedSessionPersistedObject
java.lang.Object
org.apache.tapestry5.BaseOptimizedSessionPersistedObject
- All Implemented Interfaces:
Serializable
,OptimizedSessionPersistedObject
- Direct Known Subclasses:
DefaultTreeExpansionModel
,DefaultTreeSelectionModel
,GridPaginationModelImpl
,ValidationTrackerImpl
public abstract class BaseOptimizedSessionPersistedObject
extends Object
implements OptimizedSessionPersistedObject, Serializable
Base implementation of
OptimizedSessionPersistedObject
. Subclasses
should invoke markDirty()
after the internal state of the object changes.
Due to the concurrent nature of session attributes it's important that markDirty occurs after
the object has been changed. If the change occurs before the object has been mutated it's possible that another
thread may re-store the object before the changes are actually made!- Since:
- 5.1.1.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
protected final void
Invoked by the subclass after internal state of the object changes.
-
Constructor Details
-
BaseOptimizedSessionPersistedObject
public BaseOptimizedSessionPersistedObject()
-
-
Method Details
-
checkAndResetDirtyMarker
- Specified by:
checkAndResetDirtyMarker
in interfaceOptimizedSessionPersistedObject
- Returns:
- true if the object has in-memory changes since the last time this method was called.
-
markDirty
Invoked by the subclass after internal state of the object changes.
-