Class JobEndpoint
java.lang.Object
org.opencastproject.adminui.endpoint.JobEndpoint
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidactivate(org.osgi.framework.BundleContext bundleContext) com.entwinemedia.fn.data.json.JValuegetIncidentAsJSON(long id, Locale locale) Return an incident serialized as JSON.com.entwinemedia.fn.data.json.JValuegetIncidentsAsJSON(long jobId, Locale locale, boolean cascade) Returns the list of incidents for a given workflow instancejavax.ws.rs.core.ResponseList<com.entwinemedia.fn.data.json.JValue> getJobsAsJSON(List<org.opencastproject.adminui.endpoint.JobEndpoint.JobExtended> jobs) voidsetIncidentService(IncidentService incidentService) OSGi callback for the incident service.voidsetServiceRegistry(ServiceRegistry serviceRegistry) OSGi callback for the service registry.voidsetUserDirectoryService(UserDirectoryService userDirectoryService) voidsetWorkflowService(WorkflowService workflowService) OSGi callback for the workflow service.
-
Field Details
-
NOT_FOUND
public static final javax.ws.rs.core.Response NOT_FOUND
-
-
Constructor Details
-
JobEndpoint
public JobEndpoint()
-
-
Method Details
-
setWorkflowService
OSGi callback for the workflow service. -
setServiceRegistry
OSGi callback for the service registry. -
setIncidentService
OSGi callback for the incident service. -
setUserDirectoryService
-
activate
protected void activate(org.osgi.framework.BundleContext bundleContext) -
getJobs
-
getJobsAsJSON
-
getIncidentsAsJSON
public com.entwinemedia.fn.data.json.JValue getIncidentsAsJSON(long jobId, Locale locale, boolean cascade) throws JobEndpointException, NotFoundException Returns the list of incidents for a given workflow instance- Parameters:
jobId- the workflow instance idlocale- the language in which title and description shall be returnedcascade- if true, return the incidents of the given job and those of of its descendants- Returns:
- the list incidents as JSON array
- Throws:
JobEndpointExceptionNotFoundException
-
getIncidentAsJSON
public com.entwinemedia.fn.data.json.JValue getIncidentAsJSON(long id, Locale locale) throws JobEndpointException, NotFoundException Return an incident serialized as JSON.- Parameters:
id- incident idlocale- the locale to be used to create title and description- Returns:
- JSON object
- Throws:
JobEndpointExceptionNotFoundException
-