org.apache.myfaces.html5.component.input
Class AbstractHtmlInputDateTime

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by javax.faces.component.UIOutput
              extended by javax.faces.component.UIInput
                  extended by javax.faces.component.html.HtmlInputText
                      extended by org.apache.myfaces.html5.component.input.AbstractHtml5BaseInputText
                          extended by org.apache.myfaces.html5.component.input.Html5BaseInputText
                              extended by org.apache.myfaces.html5.component.input.AbstractHtmlInputDateTime
All Implemented Interfaces:
EventListener, javax.faces.component.behavior.ClientBehaviorHolder, javax.faces.component.EditableValueHolder, javax.faces.component.PartialStateHolder, javax.faces.component.StateHolder, javax.faces.component.ValueHolder, javax.faces.event.ComponentSystemEventListener, javax.faces.event.FacesListener, javax.faces.event.SystemEventListenerHolder, Draggable, Html5GlobalProperties, Html5InputProperties
Direct Known Subclasses:
HtmlInputDateTime

@JSFComponent(name="hx:inputDateTime",
              clazz="org.apache.myfaces.html5.component.input.HtmlInputDateTime",
              tagClass="org.apache.myfaces.html5.tag.input.HtmlInputDateTimeTag",
              defaultRendererType="org.apache.myfaces.html5.DateTime",
              family="javax.faces.Input",
              type="org.apache.myfaces.html5.HtmlDateTime",
              implementz="javax.faces.component.behavior.ClientBehaviorHolder",
              defaultEventName="valueChange")
public abstract class AbstractHtmlInputDateTime
extends Html5BaseInputText

Convenience component for Html5 date like inputs.
Minimum and maximum date selectable is determined by using attached fx:validateDateTimeRange if any. Else, minimum and maximum are not rendered.

Author:
Ali Ok

Field Summary
 
Fields inherited from class org.apache.myfaces.html5.component.input.Html5BaseInputText
COMPONENT_FAMILY, COMPONENT_TYPE
 
Fields inherited from class javax.faces.component.UIInput
CONVERSION_MESSAGE_ID, REQUIRED_MESSAGE_ID, UPDATE_MESSAGE_ID, VALIDATE_EMPTY_FIELDS_PARAM_NAME
 
Fields inherited from class javax.faces.component.UIComponent
BEANINFO_KEY, bindings, COMPOSITE_COMPONENT_TYPE_KEY, COMPOSITE_FACET_NAME, CURRENT_COMPONENT, CURRENT_COMPOSITE_COMPONENT, FACETS_KEY, VIEW_LOCATION_KEY
 
Constructor Summary
AbstractHtmlInputDateTime()
           
 
Method Summary
 int getMaxlength()
           
 int getSize()
           
abstract  double getStep()
          Indicates the granularity of the value by limiting the allowed values.
abstract  String getType()
          Type of the input.
 
Methods inherited from class org.apache.myfaces.html5.component.input.Html5BaseInputText
getAnimationEnd, getDataList, getDefaultEventName, getDir, getEventNames, getFamily, getLang, getOndrag, getOndragend, getOndragenter, getOndragleave, getOndragover, getOndragstart, getOndrop, getOnformchange, getOnforminput, getOninput, getOninvalid, getOnmousewheel, getStyle, getStyleClass, getSuggestions, getTitle, isAutoFocus, isDraggable, isHidden, setAnimationEnd, setAutoFocus, setDataList, setDir, setDraggable, setHidden, setLang, setOndrag, setOndragend, setOndragenter, setOndragleave, setOndragover, setOndragstart, setOndrop, setOnformchange, setOnforminput, setOninput, setOninvalid, setOnmousewheel, setStyle, setStyleClass, setSuggestions, setTitle
 
Methods inherited from class javax.faces.component.html.HtmlInputText
getAccesskey, getAlt, getAutocomplete, getLabel, getOnblur, getOnchange, getOnclick, getOndblclick, getOnfocus, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnselect, getTabindex, isDisabled, isReadonly, setAccesskey, setAlt, setAutocomplete, setDisabled, setLabel, setMaxlength, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setReadonly, setSize, setTabindex
 
Methods inherited from class javax.faces.component.UIInput
addValidator, addValueChangeListener, broadcast, clearInitialState, compareValues, decode, getConvertedValue, getConverterMessage, getRequiredMessage, getSubmittedValue, getValidator, getValidatorMessage, getValidators, getValue, getValueChangeListener, getValueChangeListeners, isEmpty, isImmediate, isLocalValueSet, isRequired, isValid, markInitialState, processDecodes, processUpdates, processValidators, removeValidator, removeValueChangeListener, resetValue, restoreState, saveState, setConverterMessage, setImmediate, setLocalValueSet, setRequired, setRequiredMessage, setSubmittedValue, setValid, setValidator, setValidatorMessage, setValue, setValueChangeListener, updateModel, validate, validateValue
 
Methods inherited from class javax.faces.component.UIOutput
getConverter, getLocalValue, setConverter
 
Methods inherited from class javax.faces.component.UIComponentBase
addClientBehavior, addFacesListener, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientBehaviors, getClientId, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, initialStateMarked, invokeOnComponent, isRendered, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient, setValueBinding, visitTree
 
Methods inherited from class javax.faces.component.UIComponent
encodeAll, getClientId, getCompositeComponentParent, getContainerClientId, getCurrentComponent, getCurrentCompositeComponent, getListenersForEventClass, getNamingContainer, getResourceBundleMap, getStateHelper, getStateHelper, getValueExpression, isCompositeComponent, isInView, isVisitable, popComponentFromEL, processEvent, pushComponentToEL, setInView, setValueExpression, subscribeToEvent, unsubscribeFromEvent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.faces.component.behavior.ClientBehaviorHolder
addClientBehavior, getClientBehaviors
 
Methods inherited from interface javax.faces.component.ValueHolder
getConverter, getLocalValue, setConverter
 

Constructor Detail

AbstractHtmlInputDateTime

public AbstractHtmlInputDateTime()
Method Detail

getType

@JSFProperty(deferredValueType="java.lang.String",
             defaultValue="datetime")
public abstract String getType()
Type of the input. Can be one of "datetime", "date", "time", "month", "week", "datetime-local". Defaults to "datetime".


getStep

@JSFProperty(deferredValueType="java.lang.Double",
             defaultValue="Double.MIN_VALUE")
public abstract double getStep()
Indicates the granularity of the value by limiting the allowed values. The limited values will be decided considering the step base which is defined by 'minimum' property of the attached fx:validateDateTimeRange. If not specified, 'any' will be rendered as the step value, thus browser will decide it.
Specified value will be multiplied with the step scale factor which is different for each type.
Information about the step for each type is: <table border="1"> <tr> <th>type</th> <th>Description for step scale factor</th> <th>Default step value(what 'any' means)</th> <th>Applicable minimum value of step</th> <th>Applicable maximum value of step</th> <tr> <tr> <td>datetime</td> <td>Step should be expressed in seconds.</td> <td>1 minute</td> <td>0.01 (10 miliseconds)</td> <td>N/A</td> //XXX: test it again </tr> <tr> <td>date</td> <td>Step should be expressed in days.</td> <td>1 day</td> <td>1 (1 day)</td> <td>N/A</td> //XXX: test it again </tr> <tr> <td>time</td> <td>Step should be expressed in seconds. If the step is less than 1 second, browser should show the miliseconds input too.</td> <td>1 minute</td> <td>0.01 (10 miliseconds)</td> <td>N/A</td> //XXX: test it again </tr> <tr> <td>month</td> <td>Step should be expressed in months.</td> <td>1 month</td> <td>1 (1 month)</td> <td>N/A</td> //XXX: test it again </tr> <tr> <td>week</td> <td>Step should be expressed in weeks.</td> <td>1 week</td> <td>1 (1 week)</td> <td>N/A</td> //XXX: test it again </tr> <tr> <td>datetime-local</td> <td>Step should be expressed in seconds.</td> <td>1 minute</td> <td>0.01 (10 miliseconds)</td> <td>N/A</td> //XXX: test it again </tr> </table>


getMaxlength

@JSFProperty(tagExcluded=true,
             defaultValue="Integer.MIN_VALUE")
public int getMaxlength()
Overrides:
getMaxlength in class javax.faces.component.html.HtmlInputText

getSize

@JSFProperty(tagExcluded=true,
             defaultValue="Integer.MIN_VALUE")
public int getSize()
Overrides:
getSize in class javax.faces.component.html.HtmlInputText


Copyright © 2011 The Apache Software Foundation. All Rights Reserved.