org.knime.base.node.mine.decisiontree2.view
Class DecTreeNodeWidget

java.lang.Object
  extended by org.knime.base.node.mine.decisiontree2.view.graph.NodeWidget<K>
      extended by org.knime.base.node.mine.decisiontree2.view.graph.ComponentNodeWidget<DecisionTreeNode>
          extended by org.knime.base.node.mine.decisiontree2.view.DecTreeNodeWidget
All Implemented Interfaces:
MouseListener, EventListener

public final class DecTreeNodeWidget
extends ComponentNodeWidget<DecisionTreeNode>

A view for a DecisionTreeNode.

Author:
Heiko Hofer

Constructor Summary
DecTreeNodeWidget(HierarchicalGraphView<DecisionTreeNode> graph, DecisionTreeNode decNode, String colorColumn, boolean tableCollapsed, boolean chartCollapsed)
           
DecTreeNodeWidget(HierarchicalGraphView<DecisionTreeNode> graph, DecisionTreeNode decNode, String colorColumn, boolean tableCollapsed, boolean chartCollapsed, boolean displayTable, boolean displayChart)
           
 
Method Summary
protected  JComponent createComponent()
          Creates the component.
(package private)  boolean getChartCollapsed()
           
 String getConnectorLabelAbove()
          Get the label that should be painted on the connector above the NodeWidget.
 String getConnectorLabelBelow()
          Get the label that should be painted on the connector below the NodeWidget.
(package private)  boolean getTableCollapsed()
           
(package private)  void setChartCollapsed(boolean collapsed)
           
 void setScaleFactor(float scale)
          Get the scale factor.
(package private)  void setTableCollapsed(boolean collapsed)
           
 
Methods inherited from class org.knime.base.node.mine.decisiontree2.view.graph.ComponentNodeWidget
getPreferredSize, mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased, paint
 
Methods inherited from class org.knime.base.node.mine.decisiontree2.view.graph.NodeWidget
getGraphView, getScaleFactor, getUserObject, paint
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DecTreeNodeWidget

public DecTreeNodeWidget(HierarchicalGraphView<DecisionTreeNode> graph,
                         DecisionTreeNode decNode,
                         String colorColumn,
                         boolean tableCollapsed,
                         boolean chartCollapsed)
Parameters:
graph - the graph this widget is element of
decNode - the model for this widget
colorColumn - the column used for coloring ({link DecisionTreeNode.covoredColors()})
tableCollapsed - true when table should be collapsed initially
chartCollapsed - true when chart should be collapsed initially

DecTreeNodeWidget

public DecTreeNodeWidget(HierarchicalGraphView<DecisionTreeNode> graph,
                         DecisionTreeNode decNode,
                         String colorColumn,
                         boolean tableCollapsed,
                         boolean chartCollapsed,
                         boolean displayTable,
                         boolean displayChart)
Parameters:
graph - the graph this widget is element of
decNode - the model for this widget
colorColumn - the column used for coloring ({link DecisionTreeNode.covoredColors()})
tableCollapsed - true when table should be collapsed initially
chartCollapsed - true when chart should be collapsed initially
displayTable - true when the table should be displayed
displayChart - true when the chart should be displayed
Method Detail

createComponent

protected JComponent createComponent()
Creates the component.

Specified by:
createComponent in class ComponentNodeWidget<DecisionTreeNode>
Returns:
a component which this NodeWidget will display

getTableCollapsed

boolean getTableCollapsed()
Returns:
the tableCollapsed

setTableCollapsed

void setTableCollapsed(boolean collapsed)
Parameters:
collapsed - the tableCollapsed to set

getChartCollapsed

boolean getChartCollapsed()
Returns:
the chartCollapsed

setChartCollapsed

void setChartCollapsed(boolean collapsed)
Parameters:
collapsed - the chartCollapsed to set

setScaleFactor

public void setScaleFactor(float scale)
Get the scale factor.

Overrides:
setScaleFactor in class ComponentNodeWidget<DecisionTreeNode>
Parameters:
scale - the scale factor to set

getConnectorLabelAbove

public String getConnectorLabelAbove()
Get the label that should be painted on the connector above the NodeWidget.

Specified by:
getConnectorLabelAbove in class NodeWidget<DecisionTreeNode>
Returns:
the label painted above

getConnectorLabelBelow

public String getConnectorLabelBelow()
Get the label that should be painted on the connector below the NodeWidget.

Specified by:
getConnectorLabelBelow in class NodeWidget<DecisionTreeNode>
Returns:
the label painted below


Copyright, 2003 - 2012. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.