Class TableTreeNode
- java.lang.Object
-
- com.github.bordertech.wcomponents.util.AbstractTreeNode
-
- com.github.bordertech.wcomponents.TableTreeNode
-
- All Implemented Interfaces:
TreeNode,Serializable
@Deprecated public class TableTreeNode extends AbstractTreeNode
Deprecated.UseWTableandWTable.TableModelinstead.An extension of AbstractTreeNode that supports a data attribute, the concept of being expanded/collapsed and node-specific renderers.
- Since:
- 1.0.0
- Author:
- Yiannis Paschalidis
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TableTreeNode(Serializable data)Deprecated.Creates a TableTreeNode with the specified data.TableTreeNode(Serializable data, Class<? extends WComponent> rendererClass, boolean rendererSpansAllCols)Deprecated.Creates a TableTreeNode with the specified data.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidadd(TreeNode node)Deprecated.Adds the given TreeNode to this node.SerializablegetData()Deprecated.intgetNodeCount()Deprecated.Class<? extends WComponent>getRendererClass()Deprecated.Retrieves the custom renderer for this node.intgetRowIndex()Deprecated.booleanisExpanded()Deprecated.booleanisRendererSpansAllCols()Deprecated.Indicates whether the custom renderer, if set, should span all table columns.TableTreeNodenext()Deprecated.protected TableTreeNodenextSibling()Deprecated.TableTreeNodenextVisible()Deprecated.voidremove(TreeNode node)Deprecated.Removes the given tree node from this node.voidremoveAll()Deprecated.Removes all children from this node.voidsetExpanded(boolean expanded)Deprecated.Sets whether this node is expanded.voidsetRendererClass(Class<? extends WComponent> rendererClass)Deprecated.Sets the renderer to be used to render the row for this node.voidsetRendererSpansAllCols(boolean rendererSpansAllCols)Deprecated.Sets whether the custom renderer should span all table columns.-
Methods inherited from class com.github.bordertech.wcomponents.util.AbstractTreeNode
breadthFirst, children, depthFirst, getChildAt, getChildCount, getIndex, getLevel, getParent, getPath, getRoot, isAncestor, isDescendant, isLeaf, isRelated
-
-
-
-
Constructor Detail
-
TableTreeNode
public TableTreeNode(Serializable data)
Deprecated.Creates a TableTreeNode with the specified data. The data may be an id or complex data, and should be used in theTreeTableDataModel.getValueAt(TableTreeNode, int)method.- Parameters:
data- the data for this node.
-
TableTreeNode
public TableTreeNode(Serializable data, Class<? extends WComponent> rendererClass, boolean rendererSpansAllCols)
Deprecated.Creates a TableTreeNode with the specified data. The data may be an id or complex data, and should be used in theTreeTableDataModel.getValueAt(TableTreeNode, int)method.- Parameters:
data- the data for this node.rendererClass- The renderer class for this row.rendererSpansAllCols- true if the renderer should span all columns, false to only span the first.
-
-
Method Detail
-
getData
public Serializable getData()
Deprecated.- Returns:
- this node's data.
-
nextVisible
public TableTreeNode nextVisible()
Deprecated.- Returns:
- the next visible node, in depth-first order.
-
next
public TableTreeNode next()
Deprecated.- Returns:
- the next node, in depth-first order.
-
nextSibling
protected TableTreeNode nextSibling()
Deprecated.- Returns:
- the next sibling of this node, or null if there is none.
-
getRowIndex
public int getRowIndex()
Deprecated.- Returns:
- the row index of this node.
-
isExpanded
public boolean isExpanded()
Deprecated.- Returns:
- true if this node is expanded, false otherwise.
-
setExpanded
public void setExpanded(boolean expanded)
Deprecated.Sets whether this node is expanded.- Parameters:
expanded- true to set this node expanded this node, false for collapsed.
-
getRendererClass
public Class<? extends WComponent> getRendererClass()
Deprecated.Retrieves the custom renderer for this node.- Returns:
- the renderer class, or null if the default renderer is to be used.
-
setRendererClass
public void setRendererClass(Class<? extends WComponent> rendererClass)
Deprecated.Sets the renderer to be used to render the row for this node. If null, the default table row renderer will be used.- Parameters:
rendererClass- The renderer class to set.
-
isRendererSpansAllCols
public boolean isRendererSpansAllCols()
Deprecated.Indicates whether the custom renderer, if set, should span all table columns.- Returns:
- true if the custom renderer should span all columns, false to only span the first.
-
setRendererSpansAllCols
public void setRendererSpansAllCols(boolean rendererSpansAllCols)
Deprecated.Sets whether the custom renderer should span all table columns.- Parameters:
rendererSpansAllCols- true to span all columns, false to only span the first.
-
getNodeCount
public int getNodeCount()
Deprecated.- Returns:
- the number of nodes contained in this node.
-
add
public void add(TreeNode node)
Deprecated.Adds the given TreeNode to this node.- Specified by:
addin interfaceTreeNode- Overrides:
addin classAbstractTreeNode- Parameters:
node- the node to add.
-
remove
public void remove(TreeNode node)
Deprecated.Removes the given tree node from this node.- Specified by:
removein interfaceTreeNode- Overrides:
removein classAbstractTreeNode- Parameters:
node- the TreeNode to remove.
-
removeAll
public void removeAll()
Deprecated.Removes all children from this node.- Specified by:
removeAllin interfaceTreeNode- Overrides:
removeAllin classAbstractTreeNode
-
-