public class BeanListTableModel<T> extends TableModel
One can control which properties are exposed (and their order). There is also a convenience constructor for adding a special header row.
Constructor and Description |
---|
BeanListTableModel(Class<T> clazz,
Iterable<T> list) |
BeanListTableModel(Iterable<T> list,
LinkedHashMap<String,Object> header) |
BeanListTableModel(Iterable<T> list,
String... propertyNames) |
Modifier and Type | Method and Description |
---|---|
int |
getColumnCount()
Return the number of columns that can be queried.
|
int |
getRowCount()
Return the number of rows that can be queried.
|
Object |
getValue(int row,
int column)
Return the data value to be displayed at a given row and column, which may be null.
|
transpose
public BeanListTableModel(Iterable<T> list, LinkedHashMap<String,Object> header)
public int getRowCount()
TableModel
rowCount-1
inclusive are valid values.getRowCount
in class TableModel
public int getColumnCount()
TableModel
columnCount-1
inclusive are valid values.getColumnCount
in class TableModel
public Object getValue(int row, int column)
TableModel
getValue
in class TableModel