KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > sapia > gumby > swing > widgets > TreeNode


1 package org.sapia.gumby.swing.widgets;
2
3 import javax.swing.tree.DefaultMutableTreeNode JavaDoc;
4 import javax.swing.tree.MutableTreeNode JavaDoc;
5
6 /**
7  * @author Yanick Duchesne
8  *
9  * <dl>
10  * <dt><b>Copyright: </b>
11  * <dd>Copyright &#169; 2002-2005 <a HREF="http://www.sapia-oss.org">Sapia Open
12  * Source Software </a>. All Rights Reserved.</dd>
13  * </dt>
14  * <dt><b>License: </b>
15  * <dd>Read the license.txt file of the jar or visit the <a
16  * HREF="http://www.sapia-oss.org/license.html">license page </a> at the Sapia
17  * OSS web site</dd>
18  * </dt>
19  * </dl>
20  */

21 public class TreeNode extends DefaultMutableTreeNode JavaDoc {
22
23   static final long serialVersionUID = 1L;
24
25   public MutableTreeNode JavaDoc createNode() {
26     TreeNode node = new TreeNode();
27     insert(node, getChildCount());
28     return node;
29   }
30
31   public void setText(String JavaDoc text) {
32     super.setUserObject(text);
33   }
34
35 }
36
Popular Tags