com.opensymphony.webwork.components
Class UpDownSelect
java.lang.Object
com.opensymphony.webwork.components.Component
com.opensymphony.webwork.components.UIBean
com.opensymphony.webwork.components.ListUIBean
com.opensymphony.webwork.components.Select
com.opensymphony.webwork.components.UpDownSelect
public class UpDownSelect
- extends Select
Create a Select component with buttons to move the elements in the select component
up and down. When the containing form is submited, its elements will be submitted in
the order they are arranged (top to bottom).
<!-- Example 1: simple example -->
<ww:updownselect
list="#{'england':'England', 'america':'America', 'germany':'Germany'}"
name="prioritisedFavouriteCountries"
headerKey="-1"
headerValue="--- Please Order Them Accordingly ---"
emptyOption="true" />
<!-- Example 2: more complex example -->
<ww:updownselect
list="defaultFavouriteCartoonCharacters"
name="prioritisedFavouriteCartoonCharacters"
headerKey="-1"
headerValue="--- Please Order ---"
emptyOption="true"
allowMoveUp="true"
allowMoveDown="true"
allowSelectAll="true"
moveUpLabel="Move Up"
moveDownLabel="Move Down"
selectAllLabel="Select All" />
- Version:
- $Date: 2006-03-19 00:28:55 +0800 (Sun, 19 Mar 2006) $ $Id: UpDownSelect.java 2468 2006-03-18 16:28:55Z rgielen $
- Author:
- tm_jee
Fields inherited from class com.opensymphony.webwork.components.UIBean |
accesskey, cssClass, cssStyle, disabled, label, labelPosition, name, onblur, onchange, onclick, ondblclick, onfocus, onkeydown, onkeypress, onkeyup, onmousedown, onmousemove, onmouseout, onmouseover, onmouseup, onselect, request, required, requiredposition, response, tabindex, template, templateDir, templateSuffix, theme, title, tooltip, tooltipConfig, value |
Methods inherited from class com.opensymphony.webwork.components.UIBean |
addFormParameter, buildTemplateName, enableAncestorFormCustomOnsubmit, end, escape, evaluateNameValue, getTemplate, getTemplateDir, getTheme, getTooltipConfig, mergeTemplate, populateComponentHtmlId, setAccesskey, setCssClass, setCssStyle, setDisabled, setLabel, setLabelposition, setLabelPosition, setName, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setRequired, setRequiredposition, setTabindex, setTemplate, setTemplateDir, setTheme, setTitle, setTooltip, setTooltipConfig, setValue |
Methods inherited from class com.opensymphony.webwork.components.Component |
addAllParameters, addParameter, altSyntax, copyParams, determineActionURL, determineNamespace, end, fieldError, findAncestor, findString, findString, findValue, findValue, findValue, getComponentStack, getId, getParameters, getStack, popComponentStack, setId, start, toString, usesBody |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TEMPLATE
public static final String TEMPLATE
- See Also:
- Constant Field Values
allowMoveUp
protected String allowMoveUp
allowMoveDown
protected String allowMoveDown
allowSelectAll
protected String allowSelectAll
moveUpLabel
protected String moveUpLabel
moveDownLabel
protected String moveDownLabel
selectAllLabel
protected String selectAllLabel
UpDownSelect
public UpDownSelect(OgnlValueStack stack,
HttpServletRequest request,
HttpServletResponse response)
getDefaultTemplate
public String getDefaultTemplate()
- Description copied from class:
UIBean
- A contract that requires each concrete UI Tag to specify which template should be used as a default. For
example, the CheckboxTab might return "checkbox.vm" while the RadioTag might return "radio.vm". This value
not begin with a '/' unless you intend to make the path absolute rather than relative to the
current theme.
- Overrides:
getDefaultTemplate
in class Select
- Returns:
- The name of the template to be used as the default.
evaluateParams
public void evaluateParams()
- Overrides:
evaluateParams
in class UIBean
getAllowMoveUp
public String getAllowMoveUp()
setAllowMoveUp
public void setAllowMoveUp(String allowMoveUp)
- Whether move up button should be displayed
getAllowMoveDown
public String getAllowMoveDown()
setAllowMoveDown
public void setAllowMoveDown(String allowMoveDown)
- Whether move down button should be displayed
getAllowSelectAll
public String getAllowSelectAll()
setAllowSelectAll
public void setAllowSelectAll(String allowSelectAll)
- Whether or not select all button should be displayed
getMoveUpLabel
public String getMoveUpLabel()
setMoveUpLabel
public void setMoveUpLabel(String moveUpLabel)
- Text to display on the move up button
getMoveDownLabel
public String getMoveDownLabel()
setMoveDownLabel
public void setMoveDownLabel(String moveDownLabel)
- Text to display on the move down button
getSelectAllLabel
public String getSelectAllLabel()
setSelectAllLabel
public void setSelectAllLabel(String selectAllLabel)
- Text to display on the select all button