Class ResultsController
- java.lang.Object
-
- uk.ac.warwick.dcs.sherlock.module.web.controllers.dashboard.workspace.ResultsController
-
@Controller public class ResultsController extends java.lang.Object
The controller that deals with the workspace results pages
-
-
Constructor Summary
Constructors Constructor Description ResultsController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
comparisonGet(WorkspaceWrapper workspaceWrapper, JobResultsData jobResultsData, long id1, long id2, org.springframework.ui.Model model)
Handles GET requests for the compare submission pagejava.lang.String
deleteGet()
Handles GET requests to the delete results pagejava.lang.String
deletePost(WorkspaceWrapper workspaceWrapper, JobResultsData resultsWrapper)
Handles GET requests to the delete results pagejava.lang.String
dismissPost(long pathid, long jobid, JobResultsData results)
java.lang.String
graphGetFragment(boolean isAjax, long pathid, long jobid)
Handles GET requests to the graph fragmentjava.lang.String
jsonGet(JobResultsData results)
java.lang.String
networkGet(org.springframework.ui.Model model, javax.servlet.http.HttpServletRequest request)
Handles GET requests to the network graph pagejava.lang.String
reportGet(WorkspaceWrapper workspaceWrapper, JobResultsData jobResultsData, long id, org.springframework.ui.Model model)
Handles GET requests to the report submission pagejava.lang.String
rerunGet()
Handles GET requests to the rerun pagejava.lang.String
rerunPost(long pathid, long jobid, JobResultsData results)
Handles POST requests to the rerun pagejava.lang.String
viewGet(org.springframework.ui.Model model, JobResultsData results)
Handles GET requests to the results page
-
-
-
Method Detail
-
viewGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}") public java.lang.String viewGet(org.springframework.ui.Model model, @ModelAttribute("results") JobResultsData results)
Handles GET requests to the results page- Parameters:
model
- holder for model attributesresults
- the job results object- Returns:
- the path to the results template
-
jsonGet
@RequestMapping(value="/dashboard/workspaces/manage/{pathid}/results/{jobid}/json", method=GET, produces="application/json") @ResponseBody public java.lang.String jsonGet(@ModelAttribute("results") JobResultsData results)
-
rerunGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/rerun") public java.lang.String rerunGet()
Handles GET requests to the rerun page- Returns:
- the path to the rerun template
-
rerunPost
@PostMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/rerun") public java.lang.String rerunPost(@PathVariable("pathid") long pathid, @PathVariable("jobid") long jobid, @ModelAttribute("results") JobResultsData results)
Handles POST requests to the rerun page- Parameters:
pathid
- the workspace idjobid
- the job idresults
- the job results object- Returns:
- redirect to the job results page
-
dismissPost
@PostMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/dismiss") public java.lang.String dismissPost(@PathVariable("pathid") long pathid, @PathVariable("jobid") long jobid, @ModelAttribute("results") JobResultsData results)
-
graphGetFragment
@RequestMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/graph") public java.lang.String graphGetFragment(@ModelAttribute("isAjax") boolean isAjax, @PathVariable("pathid") long pathid, @PathVariable("jobid") long jobid) throws NotAjaxRequest
Handles GET requests to the graph fragment- Parameters:
isAjax
- whether or not the request was ajax or notpathid
- the id of the workspacejobid
- the id of the job- Returns:
- the path to the graph fragment template
- Throws:
NotAjaxRequest
- if the request was not an ajax one, the message is where to redirect the user to
-
networkGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/network") public java.lang.String networkGet(org.springframework.ui.Model model, javax.servlet.http.HttpServletRequest request)
Handles GET requests to the network graph page- Parameters:
model
- holder for model attributesrequest
- the http request information- Returns:
- the path to the graph template
-
reportGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/report/{submission}") public java.lang.String reportGet(@ModelAttribute("workspace") WorkspaceWrapper workspaceWrapper, @ModelAttribute("results") JobResultsData jobResultsData, @PathVariable("submission") long id, org.springframework.ui.Model model) throws SubmissionNotFound, MapperException
Handles GET requests to the report submission page- Parameters:
workspaceWrapper
- the workspace being managedid
- the id of the submission to report onmodel
- holder for model attributes- Returns:
- the path to the report template
- Throws:
SubmissionNotFound
- if the submission was not foundMapperException
- if there was an issue initialising the line mappers
-
comparisonGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/compare/{submission1}/{submission2}") public java.lang.String comparisonGet(@ModelAttribute("workspace") WorkspaceWrapper workspaceWrapper, @ModelAttribute("results") JobResultsData jobResultsData, @PathVariable("submission1") long id1, @PathVariable("submission2") long id2, org.springframework.ui.Model model) throws SubmissionNotFound, MapperException, CompareSameSubmission
Handles GET requests for the compare submission page- Parameters:
workspaceWrapper
- the workspace being managedid1
- the first submission to compareid2
- the second submission to comparemodel
- holder for model attributes- Returns:
- the path to the compare template
- Throws:
SubmissionNotFound
- if the submission was not foundMapperException
- if there was an issue initialising the line mappersCompareSameSubmission
-
deleteGet
@GetMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/delete") public java.lang.String deleteGet()
Handles GET requests to the delete results page- Returns:
- the path to the delete template
-
deletePost
@PostMapping("/dashboard/workspaces/manage/{pathid}/results/{jobid}/delete") public java.lang.String deletePost(@ModelAttribute("workspace") WorkspaceWrapper workspaceWrapper, @ModelAttribute("results") JobResultsData resultsWrapper)
Handles GET requests to the delete results page- Parameters:
workspaceWrapper
- the workspace being managedresultsWrapper
- the results to delete- Returns:
- the path to the delete template
-
-