|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SessionManager
Session Manager. The API required to manage sessions for a servlet context.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface org.mortbay.component.LifeCycle |
---|
LifeCycle.Listener |
Field Summary | |
---|---|
static String |
__DefaultSessionCookie
|
static String |
__DefaultSessionDomain
|
static String |
__DefaultSessionURL
|
static String |
__MaxAgeProperty
Session Max Age. |
static String |
__SessionCookieProperty
Session cookie name. |
static String |
__SessionDomainProperty
Session Domain. |
static String |
__SessionPathProperty
Session Path. |
static String |
__SessionURLProperty
Session URL parameter name. |
Methods inherited from interface org.mortbay.component.LifeCycle |
---|
addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop |
Field Detail |
---|
static final String __SessionCookieProperty
static final String __DefaultSessionCookie
static final String __SessionURLProperty
static final String __DefaultSessionURL
static final String __SessionDomainProperty
static final String __DefaultSessionDomain
static final String __SessionPathProperty
static final String __MaxAgeProperty
Method Detail |
---|
HttpSession getHttpSession(String id)
HttpSession newHttpSession(HttpServletRequest request)
boolean getSecureCookies()
boolean getHttpOnly()
int getMaxInactiveInterval()
void setMaxInactiveInterval(int seconds)
void setSessionHandler(SessionHandler handler)
void addEventListener(EventListener listener)
listener
- An Event Listener. Individual SessionManagers
implemetations may accept arbitrary listener types, but they
are expected to at least handle
HttpSessionActivationListener,
HttpSessionAttributeListener,
HttpSessionBindingListener,
HttpSessionListenervoid removeEventListener(EventListener listener)
void clearEventListeners()
Cookie getSessionCookie(HttpSession session, String contextPath, boolean requestIsSecure)
session
- The session to which the cookie should refer.contextPath
- The context to which the cookie should be linked. The client will only send the cookie value
when requesting resources under this path.requestIsSecure
- Whether the client is accessing the server over a secure protocol (i.e. HTTPS).
SessionManager
uses cookies, then this method will return a new
cookie object
that should be set on the client in order to link future HTTP requests
with the session
. If cookies are not in use, this method returns null
.SessionIdManager getIdManager()
SessionIdManager getMetaManager()
getIdManager()
void setIdManager(SessionIdManager meta)
meta
- the cross context session meta manager.boolean isValid(HttpSession session)
String getNodeId(HttpSession session)
session
-
String getClusterId(HttpSession session)
session
-
Cookie access(HttpSession session, boolean secure)
SessionHandler
when a session is access by a request
void complete(HttpSession session)
SessionHandler
when a reqeuest is not longer
handling a session. Not this includes new sessions, so there may not
be a matching call to #access(HttpSession)
.
void setSessionCookie(String cookieName)
String getSessionCookie()
void setSessionURL(String url)
String getSessionURL()
String getSessionURLPrefix()
void setSessionDomain(String domain)
String getSessionDomain()
void setSessionPath(String path)
String getSessionPath()
void setMaxCookieAge(int maxCookieAgeInSeconds)
int getMaxCookieAge()
boolean isUsingCookies()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |