Class JTreeUtil


public class JTreeUtil extends GuiUtilBase
Common utility methods for working with JTrees.

Chief among these is the loadTree method, for creating a tree from an XML definition

Since:
2.9.4
  • Constructor Details

  • Method Details

    • loadTree

      public static DefaultMutableTreeNode loadTree(String name, WindowInterface wi, Object context)
      Parameters:
      name - XML file to be read and processed
      wi - WindowInterface to be passed to the nodes in the tree
      context - Blind context Object passed to the nodes in the tree
      Returns:
      a mutable tree node
    • treeFromElement

      static DefaultMutableTreeNode treeFromElement(org.jdom2.Element main, WindowInterface wi, Object context)
      Parameters:
      main - Element to be processed
      wi - WindowInterface to be passed to the nodes in the tree
      context - Blind context Object passed to the nodes in the tree
      Returns:
      a mutable tree node