org.apache.struts2.components
Class TimePicker
java.lang.Object
org.apache.struts2.components.Component
org.apache.struts2.components.UIBean
org.apache.struts2.components.TextField
org.apache.struts2.components.TimePicker
public class TimePicker
- extends TextField
Renders timepicker element.
Format supported by this component are:-
Format |
Description |
#HH |
Display hour in two digit format |
#H |
Try to display hour in one digit format, if cannot use 2 digits |
#hh |
Display hour in two digit format |
#h |
Try to display hour in one digit format, if cannot use 2 digits |
#mm |
Display minutes in 2 digits format |
#m |
Try to display minutes in 2 digits fomrat, if cannot use 2 digits |
<s:timepicker label="Show Time" name="showTime" value="05:00" format="#hh:#mm" />
<s:timepicker label="Dinner Time" name="dinnerTime" format="#hh-#mm" />
- Version:
- $Date: 2006-09-05 23:34:39 -0400 (Tue, 05 Sep 2006) $ $Id: TimePicker.java 440597 2006-09-06 03:34:39Z wsmoak $
Fields inherited from class org.apache.struts2.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 |
Constructor Summary |
TimePicker(com.opensymphony.xwork2.util.OgnlValueStack stack,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
Method Summary |
protected void |
evaluateExtraParams()
|
protected java.lang.String |
getDefaultTemplate()
A contract that requires each concrete UI Tag to specify which template should be used as a default. |
void |
setFormat(java.lang.String format)
The format to use for time field. |
void |
setSize(java.lang.String size)
The time picker text field size. |
void |
setTemplateCssPath(java.lang.String templateCssPath)
The time picker template css path. |
void |
setTemplatePath(java.lang.String templatePath)
The time picker template path. |
void |
setTimeIconPath(java.lang.String timeIconPath)
The time picker icon path |
Methods inherited from class org.apache.struts2.components.UIBean |
addFormParameter, buildTemplateName, enableAncestorFormCustomOnsubmit, end, escape, evaluateNameValue, evaluateParams, getTemplate, getTemplateDir, getTheme, getTooltipConfig, getValueClassType, mergeTemplate, populateComponentHtmlId, setAccesskey, setCssClass, setCssStyle, setDisabled, setLabel, 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 org.apache.struts2.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 java.lang.String TEMPLATE
- See Also:
- Constant Field Values
format
protected java.lang.String format
templatePath
protected java.lang.String templatePath
templateCssPath
protected java.lang.String templateCssPath
timeIconPath
protected java.lang.String timeIconPath
size
protected java.lang.String size
TimePicker
public TimePicker(com.opensymphony.xwork2.util.OgnlValueStack stack,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
evaluateExtraParams
protected void evaluateExtraParams()
- Overrides:
evaluateExtraParams
in class TextField
getDefaultTemplate
protected java.lang.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 TextField
- Returns:
- The name of the template to be used as the default.
setFormat
public void setFormat(java.lang.String format)
- The format to use for time field.
setTimeIconPath
public void setTimeIconPath(java.lang.String timeIconPath)
- The time picker icon path
setTemplatePath
public void setTemplatePath(java.lang.String templatePath)
- The time picker template path.
setTemplateCssPath
public void setTemplateCssPath(java.lang.String templateCssPath)
- The time picker template css path.
setSize
public void setSize(java.lang.String size)
- The time picker text field size.
- Overrides:
setSize
in class TextField
Copyright © 2000-2006 Apache Software Foundation. All Rights Reserved.