org.jurvis.swing.tree
Class JvDynamicCheckedTreeNode
java.lang.Object
javax.swing.tree.DefaultMutableTreeNode
org.jurvis.swing.tree.JvDynamicTreeNode
org.jurvis.swing.tree.JvDynamicCheckedTreeNode
- All Implemented Interfaces:
- Serializable, Cloneable, MutableTreeNode, TreeNode, JvCheckedTreeNode
public class JvDynamicCheckedTreeNode
- extends JvDynamicTreeNode
- implements JvCheckedTreeNode
A JvDynamicTreeNode that has a checkbox that the user may
check or uncheck. Each node may independently be enabled or disabled.
- Author:
- Neil W. Weber
- See Also:
- Serialized Form
| Methods inherited from class javax.swing.tree.DefaultMutableTreeNode |
add, breadthFirstEnumeration, clone, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildBefore, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject, toString |
checked
protected boolean checked
enabled
protected boolean enabled
checkbox
protected boolean checkbox
icon
protected Icon icon
JvDynamicCheckedTreeNode
public JvDynamicCheckedTreeNode(Object userObj)
JvDynamicCheckedTreeNode
public JvDynamicCheckedTreeNode(boolean checked,
Object userObj)
setEnabled
public void setEnabled(boolean enabled)
isEnabled
public boolean isEnabled()
- Return true if the node is enabled.
- Specified by:
isEnabled in interface JvCheckedTreeNode
setCheckBox
public void setCheckBox(boolean checkbox)
hasCheckBox
public boolean hasCheckBox()
- Return true if the node may be checked.
- Specified by:
hasCheckBox in interface JvCheckedTreeNode
setChecked
public void setChecked(boolean checked)
- Set the checked status of the node.
- Specified by:
setChecked in interface JvCheckedTreeNode
- Parameters:
checked - true if the node is checked; false otherwise
isChecked
public boolean isChecked()
- Return true if the node is checked.
- Specified by:
isChecked in interface JvCheckedTreeNode
setIcon
public void setIcon(Icon icon)
getIcon
public Icon getIcon()
- Return the icon associated with this node.
- Specified by:
getIcon in interface JvCheckedTreeNode
- Returns:
- the icon associated with this node; may be null
Copyright © 1999-2004 Neil W. Weber. All Rights Reserved.