Class FixedSummaryRowHeaderLayer
- java.lang.Object
-
- org.eclipse.nebula.widgets.nattable.layer.AbstractLayer
-
- org.eclipse.nebula.widgets.nattable.grid.layer.DimensionallyDependentLayer
-
- org.eclipse.nebula.widgets.nattable.grid.layer.RowHeaderLayer
-
- org.eclipse.nebula.widgets.nattable.grid.data.FixedSummaryRowHeaderLayer
-
- All Implemented Interfaces:
ILayer
,ILayerListener
,IPersistable
public class FixedSummaryRowHeaderLayer extends RowHeaderLayer
Using this specialization ofRowHeaderLayer
adds support for configuring a fixedSummaryRowLayer
in the body region of a grid.
-
-
Field Summary
Fields Modifier and Type Field Description static String
DEFAULT_SUMMARY_ROW_LABEL
protected String
summaryRowLabel
-
Fields inherited from class org.eclipse.nebula.widgets.nattable.layer.AbstractLayer
commandHandlers, eventHandlers, eventHelperLock, layerPainter
-
Fields inherited from interface org.eclipse.nebula.widgets.nattable.persistence.IPersistable
DOT, VALUE_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer)
FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer, boolean useDefaultConfiguration)
FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer, boolean useDefaultConfiguration, ILayerPainter layerPainter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LabelStack
getConfigLabelsByPosition(int columnPosition, int rowPosition)
Returns the config labels for the cell at the given coordinates.Object
getDataValueByPosition(int columnPosition, int rowPosition)
Returns the data value for the cell at the given coordinates.DisplayMode
getDisplayModeByPosition(int columnPosition, int rowPosition)
Returns the activeDisplayMode
for the cell at the given coordinates.String
getSummaryRowLabel()
void
setSummaryRowLabel(String summaryRowLabel)
-
Methods inherited from class org.eclipse.nebula.widgets.nattable.grid.layer.RowHeaderLayer
doCommand
-
Methods inherited from class org.eclipse.nebula.widgets.nattable.grid.layer.DimensionallyDependentLayer
configure, getBaseLayer, getClientAreaProvider, getColumnCount, getColumnIndexByPosition, getColumnPositionByX, getColumnWidthByPosition, getHeight, getHorizontalLayerDependency, getLayerPainter, getPreferredColumnCount, getPreferredHeight, getPreferredRowCount, getPreferredWidth, getRegionLabelsByXY, getRowCount, getRowHeightByPosition, getRowIndexByPosition, getRowPositionByY, getStartXOfColumnPosition, getStartYOfRowPosition, getUnderlyingLayerByPosition, getUnderlyingLayersByColumnPosition, getUnderlyingLayersByRowPosition, getVerticalLayerDependency, getWidth, isColumnPositionResizable, isRowPositionResizable, loadState, localToUnderlyingColumnPosition, localToUnderlyingRowPosition, saveState, setClientAreaProvider, setHorizontalLayerDependency, setVerticalLayerDependency, underlyingToLocalColumnPosition, underlyingToLocalColumnPositions, underlyingToLocalRowPosition, underlyingToLocalRowPositions
-
Methods inherited from class org.eclipse.nebula.widgets.nattable.layer.AbstractLayer
addConfiguration, addLayerListener, clearConfiguration, dispose, fireLayerEvent, getBoundsByPosition, getCellByPosition, getCellPainter, getConfigLabelAccumulator, getProvidedLabels, getRegionName, handleLayerEvent, hasLayerListener, isDynamicSizeLayer, registerCommandHandler, registerCommandHandlers, registerEventHandler, registerPersistable, removeLayerListener, setConfigLabelAccumulator, setLayerPainter, setRegionName, toString, unregisterCommandHandler, unregisterEventHandler, unregisterPersistable
-
-
-
-
Field Detail
-
DEFAULT_SUMMARY_ROW_LABEL
public static final String DEFAULT_SUMMARY_ROW_LABEL
- See Also:
- Constant Field Values
-
summaryRowLabel
protected String summaryRowLabel
-
-
Constructor Detail
-
FixedSummaryRowHeaderLayer
public FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer)
-
FixedSummaryRowHeaderLayer
public FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer, boolean useDefaultConfiguration)
-
FixedSummaryRowHeaderLayer
public FixedSummaryRowHeaderLayer(IUniqueIndexLayer baseLayer, ILayer verticalLayerDependency, SelectionLayer selectionLayer, boolean useDefaultConfiguration, ILayerPainter layerPainter)
-
-
Method Detail
-
getDataValueByPosition
public Object getDataValueByPosition(int columnPosition, int rowPosition)
Description copied from interface:ILayer
Returns the data value for the cell at the given coordinates.- Specified by:
getDataValueByPosition
in interfaceILayer
- Overrides:
getDataValueByPosition
in classDimensionallyDependentLayer
- Parameters:
columnPosition
- The column position of the cell.rowPosition
- The row position of the cell.- Returns:
- The data value for the cell at the given coordinates.
-
getDisplayModeByPosition
public DisplayMode getDisplayModeByPosition(int columnPosition, int rowPosition)
Description copied from interface:ILayer
Returns the activeDisplayMode
for the cell at the given coordinates. Needed to retrieve the corresponding configurations out of theIConfigRegistry
. The default value isDisplayMode.NORMAL
. The SelectionLayer for example overrides this to returnDisplayMode.SELECT
for cells that are currently selected.- Specified by:
getDisplayModeByPosition
in interfaceILayer
- Overrides:
getDisplayModeByPosition
in classRowHeaderLayer
- Parameters:
columnPosition
- The column position of the cell.rowPosition
- The row position of the cell.- Returns:
DisplayMode
for the cell at the given coordinates.
-
getConfigLabelsByPosition
public LabelStack getConfigLabelsByPosition(int columnPosition, int rowPosition)
Description copied from interface:ILayer
Returns the config labels for the cell at the given coordinates. Needed to retrieve the corresponding configurations out of theIConfigRegistry
.- Specified by:
getConfigLabelsByPosition
in interfaceILayer
- Overrides:
getConfigLabelsByPosition
in classRowHeaderLayer
- Parameters:
columnPosition
- The column position of the cell.rowPosition
- The row position of the cell.- Returns:
- The
LabelStack
with the config labels for the cell at the given coordinates.
-
getSummaryRowLabel
public String getSummaryRowLabel()
- Returns:
- The label that is used as data value for the horizontal dependent cell to the row header column.
-
setSummaryRowLabel
public void setSummaryRowLabel(String summaryRowLabel)
- Parameters:
summaryRowLabel
- The label that should be used as data value for the horizontal dependent cell to the row header column.
-
-