Class JPPFTreeTable

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, EventListener, Accessible, CellEditorListener, ListSelectionListener, RowSorterListener, TableColumnModelListener, TableModelListener, Scrollable

public class JPPFTreeTable extends JTreeTable
Common super class for all tree tables in the admin console.
Author:
Laurent Cohen
See Also:
  • Constructor Details

    • JPPFTreeTable

      public JPPFTreeTable(AbstractJPPFTreeTableModel treeTableModel)
      Initialize this tree table with the specified model.
      Parameters:
      treeTableModel - - a tree table model.
  • Method Details

    • getPathForRow

      public TreePath getPathForRow(int n)
      Get a tree path corresponding to the node at row n in the tree.
      Parameters:
      n - the row index for which to get the path.
      Returns:
      a TreePath instance.
    • getPathForNode

      public TreePath getPathForNode(DefaultMutableTreeNode node)
      Get a tree path corresponding to the node at row n in the tree.
      Parameters:
      node - the node for which to get the path.
      Returns:
      a TreePath instance.
    • expandAll

      public void expandAll()
      Expand all paths in the tree.
    • expand

      public void expand(DefaultMutableTreeNode node)
      Expands the leaves of the specified node.
      Parameters:
      node - - the node to expand.
    • expand

      public void expand(DefaultMutableTreeNode node, boolean recursive)
      Expands the leaves of the specified node.
      Parameters:
      node - the node to expand.
      recursive - specifies whether expansion should recurse down to the leaf nodes.
    • collapseAll

      public void collapseAll()
      Collapse all paths in the tree.
    • isCollapsed

      public boolean isCollapsed(DefaultMutableTreeNode node)
      Determine whether the specified node is collapsed.
      Parameters:
      node - the tree node to check.
      Returns:
      true if the node is collapsed, false otherwise.
    • isExpanded

      public boolean isExpanded(DefaultMutableTreeNode node)
      Determine whether the specified node is expanded.
      Parameters:
      node - the tree node to check.
      Returns:
      true if the node is expanded, false otherwise.