org.knime.base.node.viz.histogram.datamodel
Class BarElementDataModel
java.lang.Object
org.knime.base.node.viz.aggregation.AggregationValSubModel<Rectangle2D,Rectangle2D>
org.knime.base.node.viz.histogram.datamodel.BarElementDataModel
- All Implemented Interfaces:
- Serializable, AggregationModel<Rectangle2D,Rectangle2D>
- Direct Known Subclasses:
- InteractiveBarElementDataModel
public class BarElementDataModel
- extends AggregationValSubModel<Rectangle2D,Rectangle2D>
- implements Serializable
This class represents the smallest element of a histogram and corresponds
to the color in which the rows of this element are colored. The BarElements
belong to one
BarDataModel
.
- Author:
- Tobias Koetter, University of Konstanz
- See Also:
- Serialized Form
Methods inherited from class org.knime.base.node.viz.aggregation.AggregationValSubModel |
addDataRow, calculateHilitedShape, clearHilite, getAggregationSum, getAggregationValue, getColor, getHilitedKeys, getHiliteRowCount, getHiliteShape, getKeys, getName, getRowCount, getShape, getValueCount, isEmpty, isHilited, isPresentable, isSelected, removeHilitedKeys, save2File, selectElement, selectElement, setHilitedKeys, setHiliteShape, setPresentable, setSelected, setShape, supportsHiliting |
BarElementDataModel
protected BarElementDataModel(Color color)
- Constructor for class BarElementDataModel.
- Parameters:
color
- the color of this element
BarElementDataModel
protected BarElementDataModel(Color color,
boolean supportHiliting)
- Constructor for class BarElementDataModel.
- Parameters:
color
- the color to use for this bar elementsupportHiliting
- if hiliting should be supported
getElementRectangle
public Rectangle2D getElementRectangle()
- Returns:
- the
Rectangle
the element should be drawn on the
screen
setRectangle
protected void setRectangle(Rectangle2D rect,
AbstractHistogramVizModel.HistogramHiliteCalculator calculator)
- Parameters:
rect
- the Rectangle
to set or null
calculator
- the hilite shape calculator
updateElementWidth
public void updateElementWidth(int xCoord,
int elementWidth,
AbstractHistogramVizModel.HistogramHiliteCalculator calculator)
- Parameters:
xCoord
- the new x coordinateelementWidth
- the new element widthcalculator
- the hilite shape calculator
clone
protected BarElementDataModel clone()
-
- Overrides:
clone
in class AggregationValSubModel<Rectangle2D,Rectangle2D>
loadFromFile
public static BarElementDataModel loadFromFile(Config config,
ExecutionMonitor exec)
throws CanceledExecutionException,
InvalidSettingsException
- Parameters:
config
- the config object to useexec
- the ExecutionMonitor
to provide progress messages
- Returns:
- the loaded
BarElementDataModel
- Throws:
CanceledExecutionException
- if the operation is canceled
InvalidSettingsException
- if the config object is invalid
Copyright, 2003 - 2010. 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.