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

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

public class CommentClient
extends RestApiClient<CommentClient>

Client for the Comment 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
CommentClient(JIRAEnvironmentData environmentData)
          Constructs a new CommentClient for a JIRA instance.
 
Method Summary
protected  com.sun.jersey.api.client.WebResource commentWithID(String issueKey, String commentID)
          Returns a WebResource for the comment with the given ID.
 Response delete(String issueKey, Comment comment)
           
 Response delete(String issueKey, String commentId)
           
 Response<Comment> get(String issueKey, String commentID)
          GETs the comment with the given ID.
 Response<CommentsWithPaginationBean> getComments(String issueKey)
           
 Response getResponse(String issueKey, String commentID)
          GETs the comment with the given ID, and returns a Response.
 Response<Comment> post(String issueKey, Comment comment)
           
 Response<Comment> put(String issueKey, Comment comment)
           
 
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

CommentClient

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

Parameters:
environmentData - The JIRA environment data
Method Detail

get

public Response<Comment> get(String issueKey,
                             String commentID)
                      throws com.sun.jersey.api.client.UniformInterfaceException
GETs the comment with the given ID.

Parameters:
issueKey - the comment belongs to
commentID - a String containing a comment id
Returns:
a Comment
Throws:
com.sun.jersey.api.client.UniformInterfaceException - if there is a problem getting the comment

getComments

public Response<CommentsWithPaginationBean> getComments(String issueKey)

put

public Response<Comment> put(String issueKey,
                             Comment comment)

post

public Response<Comment> post(String issueKey,
                              Comment comment)

delete

public Response delete(String issueKey,
                       Comment comment)

delete

public Response delete(String issueKey,
                       String commentId)

getResponse

public Response getResponse(String issueKey,
                            String commentID)
GETs the comment with the given ID, and returns a Response.

Parameters:
issueKey - the comment belongs to
commentID - a String containing a comment ID
Returns:
a Response

commentWithID

protected com.sun.jersey.api.client.WebResource commentWithID(String issueKey,
                                                              String commentID)
Returns a WebResource for the comment with the given ID.

Parameters:
issueKey - the comment belongs to
commentID - a String containing a comment ID
Returns:
a WebResource


Copyright © 2002-2012 Atlassian. All Rights Reserved.