Class SessionState
java.lang.Object
com.aquima.interactions.portal.model.session.state.SessionState
- All Implemented Interfaces:
ISessionState
,Serializable
This class contains the information of a single portal session. The session state can be converted to and from XML
using the SessionStateSerializer class.
- Since:
- 6.3
- Author:
- O. Kerpershoek
- See Also:
-
Constructor Summary
ModifierConstructorDescriptionprotected
SessionState
(ApplicationID appId, IFlowState flowState, String languageCode, PortalContextDump portalContext, PageScopeDump pageScope, SessionScopeDump sessionScope, FlowScopeDump flowScope, String profileXml, IPage currentPage) SessionState
(TxPortalContext context, IPage currentPage) Constructs a session state object using the session information provided by the portal context.SessionState
(TxPortalContext context, IPage currentPage, boolean xml) Constructs a session state object using the session information provided by the portal context. -
Method Summary
Modifier and TypeMethodDescriptionThis method returns the ID of the application for which the session was saved.This method (re)creates the current page.This method (re)creates the flow scope.This method returns the flow state of the session.getInstanceContext
(TmsProfile tmsProfile) This method (re)creates the instance context for the session.This method returns the current language (code) of the session.getPageScope
(ISolution application) This method (re)creates the page scope using the definitions from the application model.protected PageScopeDump
protected PortalContextDump
protected IXmlElement
getSessionScope
(ISolution application) This method (re)creates the session scope using the definitions from the application model.protected SessionScopeDump
void
initializeProfile
(IModule application, IProfile profile) This method is invoked to allow the session state to initialize the profile with the values of the saved session.
-
Constructor Details
-
SessionState
Constructs a session state object using the session information provided by the portal context.- Parameters:
context
- The portal context containing the session information.currentPage
- The current page.- Throws:
AppException
- This exception is thrown when the session state could not be created for the specified portal context.
-
SessionState
Constructs a session state object using the session information provided by the portal context.- Parameters:
context
- The portal context containing the session information.currentPage
- The current page.xml
- True for XML serialization, false for binary serialization.- Throws:
AppException
- This exception is thrown when the session state could not be created for the specified portal context.
-
SessionState
protected SessionState(ApplicationID appId, IFlowState flowState, String languageCode, PortalContextDump portalContext, PageScopeDump pageScope, SessionScopeDump sessionScope, FlowScopeDump flowScope, String profileXml, IPage currentPage)
-
-
Method Details
-
getProfileState
-
getApplicationId
Description copied from interface:ISessionState
This method returns the ID of the application for which the session was saved.- Specified by:
getApplicationId
in interfaceISessionState
- Returns:
- the ID of the application for which the session was saved.
-
getLanguageCode
Description copied from interface:ISessionState
This method returns the current language (code) of the session.- Specified by:
getLanguageCode
in interfaceISessionState
- Returns:
- the current language (code) of the session.
-
getFlowState
Description copied from interface:ISessionState
This method returns the flow state of the session.- Specified by:
getFlowState
in interfaceISessionState
- Returns:
- the flow state of the session.
-
getProfileXml
-
getPageScope
Description copied from interface:ISessionState
This method (re)creates the page scope using the definitions from the application model.- Specified by:
getPageScope
in interfaceISessionState
- Parameters:
application
- The application model containing the definitions of the application.- Returns:
- Page scope for the session.
-
getFlowScope
Description copied from interface:ISessionState
This method (re)creates the flow scope.- Specified by:
getFlowScope
in interfaceISessionState
- Returns:
- Flow scope for the session.
-
getSessionScope
Description copied from interface:ISessionState
This method (re)creates the session scope using the definitions from the application model.- Specified by:
getSessionScope
in interfaceISessionState
- Parameters:
application
- The application model containing the definitions of the application.- Returns:
- Session scope for the session.
-
initializeProfile
Description copied from interface:ISessionState
This method is invoked to allow the session state to initialize the profile with the values of the saved session.- Specified by:
initializeProfile
in interfaceISessionState
- Parameters:
application
- The application model containing the definitions of the application.profile
- The profile that should be initialized.
-
getInstanceContext
Description copied from interface:ISessionState
This method (re)creates the instance context for the session.- Specified by:
getInstanceContext
in interfaceISessionState
- Parameters:
tmsProfile
- The profile that should be used for the root context.- Returns:
- The instance context for the session.
-
getPageScopeDump
-
getSessionScopeDump
-
getPortalContextDump
-
getFlowScopeDump
-
getCurrentPage
Description copied from interface:ISessionState
This method (re)creates the current page.- Specified by:
getCurrentPage
in interfaceISessionState
- Returns:
- The current page, may be null.
-