1 package jde.debugger.gui;
3 import javax.swing.tree.MutableTreeNode;
4 import javax.swing.tree.TreeNode;
6 import jde.debugger.JDEException;
10 /** A TreeNode for null object references.
11 * @author <a href="mailto:udalrich@carolingia.org">Troy Daniels</a>
13 * @version $Revision: 1.1 $
15 class NullModel extends ReferenceModel {
23 /** Get the number of children.
24 * @return The number of fields that we should be displaying.
26 public int getChildCount() { return 0; }
28 /** Returns if the node allows children */
29 public boolean getAllowsChildren() { return false; }
31 /** Create a child at the given index.
32 * @return A tree node for the child at the given index */
33 MutableTreeNode createChildAt(int index) throws JDEException {
34 throw new JDEException(getClass().getName() + " does not allow children");
37 /** Get a string to represent the value of the variable */
38 String getValue() { return "null"; }
41 /** Update the values in the children
42 * @param children The array of old child values
44 void updateChildren(TreeNode[] children) {}