public abstract class AbstractRequestAttributes extends java.lang.Object implements RequestAttributes
requestCompleted()
Modifier and Type | Field and Description |
---|---|
protected java.util.Map<java.lang.String,java.lang.Runnable> |
requestDestructionCallbacks
Map from attribute name String to destruction callback Runnable.
|
REFERENCE_REQUEST, REFERENCE_SESSION, SCOPE_REQUEST, SCOPE_SESSION
Constructor and Description |
---|
AbstractRequestAttributes() |
Modifier and Type | Method and Description |
---|---|
protected boolean |
isRequestActive()
Determine whether the original request is still active.
|
protected void |
registerRequestDestructionCallback(java.lang.String name,
java.lang.Runnable callback)
Register the given callback as to be executed after request completion.
|
protected void |
removeRequestDestructionCallback(java.lang.String name)
Remove the request destruction callback for the specified attribute, if any.
|
void |
requestCompleted()
Signal that the request has been completed.
|
protected abstract void |
updateAccessedSessionAttributes()
Update all session attributes that have been accessed during request processing,
to expose their potentially updated state to the underlying session manager.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAttribute, getAttributeNames, getSessionId, getSessionMutex, registerDestructionCallback, removeAttribute, resolveReference, setAttribute
protected final java.util.Map<java.lang.String,java.lang.Runnable> requestDestructionCallbacks
public void requestCompleted()
Executes all request destruction callbacks and updates the session attributes that have been accessed during request processing.
protected final boolean isRequestActive()
requestCompleted()
protected final void registerRequestDestructionCallback(java.lang.String name, java.lang.Runnable callback)
name
- the name of the attribute to register the callback forcallback
- the callback to be executed for destructionprotected final void removeRequestDestructionCallback(java.lang.String name)
name
- the name of the attribute to remove the callback forprotected abstract void updateAccessedSessionAttributes()