com::cosylab::cdb::browser::CDBTableModel Class Reference

Inheritance diagram for com::cosylab::cdb::browser::CDBTableModel:
Inheritance graph
[legend]
Collaboration diagram for com::cosylab::cdb::browser::CDBTableModel:
Collaboration graph
[legend]

List of all members.

Public Member Functions

int getRowCount ()
int getColumnCount ()
String getColumnName (int col)
Class getColumnClass (int col)
boolean isCellEditable (int row, int col)
Object getValueAt (int row, int col)
void setValueAt (Object value, int row, int col)
void storeVal ()
void resetValues ()

Package Functions

 CDBTableModel (Object[][]data, String[]colNames)

Package Attributes

Object[][] data
String[] colNames
HashMap resetValue = new HashMap()

Constructor & Destructor Documentation

com::cosylab::cdb::browser::CDBTableModel::CDBTableModel ( Objectdata  [][],
String[]  colNames 
) [inline, package]

Constructs a table model.

Parameters:
data the data of the table
colNames names of the table columns

Member Function Documentation

Class com::cosylab::cdb::browser::CDBTableModel::getColumnClass ( int  col  )  [inline]

Returns the most specific superclass for all the cell values in the column.

Parameters:
col the index of the column

References getValueAt().

int com::cosylab::cdb::browser::CDBTableModel::getColumnCount (  )  [inline]

Returns the number of columns in the model.

References colNames.

String com::cosylab::cdb::browser::CDBTableModel::getColumnName ( int  col  )  [inline]

Returns the name of the column at columnIndex.

Parameters:
col the index of the column

References colNames.

int com::cosylab::cdb::browser::CDBTableModel::getRowCount (  )  [inline]

Returns the number of rows in the model.

References data.

Referenced by resetValues(), and com::cosylab::cdb::browser::CDBLogic::saveTable().

Object com::cosylab::cdb::browser::CDBTableModel::getValueAt ( int  row,
int  col 
) [inline]

Returns the value for the cell at columnIndex and rowIndex.

Parameters:
row the row whose value is to be queried
col the column whose value is to be queried

References data.

Referenced by getColumnClass(), and com::cosylab::cdb::browser::CDBLogic::saveTable().

boolean com::cosylab::cdb::browser::CDBTableModel::isCellEditable ( int  row,
int  col 
) [inline]

Returns true if the cell at rowIndex and columnIndex is editable.

Parameters:
row the row whose value to be queried.
col the column whose value to be queried .
void com::cosylab::cdb::browser::CDBTableModel::resetValues (  )  [inline]
void com::cosylab::cdb::browser::CDBTableModel::setValueAt ( Object  value,
int  row,
int  col 
) [inline]

Sets the value in the cell at columnIndex and rowIndex to aValue.

Parameters:
value the new value
row the row whose value is to be changed
col the column whose value is to be changed

References data.

Referenced by resetValues().

void com::cosylab::cdb::browser::CDBTableModel::storeVal (  )  [inline]

References data, and resetValue.


Member Data Documentation

Referenced by getColumnCount(), and getColumnName().

HashMap com::cosylab::cdb::browser::CDBTableModel::resetValue = new HashMap() [package]

The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2