au.com.zip.cs
Class EntityTableModel

java.lang.Object
  extended by javax.swing.table.AbstractTableModel
      extended by au.com.zip.cs.EntityTableModel
All Implemented Interfaces:
Serializable, TableModel

public class EntityTableModel
extends AbstractTableModel

A TableModel for an Entity.

Author:
Cameron Simpson <cs@zip.com.au> 22jul2003
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
EntityTableModel(Entity e)
          Construct an EntityTableModel for the the supplied Entity.
 
Method Summary
 int getColumnCount()
           
 String getColumnName(int column)
           
 Entity getEntity()
          Return the Entity presented by this model.
 int getRowCount()
           
 Object getValueAt(int row, int column)
           
 boolean isCellEditable(int row, int column)
           
 void setValueAt(Object value, int row, int column)
           
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, removeTableModelListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EntityTableModel

public EntityTableModel(Entity e)
Construct an EntityTableModel for the the supplied Entity.

Parameters:
e - the Entity to present
Method Detail

getEntity

public final Entity getEntity()
Return the Entity presented by this model.

Returns:
the Entity

getRowCount

public int getRowCount()

getColumnCount

public int getColumnCount()

isCellEditable

public boolean isCellEditable(int row,
                              int column)
Specified by:
isCellEditable in interface TableModel
Overrides:
isCellEditable in class AbstractTableModel

getColumnName

public String getColumnName(int column)
Specified by:
getColumnName in interface TableModel
Overrides:
getColumnName in class AbstractTableModel

getValueAt

public Object getValueAt(int row,
                         int column)

setValueAt

public void setValueAt(Object value,
                       int row,
                       int column)
Specified by:
setValueAt in interface TableModel
Overrides:
setValueAt in class AbstractTableModel