com.ibm.as400.ui.framework.java
Class ItemDescriptor

java.lang.Object
  |
  +--com.ibm.as400.ui.framework.java.AbstractDescriptor
        |
        +--com.ibm.as400.ui.framework.java.ItemDescriptor
All Implemented Interfaces:
javax.swing.SwingConstants

public class ItemDescriptor
extends AbstractDescriptor
implements javax.swing.SwingConstants

Describes an item in a list. ItemDescriptors represent objects on a user interface panel, as displayed in a list or table.

Since:
v4r2m0

Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NORTH, NORTH_EAST, NORTH_WEST, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 
Constructor Summary
ItemDescriptor()
          Constructs an ItemDescriptor.
ItemDescriptor(java.lang.String name, java.lang.String title)
          Constructs an ItemDescriptor with the specified name and title.
ItemDescriptor(java.lang.String name, java.lang.String title, HandlerTask[] handlerTasks)
          Constructs an ItemDescriptor with the specified name, title, and HandlerTask list.
ItemDescriptor(java.lang.String name, java.lang.String title, java.lang.String imageFile)
          Constructs an ItemDescriptor with the specified name, title and image file.
ItemDescriptor(java.lang.String name, java.lang.String title, java.lang.String imageFile, int iconPosition, int vIconPosition)
          Constructs an ItemDescriptor with the specified name, title, image file, and icon alignment.
 
Method Summary
 int getHorizontalIconPosition()
          Returns the item's horizontal icon position.
 java.lang.String getImageFile()
          Returns the item's image file name.
 int getVerticalIconPosition()
          Returns the item's vertical icon position.
 void setHorizontalIconPosition(int horizontalIconPosition)
          Sets the item's horizontal icon position.
 void setImageFile(java.lang.String imageFile)
          Sets the item's image file name.
 void setVerticalIconPosition(int verticalIconPosition)
          Sets the item's vertical icon position.
 
Methods inherited from class com.ibm.as400.ui.framework.java.AbstractDescriptor
addHandlerTask, getName, getTitle, getUserObject, removeHandlerTask, setName, setTitle, setUserObject, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ItemDescriptor

public ItemDescriptor()
Constructs an ItemDescriptor.
Since:
v4r2m0

ItemDescriptor

public ItemDescriptor(java.lang.String name,
                      java.lang.String title)
Constructs an ItemDescriptor with the specified name and title.
Parameters:
name - the name that is used to identify the item programmatically
title - the title of the item in a form suitable for displaying to the user
Since:
v4r2m0

ItemDescriptor

public ItemDescriptor(java.lang.String name,
                      java.lang.String title,
                      java.lang.String imageFile)
Constructs an ItemDescriptor with the specified name, title and image file. Default icon position of LEFT and vertical icon position of CENTER will be used.
Parameters:
name - the name that is used to identify the item programmatically
title - the title of the item in a form suitable for displaying to the user
imageFile - the name of the file containing the image to be displayed with this item
Since:
v4r5m0

ItemDescriptor

public ItemDescriptor(java.lang.String name,
                      java.lang.String title,
                      java.lang.String imageFile,
                      int iconPosition,
                      int vIconPosition)
Constructs an ItemDescriptor with the specified name, title, image file, and icon alignment.
Parameters:
name - the name that is used to identify the item programmatically
title - the title of the item in a form suitable for displaying to the user
imageFile - the name of the file containing the image to be displayed with this item
iconPosition - the position of the item's icon in relation to the item text
vIconPosition - the vertical position of the item's icon
Since:
v4r5m0

ItemDescriptor

public ItemDescriptor(java.lang.String name,
                      java.lang.String title,
                      HandlerTask[] handlerTasks)
Constructs an ItemDescriptor with the specified name, title, and HandlerTask list.
Parameters:
name - the name that is used to identify the item programmatically
title - the title of the item in a form suitable for displaying to the user
handlerTasks - a list of HandlerTasks which describe to the UI framework actions which should be carried out when the item is selected
Since:
v4r2m0
See Also:
HandlerTask
Method Detail

getImageFile

public java.lang.String getImageFile()
Returns the item's image file name.
Returns:
the name of the image resource that will be used to create the icon for the item
Since:
v4r5m0
See Also:
setImageFile(java.lang.String)

setImageFile

public void setImageFile(java.lang.String imageFile)
Sets the item's image file name.
Parameters:
imageFile - the name of the image resource that will be used to create the icon for the item
Since:
v4r5m0
See Also:
getImageFile()

getHorizontalIconPosition

public int getHorizontalIconPosition()
Returns the item's horizontal icon position.
Returns:
the horizontal position of the icon for the item
Since:
v4r5m0
See Also:
setHorizontalIconPosition(int)

setHorizontalIconPosition

public void setHorizontalIconPosition(int horizontalIconPosition)
Sets the item's horizontal icon position.
Parameters:
horizontalIconPosition - the horizontal position of the icon for the item
Since:
v4r5m0
See Also:
getHorizontalIconPosition()

getVerticalIconPosition

public int getVerticalIconPosition()
Returns the item's vertical icon position.
Returns:
the vertical position of the icon for the item
Since:
v4r5m0
See Also:
setVerticalIconPosition(int)

setVerticalIconPosition

public void setVerticalIconPosition(int verticalIconPosition)
Sets the item's vertical icon position.
Parameters:
verticalIconPosition - the vertical position of the icon for the item
Since:
v4r5m0
See Also:
getVerticalIconPosition()