com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client
Class AttachmentClient

java.lang.Object
  extended by com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client.RestApiClient<AttachmentClient>
      extended by com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client.AttachmentClient

public class AttachmentClient
extends RestApiClient<AttachmentClient>

Client for the Attachment resource.

Since:
v4.3

Nested Class Summary
 
Nested classes/interfaces inherited from class com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client.RestApiClient
RestApiClient.Method
 
Field Summary
 
Fields inherited from class com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client.RestApiClient
REST_VERSION
 
Constructor Summary
AttachmentClient(JIRAEnvironmentData environmentData)
          Constructs a new AttachmentClient for a JIRA instance.
 
Method Summary
protected  com.sun.jersey.api.client.WebResource attachmentMeta()
          Returns the WebResource for the attachment meta
protected  com.sun.jersey.api.client.WebResource attachmentWithID(String attachmentID)
          Returns the WebResource for the attachment having the given id.
 Response deleteResponse(String attachmentID)
          Deletes the attachment with the given ID, and returns the Response.
 Attachment get(String attachmentID)
          GETs the attachment with the given id.
 Map getMeta()
          GETs the global attachment meta
 Response getResponse(String attachmentID)
          GETs the attachment with the given ID, and returns the Response.
 
Methods inherited from class com.atlassian.jira.webtests.ztests.bundledplugins2.rest.client.RestApiClient
anonymous, createResource, errorResponse, expanded, loginAs, loginAs, percentEncode, resourceRoot, setOf, toResponse, toResponse
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttachmentClient

public AttachmentClient(JIRAEnvironmentData environmentData)
Constructs a new AttachmentClient for a JIRA instance.

Parameters:
environmentData - The JIRA environment data
Method Detail

get

public Attachment get(String attachmentID)
               throws com.sun.jersey.api.client.UniformInterfaceException
GETs the attachment with the given id.

Parameters:
attachmentID - a String containing the attachment id
Returns:
an Attachment
Throws:
com.sun.jersey.api.client.UniformInterfaceException - if there is a problem

getResponse

public Response getResponse(String attachmentID)
GETs the attachment with the given ID, and returns the Response.

Parameters:
attachmentID - a String containing the attachment ID
Returns:
a Response

deleteResponse

public Response deleteResponse(String attachmentID)
Deletes the attachment with the given ID, and returns the Response.

Parameters:
attachmentID - a String containing the attachment ID
Returns:
a Response

attachmentWithID

protected com.sun.jersey.api.client.WebResource attachmentWithID(String attachmentID)
Returns the WebResource for the attachment having the given id.

Parameters:
attachmentID - a String containing the attachment id
Returns:
a WebResource

getMeta

public Map getMeta()
GETs the global attachment meta

Returns:
a Response

attachmentMeta

protected com.sun.jersey.api.client.WebResource attachmentMeta()
Returns the WebResource for the attachment meta

Returns:
a WebResource


Copyright © 2002-2012 Atlassian. All Rights Reserved.