com.arsdigita.bebop.tree
Class DefaultTreeCellRenderer

java.lang.Object
  extended bycom.arsdigita.bebop.tree.DefaultTreeCellRenderer
All Implemented Interfaces:
TreeCellRenderer

public class DefaultTreeCellRenderer
extends Object
implements TreeCellRenderer

The interface describes how a tree node (component) can be rendered.

Version:
$Id: //core-platform/dev/src/com/arsdigita/bebop/tree/DefaultTreeCellRenderer.java#9 $
Author:
David Lutterkort, Tri Tran
See Also:
TreeModel, TreeNode, Tree

Field Summary
static String versionId
           
 
Constructor Summary
DefaultTreeCellRenderer()
           
 
Method Summary
 Component getComponent(Tree tree, PageState state, Object value, boolean isSelected, boolean isExpanded, boolean isLeaf, Object key)
          Returns node component to be displayed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

versionId

public static final String versionId
See Also:
Constant Field Values
Constructor Detail

DefaultTreeCellRenderer

public DefaultTreeCellRenderer()
Method Detail

getComponent

public Component getComponent(Tree tree,
                              PageState state,
                              Object value,
                              boolean isSelected,
                              boolean isExpanded,
                              boolean isLeaf,
                              Object key)
Returns node component to be displayed. The component's generateXML or print is called to render the node.

Specified by:
getComponent in interface TreeCellRenderer
Parameters:
tree - the Tree in which this node is being displayed
state - represents the state of the current request
value - the object returned by the TreeModel for that node, such as pretty name
isSelected - true if the node is selected
isExpanded - true if the node is expanded (not collapsed)
isLeaf - true if the node is a leaf node (no children)
key - the object uniquely identify that node (primary key)
Returns:
the component used to generate the output for the node item


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2337 UTC