/** * Retrieves the given issue link record. * * @param restclient REST client instance * @param id Internal JIRA ID of the issue link * * @return a issue link instance * * @throws JiraException when the retrieval fails */ public static IssueLink get(RestClient restclient, String id) throws JiraException { JSON result = null; try { result = restclient.get(getBaseUri() + "issueLink/" + id); } catch (Exception ex) { throw new JiraException("Failed to retrieve issue link " + id, ex); } if (!(result instanceof JSONObject)) throw new JiraException("JSON payload is malformed"); return new IssueLink(restclient, (JSONObject)result); }
/** * Retrieves the given issue link record. * * @param restclient REST client instance * @param id Internal JIRA ID of the issue link * * @return a issue link instance * * @throws JiraException when the retrieval fails */ public static IssueLink get(RestClient restclient, String id) throws JiraException { JSON result = null; try { result = restclient.get(getBaseUri() + "issueLink/" + id); } catch (Exception ex) { throw new JiraException("Failed to retrieve issue link " + id, ex); } if (!(result instanceof JSONObject)) throw new JiraException("JSON payload is malformed"); return new IssueLink(restclient, (JSONObject)result); }
result = (T)new Issue(restclient, (JSONObject)r); else if (type == IssueLink.class) result = (T)new IssueLink(restclient, (JSONObject)r); else if (type == IssueType.class) result = (T)new IssueType(restclient, (JSONObject)r);
result = (T)new Issue(restclient, (JSONObject)r); else if (type == IssueLink.class) result = (T)new IssueLink(restclient, (JSONObject)r); else if (type == IssueType.class) result = (T)new IssueType(restclient, (JSONObject)r);