Constructors
Name | Description |
---|---|
Choice() | Creates a new choice menu. |
Methods
Name | Description |
---|---|
add(String) | Adds an item to this Choice menu. |
addItem(String) | Adds an item to this Choice. |
addItemListener(ItemListener) | Adds the specified item listener to receive item events from this Choice menu. |
addNotify() | Creates the Choice's peer. |
countItems() | Deprecated. |
getItem(int) | Gets the string at the specified index in this Choice menu. |
getItemCount() | Returns the number of items in this Choice menu. |
getSelectedIndex() | Returns the index of the currently selected item. |
getSelectedItem() | Gets a representation of the current choice as a string. |
getSelectedObjects() | Returns an array (length 1) containing the currently selected item. |
insert(String, int) | Inserts the item into this choice at the specified position. |
paramString() | Returns the parameter string representing the state of this choice menu. |
processEvent(AWTEvent) | Processes events on this choice. |
processItemEvent(ItemEvent) | Processes item events occurring on this Choice menu by dispatching them to any registered ItemListener objects. |
remove(int) | Removes an item from the choice menu at the specified position. |
remove(String) | Remove the first occurrence of item from the Choice menu. |
removeAll() | Removes all items from the choice menu. |
removeItemListener(ItemListener) | Removes the specified item listener so that it no longer receives item events from this Choice menu. |
select(int) | Sets the selected item in this Choice menu to be the item at the specified position. |
select(String) | Sets the selected item in this Choice menu to be the item whose name is equal to the specified string. |