@Path(value="config/agents") @Produces(value="application/json") @Consumes(value="application/json") public class AgentResource extends Object
Modifier and Type | Field and Description |
---|---|
static RestAgent |
REST_AGENT |
static String |
REST_PATH |
Constructor and Description |
---|
AgentResource(RestAgentService restAgentService) |
Modifier and Type | Method and Description |
---|---|
RestAgent |
getAgentById(javax.ws.rs.core.UriInfo uriInfo,
long agentId)
Retrieve a build agent definition by id.
|
PageResponse<RestAgent> |
getAgents(javax.ws.rs.core.UriInfo uriInfo)
Return collection of all agents of all types.
|
RestAgent |
updateRestAgent(javax.ws.rs.core.UriInfo uriInfo,
long agentId,
RestAgent restAgent)
Update value of an agent
|
public static final String REST_PATH
public static final RestAgent REST_AGENT
public AgentResource(RestAgentService restAgentService)
@GET public PageResponse<RestAgent> getAgents(@Context javax.ws.rs.core.UriInfo uriInfo)
uriInfo
- Provides access to request URI information@GET @Path(value="{agentId}") public RestAgent getAgentById(@Context javax.ws.rs.core.UriInfo uriInfo, @PathParam(value="agentId") long agentId)
uriInfo
- Provides access to request URI informationagentId
- Id of the agent@PUT @Path(value="{agentId}") public RestAgent updateRestAgent(@Context javax.ws.rs.core.UriInfo uriInfo, @PathParam(value="agentId") long agentId, RestAgent restAgent) throws WebValidationException
uriInfo
- Provides access to request URI informationagentId
- Id of the agentrestAgent
- RestAgent that contains the update values.WebValidationException
- If an invalid agent defintion is givenCopyright © 2016 Atlassian Software Systems Pty Ltd. All rights reserved.