Package org.sonar.wsclient.services

Examples of org.sonar.wsclient.services.Measure


    List<Measure> projectMeasures = new ArrayList<Measure>();
    int len = utils.getArraySize(measuresJson);
    for (int i = 0; i < len; i++) {
      Object measureJson = utils.getArrayElement(measuresJson, i);
      if (measureJson != null) {
        Measure measure = parseMeasure(measureJson);
        projectMeasures.add(measure);
      }
    }
    return projectMeasures;
  }
View Full Code Here


  }

  private Measure parseMeasure(Object json) {
    WSUtils utils = WSUtils.getINSTANCE();

    Measure measure = new Measure();
    measure
        .setMetricKey(utils.getString(json, "key"))
        .setMetricName(utils.getString(json, "name"))
        .setValue(utils.getDouble(json, "val"))
        .setFormattedValue(utils.getString(json, "frmt_val"))
        .setAlertStatus(utils.getString(json, "alert"))
View Full Code Here

TOP

Related Classes of org.sonar.wsclient.services.Measure

Copyright © 2018 www.massapicom. 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.