edu.northwestern.at.wordhoard.swing.calculator.widgets
Class WordHoardSortedTableModel

java.lang.Object
  extended by javax.swing.table.AbstractTableModel
      extended by edu.northwestern.at.utils.swing.SortedTableModel
          extended by edu.northwestern.at.wordhoard.swing.calculator.widgets.WordHoardSortedTableModel
All Implemented Interfaces:
java.io.Serializable, javax.swing.table.TableModel

public class WordHoardSortedTableModel
extends SortedTableModel

WordHoard sorted table model.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class edu.northwestern.at.utils.swing.SortedTableModel
SortedTableModel.Row
 
Field Summary
protected static java.awt.Color panelBackgroundColor
          Background color for table headers.
protected  java.util.Comparator wordHoardRowComparator
          A row comparator.
 
Fields inherited from class edu.northwestern.at.utils.swing.SortedTableModel
columnNames, comparator, defaultComparator, downTriangle, headerBackgroundColor, headerClick, headerRenderer, rows, sortableColumns, sortAscending, sortColumn, tableHeader, upTriangle, view
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
WordHoardSortedTableModel(java.lang.String[] columnNames, int initialSortColumn, boolean initialSortAscending)
          Constructs a new empty sorted table model.
 
Method Summary
 void setWordHoardComparator()
          Set the WordHoard row comparator.
 
Methods inherited from class edu.northwestern.at.utils.swing.SortedTableModel
add, getColumnCount, getColumnName, getColumnNames, getRow, getRowCount, getSortAscending, getSortColumn, getValueAt, initColumnSizes, initColumnSizes, remove, remove, resort, setComparator, setData, setDefaultComparator, setHeaderBackground, setView, setView, sort
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

panelBackgroundColor

protected static java.awt.Color panelBackgroundColor
Background color for table headers. Same as JPanel background color.


wordHoardRowComparator

protected java.util.Comparator wordHoardRowComparator
A row comparator.

Rows are compared using the current sort column. Unlike the base class, the unique ID is not used to break ties.

Constructor Detail

WordHoardSortedTableModel

public WordHoardSortedTableModel(java.lang.String[] columnNames,
                                 int initialSortColumn,
                                 boolean initialSortAscending)
Constructs a new empty sorted table model.

Parameters:
columnNames - Column names.
initialSortColumn - The initial sort column.
initialSortAscending - The initial sort order.
Method Detail

setWordHoardComparator

public void setWordHoardComparator()
Set the WordHoard row comparator.