JIDE 3.5.15

com.jidesoft.grid
Class ColumnCellStyleProvider

java.lang.Object
  extended by com.jidesoft.grid.ColumnCellStyleProvider
All Implemented Interfaces:
CellStyleProvider

public class ColumnCellStyleProvider
extends Object
implements CellStyleProvider

CellStyleProvider for column stripes.


Constructor Summary
ColumnCellStyleProvider(TableModel tableModel)
          Creates a ColumnStripeCellStyleProvider.
 
Method Summary
 CellStyle getCellStyleAt(int columnIndex)
          Sets the cell style for the column.
 CellStyle getCellStyleAt(TableModel model, int rowIndex, int columnIndex)
          Gets the cell style at the specified cell.
 CellStyle[] getCellStyles()
          Gets the cell styles.
 void setCellStyleAt(int columnIndex, CellStyle style)
          Sets the cell style for the column.
 void setCellStyles(CellStyle[] cellStyles)
          Gets the cell styles.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ColumnCellStyleProvider

public ColumnCellStyleProvider(TableModel tableModel)
Creates a ColumnStripeCellStyleProvider. It uses WHITE and a very light yellow color as two alternative column colors.

Parameters:
tableModel - the table model
Method Detail

getCellStyleAt

public CellStyle getCellStyleAt(TableModel model,
                                int rowIndex,
                                int columnIndex)
Gets the cell style at the specified cell.

Specified by:
getCellStyleAt in interface CellStyleProvider
Parameters:
model - the model. This is the model from table.getModel().
rowIndex - the column index as in the model
columnIndex - the column index as in the model
Returns:
the cell style at the specified cell.

getCellStyles

public CellStyle[] getCellStyles()
Gets the cell styles.

Returns:
the cell styles.

setCellStyles

public void setCellStyles(CellStyle[] cellStyles)
Gets the cell styles.

Parameters:
cellStyles - the new cell styles.

setCellStyleAt

public void setCellStyleAt(int columnIndex,
                           CellStyle style)
Sets the cell style for the column.

Parameters:
columnIndex - the column index
style - the CellStyle for the column

getCellStyleAt

public CellStyle getCellStyleAt(int columnIndex)
Sets the cell style for the column.

Parameters:
columnIndex - the column index
Returns:
the CellStyle for the column

JIDE 3.5.15