SalesPoint Framework v3.0

Hook: Define New TableModel Type


Requirement

A new type of TableModel needs to be defined because a new type of data needs to be visualized.

Method of Adaptation
Add Feature
Level of Support
Open Ended  
HotSpot
Tables
Participants
AbstractTableModel, NewTableModel

Changes

  1. subclass NewTableModel of AbstractTableModel.
  2. NewTableModel.getRowCount implements AbstractTableModel.getRowCount .
  3. NewTableModel.getRowCount returns the number of records available in the data source.
  4. NewTableModel.getRecord implements AbstractTableModel.getRecord .
  5. NewTableModel.getRecord returns the record that was demanded.
  6. NewTableModel registers as a listener to its data source in order to be able to inform the JTable of any changes in the data source.
  7. NewTable implements sorting and (optionally) filtering of the records in its data source.

Constraints


SalesPoint Framework v3.0