com.sas.swing.visuals.dataselectors.qualifiers
Class Util

com.sas.swing.visuals.dataselectors.qualifiers.Util

public class Util

Contains utility methods to look for specific nodes into a QualifiersTree

Since:
3.1

Constructor Summary
Util()
           
 
Method Summary
static javax.swing.tree.TreePath getNodePathByValue(javax.swing.tree.DefaultMutableTreeNode node, java.lang.String nodeValue)
          Starting from a node, searches down the hierarchy to look for a node that contains a specific value.
static javax.swing.tree.TreePath getNodePathByValue(javax.swing.tree.TreeModel model, java.lang.String nodeValue)
          Given the value of a node returns the TreePath of the node in the tree model.
 

Constructor Detail

Util

public Util()
Method Detail

getNodePathByValue

public static javax.swing.tree.TreePath getNodePathByValue(javax.swing.tree.TreeModel model,
                                                           java.lang.String nodeValue)
Given the value of a node returns the TreePath of the node in the tree model.

Parameters:
model - The model of the Tree
nodeValue - The value of the node to search for
Returns:
The TreePath of the node in the tree model

getNodePathByValue

public static javax.swing.tree.TreePath getNodePathByValue(javax.swing.tree.DefaultMutableTreeNode node,
                                                           java.lang.String nodeValue)
Starting from a node, searches down the hierarchy to look for a node that contains a specific value. It works only with nodes of type DefaultMutableTreeNode. The searched value is the second element of a String[] that is the userObject of the node. Returns the TreePath of the found node, null if the node has not been found

Parameters:
node - The starting node
nodeValue - The value of the node to search for
Returns:
TreePath The TreePath of the node that contains the value, null if such a node is not found



Copyright © 2009 SAS Institute Inc. All Rights Reserved.