public class SelectItem
extends java.lang.Object
The SelectItem class holds the list data for an UI component like checkbox. (selectOneCheckBox, selectManyCheckBox, single checkBox etc).
| Modifier and Type | Class and Description |
|---|---|
static class |
SelectItem.SELECT_STATE |
| Constructor and Description |
|---|
SelectItem()
Constructs an empty SelectItem
|
SelectItem(java.lang.String label, java.lang.Object selValue, java.lang.Object unselValue, SelectItem.SELECT_STATE selState)
Constructs a SelectItem with lable, selected value, unselected Value, and current selected state.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getLabel()
Retrieves the label of the selected item
|
SelectItem.SELECT_STATE |
getSelectState()
Retrieves the selection state of a checkbox
|
java.lang.Object |
getSelectValue()
Retrieves the value when the checkbox is selected.
|
java.lang.Object |
getUnSelectValue()
Retrieves the value when the checkbox is not selected.
|
void |
setLabel(java.lang.String label)
Sets the label of the selectedItem.
|
void |
setSelectState(SelectItem.SELECT_STATE selState)
Sets the checked state for the checkbox.
|
void |
setSelectValue(java.lang.Object selValue)
Sets the value when the checkbox is selected.
|
void |
setUnSelectValue(java.lang.Object unselValue)
Sets the value when the checkbox is unselected.
|
public SelectItem()
public SelectItem(java.lang.String label,
java.lang.Object selValue,
java.lang.Object unselValue,
SelectItem.SELECT_STATE selState)
Constructs a SelectItem with lable, selected value, unselected Value, and current selected state.
label - the label used for the text of a checkboxselValue - the value used when the checkbox is selectedunselValue - the value used when the checkbox is unselectedselState - the selected state of the checkbox.public void setLabel(java.lang.String label)
Sets the label of the selectedItem.
label -public java.lang.String getLabel()
public java.lang.Object getSelectValue()
Retrieves the value when the checkbox is selected.
public void setSelectValue(java.lang.Object selValue)
Sets the value when the checkbox is selected.
selValue -public java.lang.Object getUnSelectValue()
Retrieves the value when the checkbox is not selected.
public void setUnSelectValue(java.lang.Object unselValue)
Sets the value when the checkbox is unselected.
unselValue -public SelectItem.SELECT_STATE getSelectState()
public void setSelectState(SelectItem.SELECT_STATE selState)
Sets the checked state for the checkbox.
selState -