All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sgi.sysadm.ui.ItemTable

java.lang.Object
   |
   +----com.sgi.sysadm.ui.ItemTable

public class ItemTable
extends Object
implements ItemSelectable, ItemTableProperties
A class that encapsulates an ItemTable. An ItemTable is a table where each row represents one Item in a Category. The columns of the table represent information about the state or configuration of the Item. ItemTables do not necessarily show all known information about an Item - just the "first level" information that a user might be interested in. The infrastructure will attempt to obtain an icon representing the Item by using an IconRenderer. If it sucessfully finds an icon, the icon will be placed in the first column of the table. Typically, the second column of the ItemTable will be the name of the Item, followed by some number of additional columns with more infomation.

To create an ItemTable, you should first call the static createItemTable to invoke the ItemTableFactory and to instantiate an ItemTable. It is then necessary to call setCategory on the ItemTable to tell the ItemTable which Category or Association to display.

To learn more about how to use resource files to define an ItemTable, see the ItemTableController documentation. To learn how to control the overall look of the ItemTable by setting various properties, look at the ItemTableProperties documentation.

See Also:
ItemTableFactory, ItemTableProperties, ItemTableController, Category, Association

Method Index

 o addItemListener(ItemListener)
Add a ItemListener to receive ItemEvents when the Items are selected in the ItemTable, or when the selection changes.
 o addItemViewLaunchRequestListener(ItemViewLaunchRequestListener)
Adds an ItemViewLaunchRequestListener that will be notified if a user requests that an ItemView be launched (such as by clicking on a hyperlink in the ItemTable)
 o addTitleListener(TitleListener)
Adds a TitleListener to the ItemTable.
 o createItemTable(HostContext, String)
Creates an ItemTable by invoking the ItemTableFactory
 o createItemTable(HostContext, String, int)
Creates an ItemTable by invoking the ItemTableFactory
 o createItemTable(HostContext, String, ResourceStack)
Creates an ItemTable by invoking the ItemTableFactory
 o createItemTable(HostContext, String, ResourceStack, int)
Creates an ItemTable by invoking the ItemTableFactory
 o createItemTable(HostContext, String, String)
Creates an ItemTable by invoking the ItemTableFactory
 o createItemTable(HostContext, String, String, int)
Creates an ItemTable by invoking the ItemTableFactory
 o destroy()
Destroys an ItemTable by removing listeners on categories.
 o getCategoryName()
Return the name passed into the constructor
 o getItemTableContext()
Gets the ItemTableContext being used by the ItemTable
 o getItemTablePanel()
Gets the ItemTablePanel that contains the ItemTable.
 o getSelectedObjects()
Gets the list of Items that are selected in the ItemTable
 o removeItemListener(ItemListener)
Remove an ItemListener
 o removeItemViewLaunchRequestListener(ItemViewLaunchRequestListener)
Removes an ItemViewLaunchRequestListener
 o setCategory(Category)
Sets the Cateogory that contains the Items the ItemTable should display.

Methods

 o setCategory
 public void setCategory(Category category)
Sets the Cateogory that contains the Items the ItemTable should display. You can pass a Category or an Association to this method. The Category or the child category of the Association should be the same as the name of the Category that you passed to the createItemTable method.

Parameters:
category - The Category that contains the Items to display.
 o getCategoryName
 public String getCategoryName()
Return the name passed into the constructor

Returns:
The category name
 o destroy
 public void destroy()
Destroys an ItemTable by removing listeners on categories.

 o getItemTablePanel
 public ItemTablePanel getItemTablePanel()
Gets the ItemTablePanel that contains the ItemTable.

Returns:
an ItemTablePanel
 o getItemTableContext
 public ItemTableContext getItemTableContext()
Gets the ItemTableContext being used by the ItemTable

Returns:
the ItemTableContext
 o addItemViewLaunchRequestListener
 public void addItemViewLaunchRequestListener(ItemViewLaunchRequestListener listener)
Adds an ItemViewLaunchRequestListener that will be notified if a user requests that an ItemView be launched (such as by clicking on a hyperlink in the ItemTable)

Parameters:
listener - the ItemViewLaunchRequestListener to add
 o removeItemViewLaunchRequestListener
 public void removeItemViewLaunchRequestListener(ItemViewLaunchRequestListener listener)
Removes an ItemViewLaunchRequestListener

Parameters:
listener - the ItemViewLaunchRequestListener to remove
 o addTitleListener
 public void addTitleListener(TitleListener listener)
Adds a TitleListener to the ItemTable. The TitleListener will be notified whenever the title of the ItemTable changes. The ItemTable never displays its title directly. It's up to the ItemTableFrame (or any other frame) to add itself as a TitleListener and set the Title appropriately.

Parameters:
TitleListener - The title listener to notify.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
Throws: ItemTableException
if the ItemTable can't be created.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName,
                                         ResourceStack resourceStack) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
resourceStack - Additional ResourceBundles to push onto the ItemTable's ResourceStack
Throws: ItemTableException
if the ItemTable can't be created.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName,
                                         String resourceBundleName) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
resourceBundle - Additional ResourceBundle to push onto the ItemTable's ResourceStack
Throws: ItemTableException
if the ItemTable can't be created.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName,
                                         int numRows) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
numRows - How many rows the table should have initially
Throws: ItemTableException
if the ItemTable can't be created.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName,
                                         String resourceBundleName,
                                         int numRows) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
resourceBundle - Additional ResourceBundle to push onto the ItemTable's ResourceStack
numRows - How many rows the table should have initially
Throws: ItemTableException
if the ItemTable can't be created.
 o createItemTable
 public static ItemTable createItemTable(HostContext hostContext,
                                         String categoryName,
                                         ResourceStack resourceStack,
                                         int numRows) throws ItemTableException
Creates an ItemTable by invoking the ItemTableFactory

Parameters:
hostContext - the HostContext to place in the ItemTableContext that will be created for the ItemTable.
categoryName - the Category name to use to find property files and to prepend to the ItemTable resources.
resourceStack - Additional ResourceBundles to push onto the ItemTable's ResourceStack
numRows - How many rows the table should have initially
Throws: ItemTableException
if the ItemTable can't be created.
 o addItemListener
 public void addItemListener(ItemListener listener)
Add a ItemListener to receive ItemEvents when the Items are selected in the ItemTable, or when the selection changes.

Parameters:
listener - the listener to recieve events
See Also:
addItemListener
 o removeItemListener
 public void removeItemListener(ItemListener listener)
Remove an ItemListener

Parameters:
listener - the listener being removed
See Also:
removeItemListener
 o getSelectedObjects
 public Object[] getSelectedObjects()
Gets the list of Items that are selected in the ItemTable

Returns:
The list of selected Items

All Packages  Class Hierarchy  This Package  Previous  Next  Index