public final class EmptyTableModel extends Object implements SortableTableModel
TableModel which will never have any entries. It also
implements the SortableTableModel, so it can be used for JSortedTable
as well.| Constructor and Description |
|---|
EmptyTableModel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addTableModelListener(TableModelListener l)
Adds a listener.
|
Class<?> |
getColumnClass(int columnIndex)
Gets the column class.
|
int |
getColumnCount()
Gets the column count.
|
String |
getColumnName(int columnIndex)
Gets the column name.
|
int |
getRowCount()
Gets the row count.
|
int |
getSortedColumn()
Gets the colum that is sorted.
|
Object |
getValueAt(int rowIndex,
int columnIndex)
Gets the value at a certain position.
|
boolean |
isCellEditable(int rowIndex,
int columnIndex)
Checks if a cell is editable.
|
boolean |
isDescending()
Checks if the sort order is descending.
|
void |
removeTableModelListener(TableModelListener l)
Remove sa listener.
|
void |
setValueAt(Object aValue,
int rowIndex,
int columnIndex)
Sets a value of a cell.
|
void |
sortByColumn(int columnIndex,
boolean desc)
Sorts by a column.
|
public EmptyTableModel()
public void addTableModelListener(TableModelListener l)
addTableModelListener in interface TableModelpublic Class<?> getColumnClass(int columnIndex)
getColumnClass in interface TableModelpublic int getColumnCount()
getColumnCount in interface TableModelpublic String getColumnName(int columnIndex)
null.getColumnName in interface TableModelpublic int getRowCount()
getRowCount in interface TableModelpublic Object getValueAt(int rowIndex, int columnIndex)
null.getValueAt in interface TableModelpublic boolean isCellEditable(int rowIndex, int columnIndex)
isCellEditable in interface TableModelpublic void removeTableModelListener(TableModelListener l)
removeTableModelListener in interface TableModelpublic void setValueAt(Object aValue, int rowIndex, int columnIndex)
setValueAt in interface TableModelpublic int getSortedColumn()
getSortedColumn in interface SortableTableModelpublic boolean isDescending()
false.isDescending in interface SortableTableModelpublic void sortByColumn(int columnIndex, boolean desc)
sortByColumn in interface SortableTableModelcolumnIndex - Column indexdesc - Descending?Copyright © 2004–2016. All rights reserved.