Package com.atlassian.jira.rest.v2.issue
Class PrioritySchemeResource
java.lang.Object
com.atlassian.jira.rest.v2.issue.PrioritySchemeResource
@Path("priorityschemes")
@Consumes("application/json")
@Produces("application/json")
public class PrioritySchemeResource
extends Object
Resource for managing priority schemes.
- Since:
- 7.7
-
Constructor Summary
ConstructorsConstructorDescriptionPrioritySchemeResource(PrioritySchemeService prioritySchemeService, JiraAuthenticationContext authContext, ResponseFactory responseFactory, PrioritySchemeBeansFactory prioritySchemeBeansFactory) -
Method Summary
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.ResponsecreatePriorityScheme(jakarta.ws.rs.core.UriInfo uriInfo, PrioritySchemeUpdateBean data) Creates new priority scheme.jakarta.ws.rs.core.ResponsedeletePriorityScheme(Long schemeId) Deletes a priority scheme.jakarta.ws.rs.core.ResponsegetPriorityScheme(jakarta.ws.rs.core.UriInfo uriInfo, Long schemeId) Gets a full representation of a priority scheme in JSON format.jakarta.ws.rs.core.ResponsegetPrioritySchemes(jakarta.ws.rs.core.UriInfo uriInfo, Long startAt, Integer maxResults) Returns all priority schemes.jakarta.ws.rs.core.ResponseupdatePriorityScheme(jakarta.ws.rs.core.UriInfo uriInfo, Long schemeId, PrioritySchemeUpdateBean data) Updates a priority scheme.
-
Constructor Details
-
PrioritySchemeResource
@Inject public PrioritySchemeResource(PrioritySchemeService prioritySchemeService, JiraAuthenticationContext authContext, ResponseFactory responseFactory, PrioritySchemeBeansFactory prioritySchemeBeansFactory)
-
-
Method Details
-
createPriorityScheme
@POST @ExperimentalApi public jakarta.ws.rs.core.Response createPriorityScheme(@Context jakarta.ws.rs.core.UriInfo uriInfo, PrioritySchemeUpdateBean data) Creates new priority scheme.- Parameters:
uriInfo- a UriInfodata- data of priority scheme to create- Returns:
- a response containing newly created priority scheme
PrioritySchemeBean
-
deletePriorityScheme
@DELETE @Path("{schemeId}") @ExperimentalApi public jakarta.ws.rs.core.Response deletePriorityScheme(@PathParam("schemeId") Long schemeId) Deletes a priority scheme. All projects using deleted scheme will use default priority scheme afterwards. Default priority scheme can't be deleted.- Parameters:
schemeId- Id of priority scheme to delete- Returns:
- no content response
-
updatePriorityScheme
@PUT @Path("{schemeId}") @ExperimentalApi public jakarta.ws.rs.core.Response updatePriorityScheme(@Context jakarta.ws.rs.core.UriInfo uriInfo, @PathParam("schemeId") Long schemeId, PrioritySchemeUpdateBean data) Updates a priority scheme. Update will be rejected if issue migration would be needed as a result of scheme update. Priority scheme update with migration is possible from the UI. All project keys associated with the priority scheme will only be returned if additional query parameter is providedexpand=projectKeys.- Parameters:
uriInfo- a UriInfoschemeId- id of the priority scheme to updatedata- new scheme data- Returns:
- a response containing updated priority scheme
PrioritySchemeBean
-
getPriorityScheme
@GET @Path("{schemeId}") @ExperimentalApi public jakarta.ws.rs.core.Response getPriorityScheme(@Context jakarta.ws.rs.core.UriInfo uriInfo, @PathParam("schemeId") Long schemeId) Gets a full representation of a priority scheme in JSON format. All project keys associated with the priority scheme will only be returned if additional query parameter is providedexpand=projectKeys.- Parameters:
uriInfo- a UriInfoschemeId- id of priority scheme to get- Returns:
- a priority scheme
-
getPrioritySchemes
@GET @ExperimentalApi public jakarta.ws.rs.core.Response getPrioritySchemes(@Context jakarta.ws.rs.core.UriInfo uriInfo, @QueryParam("startAt") Long startAt, @QueryParam("maxResults") Integer maxResults) Returns all priority schemes. All project keys associated with the priority scheme will only be returned if additional query parameter is providedexpand=schemes.projectKeys.- Parameters:
uriInfo- a UriInfostartAt- the page offset, if not specified then defaults to 0maxResults- how many results on the page should be included. Defaults to 100, maximum is 1000.- Returns:
- priority schemes
-