Name
javax.microedition.lcdui.ChoiceGroup
Synopsis
This class implements a group of selectable elements intended to be placed within a Form. The group may have a mode that requires a single choice to be made or that allows multiple choices. It is up to the implementation to decide on the graphical representation of these modes, but it must provide visually different graphics for different modes—for example, radio buttons for single-choice mode and checkboxes for multiple-choice mode.
public classChoiceGroup
extends Item implements Choice { // public constructors publicChoiceGroup
(String label, int choiceType); publicChoiceGroup
(String label, int choiceType, String[] stringElements, Image[] imgElements); // public instance methods public intappend
(String stringPart, Image imagePart); public voiddelete
(int elementNum); public ImagegetImage
(int elementNum); public intgetSelectedFlags
(boolean[] selectedArray); public intgetSelectedIndex
( ); public StringgetString
(int elementNum); public voidinsert
(int elementNum, String stringElement, Image imageElement); public booleanisSelected
(int elementNum); public voidset
(int elementNum, String stringPart, Image imagePart); public voidsetsSelectedFlags
(boolean[] selectedArray); public voidsetSelectedIndex
(int elementNum, boolean selected); public intsize
( ); }
Get Wireless Java now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.