org.dom4j.swing
Class BranchTreeNode
java.lang.Object
org.dom4j.swing.LeafTreeNode
org.dom4j.swing.BranchTreeNode
- All Implemented Interfaces:
- TreeNode
- public class BranchTreeNode
- extends LeafTreeNode
BranchTreeNode
implements the Swing TreeNode interface to bind
dom4j XML Branch nodes (i.e. Document and Element nodes) to a Swing
TreeModel.
- Version:
- $Revision: 1.10 $
- Author:
- James Strachan , Jakob Jenkov
Field Summary |
protected List |
children
Stores the child tree nodes |
children
protected List children
- Stores the child tree nodes
BranchTreeNode
public BranchTreeNode()
BranchTreeNode
public BranchTreeNode(Branch xmlNode)
BranchTreeNode
public BranchTreeNode(TreeNode parent,
Branch xmlNode)
children
public Enumeration children()
- Specified by:
children
in interface TreeNode
- Overrides:
children
in class LeafTreeNode
getAllowsChildren
public boolean getAllowsChildren()
- Specified by:
getAllowsChildren
in interface TreeNode
- Overrides:
getAllowsChildren
in class LeafTreeNode
getChildAt
public TreeNode getChildAt(int childIndex)
- Specified by:
getChildAt
in interface TreeNode
- Overrides:
getChildAt
in class LeafTreeNode
getChildCount
public int getChildCount()
- Specified by:
getChildCount
in interface TreeNode
- Overrides:
getChildCount
in class LeafTreeNode
getIndex
public int getIndex(TreeNode node)
- Specified by:
getIndex
in interface TreeNode
- Overrides:
getIndex
in class LeafTreeNode
isLeaf
public boolean isLeaf()
- Specified by:
isLeaf
in interface TreeNode
- Overrides:
isLeaf
in class LeafTreeNode
toString
public String toString()
- Overrides:
toString
in class LeafTreeNode
getChildList
protected List getChildList()
- Uses Lazy Initialization pattern to create a List of children
- Returns:
- DOCUMENT ME!
createChildList
protected List createChildList()
- Factory method to create List of children TreeNodes
- Returns:
- DOCUMENT ME!
createChildTreeNode
protected TreeNode createChildTreeNode(Node xmlNode)
- Factory method to create child tree nodes for a given XML node type
- Parameters:
xmlNode
- DOCUMENT ME!
- Returns:
- DOCUMENT ME!
getXmlBranch
protected Branch getXmlBranch()
Copyright © 2001-2005 MetaStuff Ltd.. All Rights Reserved.