org.jfree.report.modules.misc.tablemodel

Class PrintableTableModel

public class PrintableTableModel extends Object implements TableModel

A tablemodel that allows to override the column names. This is usefull in internationalized environments, where the tablemodel returns diffent columnnames depending on the current locale.

Author: LordOfCode

Constructor Summary
PrintableTableModel(TableModel source, String[] keys)
Method Summary
voidaddTableModelListener(TableModelListener l)
ClassgetColumnClass(int columnIndex)
intgetColumnCount()
StringgetColumnName(int columnIndex)
Retrieves the internationalized column name from the string array.
intgetRowCount()
ObjectgetValueAt(int rowIndex, int columnIndex)
booleanisCellEditable(int rowIndex, int columnIndex)
voidremoveTableModelListener(TableModelListener l)
voidsetValueAt(Object aValue, int rowIndex, int columnIndex)

Constructor Detail

PrintableTableModel

public PrintableTableModel(TableModel source, String[] keys)

Method Detail

addTableModelListener

public void addTableModelListener(TableModelListener l)

getColumnClass

public Class getColumnClass(int columnIndex)

getColumnCount

public int getColumnCount()

getColumnName

public String getColumnName(int columnIndex)
Retrieves the internationalized column name from the string array.

See Also: TableModel#getColumnName(int)

getRowCount

public int getRowCount()

getValueAt

public Object getValueAt(int rowIndex, int columnIndex)

isCellEditable

public boolean isCellEditable(int rowIndex, int columnIndex)

removeTableModelListener

public void removeTableModelListener(TableModelListener l)

setValueAt

public void setValueAt(Object aValue, int rowIndex, int columnIndex)