Class CmsSerialDateController
java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Composite
org.opencms.acacia.client.widgets.serialdate.CmsSerialDateController
- All Implemented Interfaces:
com.google.gwt.event.dom.client.HasFocusHandlers,com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.logical.shared.HasValueChangeHandlers<String>,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.TakesValue<String>,com.google.gwt.user.client.ui.HasValue<String>,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.IsRenderable,com.google.gwt.user.client.ui.IsWidget,I_CmsEditWidget,I_StatusUpdateHandler
public class CmsSerialDateController
extends com.google.gwt.user.client.ui.Composite
implements I_CmsEditWidget, I_StatusUpdateHandler
Controller for the serial date widget, being the widget implementation itself.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classData wrapper for the default values to set when changing the pattern, dependent on the event's start date.protected static classThe status update timer.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 -
Field Summary
FieldsFields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.google.gwt.event.shared.HandlerRegistrationaddFocusHandler(com.google.gwt.event.dom.client.FocusHandler handler) com.google.gwt.event.shared.HandlerRegistrationaddValueChangeHandler(com.google.gwt.event.logical.shared.ValueChangeHandler<String> handler) voidconditionallyRemoveExceptionsOnChange(com.google.gwt.user.client.Command action, boolean showDialog) voidShow the dates for managing exceptions.Returns the controller for the currently active pattern.Returns the default values to set for the patterns dependent on the current start date.Returns the widget to place in the pattern panel.getValue()booleanisActive()Returns if the widget is active.voidThis method is called when a widget is attached to the browser's document.booleanowns(com.google.gwt.dom.client.Element element) Returns true if the element should be logically counted as part of the widget for the purpose of determining whether a mouse click is "outside".voidremoveExceptionsOnChange(com.google.gwt.user.client.Command cmd) voidsetActive(boolean active) Sets the widget active/inactive.voidsetCurrentTillEnd(Boolean isCurrentTillEnd) Set the flag, indicating if the events are displayed as "current" till they end (true) or only till they start (false).voidsetEndTime(Date date) Set the end time.voidsetEndType(String value) Set the duration option.voidsetIsSeries(Boolean isSeries) Toggle between single events and series.voidSets the name of input fields.voidsetOccurrences(String occurrences) Set the occurrences.voidsetPattern(String patternType) Set the serial pattern type.voidsetSeriesEndDate(Date date) Set the serial end date.voidsetStartTime(Date date) Set the start time.voidvoidvoidsetWholeDay(Boolean isWholeDay) Sets the whole day flag.voidvoidupdateExceptions(SortedSet<Date> exceptions) Updates the exceptions.voidMethod called when a status update is triggered.voidMethods inherited from class com.google.gwt.user.client.ui.Composite
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidgetMethods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEventsMethods 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, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEventMethods inherited from interface org.opencms.acacia.client.widgets.I_CmsEditWidget
shouldSetDefaultWhenDisabledMethods inherited from interface com.google.gwt.user.client.ui.IsWidget
asWidget
-
Field Details
-
DEFAULT_DATE_FORMAT
Default date format.- See Also:
-
-
Constructor Details
-
CmsSerialDateController
public CmsSerialDateController()Category field widgets for ADE forms.
-
-
Method Details
-
addFocusHandler
public com.google.gwt.event.shared.HandlerRegistration addFocusHandler(com.google.gwt.event.dom.client.FocusHandler handler) - Specified by:
addFocusHandlerin interfacecom.google.gwt.event.dom.client.HasFocusHandlers- See Also:
-
conditionallyRemoveExceptionsOnChange
public void conditionallyRemoveExceptionsOnChange(com.google.gwt.user.client.Command action, boolean showDialog) - See Also:
-
executeShowDatesAction
Show the dates for managing exceptions. -
getPattern
Returns the controller for the currently active pattern.- Returns:
- the controller for the currently active pattern.
-
getPatternDefaultValues
Returns the default values to set for the patterns dependent on the current start date.- Returns:
- the default values to set for the patterns dependent on the current start date.
-
getPatternView
Returns the widget to place in the pattern panel.- Returns:
- the widget to place in the pattern panel.
-
getValue
-
isActive
Description copied from interface:I_CmsEditWidgetReturns if the widget is active.- Specified by:
isActivein interfaceI_CmsEditWidget- Returns:
trueif the widget is active- See Also:
-
onAttachWidget
Description copied from interface:I_CmsEditWidgetThis method is called when a widget is attached to the browser's document.It needs to call the
Widget.onAttach()method.- Specified by:
onAttachWidgetin interfaceI_CmsEditWidget- See Also:
-
owns
Description copied from interface:I_CmsEditWidgetReturns true if the element should be logically counted as part of the widget for the purpose of determining whether a mouse click is "outside". For example, this is needed if the widget uses a popup.- Specified by:
ownsin interfaceI_CmsEditWidget- Parameters:
element- the element to check- Returns:
- true if the element counts as part of the widget
- See Also:
-
removeExceptionsOnChange
- See Also:
-
setActive
Description copied from interface:I_CmsEditWidgetSets the widget active/inactive.- Specified by:
setActivein interfaceI_CmsEditWidget- Parameters:
active-trueto activate the widget- See Also:
-
setCurrentTillEnd
Set the flag, indicating if the events are displayed as "current" till they end (true) or only till they start (false).- Parameters:
isCurrentTillEnd- the flag, indicating if the events are displayed as "current" till they end (true) or only till they start (false).
-
setEndTime
Set the end time.- Parameters:
date- the end time to set.
-
setEndType
Set the duration option.- Parameters:
value- the duration option to set (I_CmsSerialDateValue.EndTypeas string).
-
setIsSeries
Toggle between single events and series.- Parameters:
isSeries- flag, indicating if we want a series of events.
-
setName
Description copied from interface:I_CmsEditWidgetSets the name of input fields.- Specified by:
setNamein interfaceI_CmsEditWidget- Parameters:
name- of the input field- See Also:
-
setOccurrences
Set the occurrences. If the String is invalid, the occurrences will be set to "-1" to cause server-side validation to fail.- Parameters:
occurrences- the interval to set.
-
setPattern
Set the serial pattern type.- Parameters:
patternType- the pattern type to set.
-
setSeriesEndDate
Set the serial end date.- Parameters:
date- the serial end date.
-
setStartTime
Set the start time.- Parameters:
date- the start time to set.
-
setValue
-
setValue
- Specified by:
setValuein interfacecom.google.gwt.user.client.ui.HasValue<String>- Specified by:
setValuein interfaceI_CmsEditWidget- See Also:
-
setWholeDay
Sets the whole day flag.- Parameters:
isWholeDay- flag, indicating if the event lasts whole days.
-
sizeChanged
- See Also:
-
updateExceptions
Updates the exceptions.- Parameters:
exceptions- the exceptions to set
-
updateStatus
Description copied from interface:I_StatusUpdateHandlerMethod called when a status update is triggered.- Specified by:
updateStatusin interfaceI_StatusUpdateHandler- See Also:
-
valueChanged
- See Also:
-