eu.keep.uphec.software
Class SoftwareTableModel

Object
  extended by javax.swing.table.AbstractTableModel
      extended by SoftwareTableModel
All Implemented Interfaces:
Serializable, javax.swing.table.TableModel

public class SoftwareTableModel
extends javax.swing.table.AbstractTableModel

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
SoftwareTableModel(Object[][] content, int rows)
          Default constructor for SoftwareTableModel
 
Method Summary
 Class getColumnClass(int column)
          This method returns the class type of a specific column in SoftwareTable
 int getColumnCount()
          This method returns the number of existing columns in SoftwareTable
 String getColumnName(int column)
          This method provides the title of each column in SoftwareTable
 int getRowCount()
          This method returns the number of existing rows in SoftwareTable
 Object getValueAt(int row, int column)
          This method returns the value of a specific cell in SoftwareTable
 boolean isCellEditable(int row, int col)
          This method defines the editability of each cell in SoftwareTable
 void setValueAt(Object aValue, int row, int column)
          This method enables to set the value in a specific cell in SoftwareTable
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SoftwareTableModel

public SoftwareTableModel(Object[][] content,
                          int rows)
Default constructor for SoftwareTableModel

Parameters:
content - instance of 2D Object Array
cols - instance of int
Method Detail

getColumnCount

public int getColumnCount()
This method returns the number of existing columns in SoftwareTable


getRowCount

public int getRowCount()
This method returns the number of existing rows in SoftwareTable


isCellEditable

public boolean isCellEditable(int row,
                              int col)
This method defines the editability of each cell in SoftwareTable

Specified by:
isCellEditable in interface javax.swing.table.TableModel
Overrides:
isCellEditable in class javax.swing.table.AbstractTableModel
Parameters:
row - instance of int
col - instance of int

getColumnName

public String getColumnName(int column)
This method provides the title of each column in SoftwareTable

Specified by:
getColumnName in interface javax.swing.table.TableModel
Overrides:
getColumnName in class javax.swing.table.AbstractTableModel
Parameters:
column - instance of int

getValueAt

public Object getValueAt(int row,
                         int column)
This method returns the value of a specific cell in SoftwareTable

Parameters:
row - instance of int
column - instance of int

getColumnClass

public Class getColumnClass(int column)
This method returns the class type of a specific column in SoftwareTable

Specified by:
getColumnClass in interface javax.swing.table.TableModel
Overrides:
getColumnClass in class javax.swing.table.AbstractTableModel
Parameters:
column - instance of int

setValueAt

public void setValueAt(Object aValue,
                       int row,
                       int column)
This method enables to set the value in a specific cell in SoftwareTable

Specified by:
setValueAt in interface javax.swing.table.TableModel
Overrides:
setValueAt in class javax.swing.table.AbstractTableModel
Parameters:
aValue - instance of Object
row - instance of int
column - instance of int