Package com.aquima.web.controller
Class StartController
java.lang.Object
com.aquima.web.controller.StartController
This class is the main controller for creating an Aquima session and executing a flow. Note: in 9.7 the
StartController
is introduced for Blueriq Mobile. This controller maps the same requests, but returns JSON
messages instead of HTML as this controller does. To determine which controller to use, the Accept request header is
checked to see if "application/json" is expected, in which case the JsonStartController will be used. In all other
cases this controller will be used.- Since:
- 8.0
- Author:
- Danny Roest
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionStartController
(com.blueriq.component.api.IAquimaEngineConfiguration config, com.blueriq.component.api.security.IAuthorisationManager authorisationManager, com.blueriq.component.api.IAquimaSessionsMap sessionManager, FlowStarter flowStarter, com.blueriq.component.api.shortcut.IShortcutManager shortcutsManager, ProductionProperties productionProperties, MvcRedirectHelper redirectHelper) Creates a start which is the main controller for starting a aquima-interactions flow. -
Method Summary
Modifier and TypeMethodDescriptioncloseSession
(String sessionId) void
createSession
(org.springframework.web.context.request.WebRequest request, String projectName, String flow, String version, String languageCode, String aquimaUi, String theme, String channel, javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse response) loginSuccess
(org.springframework.web.context.request.WebRequest request, javax.servlet.http.HttpServletRequest servletRequest) This method closes all Aquima sessions and redirects to the logout.html.void
setDefaultEntryPoint
(String defaultEntryPoint) void
setOpenIdConnectSettings
(OpenIdConnectSettings openIdConnectSettings) startDefault
(javax.servlet.http.HttpServletRequest request) startSession
(org.springframework.web.context.request.WebRequest request, String projectName, String flow, String version, String languageCode, String aquimaUi, String theme, String channel, String testPath, String devTools) startShortcut
(javax.servlet.http.HttpServletRequest request, String unsafeShortcut, String testPath)
-
Field Details
-
ROLES
- See Also:
-
-
Constructor Details
-
StartController
@Autowired public StartController(com.blueriq.component.api.IAquimaEngineConfiguration config, com.blueriq.component.api.security.IAuthorisationManager authorisationManager, com.blueriq.component.api.IAquimaSessionsMap sessionManager, FlowStarter flowStarter, com.blueriq.component.api.shortcut.IShortcutManager shortcutsManager, ProductionProperties productionProperties, MvcRedirectHelper redirectHelper) Creates a start which is the main controller for starting a aquima-interactions flow.- Parameters:
config
- the Aquima Engine configurationauthorisationManager
- the authorisation managersessionManager
- the session managerflowStarter
- the flowstartershortcutsManager
- the shortcut managerproductionProperties
- holds production propertiesredirectHelper
- the mvc redirect helper
-
-
Method Details
-
setOpenIdConnectSettings
@Autowired(required=false) public void setOpenIdConnectSettings(OpenIdConnectSettings openIdConnectSettings) -
startDefault
@RequestMapping(value="/start", params={"!project","!loginSuccess","!close","!logout"}) public Object startDefault(javax.servlet.http.HttpServletRequest request) throws Exception - Throws:
Exception
-
startShortcut
-
startSession
@RequestMapping(value="/start", params="project") public Object startSession(org.springframework.web.context.request.WebRequest request, @RequestParam("project") String projectName, @RequestParam(value="flow",required=false) String flow, @RequestParam(value="version",required=false) String version, @RequestParam(value="languageCode",required=false) String languageCode, @RequestParam(value="ui",required=false) String aquimaUi, @RequestParam(value="theme",required=false) String theme, @RequestParam(value="channel",required=false) String channel, @RequestParam(value="testPath",required=false) String testPath, @RequestParam(value="devtools",required=false) String devTools) throws Exception - Throws:
Exception
-
createSession
@RequestMapping(value="/start", params={"create","project"}) public void createSession(org.springframework.web.context.request.WebRequest request, @RequestParam("project") String projectName, @RequestParam(value="flow",required=false) String flow, @RequestParam(value="version",required=false) String version, @RequestParam(value="languageCode",required=false) String languageCode, @RequestParam(value="ui",required=false) String aquimaUi, @RequestParam(value="theme",required=false) String theme, @RequestParam(value="channel",required=false) String channel, javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse response) throws Exception - Throws:
Exception
-
loginSuccess
@RequestMapping(value="/start", params="loginSuccess") public String loginSuccess(org.springframework.web.context.request.WebRequest request, javax.servlet.http.HttpServletRequest servletRequest) throws Exception - Throws:
Exception
-
closeSession
-
logout
@RequestMapping(value="/start", params="logout") public Object logout(@RequestParam(value="logout",required=false) Boolean logout) This method closes all Aquima sessions and redirects to the logout.html.Note: this method returns a string, but its signature declares Object as return type, so it may be mocked using
MvcUriComponentsBuilder.fromMethodCall(Object)
, which requires that the return type is not final (java.lang.String is final).- Parameters:
logout
- boolean wheter to log out (unused).- Returns:
- The view (string)
-
getDefaultEntryPoint
-
setDefaultEntryPoint
@Autowired(required=false) @Qualifier("defaultEntryPoint") public void setDefaultEntryPoint(String defaultEntryPoint)
-