Overview  Package   Class  Tree  Index 

be.lassi.ui.patch
Class PatchChannelTableModel

java.lang.Object
  extended by javax.swing.table.AbstractTableModel
      extended by be.lassi.ui.patch.PatchChannelTableModel
All Implemented Interfaces:
NameListener, ShowContextListener, SortableTableModel, java.io.Serializable, javax.swing.table.TableModel

public class PatchChannelTableModel
extends javax.swing.table.AbstractTableModel
implements SortableTableModel, ShowContextListener, NameListener

Table model that provides access to information about the channels in the currently selected group.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
PatchChannelTableModel(ShowContext context)
          Constructs a new table model.
 
Method Summary
 void fireTableDataChanged()
          
 Channel getChannel(int row)
          Gets the channel at given row.
 java.lang.Class<?> getColumnClass(int col)
          
 int getColumnCount()
          
 java.lang.String getColumnName(int col)
          
 java.lang.Object getObject(int row)
          
 int getRowCount()
          
 int getSortColumn()
          Gets the index of the column on which the table is sorted.
 java.lang.Object getValueAt(int row, int col)
          
 boolean isCellEditable(int row, int col)
          
 void nameChanged(NamedObject object)
          Notification that name has changed.
 void postShowChange()
          Performs the activities that have to be carried out on the new show after a show change.
 void preShowChange()
          Performs the activities that have to be carried out on the old show before a show change.
 void setSortColumn(int sortColumn)
          Sets the index of the column on which the table should be sorted.
 void setValueAt(java.lang.Object value, int row, int col)
          
 void shift(int target, int[] indexes)
           
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PatchChannelTableModel

public PatchChannelTableModel(ShowContext context)
Constructs a new table model.

Parameters:
context - the show context
Method Detail

fireTableDataChanged

public void fireTableDataChanged()

Overrides:
fireTableDataChanged in class javax.swing.table.AbstractTableModel

getChannel

public Channel getChannel(int row)
Gets the channel at given row.

Parameters:
row - the row index of the channel to retrieve
Returns:
the channel at given row

getColumnClass

public java.lang.Class<?> getColumnClass(int col)

Specified by:
getColumnClass in interface javax.swing.table.TableModel
Overrides:
getColumnClass in class javax.swing.table.AbstractTableModel

getColumnCount

public int getColumnCount()

Specified by:
getColumnCount in interface javax.swing.table.TableModel

getColumnName

public java.lang.String getColumnName(int col)

Specified by:
getColumnName in interface javax.swing.table.TableModel
Overrides:
getColumnName in class javax.swing.table.AbstractTableModel

getObject

public java.lang.Object getObject(int row)

Specified by:
getObject in interface SortableTableModel

getRowCount

public int getRowCount()

Specified by:
getRowCount in interface javax.swing.table.TableModel

getSortColumn

public int getSortColumn()
Gets the index of the column on which the table is sorted.

Specified by:
getSortColumn in interface SortableTableModel
Returns:
the sort column index

getValueAt

public java.lang.Object getValueAt(int row,
                                   int col)

Specified by:
getValueAt in interface javax.swing.table.TableModel

isCellEditable

public boolean isCellEditable(int row,
                              int col)

Specified by:
isCellEditable in interface javax.swing.table.TableModel
Overrides:
isCellEditable in class javax.swing.table.AbstractTableModel

nameChanged

public void nameChanged(NamedObject object)
Notification that name has changed.

Specified by:
nameChanged in interface NameListener
Parameters:
object - The object whose name has changed.

postShowChange

public void postShowChange()
Performs the activities that have to be carried out on the new show after a show change.

Specified by:
postShowChange in interface ShowContextListener

preShowChange

public void preShowChange()
Performs the activities that have to be carried out on the old show before a show change.

Specified by:
preShowChange in interface ShowContextListener

setSortColumn

public void setSortColumn(int sortColumn)
Sets the index of the column on which the table should be sorted.

Specified by:
setSortColumn in interface SortableTableModel
Parameters:
sortColumn - the column to sort on

setValueAt

public void setValueAt(java.lang.Object value,
                       int row,
                       int col)

Specified by:
setValueAt in interface javax.swing.table.TableModel
Overrides:
setValueAt in class javax.swing.table.AbstractTableModel

shift

public void shift(int target,
                  int[] indexes)

Overview  Package   Class  Tree  Index 
Lighting Assistant 1.2