wt.clients.beans.table
Class WTTableModel.GroupTreeModel

java.lang.Object
  extended byjavax.swing.tree.DefaultTreeModel
      extended bywt.clients.beans.table.WTTableModel.GroupTreeModel
All Implemented Interfaces:
Serializable, TreeModel
Enclosing class:
WTTableModel

public class WTTableModel.GroupTreeModel
extends DefaultTreeModel

See Also:
Serialized Form

Field Summary
protected  WTTableTreeNode root
          The root node of the tree
private  String rootLabel
          Label of the root node of the tree
 
Fields inherited from class javax.swing.tree.DefaultTreeModel
asksAllowsChildren, listenerList
 
Constructor Summary
WTTableModel.GroupTreeModel(WTTableTreeNode pRootNode)
          Construct a new group tree model
 
Method Summary
 void fillTreeModel()
          Fill the tree using the data set in the main model.
 String getRootLabel()
          Answer the label of the root node of the tree.
 void refreshModel()
          Some data may have change, force the tree to be rebuild.
 void setRootLabel(String pRootLabel)
          Set the label of the root node of the tree.
 
Methods inherited from class javax.swing.tree.DefaultTreeModel
addTreeModelListener, asksAllowsChildren, fireTreeNodesChanged, fireTreeNodesInserted, fireTreeNodesRemoved, fireTreeStructureChanged, getChild, getChildCount, getIndexOfChild, getListeners, getPathToRoot, getPathToRoot, getRoot, getTreeModelListeners, insertNodeInto, isLeaf, nodeChanged, nodesChanged, nodeStructureChanged, nodesWereInserted, nodesWereRemoved, reload, reload, removeNodeFromParent, removeTreeModelListener, setAsksAllowsChildren, setRoot, valueForPathChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

root

protected WTTableTreeNode root
The root node of the tree


rootLabel

private String rootLabel
Label of the root node of the tree

Constructor Detail

WTTableModel.GroupTreeModel

public WTTableModel.GroupTreeModel(WTTableTreeNode pRootNode)
Construct a new group tree model

Method Detail

refreshModel

public void refreshModel()
Some data may have change, force the tree to be rebuild.


setRootLabel

public void setRootLabel(String pRootLabel)
Set the label of the root node of the tree.

Parameters:
pRootLabel - the label for the root of the tree

getRootLabel

public String getRootLabel()
Answer the label of the root node of the tree.

Returns:
String the label of the root node

fillTreeModel

public void fillTreeModel()
Fill the tree using the data set in the main model.