|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.swing.table.AbstractTableModel
com.pixelmed.database.MapTableModel
public class MapTableModel
The MapTableModel class extends a
AbstractTableModel to abstract the contents of a database as
a tree in order to provide support for a MapTableBrowser.
For details of some of the methods implemented here see javax.swing.table.AbstractTableModel.
| Field Summary | |
|---|---|
protected int |
columnCount
|
protected String[] |
columnNames
|
protected Object[][] |
data
|
protected HashSet |
excludeList
|
protected HashSet |
includeList
|
protected int |
rowCount
|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Constructor Summary | |
|---|---|
MapTableModel()
Construct an empty single row table model. |
|
MapTableModel(Map map,
Map descriptiveNameMap)
Construct a single row table model filled with the supplied attributes and values. |
|
MapTableModel(Map map,
Map descriptiveNameMap,
HashSet includeList,
HashSet excludeList)
Construct a single row table model filled with the supplied attributes and values. |
|
| Method Summary | |
|---|---|
int |
getColumnCount()
|
String |
getColumnName(int col)
|
int |
getRowCount()
|
Object |
getValueAt(int row,
int col)
|
void |
initializeModelFromMap(Map map,
Map descriptiveNameMap)
Initialize a single row table model filled with the supplied attributes and values. |
protected boolean |
isAcceptable(HashSet includeList,
HashSet excludeList,
String name)
Check whether or not the named attribute is acceptable for inclusion as a column in the table. |
boolean |
isCellEditable(int row,
int col)
|
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, removeTableModelListener, setValueAt |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected int columnCount
protected int rowCount
protected String[] columnNames
protected Object[][] data
protected HashSet includeList
protected HashSet excludeList
| Constructor Detail |
|---|
public MapTableModel()
Construct an empty single row table model.
public MapTableModel(Map map,
Map descriptiveNameMap)
Construct a single row table model filled with the supplied attributes and values.
map - a map of string names for attributes to their string valuesdescriptiveNameMap - a map of string names for attributes to descriptions for use as column titles (may be null)
public MapTableModel(Map map,
Map descriptiveNameMap,
HashSet includeList,
HashSet excludeList)
Construct a single row table model filled with the supplied attributes and values.
map - a map of string names for attributes to their string valuesdescriptiveNameMap - a map of string names for attributes to descriptions for use as column titles (may be null)includeList - a set of upper case string names for suitable attributes (may be null)excludeList - a set of upper case string names for unsuitable attributes (may be null)| Method Detail |
|---|
protected boolean isAcceptable(HashSet includeList,
HashSet excludeList,
String name)
Check whether or not the named attribute is acceptable for inclusion as a column in the table.
includeList - a set of upper case string names for suitable attributes (currently ignored)excludeList - a set of upper case string names for unsuitable attributesname - the name of the attribute to be checked (case insensitive)
public void initializeModelFromMap(Map map,
Map descriptiveNameMap)
Initialize a single row table model filled with the supplied attributes and values.
map - a map of string names for attributes to their string valuesdescriptiveNameMap - a map of string names for attributes to descriptions for use as column titles (may be null)public int getColumnCount()
public int getRowCount()
public Object getValueAt(int row,
int col)
row - col -
public boolean isCellEditable(int row,
int col)
isCellEditable in interface TableModelisCellEditable in class AbstractTableModelrow - col - public String getColumnName(int col)
getColumnName in interface TableModelgetColumnName in class AbstractTableModelcol -
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||