Package com.vaadin.client.ui
Class VDateFieldCalendar
- java.lang.Object
-
- com.google.gwt.user.client.ui.UIObject
-
- com.google.gwt.user.client.ui.Widget
-
- com.google.gwt.user.client.ui.Panel
-
- com.google.gwt.user.client.ui.ComplexPanel
-
- com.google.gwt.user.client.ui.FlowPanel
-
- com.vaadin.client.ui.VDateField<R>
-
- com.vaadin.client.ui.VAbstractDateFieldCalendar<VDateCalendarPanel,DateResolution>
-
- com.vaadin.client.ui.VDateFieldCalendar
-
- All Implemented Interfaces:
com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.ui.HasEnabled,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.HasWidgets,com.google.gwt.user.client.ui.HasWidgets.ForIsWidget,com.google.gwt.user.client.ui.IndexedPanel,com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget,com.google.gwt.user.client.ui.InsertPanel,com.google.gwt.user.client.ui.InsertPanel.ForIsWidget,com.google.gwt.user.client.ui.IsWidget,Field,Iterable<com.google.gwt.user.client.ui.Widget>
public class VDateFieldCalendar extends VAbstractDateFieldCalendar<VDateCalendarPanel,DateResolution>
A client side implementation for InlineDateField.- Author:
- Vaadin Ltd
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled
-
Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasWidgets
com.google.gwt.user.client.ui.HasWidgets.ForIsWidget
-
-
Field Summary
-
Fields inherited from class com.vaadin.client.ui.VAbstractDateFieldCalendar
calendarPanel
-
Fields inherited from class com.vaadin.client.ui.VDateField
bufferedDateString, bufferedResolutions, CLASSNAME, client, connector, currentLocale, dts, enabled, readonly, rpc, showISOWeekNumbers
-
-
Constructor Summary
Constructors Constructor Description VDateFieldCalendar()Constructs a widget for the InlineDateField component.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected DateResolution[]doGetResolutions()Returns all available resolutions as an array.protected DategetDate(Map<DateResolution,Integer> dateVaules)Returns a date based on the provided date values map.booleanisYear(DateResolution resolution)Checks whether the givenresolutionrepresents an year.StringresolutionAsString()Returns a current resolution as a string.voidsetCurrentResolution(DateResolution resolution)Sets the resolution.protected booleansupportsTime()Checks whether time is supported by this widget.voidupdateBufferedValues()Update buffered valuesVDateField.bufferedDateStringandVDateField.bufferedResolutionsthat will be sent to the server.voidupdateValueFromPanel()TODO refactor: almost same method as in VPopupCalendar.updateValue-
Methods inherited from class com.vaadin.client.ui.VAbstractDateFieldCalendar
getTabIndex, setTabIndex
-
Methods inherited from class com.vaadin.client.ui.VDateField
getClient, getCurrentDate, getCurrentLocale, getCurrentResolution, getDate, getDateTimeService, getDefaultDate, getId, getResolutions, getResolutionVariable, isEnabled, isReadonly, isShowISOWeekNumbers, sendBufferedValues, sendBufferedValuesWithDelay, setCurrentDate, setCurrentDate, setCurrentLocale, setDate, setDefaultDate, setDefaultDate, setEnabled, setReadonly, setShowISOWeekNumbers
-
Methods inherited from class com.google.gwt.user.client.ui.ComplexPanel
add, add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getChildren, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, insert, iterator, remove, remove
-
Methods inherited from class com.google.gwt.user.client.ui.Panel
add, adopt, doAttachChildren, doDetachChildren, orphan, remove
-
Methods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
-
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel
getWidget, getWidgetCount, getWidgetIndex, remove
-
Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget
getWidgetIndex
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
updateBufferedValues
public void updateBufferedValues()
Description copied from class:VDateFieldUpdate buffered valuesVDateField.bufferedDateStringandVDateField.bufferedResolutionsthat will be sent to the server.This method should NOT send values to the server.
This method can be implemented by subclasses to update buffered values from component values.
- Specified by:
updateBufferedValuesin classVDateField<DateResolution>
-
updateValueFromPanel
public void updateValueFromPanel()
TODO refactor: almost same method as in VPopupCalendar.updateValueFor internal use only. May be removed or replaced in the future.
- Specified by:
updateValueFromPanelin classVAbstractDateFieldCalendar<VDateCalendarPanel,DateResolution>
-
setCurrentResolution
public void setCurrentResolution(DateResolution resolution)
Description copied from class:VDateFieldSets the resolution.- Overrides:
setCurrentResolutionin classVDateField<DateResolution>- Parameters:
resolution- the new resolution
-
resolutionAsString
public String resolutionAsString()
Description copied from class:VDateFieldReturns a current resolution as a string.The method is used to generate a style name for the current resolution.
- Specified by:
resolutionAsStringin classVDateField<DateResolution>- Returns:
- the current resolution as a string
-
isYear
public boolean isYear(DateResolution resolution)
Description copied from class:VDateFieldChecks whether the givenresolutionrepresents an year.- Specified by:
isYearin classVDateField<DateResolution>- Parameters:
resolution- the given resolution- Returns:
trueif theresolutionrepresents an year
-
doGetResolutions
protected DateResolution[] doGetResolutions()
Description copied from class:VDateFieldReturns all available resolutions as an array.No any order is required (in contrary to
VDateField.getResolutions().- Specified by:
doGetResolutionsin classVDateField<DateResolution>- Returns:
- all available resolutions
- See Also:
VDateField.getResolutions()
-
getDate
protected Date getDate(Map<DateResolution,Integer> dateVaules)
Description copied from class:VDateFieldReturns a date based on the provided date values map.- Specified by:
getDatein classVDateField<DateResolution>- Parameters:
dateVaules- a map with date values to convert into a date- Returns:
- the date based on the dateValues map
- See Also:
VDateField.setCurrentDate(Map)
-
supportsTime
protected boolean supportsTime()
Description copied from class:VDateFieldChecks whether time is supported by this widget.- Specified by:
supportsTimein classVDateField<DateResolution>- Returns:
trueif time is supported in addition to date,falseif only dates are supported
-
-