com.sdm.quasar.client.jsf.application.dialog.impl
Class DefaultJSFSessionManager

java.lang.Object
  extended bycom.sdm.quasar.client.core.application.AbstractSessionManager
      extended bycom.sdm.quasar.client.jsf.application.dialog.impl.DefaultJSFSessionManager
All Implemented Interfaces:
Disposable, SessionManager

public class DefaultJSFSessionManager
extends AbstractSessionManager
implements SessionManager

The default-implementation of the JSFSessionManager interface.

Version:
1.0
Author:
Carsten Lucke , sd&m AG

Field Summary
 
Fields inherited from class com.sdm.quasar.client.core.application.AbstractSessionManager
listeners
 
Constructor Summary
DefaultJSFSessionManager(Application application, SessionCreator sessionCreator)
          Constructor.
 
Method Summary
 Session createSession()
          If the current http-session is unknown to this SessionManager, a new session is created.
 void disposeSession(SessionId sessionId)
           This method disposes the quasar-client session and invalidates the equivalent http-session.
 
Methods inherited from class com.sdm.quasar.client.core.application.AbstractSessionManager
addSessionListener, createSessionInstance, dispose, fireSessionCreated, fireSessionWillBeDisposed, getApplication, getRegisteredSession, getRegisteredSessionCount, hasRegisteredSession, registerSession, removeSessionListener, unregisterSession
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.sdm.quasar.client.core.application.SessionManager
addSessionListener, removeSessionListener
 

Constructor Detail

DefaultJSFSessionManager

public DefaultJSFSessionManager(Application application,
                                SessionCreator sessionCreator)
Constructor.

See Also:
AbstractSessionManager.AbstractSessionManager(Application, SessionCreator)
Method Detail

createSession

public Session createSession()
If the current http-session is unknown to this SessionManager, a new session is created. Otherwise the already existing session is returned. In both cases the session object is stored as a request attribute with the key DefaultJSFSessionManager#CURRENT_SESSION_REQUEST_CONTEXT_KEY.

Specified by:
createSession in interface SessionManager
Specified by:
createSession in class AbstractSessionManager
Returns:
the session associated with the request that is processed in this thread
See Also:
SessionManager.createSession(), AbstractSessionManager

disposeSession

public void disposeSession(SessionId sessionId)
This method disposes the quasar-client session and invalidates the equivalent http-session.

Specified by:
disposeSession in interface SessionManager
Specified by:
disposeSession in class AbstractSessionManager
See Also:
AbstractSessionManager.disposeSession(com.sdm.quasar.client.core.application.SessionId)