public class DefaultSessionFactory extends Object implements SessionFactory
SessionFactory that allows creation of generic
sessions. It is meant for use with sessions not linked to the servlet engines
and HttpServletRequest. For servlet engines use
com.amadeus.session.servlet.HttpSessionFactory.| Modifier and Type | Field and Description |
|---|---|
protected SessionManager |
sessionManager |
| Constructor and Description |
|---|
DefaultSessionFactory() |
| Modifier and Type | Method and Description |
|---|---|
RepositoryBackedSession |
build(SessionData sessionData)
Builds instance of session based on passed
SessionData. |
void |
committed(RepositoryBackedSession session)
Called by each session when it is committed.
|
protected RepositoryBackedSession |
newSessionObject(SessionData sessionData)
Creates new memory representation of session based on session data.
|
void |
sessionIdChange(SessionData sessionData)
Called by session manager to notify session factory that session id has
changed.
|
void |
setSessionManager(SessionManager sessionManager)
Callback to associated
SessionManager with this instance of factory. |
protected RepositoryBackedSession |
wrapSession(RepositoryBackedSession oldSession)
Wraps old session object into a new one.
|
protected SessionManager sessionManager
public void setSessionManager(SessionManager sessionManager)
SessionFactorySessionManager with this instance of factory.setSessionManager in interface SessionFactorysessionManager - SessionManager to use with this factory.public RepositoryBackedSession build(SessionData sessionData)
SessionFactorySessionData.build in interface SessionFactorysessionData - the descriptor of the session to buildRepositoryBackedSessionprotected RepositoryBackedSession wrapSession(RepositoryBackedSession oldSession)
oldSession - session to wrapprotected RepositoryBackedSession newSessionObject(SessionData sessionData)
sessionData - the session descriptorpublic void committed(RepositoryBackedSession session)
committed in interface SessionFactorysession - the session being committedpublic void sessionIdChange(SessionData sessionData)
SessionFactorysessionIdChange in interface SessionFactorysessionData - the descriptor of the session whose id changesCopyright © 2018 Amadeus s.a.s.. All rights reserved.