public class Calendar extends com.googlecode.wicket.jquery.core.JQueryContainer implements ICalendarListener
| Modifier and Type | Field and Description |
|---|---|
protected com.googlecode.wicket.jquery.core.Options |
options |
ENABLE, FLAG_AFTER_RENDERING, FLAG_INITIALIZED, FLAG_PREPARED_FOR_RENDER, FLAG_REMOVING_FROM_HIERARCHY, FLAG_RENDERING, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED8, PARENT_PATH, PATH_SEPARATOR, RENDER, RFLAG_CONTAINER_DEQUEING| Constructor and Description |
|---|
Calendar(String id,
CalendarModel model)
Constructor
|
Calendar(String id,
CalendarModel model,
com.googlecode.wicket.jquery.core.Options options)
Constructor
|
Calendar(String id,
com.googlecode.wicket.jquery.core.Options options)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
addSource(EventSource source)
Adds a
EventSource, can be a EventSource.GoogleCalendar |
CharSequence |
getEventDropPrecondition()
Gets the javascript statement which will be executed before
ICalendarListener.onEventDrop(AjaxRequestTarget, int, long, boolean) event is triggeredA common use case is to call the revertFunc callback to cancel the event. |
CharSequence |
getEventResizePrecondition()
Gets the javascript statement which will be executed before
ICalendarListener.onEventResize(AjaxRequestTarget, int, long) event is triggeredA common use case is to call the revertFunc callback to cancel the event. |
CalendarModel |
getModel()
Gets the calendar's model
|
boolean |
isDayClickEnabled()
Indicates whether a day can be clicked.
If true, the ICalendarListener.onDayClick(AjaxRequestTarget, CalendarView, LocalDateTime, boolean) event will be triggeredNote: true will enable the global 'editable' option to true. |
boolean |
isEventClickEnabled()
Indicates whether an event can be clicked.
If true, the ICalendarListener.onEventClick(AjaxRequestTarget, CalendarView, int) event will be triggeredNote: true will enable the global 'editable' option to true. |
boolean |
isEventDropEnabled()
Indicates whether the event can be dragged & dropped.
|
boolean |
isEventResizeEnabled()
Indicates whether the event can be resized.
|
boolean |
isObjectDropEnabled()
Indicates whether the
ICalendarListener.onObjectDrop(AjaxRequestTarget, String, LocalDateTime, boolean) event will be triggered |
boolean |
isSelectable()
Indicates whether a cell can be selected.
If true, the ICalendarListener.onSelect(AjaxRequestTarget, CalendarView, LocalDateTime, LocalDateTime, boolean) event will be triggered |
boolean |
isViewRenderEnabled()
Indicates whether the
ICalendarListener.onViewRender(AjaxRequestTarget, CalendarView, LocalDateTime, LocalDateTime) event will be triggered |
protected CalendarModelBehavior |
newCalendarModelBehavior(CalendarModel model)
Gets a new
CalendarModelBehavior |
com.googlecode.wicket.jquery.core.JQueryBehavior |
newWidgetBehavior(String selector)
see
IJQueryWidget.newWidgetBehavior(String) |
void |
onConfigure(com.googlecode.wicket.jquery.core.JQueryBehavior behavior) |
void |
onDayClick(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime date,
boolean allDay)
Triggered when a calendar day is clicked
ICalendarListener.isDayClickEnabled() should return true for this event to be triggered. |
void |
onEventClick(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
int eventId)
Triggered when an event is clicked.
ICalendarListener.isEventClickEnabled() should return true for this event to be triggered. |
void |
onEventDrop(org.apache.wicket.ajax.AjaxRequestTarget target,
int eventId,
long delta,
boolean allDay)
Triggered when an event is dropped (after being dragged).
ICalendarListener.isEventDropEnabled() should return true for this event to be triggered. |
void |
onEventResize(org.apache.wicket.ajax.AjaxRequestTarget target,
int eventId,
long delta)
Triggered when an event is dropped (after being dragged).
ICalendarListener.isEventResizeEnabled() should return true for this event to be triggered. |
protected void |
onInitialize() |
void |
onObjectDrop(org.apache.wicket.ajax.AjaxRequestTarget target,
String title,
LocalDateTime date,
boolean allDay)
Triggered when an event-object is dropped.
ICalendarListener.isObjectDropEnabled() should return true for this event to be triggered. |
void |
onSelect(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime start,
LocalDateTime end,
boolean allDay)
Triggered when an cell is selected.
ICalendarListener.isSelectable() should return true for this event to be triggered. |
void |
onViewRender(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime start,
LocalDateTime end)
Triggered when the calendar loads and every time a different date-range is displayed.
ICalendarListener.isViewRenderEnabled() should return true for this event to be triggered. |
void |
refresh(org.apache.wicket.core.request.handler.IPartialPageRequestHandler handler)
Re-fetches and refreshes the events currently available in the selected view.
|
getWebApplication, getWebPage, getWebRequest, getWebResponse, getWebSessionadd, addDequeuedComponent, addOrReplace, autoAdd, canDequeueTag, contains, dequeue, dequeue, dequeuePreamble, findComponentToDequeue, get, getAssociatedMarkup, getAssociatedMarkupStream, getMarkup, getMarkupType, getRegionMarkup, internalAdd, internalInitialize, iterator, iterator, newDequeueContext, onAfterRenderChildren, onComponentTagBody, onDetach, onRender, queue, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderNext, replace, setDefaultModel, size, toString, toString, visitChildren, visitChildrenadd, addStateChange, afterRender, beforeRender, canCallListenerInterface, canCallListenerInterfaceAfterExpiry, checkComponentTag, checkComponentTagAttribute, checkHierarchyChange, clearOriginalDestination, configure, continueToOriginalDestination, debug, detach, detachModel, detachModels, determineVisibility, error, exceptionMessage, fatal, findMarkupStream, findPage, findParent, findParentWithAssociatedMarkup, getAjaxRegionMarkupId, getApplication, getBehaviorById, getBehaviorId, getBehaviors, getBehaviors, getClassRelativePath, getConverter, getDefaultModel, getDefaultModelObject, getDefaultModelObjectAsString, getDefaultModelObjectAsString, getEscapeModelStrings, getFeedbackMessages, getFlag, getId, getInnermostModel, getInnermostModel, getLocale, getLocalizer, getMarkup, getMarkupAttributes, getMarkupId, getMarkupId, getMarkupIdFromMarkup, getMarkupIdImpl, getMarkupSourcingStrategy, getMetaData, getModelComparator, getOutputMarkupId, getOutputMarkupPlaceholderTag, getPage, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getRequestFlag, getResponse, getSession, getSizeInBytes, getStatelessHint, getString, getString, getString, getStyle, getVariation, hasBeenRendered, hasErrorMessage, hasFeedbackMessage, info, initModel, internalOnModelChanged, internalPrepareForRender, internalRenderComponent, internalRenderHead, isActionAuthorized, isAuto, isBehaviorAccepted, isEnableAllowed, isEnabled, isEnabledInHierarchy, isIgnoreAttributeModifier, isInitialized, isRenderAllowed, isRendering, isStateless, isVersioned, isVisibilityAllowed, isVisible, isVisibleInHierarchy, markRendering, modelChanged, modelChanging, newMarkupSourcingStrategy, onAfterRender, onBeforeRender, onComponentTag, onConfigure, onEvent, onModelChanged, onModelChanging, onReAdd, onRemove, prepareForRender, redirectToInterceptPage, remove, remove, render, renderComponentTag, rendered, renderHead, renderHead, renderPlaceholderTag, replaceComponentTagBody, replaceWith, sameInnermostModel, sameInnermostModel, send, setAuto, setDefaultModelObject, setEnabled, setEscapeModelStrings, setFlag, setIgnoreAttributeModifier, setMarkup, setMarkupId, setMarkupIdImpl, setMetaData, setOutputMarkupId, setOutputMarkupPlaceholderTag, setParent, setRenderBodyOnly, setRequestFlag, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisibilityAllowed, setVisible, success, urlFor, urlFor, urlFor, urlForListener, urlForListener, visitParents, visitParents, warn, wrapclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic Calendar(String id, com.googlecode.wicket.jquery.core.Options options)
id - the markup idoptions - the Options. Note that 'selectable' and 'selectHelper' options are set by overriding isSelectable() (default is false)public Calendar(String id, CalendarModel model)
id - the markup idmodel - the CalendarModelpublic Calendar(String id, CalendarModel model, com.googlecode.wicket.jquery.core.Options options)
id - the markup idmodel - the CalendarModeloptions - the Options. Note that 'selectable' and 'selectHelper' options are set by overriding isSelectable() (default is false)public CalendarModel getModel()
CalendarModelpublic void addSource(EventSource source)
EventSource, can be a EventSource.GoogleCalendarsource - the EventSource,public void refresh(org.apache.wicket.core.request.handler.IPartialPageRequestHandler handler)
handler - the IPartialPageRequestHandlerpublic boolean isSelectable()
ICalendarListenerICalendarListener.onSelect(AjaxRequestTarget, CalendarView, LocalDateTime, LocalDateTime, boolean) event will be triggeredisSelectable in interface ICalendarListenerpublic boolean isDayClickEnabled()
ICalendarListenerICalendarListener.onDayClick(AjaxRequestTarget, CalendarView, LocalDateTime, boolean) event will be triggeredtrue will enable the global 'editable' option to true.isDayClickEnabled in interface ICalendarListenerCalendarEvent.setEditable(Boolean)public boolean isEventClickEnabled()
ICalendarListenerICalendarListener.onEventClick(AjaxRequestTarget, CalendarView, int) event will be triggeredtrue will enable the global 'editable' option to true.isEventClickEnabled in interface ICalendarListenerCalendarEvent.setEditable(Boolean)public boolean isEventDropEnabled()
ICalendarListenerICalendarListener.onEventDrop(AjaxRequestTarget, int, long, boolean) event will be triggeredisEventDropEnabled in interface ICalendarListenerpublic boolean isEventResizeEnabled()
ICalendarListenerICalendarListener.onEventResize(AjaxRequestTarget, int, long) event will be triggeredisEventResizeEnabled in interface ICalendarListenerpublic boolean isObjectDropEnabled()
ICalendarListenerICalendarListener.onObjectDrop(AjaxRequestTarget, String, LocalDateTime, boolean) event will be triggeredisObjectDropEnabled in interface ICalendarListenerpublic boolean isViewRenderEnabled()
ICalendarListenerICalendarListener.onViewRender(AjaxRequestTarget, CalendarView, LocalDateTime, LocalDateTime) event will be triggeredisViewRenderEnabled in interface ICalendarListenerpublic CharSequence getEventDropPrecondition()
ICalendarListenerICalendarListener.onEventDrop(AjaxRequestTarget, int, long, boolean) event is triggeredrevertFunc callback to cancel the event.getEventDropPrecondition in interface ICalendarListenerpublic CharSequence getEventResizePrecondition()
ICalendarListenerICalendarListener.onEventResize(AjaxRequestTarget, int, long) event is triggeredrevertFunc callback to cancel the event.getEventResizePrecondition in interface ICalendarListenerprotected void onInitialize()
onInitialize in class com.googlecode.wicket.jquery.core.JQueryContainerpublic void onConfigure(com.googlecode.wicket.jquery.core.JQueryBehavior behavior)
onConfigure in interface com.googlecode.wicket.jquery.core.IJQueryWidgetonConfigure in class com.googlecode.wicket.jquery.core.JQueryContainerpublic void onSelect(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime start,
LocalDateTime end,
boolean allDay)
ICalendarListenerICalendarListener.isSelectable() should return true for this event to be triggered.onSelect in interface ICalendarListenertarget - the AjaxRequestTargetview - the current calendar viewstart - the event start LocalDateTimeend - the event end LocalDateTimeallDay - the event all-day propertypublic void onDayClick(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime date,
boolean allDay)
ICalendarListenerICalendarListener.isDayClickEnabled() should return true for this event to be triggered.onDayClick in interface ICalendarListenertarget - the AjaxRequestTargetview - the current calendar viewdate - the dayallDay - the event all-day propertypublic void onEventClick(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
int eventId)
ICalendarListenerICalendarListener.isEventClickEnabled() should return true for this event to be triggered.onEventClick in interface ICalendarListenertarget - the AjaxRequestTargetview - the current calendar vieweventId - the CalendarEvent idpublic void onEventDrop(org.apache.wicket.ajax.AjaxRequestTarget target,
int eventId,
long delta,
boolean allDay)
ICalendarListenerICalendarListener.isEventDropEnabled() should return true for this event to be triggered.onEventDrop in interface ICalendarListenertarget - the AjaxRequestTargeteventId - the CalendarEvent iddelta - the delta (time) with the original event dateallDay - the event all-day propertypublic void onEventResize(org.apache.wicket.ajax.AjaxRequestTarget target,
int eventId,
long delta)
ICalendarListenerICalendarListener.isEventResizeEnabled() should return true for this event to be triggered.onEventResize in interface ICalendarListenertarget - the AjaxRequestTargeteventId - the CalendarEvent iddelta - the delta (time) with the original event datepublic void onObjectDrop(org.apache.wicket.ajax.AjaxRequestTarget target,
String title,
LocalDateTime date,
boolean allDay)
ICalendarListenerICalendarListener.isObjectDropEnabled() should return true for this event to be triggered.onObjectDrop in interface ICalendarListenertarget - the AjaxRequestTargettitle - the titledate - the dayallDay - the event all-day propertypublic void onViewRender(org.apache.wicket.ajax.AjaxRequestTarget target,
CalendarView view,
LocalDateTime start,
LocalDateTime end)
ICalendarListenerICalendarListener.isViewRenderEnabled() should return true for this event to be triggered.onViewRender in interface ICalendarListenertarget - the AjaxRequestTargetview - the current calendar viewstart - the start LocalDateTime of the current viewend - the event end LocalDateTime of the current viewpublic com.googlecode.wicket.jquery.core.JQueryBehavior newWidgetBehavior(String selector)
IJQueryWidget.newWidgetBehavior(String)newWidgetBehavior in interface com.googlecode.wicket.jquery.core.IJQueryWidgetprotected CalendarModelBehavior newCalendarModelBehavior(CalendarModel model)
CalendarModelBehaviormodel - the CalendarModelCalendarModelBehaviorCopyright © 2016 7thWeb. All rights reserved.