org.apache.tapestry
Class BaseSessionStoreOptimized

java.lang.Object
  extended by org.apache.tapestry.BaseSessionStoreOptimized
All Implemented Interfaces:
Serializable, EventListener, HttpSessionBindingListener, SessionStoreOptimized

public class BaseSessionStoreOptimized
extends Object
implements SessionStoreOptimized, Serializable, HttpSessionBindingListener

Base implementation of SessionStoreOptimized. Subclasses should invoke markSessionStoreNeeded() any time internal state changed.

Since:
4.0
Author:
Howard M. Lewis Ship
See Also:
Serialized Form

Constructor Summary
BaseSessionStoreOptimized()
           
 
Method Summary
 boolean isStoreToSessionNeeded()
          Returns the dirty flag.
protected  void markSessionStoreNeeded()
          Sets the dirty flag.
 void valueBound(HttpSessionBindingEvent event)
          Clears the dirty flag.
 void valueUnbound(HttpSessionBindingEvent event)
          Does nothing.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseSessionStoreOptimized

public BaseSessionStoreOptimized()
Method Detail

valueBound

public void valueBound(HttpSessionBindingEvent event)
Clears the dirty flag.

Specified by:
valueBound in interface HttpSessionBindingListener

valueUnbound

public void valueUnbound(HttpSessionBindingEvent event)
Does nothing.

Specified by:
valueUnbound in interface HttpSessionBindingListener

markSessionStoreNeeded

protected void markSessionStoreNeeded()
Sets the dirty flag.


isStoreToSessionNeeded

public boolean isStoreToSessionNeeded()
Returns the dirty flag.

Specified by:
isStoreToSessionNeeded in interface SessionStoreOptimized
Returns:
true if the object needs to be stored back into the session, false if the internal state of the object is unchanged


Copyright © 2006-2008 Apache Software Foundation. All Rights Reserved.