com.sdm.quasar.client.spring.application.dialog.impl
Class SpringSessionCreator

java.lang.Object
  extended bycom.sdm.quasar.client.core.application.dialog.impl.AbstractSessionCreator
      extended bycom.sdm.quasar.client.spring.application.dialog.impl.SpringSessionCreator
All Implemented Interfaces:
SessionCreator

public class SpringSessionCreator
extends AbstractSessionCreator
implements SessionCreator

Creates the session using a spring bean factory.

See Also:
createSession(com.sdm.quasar.client.core.application.SessionId, com.sdm.quasar.client.core.application.Application)

Constructor Summary
SpringSessionCreator(java.lang.String sessionConfigFilename)
          Constructor.
 
Method Summary
 Session createSession(SessionId sessionId, Application application)
          Creates the session using a spring bean factory.
protected  void registerMultipleServices(DialogServiceManager dialogServiceManager, DialogInstanceId sessionDialogId, java.util.Map serviceMap)
          Registers all given services for the session id.
 
Methods inherited from class com.sdm.quasar.client.core.application.dialog.impl.AbstractSessionCreator
createAndActivateSession, createSessionDialogInstanceId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpringSessionCreator

public SpringSessionCreator(java.lang.String sessionConfigFilename)
Constructor.

Parameters:
sessionConfigFilename - the filename of the Spring configuration of the session, see createSession(com.sdm.quasar.client.core.application.SessionId, com.sdm.quasar.client.core.application.Application) for details.
Method Detail

createSession

public Session createSession(SessionId sessionId,
                             Application application)
Creates the session using a spring bean factory.

The following contract is made between the xml definition and the bean factory configuration:

Specified by:
createSession in interface SessionCreator
Parameters:
sessionId - the session id for the new session instance
application - the application
Returns:
the new session instance

registerMultipleServices

protected void registerMultipleServices(DialogServiceManager dialogServiceManager,
                                        DialogInstanceId sessionDialogId,
                                        java.util.Map serviceMap)
Registers all given services for the session id.

Parameters:
dialogServiceManager - the DialogServiceManager to register services at
sessionDialogId - the DialogInstanceId of the session
serviceMap - the map containing the service interface class or the classname as key and the service implementation as value.
See Also:
for information about the content of the map.