public abstract class AbstractTableModelImpl extends AbstractTableModel implements TableModelListener
AbstractTableModel
implementation.
Name | Mode | Type | isHidden | isBound | isConstrained |
---|---|---|---|---|---|
columnClass | [RW] | null | false | false | false |
columnCount | R | int | false | false | false |
columnName | [RW] | null | false | false | false |
rowCount | R | int | false | false | false |
tableModelListeners | R | TableModelListener[] | false | false | false |
listenerList
Modifier | Constructor and Description |
---|---|
protected |
AbstractTableModelImpl(int columns)
Construct a
TableModel with the specified
number of columns. |
protected |
AbstractTableModelImpl(String... names)
Construct a
TableModel with the specified
column names. |
Modifier and Type | Method and Description |
---|---|
protected Object[] |
column(int x)
Convenience method to get a column's values as an array.
|
Class<?> |
getColumnClass(int x) |
int |
getColumnCount() |
String |
getColumnName(int x) |
abstract int |
getRowCount() |
abstract Object |
getValueAt(int y,
int x) |
protected String[] |
header()
Convenience method to get the column names as an array.
|
boolean |
isCellEditable(int y,
int x) |
protected Object[] |
row(int y)
Convenience method to get a row's values as an array.
|
void |
setColumnClass(int x,
Class<?> type) |
void |
setColumnName(int x,
String name) |
void |
setValueAt(Object value,
int y,
int x) |
void |
tableChanged(TableModelEvent event) |
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
protected AbstractTableModelImpl(String... names)
TableModel
with the specified
column names.names
- The column names.protected AbstractTableModelImpl(int columns)
TableModel
with the specified
number of columns.columns
- The number of columns.protected String[] header()
protected Object[] column(int x)
x
- The column index.protected Object[] row(int y)
y
- The row index.public int getColumnCount()
getColumnCount
in interface TableModel
public Class<?> getColumnClass(int x)
getColumnClass
in interface TableModel
getColumnClass
in class AbstractTableModel
public void setColumnClass(int x, Class<?> type)
public String getColumnName(int x)
getColumnName
in interface TableModel
getColumnName
in class AbstractTableModel
public void setColumnName(int x, String name)
public abstract int getRowCount()
getRowCount
in interface TableModel
public boolean isCellEditable(int y, int x)
isCellEditable
in interface TableModel
isCellEditable
in class AbstractTableModel
public abstract Object getValueAt(int y, int x)
getValueAt
in interface TableModel
public void setValueAt(Object value, int y, int x)
setValueAt
in interface TableModel
setValueAt
in class AbstractTableModel
public void tableChanged(TableModelEvent event)
tableChanged
in interface TableModelListener
Copyright © 2015–2020 Allen D. Ball. All rights reserved.