Class ResultsController


  • @Controller
    public class ResultsController
    extends java.lang.Object
    The controller that deals with the workspace results pages
    • 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 page
      java.lang.String deleteGet()
      Handles GET requests to the delete results page
      java.lang.String deletePost​(WorkspaceWrapper workspaceWrapper, JobResultsData resultsWrapper)
      Handles GET requests to the delete results page
      java.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 fragment
      java.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 page
      java.lang.String reportGet​(WorkspaceWrapper workspaceWrapper, JobResultsData jobResultsData, long id, org.springframework.ui.Model model)
      Handles GET requests to the report submission page
      java.lang.String rerunGet()
      Handles GET requests to the rerun page
      java.lang.String rerunPost​(long pathid, long jobid, JobResultsData results)
      Handles POST requests to the rerun page
      java.lang.String viewGet​(org.springframework.ui.Model model, JobResultsData results)
      Handles GET requests to the results page
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ResultsController

        public ResultsController()
    • 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 attributes
        results - 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 id
        jobid - the job id
        results - 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 not
        pathid - the id of the workspace
        jobid - 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 attributes
        request - 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 managed
        id - the id of the submission to report on
        model - holder for model attributes
        Returns:
        the path to the report template
        Throws:
        SubmissionNotFound - if the submission was not found
        MapperException - 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 managed
        id1 - the first submission to compare
        id2 - the second submission to compare
        model - holder for model attributes
        Returns:
        the path to the compare template
        Throws:
        SubmissionNotFound - if the submission was not found
        MapperException - if there was an issue initialising the line mappers
        CompareSameSubmission
      • 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 managed
        resultsWrapper - the results to delete
        Returns:
        the path to the delete template