Package com.microstrategy.web.beans
Class WebSessionManagerImpl
- java.lang.Object
-
- com.microstrategy.utils.serialization.AbstractPersistable
-
- com.microstrategy.web.beans.WebSessionManagerImpl
-
- All Implemented Interfaces:
EnumWebPersistableState
,Persistable
,RequestPersistable
,WebSessionManager
- Direct Known Subclasses:
WebAppSessionManagerImpl
public class WebSessionManagerImpl extends AbstractPersistable implements WebSessionManager
- Since:
- MicroStrategy Web 8.0.1
-
-
Field Summary
Fields Modifier and Type Field Description protected WebIServerSessionList
_sessionList
static java.lang.String
WebSessionManagerState
static java.lang.String
WebUserSessionManagerState
-
Fields inherited from class com.microstrategy.utils.serialization.AbstractPersistable
scriptEndTagEncoder
-
Fields inherited from interface com.microstrategy.utils.serialization.EnumWebPersistableState
BARE_MINIMAL_STATE_INFO, MAXIMAL_STATE_INFO, MINIMAL_STATE_INFO, TYPICAL_STATE_INFO
-
-
Constructor Summary
Constructors Constructor Description WebSessionManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description WebIServerSession
getActiveSession()
Returns theWebIServerSession
in the list currently considered to be active.java.lang.String
getKey()
Returns the key of the Session Manager.WebIServerSession
getSession(java.lang.String server, int port, java.lang.String project)
WebIServerSessionList
getSessionList()
Returns the underlyingWebIServerSessionList
object.protected void
init()
WebIServerSession
initActiveSessionFromRequestKeys(RequestKeys rk, AbstractConfigurableContainerServices acs)
protected boolean
restoreSessionListState(WebIServerSessionList list, java.lang.String state)
protected boolean
restoreState(RequestKeys rk, java.lang.String key, java.lang.String state)
boolean
restoreState(java.lang.String state)
Restores a component based on its saved state.boolean
restoreStateFromRequest(RequestKeys rk)
Restores aWebComponent
based on theRequestKeys
instance.boolean
restoreStateFromRequest(RequestKeys rk, java.lang.String keyName)
Restores aWebComponent
based on theRequestKeys
instance.WebIServerSession
setActiveSession(java.lang.String key)
Sets the active session to be the session with the given key in the collection.-
Methods inherited from class com.microstrategy.utils.serialization.AbstractPersistable
doFlatState, doFlatState, getStateHandler, isXMLStateZipped, restoreState, restoreXMLState, saveState, saveState, saveState, saveState, saveXMLState, saveXMLState
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.microstrategy.utils.serialization.Persistable
restoreState, saveState, saveState, saveState, saveState
-
-
-
-
Field Detail
-
WebSessionManagerState
public static final java.lang.String WebSessionManagerState
- See Also:
- Constant Field Values
-
WebUserSessionManagerState
public static final java.lang.String WebUserSessionManagerState
- See Also:
- Constant Field Values
-
_sessionList
protected WebIServerSessionList _sessionList
-
-
Method Detail
-
init
protected void init()
-
getSessionList
public WebIServerSessionList getSessionList()
Description copied from interface:WebSessionManager
Returns the underlyingWebIServerSessionList
object. This object represents a list of sessions that are being managed by the session manager.- Specified by:
getSessionList
in interfaceWebSessionManager
- Returns:
- The
WebIServerSessionList
object representing the list of sessions being managed by the session manager.
-
setActiveSession
public WebIServerSession setActiveSession(java.lang.String key)
Description copied from interface:WebSessionManager
Sets the active session to be the session with the given key in the collection. The newly set active session will be returned. If there exists no session with the given key in the collection, then this method will return null.- Specified by:
setActiveSession
in interfaceWebSessionManager
- Parameters:
key
- The key to look for in the session list.- Returns:
- The session set as active, or null if the active session has not changed.
-
getActiveSession
public WebIServerSession getActiveSession()
Description copied from interface:WebSessionManager
Returns theWebIServerSession
in the list currently considered to be active.- Specified by:
getActiveSession
in interfaceWebSessionManager
- Returns:
- The current active session.
-
restoreStateFromRequest
public boolean restoreStateFromRequest(RequestKeys rk)
Description copied from interface:RequestPersistable
Restores aWebComponent
based on theRequestKeys
instance. This method retrieves the saved state of a component based on the component's name.- Specified by:
restoreStateFromRequest
in interfaceRequestPersistable
- Parameters:
rk
- aRequestKeys
instance.- Returns:
- true if restoration succeeds.
-
restoreState
protected boolean restoreState(RequestKeys rk, java.lang.String key, java.lang.String state)
-
restoreState
public boolean restoreState(java.lang.String state)
Description copied from interface:Persistable
Restores a component based on its saved state.- Specified by:
restoreState
in interfacePersistable
- Overrides:
restoreState
in classAbstractPersistable
- Parameters:
state
- the state of a component- Returns:
- true if restoration succeeds.
-
restoreStateFromRequest
public boolean restoreStateFromRequest(RequestKeys rk, java.lang.String keyName)
Description copied from interface:RequestPersistable
Restores aWebComponent
based on theRequestKeys
instance. This method retrieves the saved state of a component based on the parameter keyName.- Specified by:
restoreStateFromRequest
in interfaceRequestPersistable
- Parameters:
rk
- aRequestKeys
instance.keyName
- the key to the state of a component.- Returns:
- true if restoration succeeds.
-
getKey
public java.lang.String getKey()
Returns the key of the Session Manager. This value is used to store and retrieve the state of the Session Manager.
-
restoreSessionListState
protected boolean restoreSessionListState(WebIServerSessionList list, java.lang.String state)
-
initActiveSessionFromRequestKeys
public WebIServerSession initActiveSessionFromRequestKeys(RequestKeys rk, AbstractConfigurableContainerServices acs)
- Specified by:
initActiveSessionFromRequestKeys
in interfaceWebSessionManager
-
getSession
public WebIServerSession getSession(java.lang.String server, int port, java.lang.String project)
-
-