Package pspdash.data

Examples of pspdash.data.SimpleData.format()


        data = r;
        if (path == null) path = "";
        String dataName = data.createDataName(path, SETTING_DATA_NAME);
        SimpleData defectSetting = data.getSimpleValue(dataName);
        String result = null;
        if (defectSetting != null) result = defectSetting.format();
        if (result != null && result.length() == 0) result = null;
        return result;
    }

View Full Code Here


        String dataName = DataRepository.createDataName(path, "Project_WBS_ID");
        SimpleData val = data.getSimpleValue(dataName);
        if (val == null)
            return null;
        else
            return val.format();
    }

    private static String rerootPath(DataRepository data, String defectPath, Map wbsIdMap) {
        SaveableData wbsIdValue = data.getInheritableValue(defectPath, "Project_WBS_ID");
        if (wbsIdValue == null)
View Full Code Here

            return defectPath;
        SimpleData wbsIdSimpleValue = wbsIdValue.getSimpleValue();
        if (wbsIdSimpleValue == null)
            return defectPath;
       
        String wbsID = wbsIdSimpleValue.format();
        while (wbsID != null && wbsID.length() > 0) {
          String result = (String) wbsIdMap.get(wbsID);
          if (result != null)
            return result;
          wbsID = DataRepository.chopPath(wbsID);
View Full Code Here

            (prefix, ImportExport.EXPORT_DATANAME);
        SimpleData filename = dash.data.getSimpleValue(dataName);
        if (filename != null && filename.test()) {
            Vector filter = new Vector();
            filter.add(prefix);
            ImportExport.export(dash, filter, new File(filename.format()));
        }
    }


    public static void startTiming() {
View Full Code Here

        String dataName = DataRepository.createDataName(prefix, name);
        SimpleData val = getDataRepository().getSimpleValue(dataName);
        if (val == null)
            return NA;
        else
            return val.format();
    }


    protected void printResPhaseOrTotal(String resKey, String arg) {
        if (arg == TOTAL_CATEGORY_KEY) {
View Full Code Here

    }

    protected String getProcessString(String stringName) {
        String dataName = DataRepository.createDataName(getPrefix(), stringName);
        SimpleData val = getDataRepository().getSimpleValue(dataName);
        return val == null ? "" : val.format();
    }
   
    protected String getAggrSizeLabel() {
        return Translator.translate
            (getProcessString("AGGR_SIZE_METRIC_NAME_ABBR"));
View Full Code Here

   * the data element be named?
   */
  public static String exportedScheduleName(DataRepository data,
                                            String scheduleName) {
    SimpleData o = data.getSimpleValue("/Owner");
    String owner = (o == null ? "?????" : safeName(o.format()));
    String name = safeName(scheduleName) + " (" + owner + ")";
    return EVTaskList.MAIN_DATA_PREFIX + name;
  }

  public static void export(PSPDashboard parent, Vector filter, File dest) {
View Full Code Here

        if (pos != -1 && Filter.matchesFilter(filter, name))
          taskListNames.add(name.substring(pos+TASK_ORD_PREF.length()));
      }
      i = taskListNames.iterator();
      SimpleData o = parent.data.getSimpleValue("/Owner");
      String owner = (o == null ? "?????" : safeName(o.format()));
      while (i.hasNext()) {
        name = (String) i.next();
        EVTaskList tl = EVTaskList.openExisting
          (name, parent.data, parent.props, parent.objectCache, false);
        if (tl == null) continue;
View Full Code Here

      if (pos < 1) continue;
      filename = parent.data.getSimpleValue(name);
      if (filename == null || !filename.test()) continue;
      Vector filter = new Vector();
      filter.add(name.substring(0, pos-1));
      String file_name = Settings.translateFile(filename.format());
      p.addTask(new ExportTask(parent, filter, new File(file_name)));
      foundWork = true;
    }

    if (!foundWork) return;
View Full Code Here

        String prefix = getPrefix();
        String name = data.createDataName(prefix, what);
        name = data.createDataName(name, "Probe Method");
        SimpleData d = data.getSimpleValue(name);
        if (d instanceof StringData) {
            String result = d.format();
            if (result.endsWith("  ")) return null;
            return result.trim();
        } else
            return null;
    }
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.