public class HTMLRadioButtonGroup
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
additionalTagFragments |
protected java.lang.String |
className |
protected int |
editBeginIndex |
Constructor and Description |
---|
HTMLRadioButtonGroup(java.lang.String[] keys,
java.lang.String[] labels) |
HTMLRadioButtonGroup(java.lang.String name,
java.lang.String[] keys,
java.lang.String[] labels) |
Modifier and Type | Method and Description |
---|---|
void |
fetchYourValueFromRequest(GeneralizedRequest request)
Causes the component to read user input by calling request.getParameter and
update the internal mirrored value.
|
java.lang.String |
getCreationTag()
Returns the tag sequence that's needed to show this object in the user
interface.
|
int |
getSelectedIndex()
Returns the index of the currently selected item.
|
java.lang.String |
getSelectedKey()
Returns the key of the currently selected item.
|
boolean |
isModified()
Indicates whether the component's value differs from its initial value.
|
void |
selectFirstEnabledItem()
Selects the first of all enabled items.
|
void |
setEnabled(boolean enabled)
Enables or disables all items.
|
void |
setEnabled(int anIndex,
boolean enabled)
Enables or disables an item by index.
|
void |
setSelectedIndex(int anIndex)
Selects the item at index.
|
void |
setSelectedKey(java.lang.String key)
Selects the item by its key.
|
protected java.lang.String className
protected java.lang.String additionalTagFragments
protected int editBeginIndex
public HTMLRadioButtonGroup(java.lang.String[] keys, java.lang.String[] labels)
public HTMLRadioButtonGroup(java.lang.String name, java.lang.String[] keys, java.lang.String[] labels)
public void setEnabled(boolean enabled)
enabled
- whether the items should be enabeld or notpublic void setEnabled(int anIndex, boolean enabled)
anIndex
- an int specifying the item to select, where 0 specifiesenabled
- whether the item should be enabled or notpublic void selectFirstEnabledItem()
public void setSelectedKey(java.lang.String key)
key
- the key of the item to selectpublic void setSelectedIndex(int anIndex)
anIndex
- an int specifying the item to select, where 0 specifies
the first itempublic int getSelectedIndex()
public java.lang.String getSelectedKey()
public java.lang.String getCreationTag()
public void fetchYourValueFromRequest(GeneralizedRequest request)
request
- the current requestpublic boolean isModified()
Copyright 1998-2023 Christoph Mueller, Kaerntner Str. 56, D-70469 Stuttgart, Germany, https://www.perpus.de