Package com.lowagie.rups.view.models
Class JTableAutoModel
java.lang.Object
javax.swing.table.AbstractTableModel
com.lowagie.rups.view.models.JTableAutoModel
- All Implemented Interfaces:
Serializable
,TableModel
A reusable TableModel class for tables that implement the JTableAutoModelInterface.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final long
The serial version uid.protected JTableAutoModelInterface
The table that knows how to model itself.Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs an auto model for a JTable. -
Method Summary
Modifier and TypeMethodDescriptionint
getColumnName
(int columnIndex) int
getValueAt
(int rowIndex, int columnIndex) Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDThe serial version uid.- See Also:
-
table
The table that knows how to model itself.
-
-
Constructor Details
-
JTableAutoModel
Constructs an auto model for a JTable.- Parameters:
table
- a JTable that knows information about its model.
-
-
Method Details
-
getColumnCount
public int getColumnCount()- Returns:
- int the number of columns
- See Also:
-
getRowCount
public int getRowCount()- Returns:
- int the number of rows
- See Also:
-
getColumnName
- Specified by:
getColumnName
in interfaceTableModel
- Overrides:
getColumnName
in classAbstractTableModel
- Parameters:
columnIndex
- a column number.- Returns:
- the name of the column
- See Also:
-
getValueAt
- Parameters:
rowIndex
- int a row numbercolumnIndex
- int a column number- Returns:
- Object an object corresponding with a cell in the table
- See Also:
-