Class TasksResource


  • @Path("/tasks")
    public class TasksResource
    extends Object
    Create and monitor (possibly time consuming) tasks within the viewer. These tasks are managed by the TaskManager
    Author:
    florian
    • Constructor Detail

      • TasksResource

        public TasksResource​(@Context
                             javax.servlet.http.HttpServletRequest request,
                             @Context
                             javax.servlet.http.HttpServletResponse response)
    • Method Detail

      • addTask

        @POST
        @Consumes("application/json")
        @Produces("application/json")
        public Task addTask​(TaskParameter desc)
                     throws javax.ws.rs.WebApplicationException
        Throws:
        javax.ws.rs.WebApplicationException
      • getTask

        @GET
        @Path("/{id}")
        @Produces("application/json")
        public Task getTask​(@PathParam("id")
                            Long id)
                     throws de.unigoettingen.sub.commons.contentlib.exceptions.ContentNotFoundException
        Throws:
        de.unigoettingen.sub.commons.contentlib.exceptions.ContentNotFoundException
      • getTasks

        @GET
        @Produces("application/json")
        public List<Task> getTasks()
      • isAuthorized

        public boolean isAuthorized​(Task.TaskType type,
                                    Optional<String> jobSessionId,
                                    javax.servlet.http.HttpServletRequest request)