rp.gui
Class TableModel

java.lang.Object
  |
  +--javax.swing.table.AbstractTableModel
        |
        +--rp.gui.TableModel
All Implemented Interfaces:
java.io.Serializable, javax.swing.table.TableModel
Direct Known Subclasses:
AddressTableModel, EventTableModel, MainTableModel

public abstract class TableModel
extends javax.swing.table.AbstractTableModel

Oberklasse für unsere TableModels Creation date: (30.01.2001 14:43:50)

See Also:
Serialized Form

Field Summary
protected  java.util.ArrayList data
           
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
TableModel()
           
TableModel(java.lang.String[] column_names)
           
 
Method Summary
protected  void add(java.lang.Object row)
          Just add without questions
protected  void addRow(java.lang.Object row)
          Update/add row
protected  boolean checkIndex(int row)
           
protected  int contains(java.lang.Object row)
           
 int getColumnCount()
           
 java.lang.String getColumnName(int column)
           
 int getRowCount()
           
 boolean isCellEditable(int row, int col)
           
 void moveRows(int from, int to, int num)
           
 void removeRow(int row)
           
 void removeRows(int from, int to)
           
 void setValueAt(java.lang.Object o, int row, int column)
          Ignored by default
 void update(int index, java.lang.Object row)
           
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getValueAt, removeTableModelListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

data

protected java.util.ArrayList data
Constructor Detail

TableModel

public TableModel(java.lang.String[] column_names)

TableModel

public TableModel()
Method Detail

getColumnCount

public int getColumnCount()
Overrides:
getColumnCount in class javax.swing.table.AbstractTableModel

getRowCount

public int getRowCount()
Overrides:
getRowCount in class javax.swing.table.AbstractTableModel

getColumnName

public java.lang.String getColumnName(int column)
Overrides:
getColumnName in class javax.swing.table.AbstractTableModel

removeRow

public void removeRow(int row)

isCellEditable

public boolean isCellEditable(int row,
                              int col)
Overrides:
isCellEditable in class javax.swing.table.AbstractTableModel

checkIndex

protected boolean checkIndex(int row)

moveRows

public void moveRows(int from,
                     int to,
                     int num)

add

protected void add(java.lang.Object row)
Just add without questions

update

public void update(int index,
                   java.lang.Object row)

addRow

protected void addRow(java.lang.Object row)
Update/add row

contains

protected int contains(java.lang.Object row)
Returns:
index, if object already inserted, or -1

removeRows

public void removeRows(int from,
                       int to)

setValueAt

public void setValueAt(java.lang.Object o,
                       int row,
                       int column)
Ignored by default
Overrides:
setValueAt in class javax.swing.table.AbstractTableModel