infovis.panel
Class ColumnListModel

java.lang.Object
  extended by javax.swing.AbstractListModel
      extended by infovis.panel.ColumnListModel
All Implemented Interfaces:
Serializable, EventListener, ComboBoxModel, TableModelListener, ListModel
Direct Known Subclasses:
FilteredColumnListModel

public class ColumnListModel
extends AbstractListModel
implements ComboBoxModel, TableModelListener

ListModel for columns inside a table.

Version:
$Revision: 1.13 $
Author:
Jean-Daniel Fekete
See Also:
Serialized Form

Constructor Summary
ColumnListModel(Table table)
          Constructor for ColumnListModel.
 
Method Summary
 Object getElementAt(int index)
           
 Object getSelectedItem()
           
 int getSize()
           
 Table getTable()
          Returns the table.
 boolean isNullAdded()
          Returns the nullAdded.
 void setNullAdded(boolean nullAdded)
          Sets the nullAdded.
 void setSelectedItem(Object anObject)
          Sets the value of the selected item.
 void tableChanged(TableModelEvent e)
           
 
Methods inherited from class javax.swing.AbstractListModel
addListDataListener, getListDataListeners, getListeners, removeListDataListener
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.swing.ListModel
addListDataListener, removeListDataListener
 

Constructor Detail

ColumnListModel

public ColumnListModel(Table table)
Constructor for ColumnListModel.

Method Detail

tableChanged

public void tableChanged(TableModelEvent e)
Specified by:
tableChanged in interface TableModelListener
See Also:
TableModelListener.tableChanged(TableModelEvent)

getElementAt

public Object getElementAt(int index)
Specified by:
getElementAt in interface ListModel
See Also:
ListModel.getElementAt(int)

getSize

public int getSize()
Specified by:
getSize in interface ListModel
See Also:
ListModel.getSize()

setSelectedItem

public void setSelectedItem(Object anObject)
Sets the value of the selected item. The selected item may be null.

Specified by:
setSelectedItem in interface ComboBoxModel
Parameters:
anObject - The combo box value or null for no selection.

getSelectedItem

public Object getSelectedItem()
Specified by:
getSelectedItem in interface ComboBoxModel

getTable

public Table getTable()
Returns the table.

Returns:
Table

isNullAdded

public boolean isNullAdded()
Returns the nullAdded.

Returns:
boolean

setNullAdded

public void setNullAdded(boolean nullAdded)
Sets the nullAdded.

Parameters:
nullAdded - The nullAdded to set


Copyright 2005 by Jean-Daniel Fekete and INRIA, France All rights reserved.