|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectBaseHandler
DefaultHandler
SimpleSessionStorageHandler
public class SimpleSessionStorageHandler
This storage handler simply puts/gets attributes in the session. It does not do anything to support multiple concurrent forwarded requests that are simultaneously modifying session data.
DeferredSessionStorageHandler
,
Serialized FormConstructor Summary | |
---|---|
SimpleSessionStorageHandler(ServletContext servletContext)
|
Method Summary | |
---|---|
boolean |
allowBindingEvent(Object event)
Tell whether a given binding event should be allowed to occur. |
void |
applyChanges(RequestContext context)
Apply any deferred changes, at the end of a chain of requests. |
void |
ensureFailover(RequestContext context,
String attributeName,
Object value)
Ensure that the given named attribute is replicated in a cluster for session failover, if appropriate. |
Object |
getAttribute(RequestContext context,
String attributeName)
Get a named attribute. |
void |
removeAttribute(RequestContext context,
String attributeName)
Remove a named attribute. |
void |
setAttribute(RequestContext context,
String attributeName,
Object value)
Set a named attribute. |
Methods inherited from class DefaultHandler |
---|
getRegisteredHandler, setRegisteredHandler |
Methods inherited from class BaseHandler |
---|
getConfig, getPreviousHandler, getServletContext, init, reinit |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface Handler |
---|
init, reinit |
Constructor Detail |
---|
public SimpleSessionStorageHandler(ServletContext servletContext)
Method Detail |
---|
public void setAttribute(RequestContext context, String attributeName, Object value)
StorageHandler
setAttribute
in interface StorageHandler
context
- the current RequestContext.attributeName
- the name of the attribute to set.value
- the attribute value.public void removeAttribute(RequestContext context, String attributeName)
StorageHandler
removeAttribute
in interface StorageHandler
context
- the current RequestContext.attributeName
- the name of the attribute to remove.public Object getAttribute(RequestContext context, String attributeName)
StorageHandler
getAttribute
in interface StorageHandler
context
- the current RequestContext.attributeName
- the name of the attribute to get.
null
if there is no such named attribute.public void ensureFailover(RequestContext context, String attributeName, Object value)
StorageHandler
ensureFailover
in interface StorageHandler
context
- the current request context.attributeName
- the name of the attribute for which failover should be ensured.value
- the value of the attribute for which failover should be ensured.public boolean allowBindingEvent(Object event)
StorageHandler
HttpSession
) at some time other than
when StorageHandler.setAttribute(org.apache.beehive.netui.pageflow.RequestContext, java.lang.String, java.lang.Object)
is called, in which case a binding event would be misleading. Only
PageFlowManagedObject
s pay attention to this.
allowBindingEvent
in interface StorageHandler
event
- the binding event, e.g., javax.servlet.http.HttpSessionBindingEvent
true
if the event should be processed.public void applyChanges(RequestContext context)
StorageHandler
applyChanges
in interface StorageHandler
context
- the current request context.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |