All Packages Class Hierarchy This Package Previous Next Index
Interface com.sgi.sysadm.ui.ItemTableColumnRenderer
- public interface ItemTableColumnRenderer
An interface that describes how to render a particular column of an
ItemTable and how to sort Items based on that column.
The ItemTableColumnRenderer is used by the ItemTableController to
render cells in ways that are not automatically handled by the
ItemTableController. To
use a ItemTableColumnRenderer, the programmer should set the METHOD
resource to componentRenderer, stringRenderer, or
richTextRenderer in the Category's property file and set the
COLUMN_RENDERER property to a class that implements this interface.
See the ItemTable documentation for more information
- See Also:
- ItemTableController, ItemTable, COLUMN_RENDERER, METHOD
-
compareItemsForItemTable(Item, Item, String)
- Compare two items based on a particular column.
-
getComponentForCellOfItemTable(Item, String, ItemTableContext)
- Returns a JComponent that should be displayed for a particular
Item in a particular column.
-
getRichTextForCellOfItemTable(Item, String, ItemTableContext)
- Returns a String that should be displayed in a
RichTextComponent in the table's cell for a particular
Item in a particular column.
-
getStringForCellOfItemTable(Item, String, ItemTableContext)
-
Returns a string that represents the value of a particular
Item in a particular column.
getStringForCellOfItemTable
public abstract String getStringForCellOfItemTable(Item item,
String columnName,
ItemTableContext context)
- Returns a string that represents the value of a particular
Item in a particular column.
The string will be displayed in a cell of an ItemTable.
- Parameters:
- item - The Item being rendered
- columnName - The column containing the cell that needs to
be rendered.
- context - An ItemTableContext for use by the renderer
- Returns:
- A String representing the state of Item
item that should be displayed in column
columnName.
getComponentForCellOfItemTable
public abstract JComponent getComponentForCellOfItemTable(Item item,
String columnName,
ItemTableContext context)
- Returns a JComponent that should be displayed for a particular
Item in a particular column. The component will be displayed
in a cell of an ItemTable.
- Parameters:
- item - The Item being rendered
- columnName - The column containing the cell that needs to
be rendered.
- context - An ItemTableContext for use by the renderer
- Returns:
- A JComponent representing the state of Item
item that should be displayed in column
columnName.
getRichTextForCellOfItemTable
public abstract String getRichTextForCellOfItemTable(Item item,
String columnName,
ItemTableContext context)
- Returns a String that should be displayed in a
RichTextComponent in the table's cell for a particular
Item in a particular column. The string will be used to create a
RichTextComponent that will be displayed in an ItemTable.
If desired, the string that is returned can contain HTML markup
that describes a link to an ItemView, as created by ItemView's
createURLToLaunch. In this case, the
ItemTableController will automatically handle the user's click
on the link.
- Parameters:
- item - The Item being rendered
- columnName - The column containing the cell that needs to
be rendered.
- context - An ItemTableContext for use by the renderer
- Returns:
- A String representing the state of Item
item that should be displayed in column
columnName.
- See Also:
- createURLToLaunch
compareItemsForItemTable
public abstract int compareItemsForItemTable(Item item1,
Item item2,
String columnName)
- Compare two items based on a particular column. Returns
- < 0 if item1 < item2
- 0 if item1 == item2
- > 0 if item1 > item2
- Parameters:
- item1 - The first Item
- item2 - The second Item
- columnName - The column of the ItemTable to compare on.
- Returns:
- An integer
All Packages Class Hierarchy This Package Previous Next Index