use of net.sourceforge.processdash.data.ListData in project processdash by dtuma.
the class UserDataWriter method getDiscrepancyList.
private ListData getDiscrepancyList() throws IOException {
ListData discrepancies = ListData.asListData(getData(SyncDiscrepancy.DISCREPANCIES_DATANAME));
if (needsRefresh(discrepancies)) {
refreshDiscrepancyList();
discrepancies = ListData.asListData(getData(SyncDiscrepancy.DISCREPANCIES_DATANAME));
}
return discrepancies;
}
use of net.sourceforge.processdash.data.ListData in project processdash by dtuma.
the class SelectLabelFilter method getDefinedLabelsArray.
private JSONArray getDefinedLabelsArray(String projectRoot) {
String dataName = DataRepository.createDataName(projectRoot, LABELS_DATA_NAME);
SimpleData labelsValue = getDataRepository().getSimpleValue(dataName);
ListData list = ListData.asListData(labelsValue);
JSONArray result = new JSONArray();
try {
result.addAll(Globsearch.getTags(list));
Collections.sort(result, String.CASE_INSENSITIVE_ORDER);
} catch (Throwable t) {
// the Globsearch.getTags() method was added in PD 1.14.5. In
// earlier versions, this will throw an exception. Gracefully
// degrade and diable autocompletion support.
}
return result;
}
use of net.sourceforge.processdash.data.ListData in project processdash by dtuma.
the class UserDataWriter method writeDiscrepancies.
private void writeDiscrepancies(XmlSerializer ser) throws IOException {
ListData discrepancies = getDiscrepancyList();
if (discrepancies != null && discrepancies.size() > 1) {
DiscrepancyWriter dw = new DiscrepancyWriter(ser);
for (int i = 1; i < discrepancies.size(); i++) {
SyncDiscrepancy d = (SyncDiscrepancy) discrepancies.get(i);
d.visit(dw);
}
}
}
use of net.sourceforge.processdash.data.ListData in project processdash by dtuma.
the class DefectAnalysisPage method writeCumulativePercentArgs.
private void writeCumulativePercentArgs(String listName, String titleKey, String dataName) {
ListData allPhases = getProcessList("Phase_List");
ListData developmentPhases = getProcessList(listName);
out.println("qf=" + PATH_TO_REPORTS + "compProj.rpt");
out.print("title=");
out.println(resources.getString(titleKey));
out.print("units=");
out.println(resources.getString("Percent_Units"));
for (int i = 0; i < developmentPhases.size(); i++) {
String num = Integer.toString(developmentPhases.size() - i);
String phaseName = (String) developmentPhases.get(i);
String displayName = Translator.translate(phaseName);
out.print("h" + num + "=");
out.println(displayName);
out.println("f" + num + "=100%");
out.print("d" + num + "=");
out.println(getCumPhaseSumPct(allPhases, phaseName, dataName));
}
}
use of net.sourceforge.processdash.data.ListData in project processdash by dtuma.
the class DefectAnalysisPage method writeDRLArgs.
public void writeDRLArgs() {
ListData qualityPhases = getProcessList("Quality_Phase_List");
String lastFailurePhase = Translator.translate((String) qualityPhases.get(qualityPhases.size() - 1));
out.println("qf=" + PATH_TO_REPORTS + "compProj.rpt");
out.print("title=");
out.println(resources.getString("Defects.Leverage.Title"));
out.print("headerComment=");
out.println(resources.format("Defects.Leverage.Comment_FMT", lastFailurePhase));
out.print("h1=");
out.println(lastFailurePhase);
out.println("d1=1.0 /* [ignored but necessary] */");
for (int i = 0; i < qualityPhases.size() - 1; i++) {
String num = Integer.toString(qualityPhases.size() - i);
String phaseName = (String) qualityPhases.get(i);
String displayName = Translator.translate(phaseName);
out.println("h" + num + "=" + displayName);
out.println("d" + num + "=" + phaseName + "/DRL");
}
}
Aggregations