Examples of ListData


Examples of net.sourceforge.processdash.data.ListData

            prefix = context.get(ExpressionContext.PREFIXVAR_NAME).format();

        if (prefix == null) return null;
       
        try {
            ListData hierItem = (ListData) context
                    .get(DashHierarchy.DATA_REPOSITORY_NAME);
            DashHierarchy hier = (DashHierarchy) hierItem.get(0);
           
            PropertyKey key = hier.findExistingKey(prefix);
            if (key == null) return null;
           
            String templateID = hier.getID(key);
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

     *
     * This method <b>must</b> be thread-safe.
     */
    public Object call(java.util.List arguments, ExpressionContext context)
    {
        ListData result = new ListData();
        Iterator i = collapseLists(arguments, 0).iterator();
        while (i.hasNext())
            result.add(i.next());

        return result;
    }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

            new DeferredDataLookup(context));
       
        if (results == null || results.isEmpty())
            return ListData.EMPTY_LIST;
       
        ListData result = new ListData();
        for (Iterator i = results.iterator(); i.hasNext();)
            result.add(i.next());
       
        try {
            result.sortContents(String.CASE_INSENSITIVE_ORDER);
        } catch (Exception e) {}
       
        return result;
    }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

        protected DeferredDataLookup(ExpressionContext context) {
            this.context = context;
        }

        public List getTaggedData(String dataName) {
            ListData result = ListData.asListData(context.get(dataName));
            return (result == null ? null : result.asList());
        }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

        this.start = start;
        storeTag(tag);
        this.script = expression;
        this.data = data;
        this.prefix = prefix;
        this.value = new ListData();
        this.externalValue = null;
        chopTagLength = (this.tag.startsWith("/") ? this.tag.length() : 0);

        this.value.setEditable(false);
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

    public String saveString() { return ""; }

    public SimpleData getSimpleValue() {
        valueQueried = true;
        if (externalValue == null && value != null)
            externalValue = new ListData(value);
        return externalValue;
    }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

        return (sd == null ? null : sd.format());
    }

    public List<String> getList(String dataName) {
        SimpleData sd = getSimpleValue(dataName);
        ListData ld = ListData.asListData(sd);
        if (ld == null)
            return null;

        List result = new ArrayList(ld.asList());
        for (int i = result.size(); i-- > 0;) {
            Object item = result.get(i);
            if (item instanceof SimpleData)
                result.set(i, convert((SimpleData) item));
        }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

        }
        return null;
    }

    public synchronized ListData getSaveList() {
        ListData result = new ListData();
        result.add(saveDate(get(0).endDate));
        Period p;
        for (int i = 1;   i < periods.size();  i++) {
            p = get(i);
            if (p.automatic)
                break;
            result.add(Double.toString(p.planTotalTime));
            result.add(saveDate(p.endDate));
        }
        result.setImmutable();
        return result;
    }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

    }
   
    public String getPeriodNoteData() {
        if (periodNotes == null || periodNotes.isEmpty())
            return null;
        ListData result = new ListData();
        for (Map.Entry<Date, String> e : periodNotes.entrySet()) {
            result.add(saveDate(e.getKey()));
            result.add(e.getValue());
        }
        return result.format();
    }
View Full Code Here

Examples of net.sourceforge.processdash.data.ListData

    }
   
    public void setPeriodNoteData(String noteData) {
        periodNotes = new TreeMap<Date, String>();
        if (noteData != null && noteData.length() > 0) {
            ListData data = new ListData(noteData);
            for (int i = 1;  i < data.size(); i += 2) {
                try {
                    Date date = parseDate((String) data.get(i-1));
                    String note = (String) data.get(i);
                    periodNotes.put(date, note);
                } catch (Exception e) {
                    // bad data - try to continue with the next element.
                }
            }
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.