Package net.sourceforge.processdash.hier

Examples of net.sourceforge.processdash.hier.PropertyKey


   
    public void addRow() {
        int rowBasedOn = -1;
        String pathBasedOn = null;
        DefaultMutableTreeNode selected;
        PropertyKey key;

        // try to base new row on current tree selection
        if ((selected = getSelectedNode()) != null
                && (key = treeModel.getPropKey(useProps, selected.getPath())) != null
                && timeLoggingAllowed(key))
            pathBasedOn = key.path();

        // else try to base new row on current editing row
        else if ((rowBasedOn = table.getEditingRow()) != -1)
            saveEditInProgress();
View Full Code Here


    protected String getPathIfLoggingAllowed(TreePath path) {
        if (path == null)
            return null;
       
        PropertyKey key = treeModel.getPropKey(useProps, path.getPath());
        return (timeLoggingAllowed(key) ? key.path() : null);
    }
View Full Code Here

            tree.clearSelection();
            applyFilter();
            return;
        }
        Object[] path = tp.getPath();
        PropertyKey key = treeModel.getPropKey(useProps, path);
        checkSelectedNodeLoggingAllowed(key);
        applyFilter();
    }
View Full Code Here

        applyFilter();
    }

    private void checkSelectedNodeLoggingAllowed() {
        TreePath selPath = tree.getSelectionPath();
        PropertyKey key = null;
        if (selPath != null) {
            Object[] path = selPath.getPath();
            key = treeModel.getPropKey(useProps, path);
        }
        checkSelectedNodeLoggingAllowed(key);
View Full Code Here

     * @param t An analysis task to perform.  Every defect encountered will
     *    be passed to the task, in turn.
     */
    public static void run(DashHierarchy props, String path,
            boolean includeChildren, Task t) {
        PropertyKey pKey;
        if (path == null || path.length() == 0)
            pKey = PropertyKey.ROOT;
        else
            pKey = props.findExistingKey(path);

View Full Code Here

       
        Enumeration leafNames = getInheritedPhaseList(defectPath, context
                .getData());
        if (leafNames == null) {
            DashHierarchy hier = context.getHierarchy();
            PropertyKey defectPathKey = hier.findExistingKey(defectPath);
            if (defectPathKey == null)
                return result;
            leafNames = hier.getLeafNames(defectPathKey);
            prefixLength = defectPath.length() + 1;
        }
View Full Code Here

   
        // no luck so far.  Look at the task in question, and see if it only
        // includes a single phase child (typical for old-style team projects
        // with phase stubs).
        DashHierarchy hier = context.getHierarchy();
        PropertyKey defectPathKey = hier.findExistingKey(defectPath);
        if (defectPathKey != null) {
            Enumeration leafNames = hier.getLeafNames(defectPathKey);
            List possibleMatches = new ArrayList();
            while (leafNames.hasMoreElements()) {
                String oneLeaf = (String) leafNames.nextElement();
View Full Code Here

        // find the leaves in the hierarchy, and augment each leaf with
        // supplementary children provided from data element specifications
        DataRepository data = getDataRepository();
        Enumeration<PropertyKey> leaves = result.getLeaves(PropertyKey.ROOT);
        while (leaves.hasMoreElements()) {
            PropertyKey leaf = leaves.nextElement();
            augmentHierarchy(result, leaf, data);
        }

        return result;
    }
View Full Code Here

        if (parentProp == null)
            return;

        for (Element childXml : XMLUtils.getChildElements(parentXml)) {
            String childName = childXml.getAttribute("name");
            PropertyKey childNode = new PropertyKey(parentNode, childName);
            parentProp.addChild(childNode, -1);
            hier.put(childNode, new Prop());
            augmentHierarchy(hier, childNode, childXml);
        }
    }
View Full Code Here

        updateAll();
    }

    private void updateAll() {
        PropertyKey currentPhase = parent.getActiveTaskModel().getNode();
        setPaths(parent.getHierarchy().defectLog(currentPhase , parent.getDirectory()));
    }
View Full Code Here

TOP

Related Classes of net.sourceforge.processdash.hier.PropertyKey

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.