Business Components

oracle.jbo.http
Class HttpSessionCookieImpl

java.lang.Object
  |
  +--oracle.jbo.common.ampool.SessionCookieImpl
        |
        +--oracle.jbo.http.HttpSessionCookieImpl
All Implemented Interfaces:
ApplicationModuleRef, oracle.jbo.http.BindingListener, HttpSessionCookie, java.io.Serializable, SessionCookie
Direct Known Subclasses:
SharedSessionCookieImpl

public class HttpSessionCookieImpl
extends SessionCookieImpl
implements HttpSessionCookie, oracle.jbo.http.BindingListener, java.io.Serializable

Default HttpSessionCookie implementation.

The implementation uses a pluggable helper interface, HttpSessionCookieHelper, to generate unique session identifiers for browser sessions, to read browser cookie values, and to write browser cookie values.

Implements the BindingListener interface. When a session HttpContainer instance is unbound from an HttpSession context the BindingListeners will be notified that a timeout event occured. The timeout implementation releases the application module resource to the application pool. The release is unmanaged since the request is assumed to have already ended.

Finally, the HttpSessionCookie implementation uses composition to implement the SessionCookie interface. All SessionCookie methods are delegated to an instance of the default SessionCookie implementation. Please see SessionCookieImpl for more infomartion regarding the default session cookie implementation.

See Also:
Serialized Form

Fields inherited from interface oracle.jbo.common.ampool.SessionCookie
NULL_PASSIVATION_ID
 
Constructor Summary
HttpSessionCookieImpl(java.lang.String applicationId, java.lang.String sessionId, ApplicationPool pool)
          This constructor may be used if the sessionId is already known.
 
Method Summary
TypeMethod
 boolean isFailoverEnabled()
          Indicates that session application module state should be persisted to secondary storage immediately upon a managed release.
 java.lang.String readValue(java.lang.Object source)
          Read the cookie value to the specified data sink.
 void timeout(oracle.jbo.http.BindingEvent ev)
           
 void valueBound(oracle.jbo.http.BindingEvent ev)
           
 void valueUnbound(oracle.jbo.http.BindingEvent ev)
           
 void writeValue(java.lang.Object sink)
          Write the cookie value to the specified data sink.
 
Methods inherited from class oracle.jbo.common.ampool.SessionCookieImpl
copyInto, equals, getApplicationId, getEnvInfoProvider, getEnvironment, getLastUpdate, getPassivationId, getPoolSignature, getProperty, getReservedPassivationId, getSessionId, getSyncLock, getUserData, getValue, hashCode, isActivationRequired, isApplicationModuleReserved, isConnectionPoolingEnabled, isResetNonTransactionalState, parsePassivationId, parseSessionId, releaseApplicationModule, releaseApplicationModule, reservePassivationId, resetState, setActivationRequired, setEnvInfoProvider, setEnvironment, setPassivationId, setReservedPassivationId, setSessionCookieListener, timeout, toString, useApplicationModule, useApplicationModule, useApplicationModule
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface oracle.jbo.common.ampool.SessionCookie
copyInto, equals, getApplicationId, getEnvInfoProvider, getEnvironment, getLastUpdate, getPassivationId, getPoolSignature, getReservedPassivationId, getSessionId, getSyncLock, getUserData, getValue, hashCode, isActivationRequired, isConnectionPoolingEnabled, isResetNonTransactionalState, reservePassivationId, resetState, setActivationRequired, setEnvInfoProvider, setEnvironment, setPassivationId, setReservedPassivationId, setSessionCookieListener, toString
 
Methods inherited from interface oracle.jbo.common.ampool.ApplicationModuleRef
isApplicationModuleReserved, releaseApplicationModule, releaseApplicationModule, useApplicationModule, useApplicationModule, useApplicationModule
 

Constructor Detail

HttpSessionCookieImpl

public HttpSessionCookieImpl(java.lang.String applicationId,
                             java.lang.String sessionId,
                             ApplicationPool pool)
This constructor may be used if the sessionId is already known.
Method Detail

valueBound

public void valueBound(oracle.jbo.http.BindingEvent ev)
Specified by:
valueBound in interface oracle.jbo.http.BindingListener

valueUnbound

public void valueUnbound(oracle.jbo.http.BindingEvent ev)
Specified by:
valueUnbound in interface oracle.jbo.http.BindingListener

timeout

public void timeout(oracle.jbo.http.BindingEvent ev)
Specified by:
timeout in interface oracle.jbo.http.BindingListener

writeValue

public void writeValue(java.lang.Object sink)
Description copied from interface: SessionCookie
Write the cookie value to the specified data sink.

Specified by:
writeValue in interface SessionCookie
Overrides:
writeValue in class SessionCookieImpl
Following copied from interface: oracle.jbo.common.ampool.SessionCookie
Parameters:
sink - a data sink

readValue

public java.lang.String readValue(java.lang.Object source)
Description copied from interface: SessionCookie
Read the cookie value to the specified data sink.

Specified by:
readValue in interface SessionCookie
Overrides:
readValue in class SessionCookieImpl
Following copied from interface: oracle.jbo.common.ampool.SessionCookie
Parameters:
source - a data source

isFailoverEnabled

public boolean isFailoverEnabled()
Description copied from interface: SessionCookie
Indicates that session application module state should be persisted to secondary storage immediately upon a managed release.

Session cookie developers should be careful that this value not change after a session cookie has become active.

Specified by:
isFailoverEnabled in interface SessionCookie
Overrides:
isFailoverEnabled in class SessionCookieImpl

Business Components