Examples of BasicStatus


Examples of com.atlassian.jira.rest.client.domain.BasicStatus

public class BasicStatusJsonParserTest {
  @Test
  public void testParse() throws JSONException {
    final BasicStatusJsonParser parser = new BasicStatusJsonParser();
    final BasicStatus basicStatus = parser.parse(ResourceUtil.getJsonObjectFromResource("/json/status/valid.json"));
    Assert.assertEquals(new BasicStatus(TestUtil.toUri("http://localhost:8090/jira/rest/api/latest/status/1"), "Open"), basicStatus);
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.BasicStatus

public class BasicStatusJsonParser implements JsonParser<BasicStatus> {
  @Override
    public BasicStatus parse(JSONObject json) throws JSONException {
    final URI self = JsonParseUtil.getSelfUri(json);
    final String name = json.getString("name");
    return new BasicStatus(self, name);
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.BasicStatus

*/
public class StatusJsonParser implements JsonParser<Status> {
  private final BasicStatusJsonParser basicStatusJsonParser = new BasicStatusJsonParser();
  @Override
  public Status parse(JSONObject json) throws JSONException {
    final BasicStatus basicStatus = basicStatusJsonParser.parse(json);
    final String description = json.getString("description");
    final URI iconUri = JsonParseUtil.parseURI(json.getString("iconUrl"));
    return new Status(basicStatus.getSelf(), basicStatus.getName(), description, iconUri);
  }
View Full Code Here

Examples of com.atlassian.jira.rest.client.domain.BasicStatus

    if (isJira5x0OrNewer) {
      subtasks = parseOptionalArray(shouldUseNestedValueAttribute, s, new JsonWeakParserForJsonObject<Subtask>(subtaskJsonParser), FIELDS, SUBTASKS_FIELD.id);
    }

    final BasicVotes votes = getOptionalField(shouldUseNestedValueAttribute, s, VOTES_FIELD.id, votesJsonParser);
    final BasicStatus status = statusJsonParser.parse(getFieldUnisex(s, STATUS_FIELD.id));

    final Collection<Version> fixVersions = parseOptionalArray(shouldUseNestedValueAttribute, s, new JsonWeakParserForJsonObject<Version>(versionJsonParser), FIELDS, FIX_VERSIONS_FIELD.id);
    final Collection<Version> affectedVersions = parseOptionalArray(shouldUseNestedValueAttribute, s, new JsonWeakParserForJsonObject<Version>(versionJsonParser), FIELDS, AFFECTS_VERSIONS_FIELD.id);
    final Collection<BasicComponent> components = parseOptionalArray(shouldUseNestedValueAttribute, s, new JsonWeakParserForJsonObject<BasicComponent>(basicComponentJsonParser), FIELDS, COMPONENTS_FIELD.id);
View Full Code Here

Examples of org.rioproject.entry.BasicStatus

         */
        EventDescriptor thresholdEventDesc = SLAThresholdEvent.getEventDescriptor();
        getEventTable().put(thresholdEventDesc.eventID, getSLAEventHandler());
        addAttribute(thresholdEventDesc);       

        addAttribute(new BasicStatus(StatusType.NORMAL));

        /* Create the container */
        createContainer();

        /* Create the consumer which will discover, register and maintain
View Full Code Here

Examples of org.rioproject.entry.BasicStatus

     * Change the BasicStatus Entry to reflect a change in state
     *
     * @param statusType The StatusType
     */
    void setChanged(StatusType statusType) {
        joiner.modifyAttributes(new Entry[]{new BasicStatus()}, new Entry[]{new BasicStatus(statusType)});
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.