|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
ObjectTagSupport
BodyTagSupport
AbstractClassicTag
HtmlGroupBaseTag
RadioButtonGroup
public class RadioButtonGroup
Groups a collection of RadioButtonOptions, and handles databinding of their values. If RadioButtonGroup uses any Format tags, it must have those tags come before above any nested RadioButtonOption tags.
preferredColors.
<netui:radioButtonGroup
dataSource="actionForm.preferredColors"
optionsDataSource="${pageFlow.colors}" />
The optionsDataSource attribute points to a get method for a String[] on the Controller file:
String[] colors = new String[] {"Red", "Blue", "Green", "Yellow", "White", "Black"};
public String[] getColors()
{
return colors;
}
This automatically renders the appropriate set of radionbutton options:
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="Red">Red</input>
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="Blue">Blue</input>
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="Green">Green</input>
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="Yellow">Yellow</input>
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="White">White</input>
<input type="radio" name="wlw-radio_button_group_key:{actionForm.preferredColors}" value="Black">Black</input>| Nested Class Summary | |
|---|---|
static class |
RadioButtonGroup.RadioButtonGroupPrefixHandler
The handler for naming and indexing the RadioButtonGroup. |
| Field Summary | |
|---|---|
static String |
RADIOBUTTONGROUP_KEY
|
| Fields inherited from class HtmlGroupBaseTag |
|---|
_cr, _dataSource, _defaultValue, _disabled, _labelStyle, _labelStyleClass, _optionsDataSource, _repCurItem, _repeater, _repIdx, HORIZONTAL_VALUE, VERTICAL_VALUE |
| Fields inherited from class AbstractClassicTag |
|---|
DefaultNamingChain, EMPTY_STRING, NETUI_UNIQUE_CNT |
| Fields inherited from class BodyTagSupport |
|---|
bodyContent |
| Fields inherited from class TagSupport |
|---|
id, pageContext |
| Fields inherited from interface BodyTag |
|---|
EVAL_BODY_BUFFERED, EVAL_BODY_TAG |
| Fields inherited from interface IterationTag |
|---|
EVAL_BODY_AGAIN |
| Fields inherited from interface Tag |
|---|
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE |
| Constructor Summary | |
|---|---|
RadioButtonGroup()
|
|
| Method Summary | |
|---|---|
int |
doAfterBody()
Save any body content of this tag, which will generally be the option(s) representing the values displayed to the user. |
int |
doEndTag()
Render the set of RadioButtonOptions. |
int |
doStartTag()
Determine the match for the RadioButtonGroup |
protected List |
getNamingChain()
Return an ArrayList which represents a chain of INameInterceptor
objects. |
String |
getTagName()
Return the name of the Tag. |
boolean |
isMatched(String value,
Boolean defaultValue)
Does the specified value match one of those we are looking for? |
protected void |
localRelease()
Release any acquired resources. |
| Methods inherited from class BodyTagSupport |
|---|
doInitBody, getBodyContent, getPreviousOut, release, setBodyContent |
| Methods inherited from class TagSupport |
|---|
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue |
| Methods inherited from class Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface Tag |
|---|
getParent, setPageContext, setParent |
| Field Detail |
|---|
public static final String RADIOBUTTONGROUP_KEY
| Constructor Detail |
|---|
public RadioButtonGroup()
| Method Detail |
|---|
public String getTagName()
getTagName in interface INetuiTaggetTagName in class AbstractClassicTagprotected List getNamingChain()
ArrayList which represents a chain of INameInterceptor
objects. This method by default returns null and should be overridden
by objects that support naming.
getNamingChain in class HtmlGroupBaseTagArrayList that will contain INameInterceptor objects.
public boolean isMatched(String value,
Boolean defaultValue)
isMatched in class HtmlGroupBaseTagvalue - Value to be compared
public int doStartTag()
throws JspException
doStartTag in interface TagdoStartTag in class BodyTagSupportJspException - if a JSP exception has occurred
public int doAfterBody()
throws JspException
doAfterBody in interface IterationTagdoAfterBody in class BodyTagSupportJspException - if a JSP exception has occurred
public int doEndTag()
throws JspException
doEndTag in interface TagdoEndTag in class BodyTagSupportJspException - if a JSP exception has occurredprotected void localRelease()
localRelease in class HtmlGroupBaseTag
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||