All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sgi.sysadm.ui.ItemTablePanel

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----javax.swing.JComponent
                           |
                           +----javax.swing.JPanel
                                   |
                                   +----com.sgi.sysadm.ui.ItemTablePanel

public class ItemTablePanel
extends JPanel
implements ExtraCleanup, ItemTableProperties
This class uses a ComponentPanel and an associated TabelModel to display a ItemTable


Constructor Index

 o ItemTablePanel(UIContext)
Constructor

Method Index

 o addListSelectionListener(ListSelectionListener)
Adds a ListSelectionListener to the table's selection model
 o addTableSortRequestListener(TableSortRequestListener)
Adds a TableSortRequestListener to this table.
 o extraCleanup()
Called by RFrame when we are destroyed.
 o fireTableCellChanged(int, int)
Tells the table that the cell at row, column has changed, and the table should redraw that cell.
 o fireTableDataChanged()
Tells the table that the data in the table has changed, and it should redraw the entire table.
 o fireTableRowDeleted(int)
Tells the table that row has been deleted from the table
 o fireTableRowInserted(int)
Tells the table that row has been inserted in the table
 o fireTableRowsDeleted(int, int)
Tells the table that rows has been deleted from the table
 o fireTableRowUpdated(int)
Tells the table that the data in row has changed and it should redraw that row.
 o fireTableStructureChanged()
Tells the table that the structure of the table (number of columns) has changed, and it should recalculate and redraw the entire table.
 o getSelectedRows()
Returns the rows that are currently selected
 o removeTableSortRequestListener(TableSortRequestListener)
Removes a TableSortRequestListener from this table.
 o setData(Vector)
Sets the data to be used by the table.
 o setNumRows(int)
Sets the height of the ItemTablePanel by specifying the number of rows.
 o setupColumns(ItemTableColumn[])
Sets up the columns for the table, as described by the array of ItemTableColumn objects.

Constructors

 o ItemTablePanel
 public ItemTablePanel(UIContext uic)
Constructor

Parameters:
uic - The UIContext that the Panel can use to display messages.

Methods

 o setupColumns
 public void setupColumns(ItemTableColumn columns[])
Sets up the columns for the table, as described by the array of ItemTableColumn objects.

Parameters:
columns - An array of ItemTableColumns specifying the order and properties of the columns in the table.
 o setNumRows
 public void setNumRows(int rows)
Sets the height of the ItemTablePanel by specifying the number of rows. The height of each row is determined by the ROW_HEIGHT property. If there are more Items than rows, a scroll bar will appear.

Parameters:
rows - The number of rows this ItemTablePanel will show.
 o setData
 public void setData(Vector data)
Sets the data to be used by the table. The data should be in the form of a Vector of rows, where each row is a Vector of Objects representing the cells in the row.

Parameters:
data - The data to use
 o fireTableRowUpdated
 public void fireTableRowUpdated(int row)
Tells the table that the data in row has changed and it should redraw that row.

Parameters:
row - The row to redraw
 o fireTableRowInserted
 public void fireTableRowInserted(int row)
Tells the table that row has been inserted in the table

Parameters:
row - The row that was inserted
 o fireTableRowDeleted
 public void fireTableRowDeleted(int row)
Tells the table that row has been deleted from the table

Parameters:
row - The row that was deleted
 o fireTableRowsDeleted
 public void fireTableRowsDeleted(int startRow,
                                  int endRow)
Tells the table that rows has been deleted from the table

Parameters:
startRow - The first row that was deleted
endRow - The last row that was deleted
 o fireTableCellChanged
 public void fireTableCellChanged(int row,
                                  int column)
Tells the table that the cell at row, column has changed, and the table should redraw that cell.

Parameters:
row - The row
column - The column
 o fireTableDataChanged
 public void fireTableDataChanged()
Tells the table that the data in the table has changed, and it should redraw the entire table.

 o fireTableStructureChanged
 public void fireTableStructureChanged()
Tells the table that the structure of the table (number of columns) has changed, and it should recalculate and redraw the entire table.

 o addTableSortRequestListener
 public void addTableSortRequestListener(TableSortRequestListener listener)
Adds a TableSortRequestListener to this table.

Parameters:
listener - The TableSortRequestListener to add
 o extraCleanup
 public void extraCleanup()
Called by RFrame when we are destroyed. Tell ItemTableController to stop listening to our Category.

 o removeTableSortRequestListener
 public void removeTableSortRequestListener(TableSortRequestListener listener)
Removes a TableSortRequestListener from this table.

Parameters:
listener - the TableSortRequestListener to remove
 o getSelectedRows
 public int[] getSelectedRows()
Returns the rows that are currently selected

Returns:
Currently selected rows.
 o addListSelectionListener
 public void addListSelectionListener(ListSelectionListener listener)
Adds a ListSelectionListener to the table's selection model

Parameters:
listener - The listener to add.

All Packages  Class Hierarchy  This Package  Previous  Next  Index