java.awt

Interface ItemSelectable

public interface ItemSelectable

This interface is for objects that can have one or more items selected. For example, radio buttons.

Since: 1.0

UNKNOWN: updated to 1.4

Method Summary
voidaddItemListener(ItemListener listener)
Adds an item listener to this object.
Object[]getSelectedObjects()
Returns the list of objects that are selected in this component.
voidremoveItemListener(ItemListener listener)
Removes an item listener from this object.

Method Detail

addItemListener

public void addItemListener(ItemListener listener)
Adds an item listener to this object. It will receive selection events for this object by the user (but not programatically). If listener is null, it is ignored.

Parameters: listener the item listener to add

getSelectedObjects

public Object[] getSelectedObjects()
Returns the list of objects that are selected in this component.

Returns: the list of selected objects, or null

removeItemListener

public void removeItemListener(ItemListener listener)
Removes an item listener from this object.

Parameters: listener the item listener to remove