Class Calendar
- All Implemented Interfaces:
HasAttachHandlers
,HasHandlers
,EventListener
,HasVisibility
,IsWidget
,LogicalStructure
,HasBackgroundClickHandlers
,HasBackgroundMouseDownHandlers
,HasBackgroundMouseUpHandlers
,HasCurrentViewChangedHandlers
,HasDateChangedHandlers
,HasDayBodyClickHandlers
,HasDayHeaderClickHandlers
,HasEventAddedHandlers
,HasEventChangedHandlers
,HasEventClickHandlers
,HasEventRemoveClickHandlers
,HasEventRemovedHandlers
,HasEventRepositionMoveHandlers
,HasEventRepositionStopHandlers
,HasEventResizeMoveHandlers
,HasEventResizeStopHandlers
,HasEventSaveErrorHandlers
,HasEventsRenderedHandlers
,HasIndicatorClickHandlers
,HasZoneClickHandlers
,DataBoundComponent
,HasClearHandlers
,HasClickHandlers
,HasDoubleClickHandlers
,HasDragCompleteHandlers
,HasDragMoveHandlers
,HasDragRepositionMoveHandlers
,HasDragRepositionStartHandlers
,HasDragRepositionStopHandlers
,HasDragResizeMoveHandlers
,HasDragResizeStartHandlers
,HasDragResizeStopHandlers
,HasDragStartHandlers
,HasDragStopHandlers
,HasDropCompleteHandlers
,HasDropHandlers
,HasDropMoveHandlers
,HasDropOutHandlers
,HasDropOverHandlers
,HasFetchDataHandlers
,HasFocusChangedHandlers
,HasHoverHandlers
,HasHoverHiddenHandlers
,HasKeyDownHandlers
,HasKeyPressHandlers
,HasMouseDownHandlers
,HasMouseMoveHandlers
,HasMouseOutHandlers
,HasMouseOverHandlers
,HasMouseStillDownHandlers
,HasMouseUpHandlers
,HasMouseWheelHandlers
,HasMovedHandlers
,HasParentMovedHandlers
,HasResizedHandlers
,HasRightMouseDownHandlers
,HasRuleContextChangedHandlers
,HasScrolledHandlers
,HasShowContextMenuHandlers
,HasVisibilityChangedHandlers
- Direct Known Subclasses:
Timeline
CalendarEvents
Events are
represented as ordinary JavaScript Objects (see CalendarEvent
). The
Calendar expects to be able to read and write a basic set of properties on events: name, startDate, endDate,
description, etc, which can be stored under configurable property names (see eg startDateField
).
Much like a ListGrid
manages it's ListGridRecords, the Calendar can either be passed an ordinary
Array of CalendarEvents or can fetch data from a DataSource. When this is the case, if the DataSource does not
contain fields with the configured property names, an attempt is made to auto-detect likely-looking fields from those
that are present. To see logs indicating that this has happened, switch default logging preferences to INFO level in
the Developer Console.
If the calendar is bound to a DataSource, event changes by user action or by calling methods will be saved to the DataSource.
Navigation
The calendar supports a number of views by default: day
, week
, month
and timeline
. The user can navigate using back and forward
buttons or via an attached DateChooser
.
Event Manipulation
Events can be created by clicking directly onto one of the views, or via the Add Event
button. In the day, week and timeline views,
the user may click and drag to create an event of a specific duration.
Creating an event via click or click and
drag pops up the EventDialog
, which provides a
simple form for quick event entry (for normal events, only the description is required by default - for events that
are shown in a lane
, that field is also required).
A
separate editor called the EventEditor
provides an
interface for editing all possible properties of an event, including custom properties. The EventEditor is used
whenever a pre-existing event is being edited, and can also be invoked by the user wherever the simpler EventDialog
appears.
Events can also be programmatically added
, removed
, or updated
.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
-
Field Summary
Fields inherited from class com.smartgwt.client.widgets.BaseWidget
config, configOnly, factoryCreated, factoryProperties, id, nativeObject, scClassName
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionAdd a backgroundClick handler.Add a backgroundMouseDown handler.Add a backgroundMouseUp handler.void
addCalendarEvent
(CalendarEvent event) Create a new event in this calendar.void
addCalendarEvent
(CalendarEvent event, Map customValues) Create a new event in this calendar.Add a currentViewChanged handler.addDateChangedHandler
(DateChangedHandler handler) Add a dateChanged handler.Add a dayBodyClick handler.Add a dayHeaderClick handler.Add acom.smartgwt.client.widgets.DragCompleteHandler
.Add acom.smartgwt.client.widgets.DropCompleteHandler
.void
Create a new event in this calendar instance.void
Create a new event in this calendar instance.addEventAddedHandler
(EventAddedHandler handler) Add a eventAdded handler.Add a eventChanged handler.addEventClickHandler
(EventClickHandler handler) Add a eventClick handler.Add a eventRemoveClick handler.Add a eventRemoved handler.Add a eventRepositionMove handler.Add a eventRepositionStop handler.Add a eventResizeMove handler.Add a eventResizeStop handler.Add a eventSaveError handler.Add a eventsRendered handler.addFetchDataHandler
(FetchDataHandler handler) Add a fetchData handler.void
Convenience method to display a {@link com.smartgwt.client..FormulaBuilder} to create a new Formula Field.void
addIndicator
(CalendarEvent indicator) Adds a newindicator
to the calendar.Add a indicatorClick handler.void
Adds a newLane
to the calendar, for display in thetimeline view
, and in theday view
ifshowDayLanes
is true.void
addLaneEvent
(Lane laneName, Date startDate) Deprecated.void
addLaneEvent
(Lane laneName, Date startDate, Date endDate) void
addLaneEvent
(Lane laneName, Date startDate, Date endDate, String name) void
void
addLaneEvent
(Lane laneName, Date startDate, Date endDate, String name, String description, Object otherFields) Deprecated.in favor ofaddCalendarEvent()
void
Convenience method to display a {@link com.smartgwt.client..SummaryBuilder} to create a new Summary Field.void
addZone
(CalendarEvent zone) Adds a newzone
to the calendar.addZoneClickHandler
(ZoneClickHandler handler) Add a zoneClick handler.Whether at least one item is selected
static boolean
Static method indicating whether the optional Calendar module is loaded for the page.void
Cancels the current edit-session, closing the builtin eventdialog
oreditor
and clearing any visible edit-selection from thecurrent CalendarView
.static void
changeAutoChildDefaults
(String autoChildName, Canvas defaults) Changes the defaults for Canvas AutoChildren namedautoChildName
.static void
changeAutoChildDefaults
(String autoChildName, FormItem defaults) Changes the defaults for FormItem AutoChildren namedautoChildName
.protected JavaScriptObject
create()
Called fromEventCanvas.setEvent()
whenshowEventCanvasComponents
is true and an eventCanvas needs a component.boolean
dateIsWorkday
(Date date) boolean
dateIsWorkday
(Date date, String laneName) Should the parameter date be considered a workday? By default this method tries to find the parameter date day inworkdays
, and returns true if found.void

 Deselect all records

deselectEvent
(CalendarEvent event) Removes an event from the list of selected events in the current view, clearing its selected style.deselectEvents
(CalendarEvent... events) Removes one or more events from the list of selected events in the current view, clearing their selected styles.void
deselectRecord
(int record) Deselect aRecord
passed in explicitly, or by index.void
deselectRecord
(Record record) Deselect aRecord
passed in explicitly, or by index.void
deselectRecords
(int[] records) Deselect a list ofRecord
s passed in explicitly, or by index.void
deselectRecords
(Record[] records) Deselect a list ofRecord
s passed in explicitly, or by index.void
disableHilite
(String hiliteID) Disable a hilite

void
Disable all hilites.

void
Shows a FieldPicker interface allowing end-users to rearrange the order and visibiility of the fields in the associated DataBoundComponent.void
Shows a HiliteEditor interface allowing end-users to edit the data-hilites currently in use by this DataBoundComponent.void
enableHilite
(String hiliteID) Enable / disable ahilites


void
enableHilite
(String hiliteID, boolean enable) Enable / disable ahilites


void
Enable all hilites.

void
enableHiliting
(boolean enable) Enable all hilites.

boolean
eventMoved
(Date newDate, CalendarEvent event, String newLane) Deprecated.in favor ofCalendar.eventRepositionStop()
Notification fired when a user drags an EventCanvas.boolean
eventResized
(Date newDate, CalendarEvent event) Deprecated.in favor ofCalendar.eventResizeStop()
void
void
exportData
(DSRequest requestProperties) void
exportData
(DSRequest requestProperties, RPCCallback callback) Uses a "fetch" operation on the currentDataSource
to retrieve data that matches the current filter and sort criteria for this component, then exports the resulting data to a file or window in the requested format.void
Retrieves data from the DataSource that matches the specified criteria.void
Retrieves data from the DataSource that matches the specified criteria.void
fetchData
(Criteria criteria, DSCallback callback) Retrieves data from the DataSource that matches the specified criteria.void
fetchData
(Criteria criteria, DSCallback callback, DSRequest requestProperties) Retrieves data from the DataSource that matches the specified criteria.void
Retrieves data that matches the provided criteria and displays the matching data in this component.void
filterData
(Criteria criteria) Retrieves data that matches the provided criteria and displays the matching data in this component.void
filterData
(Criteria criteria, DSCallback callback) Retrieves data that matches the provided criteria and displays the matching data in this component.void
filterData
(Criteria criteria, DSCallback callback, DSRequest requestProperties) Retrieves data that matches the provided criteria and displays the matching data in this component.find
(AdvancedCriteria adCriteria) Filters all objects according to the AdvancedCriteria passed and returns the first matching object or null if not foundRecord[]
findAll
(AdvancedCriteria adCriteria) Filters all objects according to the AdvancedCriteria passedint
findIndex
(AdvancedCriteria adCriteria) Finds the index of the first Record that matches with the AdvacendCriteria passed.int
findNextIndex
(int startIndex, AdvancedCriteria adCriteria) LikeRecordList.findIndex(java.util.Map)
, but considering the startIndex parameter.int
findNextIndex
(int startIndex, AdvancedCriteria adCriteria, int endIndex) LikeRecordList.findIndex(java.util.Map)
, but considering the startIndex and endIndex parameters.Gets the day of the week (0-6) that the mouse is currently over.Gets a date object representing the date over which the mouse is hovering for the current selected view.Indicates whether to add "drop values" to items dropped on this component, if both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key.The text to be displayed when a user hovers over theadd event
toolbar buttonText for a menu item allowing users to add a formula fieldoperationId
this component should use when performing add operations.Text for a menu item allowing users to add a formula fieldWhen set to true, allows events to be managed by duration, as well as by end date.When showing aTimeline
, or aday view
whenshowDayLanes
is true, whether to make lane boundaries more obvious by showing alternate lanes in a different color.By default, EventCanvases show their content in hovers.IfDataBoundComponent.setAutoFetchData(Boolean)
is true, this attribute determines whether the initial fetch operation should be performed viaDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
If true, when this component is first drawn, automatically callDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
depending onDataBoundComponent.getAutoFetchAsFilter()
.IfautoFetchData
istrue
, this attribute allows the developer to specify a textMatchStyle for the initialDataBoundComponent.fetchData()
call.The icon to show in themonth-button
on Handsets when themonth view
is the current visible view.The title of themonth
on Handsets when themonth view
is the current visible view.The base name for the CSS class applied to the grid cells of the day and week views of the calendar.If set to true, clicking an event will bring it to the front of the zorder.The base name for the CSS class applied to the links rendered bygetDayBodyHTML()
.Adds an item to the header context menu allowing users to launch a dialog to define a new
 field based on values present in other fields, using the {@link com.smartgwt.client..FormulaBuilder}.
Adds an item to the header context menu allowing users to launch a dialog to define a new
 text field that can contain both user-defined text and the formatted values present in other 
 fields, using the {@link com.smartgwt.client..SummaryBuilder}.
Ancom.smartgwt.client.types.AutoChild
of typeIButton
, used to cancel editing of an event and close theeventEditor
.The title for theCancel button
in theevent editor
.If true, users can create new events.WhenshowOtherDays
is true, determines whether clicking in a Month-view body-cell that represents a date outside the selected month will open theevent-editor window
at the cell's location.Deprecated.in favor ofcanRemoveEvents
A boolean value controlling whether new events of varying length can be created by dragging the cursor.Name of the field on eachCalendarEvent
that determines whether anEventCanvas
can be moved or resized by dragging with the mouse.A boolean value controlling whether users can drag-reposition events.If true, users can edit existing events.Name of the field on eachCalendarEvent
that determines whether it can be edited in theevent editor
.Can events be moved between lanes? If so, the event can be dragged to a differentlane
, and the eventquick dialog
andeditor
allow a lane to be selected with a drop-down chooser.Name of the field on eachCalendarEvent
that determines whether that event can be moved between lanes.Can events be moved between sublanes?Name of the field on eachCalendarEvent
that determines whether that event can be moved between individualsublanes
in aLane
.If true, allows the lanes in a Timeline to be grouped by providing a value forlaneGroupByField
.If true, users can remove existing events.Name of the field on eachCalendarEvent
that determines whether an event shows a remove button.If true, lanes can be reordered by dragging theirlaneFields
with the mouse.Name of the field on eachCalendarEvent
that determines whether an event can be resized by dragging.Canevents
be resized by dragging appropriate edges of thecanvas
? Only has an effect when bothcanEditEvents
andcanDragEvents
are true.Deprecated.in favor ofcanResizeEvents
;When set to true, makes individualevent canvases
selectable.Return the Date instance associated with the passed co-ordinates in the passed or selected view.getCellDate
(Integer rowNum) getCellDate
(Integer rowNum, Integer colNum) getCellDate
(Integer rowNum, Integer colNum, CalendarView view) Return the Date instance associated with the passed co-ordinates in the passed or selected view.getCellHoverHTML
(CalendarView view, Record record, Integer rowNum, Integer colNum, Date date, String defaultValue) Returns the hover HTML for the cell at the passed co-ordinates in the passed view.The date for which events are displayed in the day, week, and month tabs of the calendar.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.When using the Next and Previous arrows to scroll a Timeline, this is the number of columns of thetimelineGranularity
to scroll by.A CSS style to apply to icons in thecontrolsBar
.The size of the various icons displayed in thecontrolsBar
of this Calendar.AnHLayout
shown above the Calendar views and displaying a set of controls for interacting with the current view - namely, thenext
,previous
andadd
buttons, thedate label
and thedate-picker
icon.Default height of thecontrolsBar
shown above the main Calendar grid.The name of the view that should be visible initially by default.getData()
A List of CalendarEvent objects, specifying the data to be used to populate the calendar.How to fetch and manage records retrieve from the server.int
When usingdata paging
, how many records to fetch at a time.The DataSource that this component should bind to for default fields and for performingDataSource requests
.getDateCellAlign
(Date date, Integer rowNum, Integer colNum, CalendarView view) WhengetDateHTML
returns a value, this method returns the horizontal alignment for that value in its cell, in the passed view.getDateCellVAlign
(Date date, Integer rowNum, Integer colNum, CalendarView view) WhengetDateHTML
returns a value, this method returns the vertical alignment for that value in its cell, in the passed view.DateChooser
used to select the date for which events will be displayed.getDateCSSText
(Date date, Integer rowNum, Integer colNum, CalendarView view) Return CSS text for styling the cell associated with the passed date and/or rowNum & colNum, which will be applied in addition to the CSS class for the cell, as overrides.Indicates the type of controls to use in event-windows.Date formatter for displaying events.Returns a Date instance representing the point at the passed offsets into the body of the current view.getDateFromPoint
(Integer x, Integer y) getDateFromPoint
(Integer x, Integer y, Boolean snapOffsets) getDateFromPoint
(Integer x, Integer y, Boolean snapOffsets, CalendarView view) Returns a Date instance representing the point at the passed offsets into the body of the current view.getDateHeaderTitle
(Date date, int dayOfWeek, String defaultValue, CalendarView view) Return the title text to display in the header-button of the ListGridField showing the passed date, in the passed view.getDateHTML
(Date date, Integer rowNum, Integer colNum, CalendarView view) Return the HTML to be displayed in the associated date-cell in the passed view.Thecom.smartgwt.client.types.AutoChild
Label
used to display the current date or range above the selected calendar view.getDateLabelText
(String viewName, Date startDate, Date endDate) Returns the text to display with the navigation buttons above the Calendar - indicates the visible date range.AnImgButton
that appears above the various views of the calendar and offers alternative access to aDateChooser
to pick the current day.The text to be displayed when a user hovers over thedate picker
toolbar buttongetDateStyle
(Date date, Integer rowNum, Integer colNum, CalendarView view) Return the CSS styleName for the associated date-cell in the passed view.The base name for the CSS class applied to the day body of the month view of the calendar.protected String
getDayBodyHTML
(Date date, CalendarEvent[] events, Calendar calendar, int rowNum, int colNum) Return the HTML to be shown in the body of a day in the month view.The base name for the CSS class applied to the day headers of the month view.CalendarView
used to display events that pertain to a given day.The title for theday view
.Before we start editing values in this DataBoundComponent, should we perform a deep clone of the underlying values.int
The number of columns of thetimelineGranularity
to give the timeline by default if noendDate
is provided.The name of the description field on aCalendarEvent
.The title for the edit button in the quickquick event dialog
.If true, weekend days appear in a disabled style and events cannot be created on weekends.Record[]
During a drag-and-drop interaction, this method returns the set of records being dragged out of the component.Indicates what to do with data dragged into another DataBoundComponent.getDragHoverHTML
(CalendarView view, CalendarEvent event, String defaultValue) Returns the HTML to show in a hover when an existing event is dragged, or when a new event is being created by dragging with the mouse.CSS Style to apply to the drag tracker when dragging occurs on this component.When an item is dropped on this component, andaddDropValues
is true and both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key, this object provides the "drop values" that Smart GWT will apply to the dropped object before updating it.Message to show when a user attempts to transfer duplicate records into this component, and
preventDuplicates
is enabled.The name of theduration
field on aCalendarEvent
.The name of thedurationUnit
field on aCalendarEvent
.Text for a menu item allowing users to edit a formula fieldText for a menu item allowing users to edit the formatter for a fieldThe end date of the calendar timeline view.The name of the end date field on aCalendarEvent
.If set to true, enables the auto-arrangement of events that share time in the calendar.getEventBodyHTML
(CalendarEvent event) Returns the description text for the passed event, for display in the body area of an event canvas.getEventBodyHTML
(CalendarEvent event, CalendarView view) Returns the description text for the passed event, for display in the body area of an event canvas.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.The close button that snaps to the top-right of an event canvas on rollover and allows an event to be removed from aCalendarView
.The size of theclose-button
that snaps to the top-right of an event canvas on rollover and shows allows an event to be removed from aCalendarView
.The size of the icon in theclose-button
floated over events on rollover.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.The context button that snaps to the top-right of an event canvas on rollover and shows a customcontext menu
when clicked.Context menu displayed when anevent canvas
is right-clicked, or when the rollovercontext button
is clicked.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.getEventCanvasStyle
(CalendarEvent event) getEventCanvasStyle
(CalendarEvent event, CalendarView view) Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.Ancom.smartgwt.client.types.AutoChild
of typeWindow
that displays a quick event entry form in a popup window.The number of pixels to leave to the right of events so overlapping events can still be added using the mouse.Ancom.smartgwt.client.types.AutoChild
of typeHLayout
which houses theSave
,Remove
andCancel
buttons in theeventEditor
.Object[]
The list of buttons to include in theeventEditor
.The title for the Date-field in theeventEditor
that allows for changing the logical start-date of an event, along with its start and end times, when editing events in theday
andweek
views.getEventEndDate
(CalendarEvent event) Returns theend date
of the passed event.int
WheneventHeaderWrap
is false andshowEventDescriptions
is true, this is the fixed height for theheader area
in event canvases.getEventHeaderHTML
(CalendarEvent event) Returns the title text for the passed event, which is displayed in the header area of an eventCanvas rendered in a vertical or horizontal view, or as a clickable link in a cell in aMonth view
.getEventHeaderHTML
(CalendarEvent event, CalendarView view) Returns the title text for the passed event, which is displayed in the header area of an eventCanvas rendered in a vertical or horizontal view, or as a clickable link in a cell in aMonth view
.boolean
When rendering thecanvas
for an event, whether to allow the content of theheader area
to wrap to multiple lines.getEventHoverHTML
(CalendarEvent event, EventCanvas eventCanvas, CalendarView view) Gets the hover HTML for an event being hovered over.getEventHoverHTML
(CalendarEvent event, EventCanvas eventCanvas, CalendarView view, String defaultValue) Gets the hover HTML for an event being hovered over.getEventLane
(CalendarEvent event) Returns thelane
associated with the passed event, in the passed viewgetEventLane
(CalendarEvent event, CalendarView view) Returns thelane
associated with the passed event, in the passed viewvoid
getEventLength
(CalendarEvent event) void
getEventLength
(CalendarEvent event, TimeUnit unit) WheneventAutoArrange
is true, setting eventOverlap to true causes events that share timeslots to overlap each other by a percentage of their width, specified byeventOverlapPercent
.When set to true, events that start at the same time will not overlap each other to prevent events having their close button hidden.int
The size of the overlap, presented as a percentage of the width of events sharing timeslots.Screen to create (viacreateScreen()
) in lieu of callingcreateEventCanvasComponent()
.The number of minutes that determines the positions to which events will snap when rendered, and when moved or resized with the mouse.getEventStartDate
(CalendarEvent event) Returns thestart date
of the passed event.The base name for the CSS class applied toevents
when they're rendered in calendar views.The name of the field used to overrideeventStyleName
for an individualCalendarEvent.styleName
.getEventSublane
(CalendarEvent event) Returns thesublane
associated with the passed event, in the passed viewgetEventSublane
(CalendarEvent event, CalendarView view) Returns thesublane
associated with the passed event, in the passed viewDeprecated.in favor ofeventStyleName
Deprecated.in favor ofeventStyleNameField
Setting exportAll to true prevents the component from passing its list of fields to the 
 export call.String[]
The list of field-names to export.If Summary rows exist for this component, whether to include them when exporting client data.Operation ID this component should use when performing fetch operations.Returna an array of field alignments for this gridint
Return the number of fields.Return the fields as JavaScriptObjects rather than as SmartGWT Java wrappers of the field class type (e.g.The numeric day (0-6, Sunday-Saturday) which the calendar should consider as the first day of the week in multi-day views, and in the popupDateChooser
.getHeaderHoverHTML
(CalendarView view, HeaderLevel headerLevel, Date startDate, Date endDate, String defaultValue) Returns the hover HTML to show in a hover when the mouse moves over the header area.Configures the levels ofheaders
shown above the event area, and their time units.When set to true, hides anylane
that doesn't have any active events in the current dataset.Marker that can be set on a record to flag that record as hilited.Hilite[]
Return the set of hilite-objects currently applied to this DataBoundComponent.Get the current hilites encoded as a String, for saving.Criteria that are never shown to or edited by the user and are cumulative with any criteria provided viaDataBoundComponent.initialCriteria
,DataBoundComponent.setCriteria()
etc.When set to true, the default, the fetches issued by navigating around in the various views are limited to the accessible date-range in the current view - as you change the current date-range, a fetch is only issued if the new range is not entirely within the previous range.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.getIndicatorCanvasStyle
(CalendarEvent indicator) getIndicatorCanvasStyle
(CalendarEvent indicator, CalendarView view) getIndicatorHoverHTML
(CalendarEvent indicator, IndicatorCanvas indicatorCanvas, CalendarView view, String defaultValue) Gets the hover HTML for anindicator
being hovered over.An array of CalendarEvent instances representing instants in time, to be highlighted intimeline views
.Criteria to use whenDataBoundComponent.setAutoFetchData(Boolean)
is used.The message to display in theeventEditor
when the 'To' date is greater than the 'From' date and a save is attempted.Returns thelane
with the passed name, in the passed viewgetLane
(String lane, CalendarView view) Returns thelane
with the passed name, in the passed viewgetLaneEvents
(Lane lane) For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.getLaneEvents
(Lane lane, CalendarView view) For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.getLaneEvents
(String lane) For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.Field definitions for the frozen area of thetimelineView
, which shows data about the timelinelanes
.Returns theLane
at the passed co-ordinates.getLaneFromPoint
(Integer x, Integer y) getLaneFromPoint
(Integer x, Integer y, CalendarView view) Returns theLane
at the passed co-ordinates.For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.String[]
Deprecated.in favor ofgetLaneGroupByFieldAsStringArray()
.String[]
For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.The name of the field which will determine thelane
in which a given event will be displayed inTimeline
s and in theday view
, ifshowDayLanes
is true.For views that supportlanes
, returns the padding to apply to events rendered in lanes in the passed or current view.getLanePadding
(CalendarView view) For views that supportlanes
, returns the padding to apply to events rendered in lanes in the passed or current view.Lane[]
getLanes()
An array ofLane
definitions that represent the rows of thetimelineView
, or the columns of thedayView
ifshowDayLanes
is true.The name of the leading date field for each event.WhenshowWorkday
is true, this attribute prevents the user from scrolling vertical views beyond the specified workdaystart
andend
hours.Getter implementing theLogicalStructure
interface, which supports Eclipse's logical structure debugging facility.boolean
A boolean value controlling whether the Calendar shows tabs for available calendar views.In themonth view
whenshowDayHeaders
is true, this is the minimum height applied to a day cell and its header combined.When showingvertical lanes
in thedayView
, this attribute sets the minimum width of each column or field.int
The minimum height of time-rows in vertical calendar views.ANavigationButton
that appears to the left of other navigation controls in thecontrols bar
on Handset devices.The icon to show next to the month-name in themonth button
, used for showing and hiding themonth view
on Handsets.The title of themonth button
, used for showing and hiding themonth view
on Handsets.The title of the link shown in a cell of amonth view
when there are too many events to be displayed at once.AutoChild Menu, shown when a user clicks themore events
link in a cell of themonthView
.CalendarView
used to display events that pertain to a given month.getMonthViewHoverHTML
(Date date, CalendarEvent... events) This method returns the hover HTML to be displayed when the user hovers over a cell displayed in the calendar month view tab.The title for themonth view
.The name of the name field on aCalendarEvent
.The title-text displayed in the popup event dialog/editor for new events.AnImgButton
that appears above the week/day/month views of the calendar and allows the user to move the calendar forwards in time.The text to be displayed when a user hovers over thenext
toolbar buttonstatic Calendar
getOrCreateRef
(JavaScriptObject jsObj) The CSS style applied to both the header and body of days from other months in themonth view
, whenshowOtherDays
is false.The base name for the CSS class applied to the day body of the month view of the calendar.WhenshowOtherDays
is true, this attribute determines whether the month-view should change month when cells representing days in the previous or following month are clicked.The base name for the CSS class applied to the day headers of the month view.A set ofsort-specifiers
for customizing the render order of events that overlap.Returns the end of the period selected in the passed, or current, calendar view.getPeriodEndDate
(CalendarView view) Returns the end of the period selected in the passed, or current, calendar view.Returns the start of the selected week or month depending on the current calendar view.Returns the start of the selected week or month depending on the current calendar view.If set, detect and prevent duplicate records from being transferred to this component, either via
 drag and drop or viaDataBoundComponent.transferSelectedData(com.smartgwt.client.widgets.DataBoundComponent)
.AnImgButton
that appears above the week/day/month views of the calendar and allows the user to move the calendar backwards in time.The text to be displayed when a user hovers over theprevious
toolbar button.Indicates whether or not this component will load its dataprogressively
int
getRecordIndex
(Record record) Get the index of the provided record.
Return the underlying data of this DataBoundComponent as aRecordList
.Ancom.smartgwt.client.types.AutoChild
of typeIButton
, used to permanently remove an event from theeventEditor
.The title for theRemove button
in theevent editor
.operationId
this component should use when performing remove operations.boolean
When set to true, the default, eachevent
is rendered as it appears in the viewport.Return the underlying data of this DataBoundComponent as aResultSet
.int
The height of time-slots in the calendar.Optional identifier for saved searches that should be applied to this component.If set, andshowWorkday
is true, automatically scrolls theday
andweek
views to the start of theworkday
when the calendar is first displayed and whenever the user changes to a different day or week.When true, shows the currentchosenDate
in a selected style in themonth view
.The base name for the CSS class applied to a cell that is selected via a mouse drag.Returns the currently selectedevent
, or the first one if more than one is selected.Returns the currently selected list ofevents
.Returns the currently selectedview
.Set to false to hide theAdd Event
button.WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over the normal cells in the body of CalendarViews.When true, causeslayouts
to be added to each column in vertical views.Whether to show fields of non-atomic types when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.
If false the controls bar at the top of the calendar will not be displayed - this means that thecontrolsBar
will be hidden, so the autoChildren (previousButton
,dateLabel
,nextButton
,addEventButton
, anddatePickerButton
) will not be created or shown.Determines whether thedateChooser
is displayed.Set to false to hide thedatePickerButton
that allows selecting a new base date for this Calendar.If true, the default, show a header cell for each day cell in themonth view
, with both cells having a minimum combined height ofminimumDayHeight
.Whether to show the Day view.Whether to show fields markeddetail:true
when a DataBoundComponent is given a DataSource but nocomponent.fields
.WhenshowViewHovers
is true, dictates whether to display hover prompts when an event is being dragged with the mouse.boolean
Whetherevent-canvases
should show a custom widget as content, rather than the defaultheader
andbody
HTML.boolean
When rendering thecanvas
for an event, whether to show thebody area
, typically containing brief details of the event -by default
,its description
.boolean
When rendering thecanvas
for an event, whether to show theheader area
, typically containing suitable title text -by default
, the event'sname
.WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over anevent canvas
in a calendarView.WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over theheader levels
in aCalendarView
.Whether to show fields markedhidden:true
when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.
Set to true to render any definedindicators
intotimeline views
.boolean
Inindicator lines
are showing, this attribute affects where in the z-order their canvases will be rendered: either in front of, or behind normal calendar events.boolean
When set to false, hides the frozen Label-Column in verticalCalendarView
s.WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over the cells in alaneField
.When set to true, causesTimelines
to highlight the Lane under the mouse with the "Over" style.Set to false to prevent theMonth
button from displaying on Handset devices.Whether to show the Month view.Set to false to hide theNext
button.If set to true, in themonth view
, days that fall in an adjacent month are still shown with a header and body area, and are interactive.Set to false to hide thePrevious
button.Determines whether the quick event dialog is displayed when a time is clicked.boolean
Whether to associate saved searches by default with the currentDataSource
of a component when asavedSearchId
is not provided.If set to true, show theTimeline view
.When set to true, the default value, causes the Calendar to show customizable hovers when the mouse moves over various areas of a CalendarView.Whether to show the Week view.When set to true, this setting enables various features related to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
) in vertical calendar views (day
andweek
).WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over azone
in a calendarView.Set to true to render any definedzones
intotimeline views
.If true, events will be sized to the grid, even if they start and/or end at times between grid cells.WhenshowWorkday
is true, attempt to resize rows in the day and week views so that theworkday hours
fill the visible viewport-height, and the whole workday is visible without scrolling.getSort()
Returns the currentSortSpecifiers
for this component.If true,ListGrid.getFieldState()
andListGrid.setFieldState(java.lang.String)
will omit state information for hidden fields by default.The start date of the calendartimeline view
.The name of the start date field on aCalendarEvent
.WhenshowWorkday
is true, applies theworkdayBaseStyle
to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
), in both thedayView
andweekView
.getSublane
(String lane, String sublane) getSublane
(String lane, String sublane, CalendarView view) getSublaneEvents
(Lane lane, Lane sublane) getSublaneEvents
(Lane lane, Lane sublane, CalendarView view) Returns thesublane
at the passed co-ordinates.getSublaneFromPoint
(Integer x, Integer y, CalendarView view) Returns thesublane
at the passed co-ordinates.The name of the field which will determine thesublane
in which this event will be displayed, within its parent Lane, inTimeline
s and in theday view
, ifshowDayLanes
is true.Display format to use for the time portion of events' date information.The granularity in which thetimelineView
will display events.int
How many units oftimelineGranularity
each cell represents.CalendarView
used to display events in lanes in a horizontalTimeline
view.The title for thetimeline view
.Method to return the fieldName which represents the "title" for records in this
 Component.

 If this.titleField is explicitly specified it will always be used.
 Otherwise, default implementation will checktitleField
for databound
 components.

 For non databound components returns the first defined field name of"title"
, 
"name"
, or"id"
.getTitleFieldValue
(Record record) Get the value of the titleField for the passed record
The background color for cells that represent today in allCalendarView
s.The name of the trailing date field for each event.Dictates whether times throughout the widget are formatted and edited as 24-hour values.operationId
this component should use when performing update operations.If true, the set of fields given by the "default binding" (see 
fields
) is used, with any fields specified in
component.fields
acting as overrides that can suppress or modify the
 display of individual fields, without having to list the entire set of fields that
 should be shown.
boolean
By default, theclose buttons
and thehorizontal
andvertical
resizer widgets for event canvases are shown only when the mouse is over a given event.TheuseFlatFields
flag causes all simple type fields anywhere in a nested
 set of DataSources to be exposed as a flat list for form binding.Returns the last visible date in the passed, or currently selected, calendar view.Returns the last visible date in the passed, or currently selected, calendar view.Returns the first visible date in the passed, or currently selected, calendar view.Returns the first visible date in the passed, or currently selected, calendar view.int[]
An array of integer day-numbers that should be considered to be weekend days by this Calendar instance.Augments the width of week event windows slightly to avoid duplicate adjacent borders between events.The text to appear before the week number in the title ofweek-based
HeaderLevel
s when this calendar is showing a timeline.CalendarView
used to display events that pertain to a given week.The title for theweek view
.IfshowWorkday
is set, this is the style used for cells that are within the workday, as defined byworkdayStart
andworkdayEnd
, or by a date-specific range provided ingetWorkdayStart()
andgetWorkdayEnd()
implementations.getWorkdayEnd
(Date date) getWorkdayEnd
(Date date, String laneName) When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.getWorkdayStart
(Date date) getWorkdayStart
(Date date, String laneName) When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists.getZoneCanvasStyle
(CalendarEvent zone, CalendarView view) getZoneHoverHTML
(CalendarEvent zone, ZoneCanvas zoneCanvas, CalendarView view, String defaultValue) Gets the hover HTML for azone
being hovered over.getZones()
An array of CalendarEvent instances representing pre-defined periods of time to be highlighted intimeline views
.The vertical alignment of the header-text in eachzone
.void
groupLanesBy
(String groupFieldName) WhencanGroupLanes
is true, this method allows the grouping intimeline
s to be altered at runtime.void
groupLanesBy
(String... groupFieldName) WhencanGroupLanes
is true, this method allows the grouping intimeline
s to be altered at runtime.void
Invalidate the current data cache for this databound component via a call to the dataset'sinvalidateCache()
method, for example,ResultSet.invalidateCache()
.void
moveToEvent
(CalendarEvent event) Deprecated.in favor ofscrollToEvent()
.void
next()
Move to the next day, week, or month, depending on which tab is selected.protected void
onInit()
protected void
void
previous()
Move to the previous day, week, month, or timeline range depending on which tab is selected.void
refreshEvent
(CalendarEvent event) Refreshes the passed event in the current view.void
removeEvent
(CalendarEvent event) Remove an event from this calendar.void
removeIndicator
(CalendarEvent indicator) Removes aindicator
from the calendar.void
removeIndicator
(String indicator) Removes aindicator
from the calendar.void
removeLane
(Lane lane) Removes a lane from the calendar intimelineView
mode.void
removeLane
(String laneName) Removes a lane from the calendar intimelineView
mode.void
removeZone
(CalendarEvent zone) Removes azone
from the calendar.void
removeZone
(String zone) Removes azone
from the calendar.void
Move the viewport of a CalendarView to the end of its scrollable range.void
scrollToEnd
(CalendarView view) Move the viewport of a CalendarView to the end of its scrollable range.void
scrollToEvent
(CalendarEvent event) Scrolls thecurrent view
so the passed event is visible.void
scrollToEvent
(CalendarEvent event, boolean canReload) Scrolls thecurrent view
so the passed event is visible.void
Move the viewport of a CalendarView to the start of it's scrollable range.void
scrollToStart
(CalendarView view) Move the viewport of a CalendarView to the start of it's scrollable range.void
scrollToTime
(String time) void
Select all records

selectEvent
(CalendarEvent event) Adds an event to the list of selected events in the current view, showing it in a selected style.selectEvents
(CalendarEvent... events) Adds one or more events to the list of selected events in the current view, showing them in a selected style.void
selectRecord
(int record) Select/deselect aRecord
passed in explicitly, or by index.void
selectRecord
(int record, boolean newState) Select/deselect aRecord
passed in explicitly, or by index.void
selectRecord
(Record record) Select/deselect aRecord
passed in explicitly, or by index.void
selectRecord
(Record record, boolean newState) Select/deselect aRecord
passed in explicitly, or by index.void
selectRecords
(int[] records) Select/deselect a list ofRecord
s passed in explicitly, or by index.void
selectRecords
(int[] records, boolean newState) Select/deselect a list ofRecord
s passed in explicitly, or by index.void
selectRecords
(Record[] records) Select/deselect a list ofRecord
s passed in explicitly, or by index.void
selectRecords
(Record[] records, boolean newState) Select/deselect a list ofRecord
s passed in explicitly, or by index.selectSingleEvent
(CalendarEvent event) Selects a single event in the current view, showing it in a selected style and deselecting any other selected events.void
selectTab
(int tabnum) Selects the calendar view in the passed tab number.setAddDropValues
(Boolean addDropValues) Indicates whether to add "drop values" to items dropped on this component, if both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key.setAddEventButtonHoverText
(String addEventButtonHoverText) The text to be displayed when a user hovers over theadd event
toolbar buttonsetAddFormulaFieldText
(String addFormulaFieldText) Text for a menu item allowing users to add a formula fieldsetAddOperation
(String addOperation) operationId
this component should use when performing add operations.setAddSummaryFieldText
(String addSummaryFieldText) Text for a menu item allowing users to add a formula fieldsetAllowDurationEvents
(Boolean allowDurationEvents) When set to true, allows events to be managed by duration, as well as by end date.setAlternateLaneStyles
(Boolean alternateLaneStyles) When showing aTimeline
, or aday view
whenshowDayLanes
is true, whether to make lane boundaries more obvious by showing alternate lanes in a different color.setAlwaysShowEventHovers
(Boolean alwaysShowEventHovers) By default, EventCanvases show their content in hovers.setAutoFetchAsFilter
(Boolean autoFetchAsFilter) IfDataBoundComponent.setAutoFetchData(Boolean)
is true, this attribute determines whether the initial fetch operation should be performed viaDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
setAutoFetchData
(Boolean autoFetchData) If true, when this component is first drawn, automatically callDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
depending onDataBoundComponent.getAutoFetchAsFilter()
.setAutoFetchTextMatchStyle
(TextMatchStyle autoFetchTextMatchStyle) IfautoFetchData
istrue
, this attribute allows the developer to specify a textMatchStyle for the initialDataBoundComponent.fetchData()
call.setBackButtonIconSrc
(String backButtonIconSrc) The icon to show in themonth-button
on Handsets when themonth view
is the current visible view.setBackButtonTitle
(String backButtonTitle) The title of themonth
on Handsets when themonth view
is the current visible view.setBaseStyle
(String baseStyle) The base name for the CSS class applied to the grid cells of the day and week views of the calendar.setBringEventsToFront
(Boolean bringEventsToFront) If set to true, clicking an event will bring it to the front of the zorder.setCalMonthEventLinkStyle
(String calMonthEventLinkStyle) The base name for the CSS class applied to the links rendered bygetDayBodyHTML()
.setCanAddFormulaFields
(Boolean canAddFormulaFields) Adds an item to the header context menu allowing users to launch a dialog to define a new
 field based on values present in other fields, using the {@link com.smartgwt.client..FormulaBuilder}.
setCanAddSummaryFields
(Boolean canAddSummaryFields) Adds an item to the header context menu allowing users to launch a dialog to define a new
 text field that can contain both user-defined text and the formatted values present in other 
 fields, using the {@link com.smartgwt.client..SummaryBuilder}.
setCancelButtonTitle
(String cancelButtonTitle) The title for theCancel button
in theevent editor
.setCanCreateEvents
(Boolean canCreateEvents) If true, users can create new events.setCanCreateOtherDayEvents
(Boolean canCreateOtherDayEvents) WhenshowOtherDays
is true, determines whether clicking in a Month-view body-cell that represents a date outside the selected month will open theevent-editor window
at the cell's location.setCanDeleteEvents
(Boolean canDeleteEvents) Deprecated.in favor ofcanRemoveEvents
setCanDragCreateEvents
(Boolean canDragCreateEvents) A boolean value controlling whether new events of varying length can be created by dragging the cursor.setCanDragEventField
(String canDragEventField) Name of the field on eachCalendarEvent
that determines whether anEventCanvas
can be moved or resized by dragging with the mouse.setCanDragEvents
(Boolean canDragEvents) A boolean value controlling whether users can drag-reposition events.setCanEditEvents
(Boolean canEditEvents) If true, users can edit existing events.setCanEditField
(String canEditField) Name of the field on eachCalendarEvent
that determines whether it can be edited in theevent editor
.setCanEditLane
(Boolean canEditLane) Can events be moved between lanes? If so, the event can be dragged to a differentlane
, and the eventquick dialog
andeditor
allow a lane to be selected with a drop-down chooser.setCanEditLaneField
(String canEditLaneField) Name of the field on eachCalendarEvent
that determines whether that event can be moved between lanes.setCanEditSublane
(Boolean canEditSublane) Can events be moved between sublanes?setCanEditSublaneField
(String canEditSublaneField) Name of the field on eachCalendarEvent
that determines whether that event can be moved between individualsublanes
in aLane
.setCanGroupLanes
(Boolean canGroupLanes) If true, allows the lanes in a Timeline to be grouped by providing a value forlaneGroupByField
.setCanRemoveEvents
(Boolean canRemoveEvents) If true, users can remove existing events.setCanRemoveField
(String canRemoveField) Name of the field on eachCalendarEvent
that determines whether an event shows a remove button.setCanReorderLanes
(Boolean canReorderLanes) If true, lanes can be reordered by dragging theirlaneFields
with the mouse.setCanResizeEventField
(String canResizeEventField) Name of the field on eachCalendarEvent
that determines whether an event can be resized by dragging.setCanResizeEvents
(Boolean canResizeEvents) Canevents
be resized by dragging appropriate edges of thecanvas
? Only has an effect when bothcanEditEvents
andcanDragEvents
are true.setCanResizeTimelineEvents
(Boolean canResizeTimelineEvents) Deprecated.in favor ofcanResizeEvents
;setCanSelectEvents
(Boolean canSelectEvents) When set to true, makes individualevent canvases
selectable.void
setCellHoverCustomizer
(CellHoverCustomizer customizer) Customize the Hover text to display when the mouse hovers over cells in a CalendarViewsetChosenDate
(Date chosenDate) The date for which events are displayed in the day, week, and month tabs of the calendar.setColumnsPerPage
(Integer columnsPerPage) When using the Next and Previous arrows to scroll a Timeline, this is the number of columns of thetimelineGranularity
to scroll by.setControlBarIconBaseStyle
(String controlBarIconBaseStyle) A CSS style to apply to icons in thecontrolsBar
.setControlBarIconSize
(Integer controlBarIconSize) The size of the various icons displayed in thecontrolsBar
of this Calendar.setControlsBarHeight
(Integer controlsBarHeight) Default height of thecontrolsBar
shown above the main Calendar grid.setCurrentViewName
(ViewName currentViewName) The name of the view that should be visible initially by default.void
An array of Record objects, specifying the data to be used to populate the DataBoundComponent.void
setData
(RecordList data) An List of Record objects, specifying the data to be used to populate the DataBoundComponent.setData
(CalendarEvent... data) A List of CalendarEvent objects, specifying the data to be used to populate the calendar.setDataFetchMode
(FetchMode dataFetchMode) How to fetch and manage records retrieve from the server.setDataPageSize
(int dataPageSize) When usingdata paging
, how many records to fetch at a time.setDataSource
(DataSource dataSource) The DataSource that this component should bind to for default fields and for performingDataSource requests
.setDataSource
(String dataSource) The DataSource that this component should bind to for default fields and for performingDataSource requests
.void
setDateCellAlignCustomizer
(DateCellAlignCustomizer customizer) This method installs a customizer that returns the horizontsal Alignment to display in the passed date-cell when rendered in the passed viewvoid
setDateCellVAlignCustomizer
(DateCellVAlignCustomizer customizer) This method installs a customizer that returns the VerticalAlignment to display in the passed date-cell when rendered in the passed viewvoid
setDateCSSTextCustomizer
(DateCSSTextCustomizer customizer) This method returns the CSS class name for the passed event when rendered in the passed viewsetDateEditingStyle
(DateEditingStyle dateEditingStyle) Indicates the type of controls to use in event-windows.setDateFormatter
(DateDisplayFormat dateFormatter) Date formatter for displaying events.void
setDateHeaderCustomizer
(DateHeaderCustomizer customizer) This method installs a customizer to determine the HTML to be displayed in the header for a given date column in a CalendarViewvoid
setDateHTMLCustomizer
(DateHTMLCustomizer customizer) This method installs a customizer that returns the HTML to display in the passed date-cell when rendered in the passed viewsetDatePickerHoverText
(String datePickerHoverText) The text to be displayed when a user hovers over thedate picker
toolbar buttonvoid
setDateStyleCustomizer
(DateStyleCustomizer customizer) This method installs a customizer that returns the CSS class name for the passed date-cell when rendered in the passed viewsetDayBodyBaseStyle
(String dayBodyBaseStyle) The base name for the CSS class applied to the day body of the month view of the calendar.setDayHeaderBaseStyle
(String dayHeaderBaseStyle) The base name for the CSS class applied to the day headers of the month view.setDayViewTitle
(String dayViewTitle) The title for theday view
.setDeepCloneOnEdit
(Boolean deepCloneOnEdit) Before we start editing values in this DataBoundComponent, should we perform a deep clone of the underlying values.static void
setDefaultProperties
(Calendar calendarProperties) Class level method to set the default properties of this class.setDefaultTimelineColumnSpan
(int defaultTimelineColumnSpan) The number of columns of thetimelineGranularity
to give the timeline by default if noendDate
is provided.setDescriptionField
(String descriptionField) The name of the description field on aCalendarEvent
.setDetailsButtonTitle
(String detailsButtonTitle) The title for the edit button in the quickquick event dialog
.void
setDisableDateCustomizer
(DisableDateCustomizer customizer) Return true from the customizer to have the passed event considered disabled in the passed viewsetDisableWeekends
(Boolean disableWeekends) If true, weekend days appear in a disabled style and events cannot be created on weekends.setDragDataAction
(DragDataAction dragDataAction) Indicates what to do with data dragged into another DataBoundComponent.setDragDataCustomizer
(DragDataCustomizer customizer) During a drag-and-drop interaction, this method returns the set of records being dragged out of the component.void
setDragHoverCustomizer
(DragHoverCustomizer customizer) Customize the Hover text to display during a drag operationsetDragTrackerStyle
(String dragTrackerStyle) CSS Style to apply to the drag tracker when dragging occurs on this component.setDropValues
(Map dropValues) When an item is dropped on this component, andaddDropValues
is true and both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key, this object provides the "drop values" that Smart GWT will apply to the dropped object before updating it.setDuplicateDragMessage
(String duplicateDragMessage) Message to show when a user attempts to transfer duplicate records into this component, and
preventDuplicates
is enabled.setDurationField
(String durationField) The name of theduration
field on aCalendarEvent
.setDurationUnitField
(String durationUnitField) The name of thedurationUnit
field on aCalendarEvent
.setEditFormulaFieldText
(String editFormulaFieldText) Text for a menu item allowing users to edit a formula fieldsetEditSummaryFieldText
(String editSummaryFieldText) Text for a menu item allowing users to edit the formatter for a fieldsetEndDate
(Date endDate) The end date of the calendar timeline view.setEndDateField
(String endDateField) The name of the end date field on aCalendarEvent
.setEventAutoArrange
(Boolean eventAutoArrange) If set to true, enables the auto-arrangement of events that share time in the calendar.void
setEventBodyHTMLCustomizer
(EventBodyHTMLCustomizer customizer) This method installs a customizer that returns the HTML to be used as the body/description for the passed event.setEventCanvasCloseButtonSize
(Integer eventCanvasCloseButtonSize) The size of theclose-button
that snaps to the top-right of an event canvas on rollover and shows allows an event to be removed from aCalendarView
.setEventCanvasCloseIconSize
(Integer eventCanvasCloseIconSize) The size of the icon in theclose-button
floated over events on rollover.void
This method sets the customizer for EventCanvasComponent methodsvoid
This method returns the SCImgURL for the icon to use as the gripper for a given EventCanvasvoid
This method returns the hover HTML to be displayed when the user hovers over an eventCanvasvoid
Customizer called whenever the Calender needs to show a context-menu for a given EventCanvassetEventDescriptionFieldTitle
(String eventDescriptionFieldTitle) void
setEventDialogCustomizer
(EventDialogCustomizer customizer) Customizer called whenever the Calender needs to show an EventDialog, to edit or view a CalendarEventvoid
setEventDialogFields
(FormItem... eventDialogFields) The set of fields for theeventDialog
.setEventDragGap
(Integer eventDragGap) The number of pixels to leave to the right of events so overlapping events can still be added using the mouse.setEventDurationFieldTitle
(String eventDurationFieldTitle) setEventDurationUnitFieldTitle
(String eventDurationUnitFieldTitle) setEventEditorButtons
(Object... eventEditorButtons) The list of buttons to include in theeventEditor
.void
setEventEditorCustomizer
(EventEditorCustomizer customizer) Customizer called whenever the Calender needs to show an EventEditor, to edit or create a CalendarEventsetEventEditorDateFieldTitle
(String eventEditorDateFieldTitle) The title for the Date-field in theeventEditor
that allows for changing the logical start-date of an event, along with its start and end times, when editing events in theday
andweek
views.void
setEventEditorFields
(FormItem... eventEditorFields) The set of fields for theeventEditor
.setEventEndDateFieldTitle
(String eventEndDateFieldTitle) setEventHeaderHeight
(int eventHeaderHeight) WheneventHeaderWrap
is false andshowEventDescriptions
is true, this is the fixed height for theheader area
in event canvases.void
This method returns the HTML to be used as the header/title for the passed event.setEventHeaderWrap
(boolean eventHeaderWrap) When rendering thecanvas
for an event, whether to allow the content of theheader area
to wrap to multiple lines.setEventLaneFieldTitle
(String eventLaneFieldTitle) setEventNameFieldTitle
(String eventNameFieldTitle) setEventOverlap
(Boolean eventOverlap) WheneventAutoArrange
is true, setting eventOverlap to true causes events that share timeslots to overlap each other by a percentage of their width, specified byeventOverlapPercent
.setEventOverlapIdenticalStartTimes
(Boolean eventOverlapIdenticalStartTimes) When set to true, events that start at the same time will not overlap each other to prevent events having their close button hidden.setEventOverlapPercent
(int eventOverlapPercent) The size of the overlap, presented as a percentage of the width of events sharing timeslots.setEventScreen
(String eventScreen) Screen to create (viacreateScreen()
) in lieu of callingcreateEventCanvasComponent()
.setEventSnapGap
(Integer eventSnapGap) The number of minutes that determines the positions to which events will snap when rendered, and when moved or resized with the mouse.setEventStartDateFieldTitle
(String eventStartDateFieldTitle) void
setEventStyle
(CalendarEvent event, String styleName) Update the styleName for the passed event.setEventStyleName
(String eventStyleName) The base name for the CSS class applied toevents
when they're rendered in calendar views.setEventStyleNameField
(String eventStyleNameField) The name of the field used to overrideeventStyleName
for an individualCalendarEvent.styleName
.setEventSublaneFieldTitle
(String eventSublaneFieldTitle) setEventWindowStyle
(String eventWindowStyle) Deprecated.in favor ofeventStyleName
setEventWindowStyleField
(String eventWindowStyleField) Deprecated.in favor ofeventStyleNameField
setExportAll
(Boolean exportAll) Setting exportAll to true prevents the component from passing its list of fields to the 
 export call.setExportFields
(String[] exportFields) The list of field-names to export.setExportIncludeSummaries
(Boolean exportIncludeSummaries) If Summary rows exist for this component, whether to include them when exporting client data.setFetchOperation
(String fetchOperation) Operation ID this component should use when performing fetch operations.setFields
(JavaScriptObject... fields) Field setter variant (alternative tosetFields(FormItem...)
,setFields(ListGridField...)
, etc.) that will accept an array of JavaScriptObject, rather than an array of SmartGWT Java wrappers of the field class type (e.g.setFirstDayOfWeek
(Integer firstDayOfWeek) The numeric day (0-6, Sunday-Saturday) which the calendar should consider as the first day of the week in multi-day views, and in the popupDateChooser
.void
setHeaderHoverCustomizer
(HeaderLevelHoverCustomizer customizer) Customize the Hover text for a given span in a HeaderLevel.setHeaderLevels
(HeaderLevel... headerLevels) Configures the levels ofheaders
shown above the event area, and their time units.setHideUnusedLanes
(Boolean hideUnusedLanes) When set to true, hides anylane
that doesn't have any active events in the current dataset.setHiliteProperty
(String hiliteProperty) Marker that can be set on a record to flag that record as hilited.setHilites
(Hilite[] hilites) Accepts an array of hilite objects and applies them to this DataBoundComponent.setHiliteState
(String hiliteState) Set the current hilites based on a hiliteState String previously returned from getHilitesState.setImplicitCriteria
(Criteria implicitCriteria) Criteria that are never shown to or edited by the user and are cumulative with any criteria provided viaDataBoundComponent.initialCriteria
,DataBoundComponent.setCriteria()
etc.setImplicitCriteria
(Criteria implicitCriteria, DSCallback callback) setImplicitCriteria
(Criteria criteria, DSCallback callback, Boolean initialFetch) setIncludeRangeCriteria
(Boolean includeRangeCriteria) When set to true, the default, the fetches issued by navigating around in the various views are limited to the accessible date-range in the current view - as you change the current date-range, a fetch is only issued if the new range is not entirely within the previous range.void
setIndicatorHoverHTMLCustomizer
(IndicatorHoverHTMLCustomizer indicatorHoverHTMLCustomizer) This method returns the hover HTML to be displayed when the user hovers over an IndicatorCanvassetIndicators
(CalendarEvent... indicators) An array of CalendarEvent instances representing instants in time, to be highlighted intimeline views
.setIndicatorStyleName
(String indicatorStyleName) setInitialCriteria
(Criteria initialCriteria) Criteria to use whenDataBoundComponent.setAutoFetchData(Boolean)
is used.setInvalidDateMessage
(String invalidDateMessage) The message to display in theeventEditor
when the 'To' date is greater than the 'From' date and a save is attempted.setLaneEventPadding
(Integer laneEventPadding) setLaneFields
(ListGridField... laneFields) Field definitions for the frozen area of thetimelineView
, which shows data about the timelinelanes
.setLaneGroupByField
(String laneGroupByField) For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.setLaneGroupByField
(String... laneGroupByField) For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.void
void
setLaneGroupStartOpen
(Object... groupValues) setLaneNameField
(String laneNameField) The name of the field which will determine thelane
in which a given event will be displayed inTimeline
s and in theday view
, ifshowDayLanes
is true.An array ofLane
definitions that represent the rows of thetimelineView
, or the columns of thedayView
ifshowDayLanes
is true.boolean
setLaneTitle
(String lane, String title) For views that supportlanes
, updates the title for the passed lane.setLeadingDateField
(String leadingDateField) The name of the leading date field for each event.setLimitToWorkday
(Boolean limitToWorkday) WhenshowWorkday
is true, this attribute prevents the user from scrolling vertical views beyond the specified workdaystart
andend
hours.Setter implementing theLogicalStructure
interface, which supports Eclipse's logical structure debugging facility.setMinimalUI
(boolean minimalUI) A boolean value controlling whether the Calendar shows tabs for available calendar views.setMinimumDayHeight
(Integer minimumDayHeight) In themonth view
whenshowDayHeaders
is true, this is the minimum height applied to a day cell and its header combined.setMinLaneWidth
(Integer minLaneWidth) When showingvertical lanes
in thedayView
, this attribute sets the minimum width of each column or field.setMinRowHeight
(int minRowHeight) The minimum height of time-rows in vertical calendar views.setMinutesPerRow
(Integer minutesPerRow) setMonthButtonIconSrc
(String monthButtonIconSrc) The icon to show next to the month-name in themonth button
, used for showing and hiding themonth view
on Handsets.setMonthButtonTitle
(String monthButtonTitle) The title of themonth button
, used for showing and hiding themonth view
on Handsets.setMonthMoreEventsLinkTitle
(String monthMoreEventsLinkTitle) The title of the link shown in a cell of amonth view
when there are too many events to be displayed at once.void
setMonthViewHoverHTMLCustomizer
(MonthViewHoverHTMLCustomizer monthViewHoverHTMLCustomizer) This method returns the hover HTML to be displayed when the user hovers over a cell displayed in the calendar month view tab.setMonthViewTitle
(String monthViewTitle) The title for themonth view
.setNameField
(String nameField) The name of the name field on aCalendarEvent
.setNewEventWindowTitle
(String newEventWindowTitle) The title-text displayed in the popup event dialog/editor for new events.setNextButtonHoverText
(String nextButtonHoverText) The text to be displayed when a user hovers over thenext
toolbar buttonsetOtherDayBlankStyle
(String otherDayBlankStyle) The CSS style applied to both the header and body of days from other months in themonth view
, whenshowOtherDays
is false.setOtherDayBodyBaseStyle
(String otherDayBodyBaseStyle) The base name for the CSS class applied to the day body of the month view of the calendar.setOtherDayClickNavigation
(Boolean otherDayClickNavigation) WhenshowOtherDays
is true, this attribute determines whether the month-view should change month when cells representing days in the previous or following month are clicked.setOtherDayHeaderBaseStyle
(String otherDayHeaderBaseStyle) The base name for the CSS class applied to the day headers of the month view.setOverlapSortSpecifiers
(SortSpecifier... overlapSortSpecifiers) A set ofsort-specifiers
for customizing the render order of events that overlap.setPreventDuplicates
(Boolean preventDuplicates) If set, detect and prevent duplicate records from being transferred to this component, either via
 drag and drop or viaDataBoundComponent.transferSelectedData(com.smartgwt.client.widgets.DataBoundComponent)
.setPreviousButtonHoverText
(String previousButtonHoverText) The text to be displayed when a user hovers over theprevious
toolbar button.setProgressiveLoading
(Boolean progressiveLoading) Indicates whether or not this component will load its dataprogressively
setRemoveButtonTitle
(String removeButtonTitle) The title for theRemove button
in theevent editor
.setRemoveOperation
(String removeOperation) operationId
this component should use when performing remove operations.setRenderEventsOnDemand
(boolean renderEventsOnDemand) When set to true, the default, eachevent
is rendered as it appears in the viewport.void
setResolution
(HeaderLevel[] headerLevels, TimeUnit unit, Integer unitCount) Reset the resolution, the header levels and scrollable range, of the timeline view.void
setResolution
(HeaderLevel[] headerLevels, TimeUnit unit, Integer unitCount, Integer granularityPerColumn) Reset the resolution, the header levels and scrollable range, of the timeline view.setRowHeight
(int rowHeight) The height of time-slots in the calendar.setRowTitleFrequency
(Integer rowTitleFrequency) setSaveButtonTitle
(String saveButtonTitle) setSavedSearchId
(String savedSearchId) Optional identifier for saved searches that should be applied to this component.setScrollToWorkday
(Boolean scrollToWorkday) If set, andshowWorkday
is true, automatically scrolls theday
andweek
views to the start of theworkday
when the calendar is first displayed and whenever the user changes to a different day or week.setSelectChosenDate
(Boolean selectChosenDate) When true, shows the currentchosenDate
in a selected style in themonth view
.setSelectedCellStyle
(String selectedCellStyle) The base name for the CSS class applied to a cell that is selected via a mouse drag.setShowAddEventButton
(Boolean showAddEventButton) Set to false to hide theAdd Event
button.setShowCellHovers
(Boolean showCellHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over the normal cells in the body of CalendarViews.setShowColumnLayouts
(Boolean showColumnLayouts) When true, causeslayouts
to be added to each column in vertical views.setShowComplexFields
(Boolean showComplexFields) Whether to show fields of non-atomic types when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.
setShowControlsBar
(Boolean showControlsBar) If false the controls bar at the top of the calendar will not be displayed - this means that thecontrolsBar
will be hidden, so the autoChildren (previousButton
,dateLabel
,nextButton
,addEventButton
, anddatePickerButton
) will not be created or shown.setShowDateChooser
(Boolean showDateChooser) Determines whether thedateChooser
is displayed.void
setShowDateCustomizer
(ShowDateCustomizer customizer) This method is called during rendering for all events in the visible range - those which would be rendered by default.setShowDatePickerButton
(Boolean showDatePickerButton) Set to false to hide thedatePickerButton
that allows selecting a new base date for this Calendar.setShowDayHeaders
(Boolean showDayHeaders) If true, the default, show a header cell for each day cell in themonth view
, with both cells having a minimum combined height ofminimumDayHeight
.setShowDayLanes
(Boolean showDayLanes) setShowDayView
(Boolean showDayView) Whether to show the Day view.setShowDetailFields
(Boolean showDetailFields) Whether to show fields markeddetail:true
when a DataBoundComponent is given a DataSource but nocomponent.fields
.setShowDragHovers
(Boolean showDragHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when an event is being dragged with the mouse.setShowEventCanvasComponents
(boolean showEventCanvasComponents) Whetherevent-canvases
should show a custom widget as content, rather than the defaultheader
andbody
HTML.void
setShowEventCustomizer
(ShowEventCustomizer customizer) Return false from the customizer to prevent the passed CalendarEvent from being rendered in the passed view.setShowEventDescriptions
(boolean showEventDescriptions) When rendering thecanvas
for an event, whether to show thebody area
, typically containing brief details of the event -by default
,its description
.setShowEventHeaders
(boolean showEventHeaders) When rendering thecanvas
for an event, whether to show theheader area
, typically containing suitable title text -by default
, the event'sname
.setShowEventHovers
(Boolean showEventHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over anevent canvas
in a calendarView.setShowHeaderHovers
(Boolean showHeaderHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over theheader levels
in aCalendarView
.setShowHiddenFields
(Boolean showHiddenFields) Whether to show fields markedhidden:true
when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.
setShowIndicators
(Boolean showIndicators) Set to true to render any definedindicators
intotimeline views
.setShowIndicatorsInFront
(boolean showIndicatorsInFront) Inindicator lines
are showing, this attribute affects where in the z-order their canvases will be rendered: either in front of, or behind normal calendar events.setShowLabelColumn
(boolean showLabelColumn) When set to false, hides the frozen Label-Column in verticalCalendarView
s.void
setShowLaneCustomizer
(ShowLaneCustomizer customizer) Return false from the customizer to prevent the passed Lane from being rendered in the passed view.setShowLaneFieldHovers
(Boolean showLaneFieldHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over the cells in alaneField
.setShowLaneRollOver
(Boolean showLaneRollOver) When set to true, causesTimelines
to highlight the Lane under the mouse with the "Over" style.setShowMonthButton
(Boolean showMonthButton) Set to false to prevent theMonth
button from displaying on Handset devices.setShowMonthView
(Boolean showMonthView) Whether to show the Month view.setShowNextButton
(Boolean showNextButton) Set to false to hide theNext
button.setShowOtherDays
(Boolean showOtherDays) If set to true, in themonth view
, days that fall in an adjacent month are still shown with a header and body area, and are interactive.setShowPreviousButton
(Boolean showPreviousButton) Set to false to hide thePrevious
button.setShowQuickEventDialog
(Boolean showQuickEventDialog) Determines whether the quick event dialog is displayed when a time is clicked.setShowSavedSearchesByDS
(boolean showSavedSearchesByDS) Whether to associate saved searches by default with the currentDataSource
of a component when asavedSearchId
is not provided.setShowTimelineView
(Boolean showTimelineView) If set to true, show theTimeline view
.setShowViewHovers
(Boolean showViewHovers) When set to true, the default value, causes the Calendar to show customizable hovers when the mouse moves over various areas of a CalendarView.setShowWeekends
(Boolean showWeekends) setShowWeekView
(Boolean showWeekView) Whether to show the Week view.setShowWorkday
(Boolean showWorkday) When set to true, this setting enables various features related to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
) in vertical calendar views (day
andweek
).setShowZoneHovers
(Boolean showZoneHovers) WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over azone
in a calendarView.setShowZones
(Boolean showZones) Set to true to render any definedzones
intotimeline views
.setSizeEventsToGrid
(Boolean sizeEventsToGrid) If true, events will be sized to the grid, even if they start and/or end at times between grid cells.setSizeToWorkday
(Boolean sizeToWorkday) WhenshowWorkday
is true, attempt to resize rows in the day and week views so that theworkday hours
fill the visible viewport-height, and the whole workday is visible without scrolling.setSort
(SortSpecifier... sortSpecifiers) Sort the component on one or more fields.setSparseFieldState
(Boolean sparseFieldState) If true,ListGrid.getFieldState()
andListGrid.setFieldState(java.lang.String)
will omit state information for hidden fields by default.setStartDate
(Date startDate) The start date of the calendartimeline view
.setStartDateField
(String startDateField) The name of the start date field on aCalendarEvent
.setStyleWorkday
(Boolean styleWorkday) WhenshowWorkday
is true, applies theworkdayBaseStyle
to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
), in both thedayView
andweekView
.setSublaneNameField
(String sublaneNameField) The name of the field which will determine thesublane
in which this event will be displayed, within its parent Lane, inTimeline
s and in theday view
, ifshowDayLanes
is true.void
setTimeFormatter
(TimeDisplayFormat timeFormatter) Display format to use for the time portion of events' date information.void
setTimeFormatter
(TimeFormatter timeFormatter) Deprecated.usesetTimeFormatter(TimeDisplayFormat)
instead.setTimelineGranularity
(TimeUnit timelineGranularity) The granularity in which thetimelineView
will display events.void
setTimelineRange
(Date start) Sets the range over which the timeline will display events.void
setTimelineRange
(Date start, Date end) Sets the range over which the timeline will display events.setTimelineUnitsPerColumn
(int timelineUnitsPerColumn) How many units oftimelineGranularity
each cell represents.setTimelineViewTitle
(String timelineViewTitle) The title for thetimeline view
.setTitleField
(String titleField) Sets the best field to use for a user-visible title for an individual record from this component.setTodayBackgroundColor
(String todayBackgroundColor) The background color for cells that represent today in allCalendarView
s.setTrailingDateField
(String trailingDateField) The name of the trailing date field for each event.setTwentyFourHourTime
(Boolean twentyFourHourTime) Dictates whether times throughout the widget are formatted and edited as 24-hour values.setUpdateOperation
(String updateOperation) operationId
this component should use when performing update operations.setUseAllDataSourceFields
(Boolean useAllDataSourceFields) If true, the set of fields given by the "default binding" (see 
fields
) is used, with any fields specified in
component.fields
acting as overrides that can suppress or modify the
 display of individual fields, without having to list the entire set of fields that
 should be shown.
setUseEventCanvasRolloverControls
(boolean useEventCanvasRolloverControls) By default, theclose buttons
and thehorizontal
andvertical
resizer widgets for event canvases are shown only when the mouse is over a given event.setUseFlatFields
(Boolean useFlatFields) TheuseFlatFields
flag causes all simple type fields anywhere in a nested
 set of DataSources to be exposed as a flat list for form binding.setUseSublanes
(Boolean useSublanes) setWeekendDays
(int... weekendDays) An array of integer day-numbers that should be considered to be weekend days by this Calendar instance.setWeekEventBorderOverlap
(Boolean weekEventBorderOverlap) Augments the width of week event windows slightly to avoid duplicate adjacent borders between events.setWeekPrefix
(String weekPrefix) The text to appear before the week number in the title ofweek-based
HeaderLevel
s when this calendar is showing a timeline.setWeekViewTitle
(String weekViewTitle) The title for theweek view
.setWorkdayBaseStyle
(String workdayBaseStyle) IfshowWorkday
is set, this is the style used for cells that are within the workday, as defined byworkdayStart
andworkdayEnd
, or by a date-specific range provided ingetWorkdayStart()
andgetWorkdayEnd()
implementations.setWorkdayEnd
(String workdayEnd) When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.void
setWorkdays
(int[] workdays) Array of days that are considered workdays whenshowWorkday
is truesetWorkdayStart
(String workdayStart) When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.void
setZoneHoverHTMLCustomizer
(ZoneHoverHTMLCustomizer zoneHoverHTMLCustomizer) This method returns the hover HTML to be displayed when the user hovers over an ZoneCanvassetZones
(CalendarEvent... zones) An array of CalendarEvent instances representing pre-defined periods of time to be highlighted intimeline views
.setZoneStyleName
(String zoneStyleName) setZoneTitleOrientation
(VerticalAlignment zoneTitleOrientation) The vertical alignment of the header-text in eachzone
.boolean
shouldDisableDate
(Date date) Returns true if the passed date should be considered disabled.boolean
shouldDisableDate
(Date date, CalendarView view) Returns true if the passed date should be considered disabled.boolean
shouldShowDate
(Date date) Indicates whether the passed date should be visible in the passedCalendarView
.boolean
shouldShowDate
(Date date, CalendarView view) Indicates whether the passed date should be visible in the passedCalendarView
.boolean
shouldShowEvent
(CalendarEvent event) Indicates whether the passedevent
should be visible in the passedCalendarView
.boolean
shouldShowEvent
(CalendarEvent event, CalendarView view) Indicates whether the passedevent
should be visible in the passedCalendarView
.boolean
shouldShowLane
(Lane lane) Indicates whether the passedlane
should be visible in the passedCalendarView
.boolean
shouldShowLane
(Lane lane, CalendarView view) Indicates whether the passedlane
should be visible in the passedCalendarView
.boolean
shouldShowLane
(String lane) Indicates whether the passedlane
should be visible in the passedCalendarView
.boolean
showEventCanvasComponent
(EventCanvas canvas) Should a component be applied to the passedcanvas
in theview
in which it appears? Return false from this method to override the global value ofshowEventCanvasComponents
for this canvas.void
Open the Quick Event dialog showing minimal information about an existingevent
.void
showEventDialog
(CalendarEvent event) void
showEventDialog
(CalendarEvent event, Boolean isNewEvent) Open the Quick Event dialog showing minimal information about an existingevent
.void
Show an Event Editor for the passed event.void
showEventEditor
(CalendarEvent event) void
showEventEditor
(CalendarEvent event, Boolean isNewEvent) Show an Event Editor for the passed event.void
Open the Quick Event dialog to begin editing a newevent
.void
showNewEventDialog
(CalendarEvent event) Open the Quick Event dialog to begin editing a newevent
.void
Show an Event Editor for a new event.void
showNewEventEditor
(CalendarEvent event) Show an Event Editor for a new event.timelineEventMoved
(CalendarEvent event, Date startDate, Date endDate, Lane lane) Deprecated.in favor ofCalendar.eventRepositionStop()
timelineEventResized
(CalendarEvent event, Date startDate, Date endDate) Deprecated.in favor ofCalendar.eventResizeStop()
void
transferRecords
(Record[] records, Record targetRecord, Integer index, Canvas sourceWidget, TransferRecordsCallback callback) Transfer a list ofRecord
s from another component (does not have to be a databound component) into this component.void
Simulates a drag / drop type transfer of the selected records in some other component to this component, without requiring any user interaction.void
transferSelectedData
(DataBoundComponent source, int index) Simulates a drag / drop type transfer of the selected records in some other component to this component, without requiring any user interaction.void
updateCalendarEvent
(CalendarEvent event, CalendarEvent newEvent, Map otherFields) Save an event to this Calendar's ${isc.DocUtils.linkForRef('attr:Calendar.dataSource','dataSource) or \ndata array')
.void
updateEvent
(CalendarEvent event, Date startDate, Date endDate, String name, String description) update an event in this calendar.void
updateEventCanvasComponent
(EventCanvas canvas, Canvas component) Called fromEventCanvas.setEvent()
whenshowEventCanvasComponents
is true and the eventCanvas already has acomponent
.Methods inherited from class com.smartgwt.client.widgets.Canvas
addChild, addChild, addChild, addChild, addChild, addClearHandler, addClickHandler, addDoubleClickHandler, addDragMoveHandler, addDragRepositionMoveHandler, addDragRepositionStartHandler, addDragRepositionStopHandler, addDragResizeMoveHandler, addDragResizeStartHandler, addDragResizeStopHandler, addDragStartHandler, addDragStopHandler, addDropHandler, addDropMoveHandler, addDropOutHandler, addDropOverHandler, addFocusChangedHandler, addHoverHandler, addHoverHiddenHandler, addKeyDownHandler, addKeyPressHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseStillDownHandler, addMouseUpHandler, addMouseWheelHandler, addMovedHandler, addParentMovedHandler, addPeer, addPeer, addPeer, addPeer, addResizedHandler, addRightMouseDownHandler, addRuleContextChangedHandler, addScrolledHandler, addShowContextMenuHandler, addSnapAlignCandidate, addStyleName, addVisibilityChangedHandler, adjustForContent, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateHide, animateHide, animateHide, animateHide, animateHide, animateHide, animateHide, animateMove, animateMove, animateMove, animateMove, animateRect, animateRect, animateRect, animateRect, animateResize, animateResize, animateResize, animateResize, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateShow, animateShow, animateShow, animateShow, animateShow, animateShow, animateShow, asSGWTComponent, blur, bringToFront, clear, clearExplicitTabIndex, clickMaskUp, clickMaskUp, contains, contains, containsEvent, containsEventTarget, containsFocus, containsPoint, containsPoint, dataContextChanged, deparent, depeer, disable, enable, encloses, focus, focusAfterGroup, focusAtEnd, focusInNextTabElement, focusInPreviousTabElement, getAbsoluteLeft, getAbsoluteTop, getAccessKey, getAdaptiveHeightPriority, getAdaptiveWidthPriority, getAlwaysManageFocusNavigation, getAlwaysShowScrollbars, getAnimateAcceleration, getAnimateFadeTime, getAnimateHideAcceleration, getAnimateHideEffect, getAnimateHideTime, getAnimateMoveAcceleration, getAnimateMoveTime, getAnimateRectAcceleration, getAnimateRectTime, getAnimateResizeAcceleration, getAnimateResizeLayoutMode, getAnimateResizeTime, getAnimateScrollAcceleration, getAnimateScrollTime, getAnimateShowAcceleration, getAnimateShowEffect, getAnimateShowTime, getAnimateTime, getAppImgDir, getAriaHandleID, getAriaRole, getAriaStateDefaults, getAutoMaskComponents, getAutoParent, getAutoPopulateData, getAutoShowParent, getBackgroundColor, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorder, getBorderRadius, getBottom, getById, getByJSObject, getByLocalId, getCanAcceptDrop, getCanAdaptHeight, getCanAdaptWidth, getCanDrag, getCanDragReposition, getCanDragResize, getCanDragScroll, getCanDrop, getCanDropBefore, getCanFocus, getCanHover, getCanSelectText, getCanvasAutoChild, getCanvasItem, getChildren, getChildrenResizeSnapAlign, getChildrenSnapAlign, getChildrenSnapCenterAlign, getChildrenSnapEdgeAlign, getChildrenSnapResizeToGrid, getChildrenSnapToGrid, getChildTabPosition, getClassName, getComponentMask, getComponentMaskDefaults, getContentElement, getContents, getContextMenu, getCorrectZoomOverflow, getCursor, getDataContext, getDataPath, getDefaultHeight, getDefaultWidth, getDefiningProperty, getDefiningPropertyName, getDefiningPropertyNameOptions, getDestroyed, getDestroying, getDisabled, getDisabledCursor, getDisableTouchScrollingForDrag, getDoubleClickDelay, getDragAppearance, getDragIntersectStyle, getDragMaskType, getDragMaxHeight, getDragMaxWidth, getDragMinHeight, getDragMinWidth, getDragOpacity, getDragRepositionAppearance, getDragRepositionCursor, getDragResizeAppearance, getDragScrollDelay, getDragStartDistance, getDragTarget, getDragTargetAsString, getDragType, getDropTarget, getDropTargetAsString, getDropTypes, getDropTypesAsString, getDynamicContents, getEdgeBackgroundColor, getEdgeCenterBackgroundColor, getEdgeImage, getEdgeMarginSize, getEdgeOffset, getEdgeOpacity, getEdgeShowCenter, getEdgeSize, getEditNode, getEditProxy, getEditProxyConstructor, getElement, getElement, getEnableWhen, getEndLine, getEventEdge, getEventEdge, getExtraSpace, getFacetId, getFloatingScrollbars, getFormItemAutoChild, getForwardSVGeventsToObject, getFullDataPath, getGroupBorderCSS, getGroupLabelBackgroundColor, getGroupLabelStyleName, getGroupPadding, getGroupTitle, getHeight, getHeightAsString, getHideUsingDisplayNone, getHoverAlign, getHoverAutoDestroy, getHoverAutoFitMaxWidth, getHoverAutoFitMaxWidthAsString, getHoverAutoFitWidth, getHoverComponent, getHoverDelay, getHoverFocusKey, getHoverHeight, getHoverHTML, getHoverMoveWithMouse, getHoverOpacity, getHoverPersist, getHoverScreen, getHoverStyle, getHoverVAlign, getHoverWidth, getHoverWrap, getHSnapPosition, getHSnapPosition, getHtmlElement, getHtmlElementAsString, getHtmlPosition, getImage, getImgURL, getImgURL, getInnerContentHeight, getInnerContentWidth, getInnerHeight, getInnerWidth, getIsGroup, getIsPrinting, getIsRuleScope, getIsSnapAlignCandidate, getKeepInParentRect, getLayoutAlign, getLeaveGroupLabelSpace, getLeavePageSpace, getLeft, getLeftAsString, getLocalId, getLocateByIDOnly, getLocateChildrenBy, getLocateChildrenType, getLocatePeersBy, getLocatePeersType, getLocatorName, getMargin, getMasterCanvas, getMasterElement, getMatchElement, getMatchElementHeight, getMatchElementWidth, getMaxHeight, getMaxWidth, getMaxZoomOverflowError, getMenuConstructor, getMinHeight, getMinNonEdgeSize, getMinWidth, getMomentumScrollMinSpeed, getMouseStillDownDelay, getMouseStillDownInitialDelay, getName, getNativeAutoHideScrollbars, getNextZIndex, getNoDoubleClicks, getNoDropCursor, getOffsetHeight, getOffsetWidth, getOffsetX, getOffsetY, getOpacity, getOuterElement, getOverflow, getPadding, getPageBottom, getPageLeft, getPageRect, getPageRight, getPageTop, getPaletteDefaults, getPanelContainer, getParentCanvas, getParentElement, getPeers, getPendingMarkerStyle, getPendingMarkerVisible, getPercentBox, getPercentSource, getPersistentMatchElement, getPointerSettings, getPointerTarget, getPointerTargetAsString, getPosition, getPrefix, getPrintChildrenAbsolutelyPositioned, getPrintHTML, getPrintHTML, getPrintStyleName, getPrompt, getProportionalResizeModifiers, getProportionalResizing, getReceiveScrollbarEvents, getRect, getRedrawOnResize, getResizeBarTarget, getResizeFrom, getRight, getRuleContext, getRuleContext, getRuleScope, getScrollbarSize, getScrollBottom, getScrollHeight, getScrollLeft, getScrollRight, getScrollTop, getScrollWidth, getShadowColor, getShadowDepth, getShadowHOffset, getShadowImage, getShadowOffset, getShadowSoftness, getShadowSpread, getShadowVOffset, getShouldPrint, getShowCustomScrollbars, getShowDragShadow, getShowEdges, getShowHover, getShowHoverComponents, getShowPointer, getShowResizeBar, getShowShadow, getShowSnapGrid, getShrinkElementOnHide, getSizeMayChangeOnRedraw, getSkinImgDir, getSnapAlignCandidates, getSnapAlignCenterLineStyle, getSnapAlignEdgeLineStyle, getSnapAxis, getSnapEdge, getSnapGridLineProperties, getSnapGridStyle, getSnapHDirection, getSnapHGap, getSnapOffsetLeft, getSnapOffsetTop, getSnapOnDrop, getSnapPosition, getSnapPosition, getSnapResizeToAlign, getSnapResizeToGrid, getSnapTo, getSnapToAlign, getSnapToCenterAlign, getSnapToEdgeAlign, getSnapToGrid, getSnapVDirection, getSnapVGap, getStartLine, getStyleName, getTabIndex, getTestDataContext, getTestInstance, getTitle, getTooltip, getTop, getTopAsString, getTopElement, getUISummary, getUpdateTabPositionOnDraw, getUpdateTabPositionOnReparent, getUseBackMask, getUseCSSShadow, getUseDragMask, getUseImageForSVG, getUseNativeDrag, getUseOpacityFilter, getUseTouchScrolling, getValuesManager, getValuesManagerAsString, getViewportHeight, getViewportWidth, getVisibility, getVisibleHeight, getVisibleWhen, getVisibleWidth, getVSnapPosition, getVSnapPosition, getWidth, getWidthAsString, getWorkflows, getZIndex, getZIndex, handleHover, hide, hideClickMask, hideClickMask, hideComponentMask, hideComponentMask, hideContextMenu, imgHTML, imgHTML, imgHTML, initComplete, intersects, isDirty, isDisabled, isFocused, isVisible, keyUp, layoutChildren, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, markForDestroy, markForRedraw, markForRedraw, moveAbove, moveBelow, moveBy, moveTo, onAttach, onDetach, pageScrollDown, pageScrollUp, parentResized, placeNear, placeNear, placeNear, print, print, print, print, printComponents, provideRuleContext, provideRuleContext, redraw, redraw, registerFontScaledPaddingStyles, removeChild, removeChild, removePeer, removePeer, removeRuleContext, removeSnapAlignCandidate, resizeAutoChildAttributes, resizeBy, resizeControls, resizeControlsTo, resizeFonts, resizeFonts, resizeFonts, resizeFontsTo, resizeIcons, resizePadding, resizePadding, resizeTo, resizeTo, revealChild, revealChild, scrollBy, scrollByPercent, scrollTo, scrollTo, scrollTo, scrollToBottom, scrollToLeft, scrollToPercent, scrollToRight, scrollToTop, sendToBack, setAccessKey, setAdaptHeightByCustomizer, setAdaptiveHeightPriority, setAdaptiveWidthPriority, setAdaptWidthByCustomizer, setAlign, setAllowExternalFilters, setAlwaysManageFocusNavigation, setAlwaysShowScrollbars, setAnimateAcceleration, setAnimateFadeTime, setAnimateHideAcceleration, setAnimateHideEffect, setAnimateHideTime, setAnimateMoveAcceleration, setAnimateMoveTime, setAnimateRectAcceleration, setAnimateRectTime, setAnimateResizeAcceleration, setAnimateResizeLayoutMode, setAnimateResizeTime, setAnimateScrollAcceleration, setAnimateScrollTime, setAnimateShowAcceleration, setAnimateShowEffect, setAnimateShowTime, setAnimateTime, setAppImgDir, setAriaRole, setAriaState, setAutoChildConstructor, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildVisibility, setAutoHeight, setAutoMaskComponents, setAutoParent, setAutoPopulateData, setAutoResizeAutoChildAttributes, setAutoResizeIcons, setAutoShowParent, setAutoWidth, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBorderRadius, setBottom, setCanAcceptDrop, setCanAdaptHeight, setCanAdaptWidth, setCanDrag, setCanDragReposition, setCanDragResize, setCanDragScroll, setCanDrop, setCanDropBefore, setCanFocus, setCanHover, setCanSelectText, setChildren, setChildrenResizeSnapAlign, setChildrenSnapAlign, setChildrenSnapCenterAlign, setChildrenSnapEdgeAlign, setChildrenSnapResizeToGrid, setChildrenSnapToGrid, setComponentMaskDefaults, setContents, setContextMenu, setCorrectZoomOverflow, setCursor, setDataContext, setDataPath, setDefaultHeight, setDefaultPageSpace, setDefaultProperties, setDefaultShowCustomScrollbars, setDefaultWidth, setDefiningProperty, setDefiningPropertyNameOptions, setDisabled, setDisabledCursor, setDisableTouchScrollingForDrag, setDoubleClickDelay, setDragAppearance, setDragIntersectStyle, setDragMaskType, setDragMaxHeight, setDragMaxWidth, setDragMinHeight, setDragMinWidth, setDragOpacity, setDragRepositionAppearance, setDragRepositionCursor, setDragResizeAppearance, setDragScrollDelay, setDragStartDistance, setDragTarget, setDragTarget, setDragType, setDropTarget, setDropTarget, setDropTypes, setDropTypes, setDynamicContents, setEdgeBackgroundColor, setEdgeCenterBackgroundColor, setEdgeImage, setEdgeMarginSize, setEdgeOffset, setEdgeOpacity, setEdgeShowCenter, setEdgeSize, setEditMode, setEditMode, setEditMode, setEditProxyConstructor, setElement, setEnableWhen, setEndLine, setExtraSpace, setFacetId, setFloatingScrollbars, setForwardSVGeventsToObject, setGroupBorderCSS, setGroupLabelBackgroundColor, setGroupLabelStyleName, setGroupPadding, setGroupTitle, setHeight, setHeight, setHeight, setHeight100, setHideUsingDisplayNone, setHoverAlign, setHoverAutoDestroy, setHoverAutoFitMaxWidth, setHoverAutoFitMaxWidth, setHoverAutoFitWidth, setHoverDelay, setHoverFocusKey, setHoverHeight, setHoverMoveWithMouse, setHoverOpacity, setHoverPersist, setHoverScreen, setHoverStyle, setHoverVAlign, setHoverWidth, setHoverWrap, setHtmlElement, setHtmlElement, setHtmlPosition, setImage, setImage, setInitHandler, setIsGroup, setIsRuleScope, setIsSnapAlignCandidate, setKeepInParentRect, setKeepInParentRect, setKeepInParentRect, setLayoutAlign, setLayoutAlign, setLeaveGroupLabelSpace, setLeavePageSpace, setLeft, setLeft, setLocateByIDOnly, setLocateChildrenBy, setLocateChildrenType, setLocatePeersBy, setLocatePeersType, setLocatorName, setLocatorParent, setLocatorParent, setLogicalStructure, setMargin, setMatchElement, setMatchElementHeight, setMatchElementWidth, setMaxHeight, setMaxWidth, setMaxZoomOverflowError, setMenuConstructor, setMinHeight, setMinNonEdgeSize, setMinWidth, setMomentumScrollMinSpeed, setMouseStillDownDelay, setMouseStillDownInitialDelay, setName, setNativeAutoHideScrollbars, setNeverUseFilters, setNoDoubleClicks, setNoDropCursor, setOpacity, setOverflow, setPadding, setPageLeft, setPageTop, setPanelContainer, setParentCanvas, setParentElement, setPeers, setPendingMarkerStyle, setPendingMarkerVisible, setPercentBox, setPercentSource, setPersistentMatchElement, setPointerSettings, setPointerTarget, setPosition, setPrefix, setPrintChildrenAbsolutelyPositioned, setPrintStyleName, setPrompt, setProportionalResizeModifiers, setProportionalResizing, setReceiveScrollbarEvents, setRect, setRect, setRedrawOnResize, setRelativeTabPosition, setResizeBarTarget, setResizeFrom, setResizeFrom, setRight, setRuleScope, setScrollbarConstructor, setScrollbarSize, setShadowColor, setShadowDepth, setShadowHOffset, setShadowImage, setShadowOffset, setShadowSoftness, setShadowSpread, setShadowVOffset, setShouldPrint, setShowCustomScrollbars, setShowDragShadow, setShowEdges, setShowHover, setShowHoverComponents, setShowPointer, setShowResizeBar, setShowShadow, setShowSnapGrid, setShrinkElementOnHide, setSizeMayChangeOnRedraw, setSkinImgDir, setSmoothFade, setSnapAlignCandidates, setSnapAlignCenterLineStyle, setSnapAlignEdgeLineStyle, setSnapAxis, setSnapEdge, setSnapGridLineProperties, setSnapGridStyle, setSnapHDirection, setSnapHGap, setSnapOffsetLeft, setSnapOffsetTop, setSnapOnDrop, setSnapResizeToAlign, setSnapResizeToGrid, setSnapTo, setSnapToAlign, setSnapToCenterAlign, setSnapToEdgeAlign, setSnapToGrid, setSnapVDirection, setSnapVGap, setStartLine, setStyleName, setTabIndex, setTestDataContext, setTitle, setTooltip, setTop, setTop, setUpdateTabPositionOnDraw, setUpdateTabPositionOnReparent, setUseBackMask, setUseCSSShadow, setUseDragMask, setUseImageForSVG, setUseNativeDrag, setUseOpacityFilter, setUseTouchScrolling, setValuesManager, setValuesManager, setVisibility, setVisible, setVisibleWhen, setWidth, setWidth, setWidth, setWidth100, setWorkflows, setZIndex, shouldDragScroll, show, showClickMask, showComponentMask, showComponentMask, showNextTo, showNextTo, showNextTo, showNextTo, showPendingMarker, showPrintPreview, showPrintPreview, showPrintPreview, showPrintPreview, showRecursively, startDebuggingOverflow, stopDebuggingOverflow, updateChildTabPosition, updateChildTabPositions, updateEditNode, updateHover, updateHover, updateShadow, updateTabPositionForDraw, visibleAtPoint, willAcceptDrop
Methods inherited from class com.smartgwt.client.widgets.BaseWidget
addDrawHandler, addDynamicProperty, addDynamicProperty, addDynamicProperty, addDynamicProperty, applyFactoryProperties, clearDynamicProperty, completeCreation, destroy, doAddHandler, doInit, doOnRender, draw, equals, error, errorIfNotCreated, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDateArray, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsFloatArray, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsObject, getAttributeAsRecord, getAttributeAsString, getAttributeAsStringArray, getConfig, getDOM, getHandlerCount, getID, getInnerHTML, getJsObj, getOrCreateJsObj, getRef, getScClassName, hasAutoAssignedID, hasDynamicProperty, hashCode, initNativeObject, internalSetID, internalSetID, isConfigOnly, isCreated, isDrawn, isFactoryCreated, onBind, onDestroy, onDraw, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setConfig, setConfigOnly, setDefaultProperties, setDragTracker, setFactoryCreated, setID, setJavaScriptObject, setLogicalStructure, setLogicalStructure, setNullProperty, setPosition, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setScClassName, toString
Methods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkBitlessEvent
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.smartgwt.client.widgets.DataBoundComponent
getOrCreateJsObj
Methods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEvent
-
Constructor Details
-
Calendar
public Calendar() -
Calendar
-
-
Method Details
-
getOrCreateRef
-
changeAutoChildDefaults
Changes the defaults for Canvas AutoChildren namedautoChildName
.- Parameters:
autoChildName
- name of an AutoChild to customize the defaults for.defaults
- Canvas defaults to apply. These defaults override any existing properties without destroying or wiping out non-overridden properties. For usage tips on this param, seeSGWTProperties
.- See Also:
-
changeAutoChildDefaults
Changes the defaults for FormItem AutoChildren namedautoChildName
.- Parameters:
autoChildName
- name of an AutoChild to customize the defaults for.defaults
- FormItem defaults to apply. These defaults override any existing properties without destroying or wiping out non-overridden properties. For usage tips on this param, seeSGWTProperties
.- See Also:
-
create
-
getAddEventButton
AnImgButton
that appears in a Calendar's week/day/month views and offers an alternative way to create a newevent
.This component is an AutoChild named "addEventButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current addEventButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setAddEventButtonHoverText
public Calendar setAddEventButtonHoverText(String addEventButtonHoverText) throws IllegalStateException The text to be displayed when a user hovers over theadd event
toolbar button- Parameters:
addEventButtonHoverText
- New addEventButtonHoverText value. Default value is "Add an event"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getAddEventButtonHoverText
The text to be displayed when a user hovers over theadd event
toolbar button- Returns:
- Current addEventButtonHoverText value. Default value is "Add an event"
-
setAllowDurationEvents
When set to true, allows events to be managed by duration, as well as by end date. Values can be set forduration
andduration unit
on each event, and are then maintained, instead of the end date, when alterations are made to the event via editors or dragging with the mouse.- Parameters:
allowDurationEvents
- New allowDurationEvents value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getAllowDurationEvents
When set to true, allows events to be managed by duration, as well as by end date. Values can be set forduration
andduration unit
on each event, and are then maintained, instead of the end date, when alterations are made to the event via editors or dragging with the mouse.- Returns:
- Current allowDurationEvents value. Default value is null
- See Also:
-
setAlternateLaneStyles
When showing aTimeline
, or aday view
whenshowDayLanes
is true, whether to make lane boundaries more obvious by showing alternate lanes in a different color.- Parameters:
alternateLaneStyles
- New alternateLaneStyles value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getAlternateLaneStyles
When showing aTimeline
, or aday view
whenshowDayLanes
is true, whether to make lane boundaries more obvious by showing alternate lanes in a different color.- Returns:
- Current alternateLaneStyles value. Default value is null
-
setAlwaysShowEventHovers
By default, EventCanvases show their content in hovers. If you set this attribute to false, hovers will only be shown if the content of the event-canvas is visually clipped.Note - if you have custom hover-content/handling, you should leave this property set to true.
- Parameters:
alwaysShowEventHovers
- New alwaysShowEventHovers value. Default value is true- Returns:
Calendar
instance, for chaining setter calls
-
getAlwaysShowEventHovers
By default, EventCanvases show their content in hovers. If you set this attribute to false, hovers will only be shown if the content of the event-canvas is visually clipped.Note - if you have custom hover-content/handling, you should leave this property set to true.
- Returns:
- Current alwaysShowEventHovers value. Default value is true
-
setBackButtonIconSrc
The icon to show in themonth-button
on Handsets when themonth view
is the current visible view.- Parameters:
backButtonIconSrc
- New backButtonIconSrc value. Default value is "Chevron_Left"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getBackButtonIconSrc
The icon to show in themonth-button
on Handsets when themonth view
is the current visible view.- Returns:
- Current backButtonIconSrc value. Default value is "Chevron_Left"
- See Also:
-
setBackButtonTitle
The title of themonth
on Handsets when themonth view
is the current visible view.When the month view is not the current visible view, the title for the month button is set according to the value of
monthButtonTitle
.- Parameters:
backButtonTitle
- New backButtonTitle value. Default value is "Back"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getBackButtonTitle
The title of themonth
on Handsets when themonth view
is the current visible view.When the month view is not the current visible view, the title for the month button is set according to the value of
monthButtonTitle
.- Returns:
- Current backButtonTitle value. Default value is "Back"
- See Also:
-
setBaseStyle
The base name for the CSS class applied to the grid cells of the day and week views of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Parameters:
baseStyle
- New baseStyle value. Default value is "calendar"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getBaseStyle
The base name for the CSS class applied to the grid cells of the day and week views of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Returns:
- Current baseStyle value. Default value is "calendar"
- See Also:
-
setBringEventsToFront
If set to true, clicking an event will bring it to the front of the zorder.- Parameters:
bringEventsToFront
- New bringEventsToFront value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getBringEventsToFront
If set to true, clicking an event will bring it to the front of the zorder.- Returns:
- Current bringEventsToFront value. Default value is null
-
setCalMonthEventLinkStyle
The base name for the CSS class applied to the links rendered bygetDayBodyHTML()
.These links are rendered as plain HTML links using A elements, and the CSS style in the provided skins references the pseudo-classes :link, :visited, :active, :hover.
Even though it goes against the general policy of not exposing the HTML structures SC writes out and not relying on them for styling, applying style to these particular selectors is acceptable, as we're unlikely to use any other kind of HTML structure than a link.- Parameters:
calMonthEventLinkStyle
- New calMonthEventLinkStyle value. Default value is "calMonthEventLink"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getCalMonthEventLinkStyle
The base name for the CSS class applied to the links rendered bygetDayBodyHTML()
.These links are rendered as plain HTML links using A elements, and the CSS style in the provided skins references the pseudo-classes :link, :visited, :active, :hover.
Even though it goes against the general policy of not exposing the HTML structures SC writes out and not relying on them for styling, applying style to these particular selectors is acceptable, as we're unlikely to use any other kind of HTML structure than a link.- Returns:
- Current calMonthEventLinkStyle value. Default value is "calMonthEventLink"
- See Also:
-
getCancelButton
Ancom.smartgwt.client.types.AutoChild
of typeIButton
, used to cancel editing of an event and close theeventEditor
.This component is an AutoChild named "cancelButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current cancelButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setCancelButtonTitle
The title for theCancel button
in theevent editor
.- Parameters:
cancelButtonTitle
- New cancelButtonTitle value. Default value is "Cancel"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCancelButtonTitle
The title for theCancel button
in theevent editor
.- Returns:
- Current cancelButtonTitle value. Default value is "Cancel"
- See Also:
-
setCanCreateEvents
If true, users can create new events.- Parameters:
canCreateEvents
- New canCreateEvents value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanCreateEvents
If true, users can create new events.- Returns:
- Current canCreateEvents value. Default value is true
-
setCanCreateOtherDayEvents
WhenshowOtherDays
is true, determines whether clicking in a Month-view body-cell that represents a date outside the selected month will open theevent-editor window
at the cell's location.Note that, when
otherDayClickNavigation
is also true, the Month-view first switches to the month of the clicked date before displaying the event-editor. This causes the editor to open in a different cell than the one clicked and may be unexpected to users.- Parameters:
canCreateOtherDayEvents
- New canCreateOtherDayEvents value. Default value is false- Returns:
Calendar
instance, for chaining setter calls
-
getCanCreateOtherDayEvents
WhenshowOtherDays
is true, determines whether clicking in a Month-view body-cell that represents a date outside the selected month will open theevent-editor window
at the cell's location.Note that, when
otherDayClickNavigation
is also true, the Month-view first switches to the month of the clicked date before displaying the event-editor. This causes the editor to open in a different cell than the one clicked and may be unexpected to users.- Returns:
- Current canCreateOtherDayEvents value. Default value is false
-
setCanDeleteEvents
Deprecated.in favor ofcanRemoveEvents
If true, users can delete existing events. Defaults tocanEditEvents
.- Parameters:
canDeleteEvents
- New canDeleteEvents value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanDeleteEvents
Deprecated.in favor ofcanRemoveEvents
If true, users can delete existing events. Defaults tocanEditEvents
.- Returns:
- Current canDeleteEvents value. Default value is null
-
setCanDragCreateEvents
A boolean value controlling whether new events of varying length can be created by dragging the cursor. By default, this is false for Touch devices and true otherwise.- Parameters:
canDragCreateEvents
- New canDragCreateEvents value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getCanDragCreateEvents
A boolean value controlling whether new events of varying length can be created by dragging the cursor. By default, this is false for Touch devices and true otherwise.- Returns:
- Current canDragCreateEvents value. Default value is null
-
setCanDragEventField
Name of the field on eachCalendarEvent
that determines whether anEventCanvas
can be moved or resized by dragging with the mouse. Note thatcanEditEvents
must be true for dragging to be allowed.- Parameters:
canDragEventField
- New canDragEventField value. Default value is "canDrag"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanDragEventField
Name of the field on eachCalendarEvent
that determines whether anEventCanvas
can be moved or resized by dragging with the mouse. Note thatcanEditEvents
must be true for dragging to be allowed.- Returns:
- Current canDragEventField value. Default value is "canDrag"
- See Also:
-
setCanDragEvents
A boolean value controlling whether users can drag-reposition events. By default, this is false for Touch devices, where drag gestures scroll the view, and true otherwise.Only has an effect when
canEditEvents
is true.- Parameters:
canDragEvents
- New canDragEvents value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanDragEvents
A boolean value controlling whether users can drag-reposition events. By default, this is false for Touch devices, where drag gestures scroll the view, and true otherwise.Only has an effect when
canEditEvents
is true.- Returns:
- Current canDragEvents value. Default value is null
-
setCanEditEvents
If true, users can edit existing events.- Parameters:
canEditEvents
- New canEditEvents value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanEditEvents
If true, users can edit existing events.- Returns:
- Current canEditEvents value. Default value is true
-
setCanEditField
Name of the field on eachCalendarEvent
that determines whether it can be edited in theevent editor
. Note that an event withcanEdit
set to true can also havecanDrag
orcanResize
set to false, which would still allow editing, but not via drag operations.- Parameters:
canEditField
- New canEditField value. Default value is "canEdit"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanEditField
Name of the field on eachCalendarEvent
that determines whether it can be edited in theevent editor
. Note that an event withcanEdit
set to true can also havecanDrag
orcanResize
set to false, which would still allow editing, but not via drag operations.- Returns:
- Current canEditField value. Default value is "canEdit"
- See Also:
-
setCanEditLane
Can events be moved between lanes? If so, the event can be dragged to a differentlane
, and the eventquick dialog
andeditor
allow a lane to be selected with a drop-down chooser.In either case, the event's
laneNameField
is updated automatically.If set to false, cross-lane dragging is disallowed and drop-down Lane-choosers are disabled when editing existng events. When creating
new events
, the Lane-chooser remains enabled so an initial Lane can be selected.This setting can be overridden on each
event
.- Parameters:
canEditLane
- New canEditLane value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanEditLane
Can events be moved between lanes? If so, the event can be dragged to a differentlane
, and the eventquick dialog
andeditor
allow a lane to be selected with a drop-down chooser.In either case, the event's
laneNameField
is updated automatically.If set to false, cross-lane dragging is disallowed and drop-down Lane-choosers are disabled when editing existng events. When creating
new events
, the Lane-chooser remains enabled so an initial Lane can be selected.This setting can be overridden on each
event
.- Returns:
- Current canEditLane value. Default value is null
-
setCanEditLaneField
Name of the field on eachCalendarEvent
that determines whether that event can be moved between lanes.- Parameters:
canEditLaneField
- New canEditLaneField value. Default value is "canEditLane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanEditLaneField
Name of the field on eachCalendarEvent
that determines whether that event can be moved between lanes.- Returns:
- Current canEditLaneField value. Default value is "canEditLane"
- See Also:
-
setCanEditSublane
Can events be moved between sublanes?If so, the event can be dragged to a different
sublane
within the same parent Lane and, when it's editor is shown, an additional drop-down widget is provided allowing the sublane to be altered.If the sublane is locked, but the
parent lane
isn't, an update to the event'slane name
will be allowed, assuming that the new Lane has an existing sublane with the same name.In either case, the event's
sublane
is updated automatically.This setting can be overridden on each
event
.- Parameters:
canEditSublane
- New canEditSublane value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanEditSublane
Can events be moved between sublanes?If so, the event can be dragged to a different
sublane
within the same parent Lane and, when it's editor is shown, an additional drop-down widget is provided allowing the sublane to be altered.If the sublane is locked, but the
parent lane
isn't, an update to the event'slane name
will be allowed, assuming that the new Lane has an existing sublane with the same name.In either case, the event's
sublane
is updated automatically.This setting can be overridden on each
event
.- Returns:
- Current canEditSublane value. Default value is null
-
setCanEditSublaneField
Name of the field on eachCalendarEvent
that determines whether that event can be moved between individualsublanes
in aLane
.- Parameters:
canEditSublaneField
- New canEditSublaneField value. Default value is "canEditSublane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanEditSublaneField
Name of the field on eachCalendarEvent
that determines whether that event can be moved between individualsublanes
in aLane
.- Returns:
- Current canEditSublaneField value. Default value is "canEditSublane"
- See Also:
-
setCanGroupLanes
If true, allows the lanes in a Timeline to be grouped by providing a value forlaneGroupByField
. The fields available for grouping on are those defined aslane fields
. Since these are definitions fornormal fields
, you can choose tohide
the field in the timeline, but still have it available for grouping.- Parameters:
canGroupLanes
- New canGroupLanes value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getCanGroupLanes
If true, allows the lanes in a Timeline to be grouped by providing a value forlaneGroupByField
. The fields available for grouping on are those defined aslane fields
. Since these are definitions fornormal fields
, you can choose tohide
the field in the timeline, but still have it available for grouping.- Returns:
- Current canGroupLanes value. Default value is null
-
setCanRemoveEvents
If true, users can remove existing events. Defaults tocanEditEvents
.- Parameters:
canRemoveEvents
- New canRemoveEvents value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanRemoveEvents
If true, users can remove existing events. Defaults tocanEditEvents
.- Returns:
- Current canRemoveEvents value. Default value is true
-
setCanRemoveField
Name of the field on eachCalendarEvent
that determines whether an event shows a remove button.- Parameters:
canRemoveField
- New canRemoveField value. Default value is "canRemove"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanRemoveField
Name of the field on eachCalendarEvent
that determines whether an event shows a remove button.- Returns:
- Current canRemoveField value. Default value is "canRemove"
- See Also:
-
setCanReorderLanes
If true, lanes can be reordered by dragging theirlaneFields
with the mouse.- Parameters:
canReorderLanes
- New canReorderLanes value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanReorderLanes
If true, lanes can be reordered by dragging theirlaneFields
with the mouse.- Returns:
- Current canReorderLanes value. Default value is null
-
setCanResizeEventField
Name of the field on eachCalendarEvent
that determines whether an event can be resized by dragging.- Parameters:
canResizeEventField
- New canResizeEventField value. Default value is "canResize"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getCanResizeEventField
Name of the field on eachCalendarEvent
that determines whether an event can be resized by dragging.- Returns:
- Current canResizeEventField value. Default value is "canResize"
- See Also:
-
setCanResizeEvents
Canevents
be resized by dragging appropriate edges of thecanvas
? Only has an effect when bothcanEditEvents
andcanDragEvents
are true. Set this attribute to false to disallow drag-resizing.Always false when
showColumnLayouts
is true.- Parameters:
canResizeEvents
- New canResizeEvents value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanResizeEvents
Canevents
be resized by dragging appropriate edges of thecanvas
? Only has an effect when bothcanEditEvents
andcanDragEvents
are true. Set this attribute to false to disallow drag-resizing.Always false when
showColumnLayouts
is true.- Returns:
- Current canResizeEvents value. Default value is true
-
setCanResizeTimelineEvents
public Calendar setCanResizeTimelineEvents(Boolean canResizeTimelineEvents) throws IllegalStateException Deprecated.in favor ofcanResizeEvents
;CanTimeline
events be stretched by their left and right edges?- Parameters:
canResizeTimelineEvents
- New canResizeTimelineEvents value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanResizeTimelineEvents
Deprecated.in favor ofcanResizeEvents
;CanTimeline
events be stretched by their left and right edges?- Returns:
- Current canResizeTimelineEvents value. Default value is false
-
setCanSelectEvents
When set to true, makes individualevent canvases
selectable. Events may be selected via a single click, as well as being included in the page's tab order. The current selected event is shown in a special style and pressing TAB or Shift-TAB will move the selection first among the events in the same lane, and then among those in the next or previous lane.Pressing Enter while an editable event is selected will show either the event-
dialog
oreditor
. Pressing Delete will remove the event.Note that when this property is false, single clicking the event canvas for an editable event will bring up an editing interface for that event. When true this is no longer the case - a user can double click to bring up the editing interface instead (a single click will simply select the event canvas).
- Parameters:
canSelectEvents
- New canSelectEvents value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getCanSelectEvents
When set to true, makes individualevent canvases
selectable. Events may be selected via a single click, as well as being included in the page's tab order. The current selected event is shown in a special style and pressing TAB or Shift-TAB will move the selection first among the events in the same lane, and then among those in the next or previous lane.Pressing Enter while an editable event is selected will show either the event-
dialog
oreditor
. Pressing Delete will remove the event.Note that when this property is false, single clicking the event canvas for an editable event will bring up an editing interface for that event. When true this is no longer the case - a user can double click to bring up the editing interface instead (a single click will simply select the event canvas).
- Returns:
- Current canSelectEvents value. Default value is null
-
setChosenDate
The date for which events are displayed in the day, week, and month tabs of the calendar. Default is today.
If this method is called after the component has been drawn/initialized: Set the current date for which the calendar will display events.- Parameters:
chosenDate
- the new date to set as the current date. Default value is 'Today'- Returns:
Calendar
instance, for chaining setter calls
-
getChosenDate
The date for which events are displayed in the day, week, and month tabs of the calendar. Default is today.- Returns:
- Current chosenDate value. Default value is 'Today'
-
getColumnLayout
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.When
showColumnLayouts
is true, the layouts added to each column to stack events.- Returns:
- null
-
setColumnsPerPage
When using the Next and Previous arrows to scroll a Timeline, this is the number of columns of thetimelineGranularity
to scroll by. With the default value of null, the Timeline will scroll by its current length.- Parameters:
columnsPerPage
- New columnsPerPage value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getColumnsPerPage
When using the Next and Previous arrows to scroll a Timeline, this is the number of columns of thetimelineGranularity
to scroll by. With the default value of null, the Timeline will scroll by its current length.- Returns:
- Current columnsPerPage value. Default value is null
-
setControlBarIconBaseStyle
public Calendar setControlBarIconBaseStyle(String controlBarIconBaseStyle) throws IllegalStateException A CSS style to apply to icons in thecontrolsBar
. This is a base style supporting suffixes for states, specifically "Over", "Down" and "Disabled", which are applied whenImgButton
settings likeImgButton.showRollOverIcon
are applied to the icons.- Parameters:
controlBarIconBaseStyle
- New controlBarIconBaseStyle value. Default value is "icon"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getControlBarIconBaseStyle
A CSS style to apply to icons in thecontrolsBar
. This is a base style supporting suffixes for states, specifically "Over", "Down" and "Disabled", which are applied whenImgButton
settings likeImgButton.showRollOverIcon
are applied to the icons.- Returns:
- Current controlBarIconBaseStyle value. Default value is "icon"
- See Also:
-
setControlBarIconSize
The size of the various icons displayed in thecontrolsBar
of this Calendar.- Parameters:
controlBarIconSize
- New controlBarIconSize value. Default value is 16- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getControlBarIconSize
The size of the various icons displayed in thecontrolsBar
of this Calendar.- Returns:
- Current controlBarIconSize value. Default value is 16
-
getControlsBar
AnHLayout
shown above the Calendar views and displaying a set of controls for interacting with the current view - namely, thenext
,previous
andadd
buttons, thedate label
and thedate-picker
icon.This component is an AutoChild named "controlsBar". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current controlsBar value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setControlsBarHeight
Default height of thecontrolsBar
shown above the main Calendar grid. When multiple views are available and tabs are visible, this value is modified to ensure that the content of thecontrolsBar
is vertically-aligned with the text in the tabs.- Parameters:
controlsBarHeight
- New controlsBarHeight value. Default value is 30- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getControlsBarHeight
Default height of thecontrolsBar
shown above the main Calendar grid. When multiple views are available and tabs are visible, this value is modified to ensure that the content of thecontrolsBar
is vertically-aligned with the text in the tabs.- Returns:
- Current controlsBarHeight value. Default value is 30
-
setCurrentViewName
The name of the view that should be visible initially by default.
If this method is called after the component has been drawn/initialized: Sets the currently visible view.- Parameters:
currentViewName
- The name of the view that should be made visible. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getCurrentViewName
The name of the view that should be visible initially by default.- Returns:
- Get the name of the visible view. Returns one of 'day', 'week', 'month' or 'timeline'. Default value is null
-
setData
A List of CalendarEvent objects, specifying the data to be used to populate the calendar.This property will typically not be explicitly specified for databound Calendars, where the data is returned from the server via databound component methods such as
fetchData()
. In this case the data objects will be set to aresultSet
rather than a simple array.
If this method is called after the component has been drawn/initialized: Initialize the data object with the given array. Observes methods of the data object so that when the data changes, the calendar will redraw automatically.- Parameters:
data
- data to show in the list. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getData
A List of CalendarEvent objects, specifying the data to be used to populate the calendar.This property will typically not be explicitly specified for databound Calendars, where the data is returned from the server via databound component methods such as
fetchData()
. In this case the data objects will be set to aresultSet
rather than a simple array.- Returns:
- Current data value. Default value is null
- See Also:
-
setDataFetchMode
How to fetch and manage records retrieve from the server. SeeFetchMode
.This setting only applies to the
ResultSet
automatically created by callingfetchData()
. If a pre-existing ResultSet is passed to setData() instead, it's existing setting forResultSet.fetchMode
applies.- Specified by:
setDataFetchMode
in interfaceDataBoundComponent
- Parameters:
dataFetchMode
- New dataFetchMode value. Default value is "basic"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getDataFetchMode
How to fetch and manage records retrieve from the server. SeeFetchMode
.This setting only applies to the
ResultSet
automatically created by callingfetchData()
. If a pre-existing ResultSet is passed to setData() instead, it's existing setting forResultSet.fetchMode
applies.- Specified by:
getDataFetchMode
in interfaceDataBoundComponent
- Returns:
- Current dataFetchMode value. Default value is "basic"
- See Also:
-
setDataSource
The DataSource that this component should bind to for default fields and for performingDataSource requests
.Can be specified as either a DataSource instance or the String ID of a DataSource.
- Specified by:
setDataSource
in interfaceDataBoundComponent
- Parameters:
dataSource
- New dataSource value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
setDataSource
The DataSource that this component should bind to for default fields and for performingDataSource requests
.Can be specified as either a DataSource instance or the String ID of a DataSource.
- Specified by:
setDataSource
in interfaceDataBoundComponent
- Parameters:
dataSource
- New dataSource value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getDateChooser
DateChooser
used to select the date for which events will be displayed.This component is an AutoChild named "dateChooser". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current dateChooser value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setDateEditingStyle
Indicates the type of controls to use in event-windows. Valid values are those in theDateEditingStyle
type.If unset, the editing style will be set to the field-type on the DataSource, if there is one. If there's no DataSource, it will be set to "date" if the
granularity
is "day" or larger and "time" if granularity is "minute" or smaller, otherwise "datetime".- Parameters:
dateEditingStyle
- New dateEditingStyle value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDateEditingStyle
Indicates the type of controls to use in event-windows. Valid values are those in theDateEditingStyle
type.If unset, the editing style will be set to the field-type on the DataSource, if there is one. If there's no DataSource, it will be set to "date" if the
granularity
is "day" or larger and "time" if granularity is "minute" or smaller, otherwise "datetime".- Returns:
- Current dateEditingStyle value. Default value is null
-
setDateFormatter
Date formatter for displaying events. Default is to use the system-wide default short date format, configured viaDateUtil.setShortDisplayFormat()
. Specify any validDateDisplayFormat
.- Parameters:
dateFormatter
- New dateFormatter value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getDateFormatter
Date formatter for displaying events. Default is to use the system-wide default short date format, configured viaDateUtil.setShortDisplayFormat()
. Specify any validDateDisplayFormat
.- Returns:
- Current dateFormatter value. Default value is null
-
getDateLabel
Thecom.smartgwt.client.types.AutoChild
Label
used to display the current date or range above the selected calendar view.This component is an AutoChild named "dateLabel". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current dateLabel value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getDatePickerButton
AnImgButton
that appears above the various views of the calendar and offers alternative access to aDateChooser
to pick the current day.This component is an AutoChild named "datePickerButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current datePickerButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setDatePickerHoverText
The text to be displayed when a user hovers over thedate picker
toolbar button- Parameters:
datePickerHoverText
- New datePickerHoverText value. Default value is "Choose a date"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDatePickerHoverText
The text to be displayed when a user hovers over thedate picker
toolbar button- Returns:
- Current datePickerHoverText value. Default value is "Choose a date"
-
setDayBodyBaseStyle
The base name for the CSS class applied to the day body of the month view of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Parameters:
dayBodyBaseStyle
- New dayBodyBaseStyle value. Default value is "calMonthDayBody"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getDayBodyBaseStyle
The base name for the CSS class applied to the day body of the month view of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Returns:
- Current dayBodyBaseStyle value. Default value is "calMonthDayBody"
- See Also:
-
setDayHeaderBaseStyle
The base name for the CSS class applied to the day headers of the month view. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Parameters:
dayHeaderBaseStyle
- New dayHeaderBaseStyle value. Default value is "calMonthDayHeader"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getDayHeaderBaseStyle
The base name for the CSS class applied to the day headers of the month view. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Returns:
- Current dayHeaderBaseStyle value. Default value is "calMonthDayHeader"
- See Also:
-
getDayView
CalendarView
used to display events that pertain to a given day.This component is an AutoChild named "dayView". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current dayView value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setDayViewTitle
The title for theday view
.- Parameters:
dayViewTitle
- New dayViewTitle value. Default value is "Day"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDayViewTitle
The title for theday view
.- Returns:
- Current dayViewTitle value. Default value is "Day"
-
setDefaultTimelineColumnSpan
public Calendar setDefaultTimelineColumnSpan(int defaultTimelineColumnSpan) throws IllegalStateException The number of columns of thetimelineGranularity
to give the timeline by default if noendDate
is provided. The default is 20.- Parameters:
defaultTimelineColumnSpan
- New defaultTimelineColumnSpan value. Default value is 20- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDefaultTimelineColumnSpan
public int getDefaultTimelineColumnSpan()The number of columns of thetimelineGranularity
to give the timeline by default if noendDate
is provided. The default is 20.- Returns:
- Current defaultTimelineColumnSpan value. Default value is 20
-
setDescriptionField
The name of the description field on aCalendarEvent
.- Parameters:
descriptionField
- New descriptionField value. Default value is "description"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDescriptionField
The name of the description field on aCalendarEvent
.- Returns:
- Current descriptionField value. Default value is "description"
-
setDetailsButtonTitle
The title for the edit button in the quickquick event dialog
.- Parameters:
detailsButtonTitle
- New detailsButtonTitle value. Default value is "Edit Details"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getDetailsButtonTitle
The title for the edit button in the quickquick event dialog
.- Returns:
- Current detailsButtonTitle value. Default value is "Edit Details"
- See Also:
-
setDisableWeekends
If true, weekend days appear in a disabled style and events cannot be created on weekends. Which days are considered weekends is controlled byweekendDays
.- Parameters:
disableWeekends
- New disableWeekends value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getDisableWeekends
If true, weekend days appear in a disabled style and events cannot be created on weekends. Which days are considered weekends is controlled byweekendDays
.- Returns:
- Current disableWeekends value. Default value is true
- See Also:
-
setDurationField
The name of theduration
field on aCalendarEvent
.- Parameters:
durationField
- New durationField value. Default value is "duration"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getDurationField
The name of theduration
field on aCalendarEvent
.- Returns:
- Current durationField value. Default value is "duration"
- See Also:
-
setDurationUnitField
The name of thedurationUnit
field on aCalendarEvent
.- Parameters:
durationUnitField
- New durationUnitField value. Default value is "durationUnit"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getDurationUnitField
The name of thedurationUnit
field on aCalendarEvent
.- Returns:
- Current durationUnitField value. Default value is "durationUnit"
- See Also:
-
setEndDate
The end date of the calendar timeline view. Has no effect in other views.To set different
start
and end dates after initial draw, seesetTimelineRange
.Note that the value you provide may be automatically altered if showing
header-levels
, to fit to header boundaries.- Parameters:
endDate
- New endDate value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEndDate
The end date of the calendar timeline view. Has no effect in other views.To set different
start
and end dates after initial draw, seesetTimelineRange
.Note that the value you provide may be automatically altered if showing
header-levels
, to fit to header boundaries.- Returns:
- Current endDate value. Default value is null
-
setEndDateField
The name of the end date field on aCalendarEvent
.- Parameters:
endDateField
- New endDateField value. Default value is "endDate"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEndDateField
The name of the end date field on aCalendarEvent
.- Returns:
- Current endDateField value. Default value is "endDate"
- See Also:
-
setEventAutoArrange
If set to true, enables the auto-arrangement of events that share time in the calendar. The default is true.- Parameters:
eventAutoArrange
- New eventAutoArrange value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventAutoArrange
If set to true, enables the auto-arrangement of events that share time in the calendar. The default is true.- Returns:
- Current eventAutoArrange value. Default value is true
-
getEventCanvas
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.To display events in
day
,week
andtimeline
views, the Calendar creates instances ofEventCanvas
for each event. Use thecom.smartgwt.client.types.AutoChild
system to customize these canvases.- Returns:
- null
-
getEventCanvasButtonLayout
HLayout that snaps to the top-right of an event canvas on rollover and contains theclose
and/orcontext
buttons.This component is an AutoChild named "eventCanvasButtonLayout". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventCanvasButtonLayout value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getEventCanvasCloseButton
The close button that snaps to the top-right of an event canvas on rollover and allows an event to be removed from aCalendarView
.This component is an AutoChild named "eventCanvasCloseButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventCanvasCloseButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setEventCanvasCloseButtonSize
public Calendar setEventCanvasCloseButtonSize(Integer eventCanvasCloseButtonSize) throws IllegalStateException The size of theclose-button
that snaps to the top-right of an event canvas on rollover and shows allows an event to be removed from aCalendarView
.- Parameters:
eventCanvasCloseButtonSize
- New eventCanvasCloseButtonSize value. Default value is 16- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventCanvasCloseButtonSize
The size of theclose-button
that snaps to the top-right of an event canvas on rollover and shows allows an event to be removed from aCalendarView
.- Returns:
- Current eventCanvasCloseButtonSize value. Default value is 16
-
setEventCanvasCloseIconSize
public Calendar setEventCanvasCloseIconSize(Integer eventCanvasCloseIconSize) throws IllegalStateException The size of the icon in theclose-button
floated over events on rollover.- Parameters:
eventCanvasCloseIconSize
- New eventCanvasCloseIconSize value. Default value is 13- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventCanvasCloseIconSize
The size of the icon in theclose-button
floated over events on rollover.- Returns:
- Current eventCanvasCloseIconSize value. Default value is 13
-
getEventCanvasComponent
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.Multi-AutoChild component, created as a space-filling member in individual
event-canvases
, whenshowEventCanvasComponents
is true. -
getEventCanvasContextButton
The context button that snaps to the top-right of an event canvas on rollover and shows a customcontext menu
when clicked.This component is an AutoChild named "eventCanvasContextButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventCanvasContextButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getEventCanvasContextMenu
Context menu displayed when anevent canvas
is right-clicked, or when the rollovercontext button
is clicked. The context button, and the menu itself, will only be displayed ifgetEventCanvasMenuItems
returns an array of appropriate items for the event.This component is an AutoChild named "eventCanvasContextMenu". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventCanvasContextMenu value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getEventCanvasGripper
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.The "gripper" widget that snaps to the top of an event canvas and allows an event to be dragged with the mouse.
- Returns:
- null
-
getEventCanvasHResizer
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.The resizer image that snaps to the left and right edges of an editable event canvas in a
Timeline
, allowing it to be resized horizontally by dragging with the mouse.- Returns:
- null
-
getEventCanvasLabel
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.- Returns:
- null
-
getEventCanvasVResizer
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.The resizer image that snaps to the bottom of event canvases in
day
andweek
views, allowing them to be resized vertically by dragging with the mouse.- Returns:
- null
-
setEventDescriptionFieldTitle
public Calendar setEventDescriptionFieldTitle(String eventDescriptionFieldTitle) throws IllegalStateException - Parameters:
eventDescriptionFieldTitle
- New eventDescriptionFieldTitle value. Default value is "Description"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventDescriptionFieldTitle
- Returns:
- Current eventDescriptionFieldTitle value. Default value is "Description"
- See Also:
-
getEventDialog
Ancom.smartgwt.client.types.AutoChild
of typeWindow
that displays a quick event entry form in a popup window.This component is an AutoChild named "eventDialog". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventDialog value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setEventDragGap
The number of pixels to leave to the right of events so overlapping events can still be added using the mouse.- Parameters:
eventDragGap
- New eventDragGap value. Default value is 10- Returns:
Calendar
instance, for chaining setter calls
-
getEventDragGap
The number of pixels to leave to the right of events so overlapping events can still be added using the mouse.- Returns:
- Current eventDragGap value. Default value is 10
-
setEventDurationFieldTitle
public Calendar setEventDurationFieldTitle(String eventDurationFieldTitle) throws IllegalStateException - Parameters:
eventDurationFieldTitle
- New eventDurationFieldTitle value. Default value is "Duration"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventDurationFieldTitle
- Returns:
- Current eventDurationFieldTitle value. Default value is "Duration"
- See Also:
-
setEventDurationUnitFieldTitle
public Calendar setEventDurationUnitFieldTitle(String eventDurationUnitFieldTitle) throws IllegalStateException - Parameters:
eventDurationUnitFieldTitle
- New eventDurationUnitFieldTitle value. Default value is " "- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventDurationUnitFieldTitle
- Returns:
- Current eventDurationUnitFieldTitle value. Default value is " "
- See Also:
-
getEventEditor
Ancom.smartgwt.client.types.AutoChild
of typeDynamicForm
which displaysevent data
. This form is created within theevent editor layout
This component is an AutoChild named "eventEditor". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventEditor value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getEventEditorButtonLayout
Ancom.smartgwt.client.types.AutoChild
of typeHLayout
which houses theSave
,Remove
andCancel
buttons in theeventEditor
.This component is an AutoChild named "eventEditorButtonLayout". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventEditorButtonLayout value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setEventEditorButtons
The list of buttons to include in theeventEditor
. Entries can be the names of the builtin buttons,saveButton
,removeButton
andcancelButton
, or the names of customautoChildren
that have been defined on the Calendar instance, or widget instances that already exist.The default is to show the builtin buttons.
- Parameters:
eventEditorButtons
- New eventEditorButtons value. Default value is (see below)- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventEditorButtons
The list of buttons to include in theeventEditor
. Entries can be the names of the builtin buttons,saveButton
,removeButton
andcancelButton
, or the names of customautoChildren
that have been defined on the Calendar instance, or widget instances that already exist.The default is to show the builtin buttons.
- Returns:
- Current eventEditorButtons value. Default value is (see below)
-
setEventEditorDateFieldTitle
public Calendar setEventEditorDateFieldTitle(String eventEditorDateFieldTitle) throws IllegalStateException The title for the Date-field in theeventEditor
that allows for changing the logical start-date of an event, along with its start and end times, when editing events in theday
andweek
views.- Parameters:
eventEditorDateFieldTitle
- New eventEditorDateFieldTitle value. Default value is "Date"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventEditorDateFieldTitle
The title for the Date-field in theeventEditor
that allows for changing the logical start-date of an event, along with its start and end times, when editing events in theday
andweek
views.- Returns:
- Current eventEditorDateFieldTitle value. Default value is "Date"
- See Also:
-
getEventEditorLayout
Ancom.smartgwt.client.types.AutoChild
of typeWindow
that displays the fullevent editor
This component is an AutoChild named "eventEditorLayout". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current eventEditorLayout value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setEventEndDateFieldTitle
public Calendar setEventEndDateFieldTitle(String eventEndDateFieldTitle) throws IllegalStateException - Parameters:
eventEndDateFieldTitle
- New eventEndDateFieldTitle value. Default value is "To"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventEndDateFieldTitle
- Returns:
- Current eventEndDateFieldTitle value. Default value is "To"
- See Also:
-
setEventHeaderHeight
WheneventHeaderWrap
is false andshowEventDescriptions
is true, this is the fixed height for theheader area
in event canvases.- Parameters:
eventHeaderHeight
- New eventHeaderHeight value. Default value is 14- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventHeaderHeight
public int getEventHeaderHeight()WheneventHeaderWrap
is false andshowEventDescriptions
is true, this is the fixed height for theheader area
in event canvases.- Returns:
- Current eventHeaderHeight value. Default value is 14
-
setEventHeaderWrap
When rendering thecanvas
for an event, whether to allow the content of theheader area
to wrap to multiple lines.The default is true - if set to false, the header area is
fixed
, unlessshowEventDescriptions
is false, in which case the header area fills the canvas.- Parameters:
eventHeaderWrap
- New eventHeaderWrap value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventHeaderWrap
public boolean getEventHeaderWrap()When rendering thecanvas
for an event, whether to allow the content of theheader area
to wrap to multiple lines.The default is true - if set to false, the header area is
fixed
, unlessshowEventDescriptions
is false, in which case the header area fills the canvas.- Returns:
- Current eventHeaderWrap value. Default value is true
-
setEventLaneFieldTitle
- Parameters:
eventLaneFieldTitle
- New eventLaneFieldTitle value. Default value is "Lane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventLaneFieldTitle
- Returns:
- Current eventLaneFieldTitle value. Default value is "Lane"
- See Also:
-
setEventNameFieldTitle
- Parameters:
eventNameFieldTitle
- New eventNameFieldTitle value. Default value is "Event Name"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventNameFieldTitle
- Returns:
- Current eventNameFieldTitle value. Default value is "Event Name"
- See Also:
-
setEventOverlap
WheneventAutoArrange
is true, setting eventOverlap to true causes events that share timeslots to overlap each other by a percentage of their width, specified byeventOverlapPercent
. The default is true for Calendars and false forTimelines
.- Parameters:
eventOverlap
- New eventOverlap value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventOverlap
WheneventAutoArrange
is true, setting eventOverlap to true causes events that share timeslots to overlap each other by a percentage of their width, specified byeventOverlapPercent
. The default is true for Calendars and false forTimelines
.- Returns:
- Current eventOverlap value. Default value is true
-
setEventOverlapIdenticalStartTimes
public Calendar setEventOverlapIdenticalStartTimes(Boolean eventOverlapIdenticalStartTimes) throws IllegalStateException When set to true, events that start at the same time will not overlap each other to prevent events having their close button hidden.- Parameters:
eventOverlapIdenticalStartTimes
- New eventOverlapIdenticalStartTimes value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventOverlapIdenticalStartTimes
When set to true, events that start at the same time will not overlap each other to prevent events having their close button hidden.- Returns:
- Current eventOverlapIdenticalStartTimes value. Default value is false
-
setEventOverlapPercent
The size of the overlap, presented as a percentage of the width of events sharing timeslots.- Parameters:
eventOverlapPercent
- New eventOverlapPercent value. Default value is 10- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventOverlapPercent
public int getEventOverlapPercent()The size of the overlap, presented as a percentage of the width of events sharing timeslots.- Returns:
- Current eventOverlapPercent value. Default value is 10
-
setEventScreen
Screen to create (viacreateScreen()
) in lieu of callingcreateEventCanvasComponent()
.If this calendar has a
dataSource
, the created screen is provided with aCanvas.dataContext
that includes the event being shown. Be sure the event screen meets theserequirements
to utilize thedataContext
.- Parameters:
eventScreen
- New eventScreen value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getEventScreen
Screen to create (viacreateScreen()
) in lieu of callingcreateEventCanvasComponent()
.If this calendar has a
dataSource
, the created screen is provided with aCanvas.dataContext
that includes the event being shown. Be sure the event screen meets theserequirements
to utilize thedataContext
.- Returns:
- Current eventScreen value. Default value is null
-
setEventSnapGap
The number of minutes that determines the positions to which events will snap when rendered, and when moved or resized with the mouse.If unset (the default), all views will snap to each cell boundary; 30 minutes in a default vertical view, or one
column
in a default Timeline.If set to zero, views will snap to one of a set of known "sensible" defaults: for a default vertical, this will be 5 minutes. For timelines, the eventSnapGap is automatic depending on the current
timelineGranularity
. IftimelineUnitsPerColumn
is greater than 1, the snapGap is set to one unit of the current granularity. So, a cell-resolution of 15 minutes would snap to every minute, assuming there are at least 15 pixels per column. Otherwise, the snapGap is either 15 minutes, 1 hour, one day or one month, depending on granularity.If any other value is specified, it is used where possible.
If the specified or calculated value is less than the time covered by a single pixel in the current view, then it can't be represented. In this case, it is rounded up to the lowest of a set of "sensible" time-spans that can be represented: one of [1, 5, 10, 15, 20, 30, 60, 120, 240, 360, 480, 720, 1440].
For example - a Timeline showing "day" columns cannot support an eventSnapGap of 1 minute, unless each column is at least 1440 pixels wide - if the columns were only 150px wide, then each pixel would represent around 9.6 minutes, which would result in unpleasant and unexpected time-offsets when dragging events. So, the calculated eventSnapGap will be rounded up to the nearest "sensible" time-span - in this case, 10 minutes. If the columns were only 60px wide, it would be 30 minutes.
- Parameters:
eventSnapGap
- New eventSnapGap value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getEventSnapGap
The number of minutes that determines the positions to which events will snap when rendered, and when moved or resized with the mouse.If unset (the default), all views will snap to each cell boundary; 30 minutes in a default vertical view, or one
column
in a default Timeline.If set to zero, views will snap to one of a set of known "sensible" defaults: for a default vertical, this will be 5 minutes. For timelines, the eventSnapGap is automatic depending on the current
timelineGranularity
. IftimelineUnitsPerColumn
is greater than 1, the snapGap is set to one unit of the current granularity. So, a cell-resolution of 15 minutes would snap to every minute, assuming there are at least 15 pixels per column. Otherwise, the snapGap is either 15 minutes, 1 hour, one day or one month, depending on granularity.If any other value is specified, it is used where possible.
If the specified or calculated value is less than the time covered by a single pixel in the current view, then it can't be represented. In this case, it is rounded up to the lowest of a set of "sensible" time-spans that can be represented: one of [1, 5, 10, 15, 20, 30, 60, 120, 240, 360, 480, 720, 1440].
For example - a Timeline showing "day" columns cannot support an eventSnapGap of 1 minute, unless each column is at least 1440 pixels wide - if the columns were only 150px wide, then each pixel would represent around 9.6 minutes, which would result in unpleasant and unexpected time-offsets when dragging events. So, the calculated eventSnapGap will be rounded up to the nearest "sensible" time-span - in this case, 10 minutes. If the columns were only 60px wide, it would be 30 minutes.
- Returns:
- Current eventSnapGap value. Default value is null
- See Also:
-
setEventStartDateFieldTitle
public Calendar setEventStartDateFieldTitle(String eventStartDateFieldTitle) throws IllegalStateException - Parameters:
eventStartDateFieldTitle
- New eventStartDateFieldTitle value. Default value is "From"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventStartDateFieldTitle
- Returns:
- Current eventStartDateFieldTitle value. Default value is "From"
- See Also:
-
setEventStyleName
The base name for the CSS class applied toevents
when they're rendered in calendar views. This style will have "Header" and "Body" appended to it, according to which part of the event window is being styled. For example, to style the header, define a CSS class called 'eventWindowHeader'.- Parameters:
eventStyleName
- New eventStyleName value. Default value is "eventWindow"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getEventStyleName
The base name for the CSS class applied toevents
when they're rendered in calendar views. This style will have "Header" and "Body" appended to it, according to which part of the event window is being styled. For example, to style the header, define a CSS class called 'eventWindowHeader'.- Returns:
- Current eventStyleName value. Default value is "eventWindow"
- See Also:
-
setEventStyleNameField
The name of the field used to overrideeventStyleName
for an individualCalendarEvent.styleName
.- Parameters:
eventStyleNameField
- New eventStyleNameField value. Default value is "styleName"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventStyleNameField
The name of the field used to overrideeventStyleName
for an individualCalendarEvent.styleName
.- Returns:
- Current eventStyleNameField value. Default value is "styleName"
- See Also:
-
setEventSublaneFieldTitle
public Calendar setEventSublaneFieldTitle(String eventSublaneFieldTitle) throws IllegalStateException - Parameters:
eventSublaneFieldTitle
- New eventSublaneFieldTitle value. Default value is "Sublane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventSublaneFieldTitle
- Returns:
- Current eventSublaneFieldTitle value. Default value is "Sublane"
- See Also:
-
setEventWindowStyle
Deprecated.in favor ofeventStyleName
The base name for the CSS class applied to event windows within calendars. This style will have "Header", "HeaderLabel", and "Body" appended to it, according to which part of the event window is being styled. For example, to style the header, define a CSS class called 'eventWindowHeader'.- Parameters:
eventWindowStyle
- New eventWindowStyle value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getEventWindowStyle
Deprecated.in favor ofeventStyleName
The base name for the CSS class applied to event windows within calendars. This style will have "Header", "HeaderLabel", and "Body" appended to it, according to which part of the event window is being styled. For example, to style the header, define a CSS class called 'eventWindowHeader'.- Returns:
- Current eventWindowStyle value. Default value is null
- See Also:
-
setEventWindowStyleField
Deprecated.in favor ofeventStyleNameField
The name of the field used to overrideeventWindowStyle
for an individualCalendarEvent
. SeeCalendarEvent.eventWindowStyle
.- Parameters:
eventWindowStyleField
- New eventWindowStyleField value. Default value is "eventWindowStyle"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getEventWindowStyleField
Deprecated.in favor ofeventStyleNameField
The name of the field used to overrideeventWindowStyle
for an individualCalendarEvent
. SeeCalendarEvent.eventWindowStyle
.- Returns:
- Current eventWindowStyleField value. Default value is "eventWindowStyle"
- See Also:
-
setFirstDayOfWeek
The numeric day (0-6, Sunday-Saturday) which the calendar should consider as the first day of the week in multi-day views, and in the popupDateChooser
.If unset, the default is taken from the current locale.
- Parameters:
firstDayOfWeek
- New firstDayOfWeek value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getFirstDayOfWeek
The numeric day (0-6, Sunday-Saturday) which the calendar should consider as the first day of the week in multi-day views, and in the popupDateChooser
.If unset, the default is taken from the current locale.
- Returns:
- Current firstDayOfWeek value. Default value is null
-
setHeaderLevels
Configures the levels ofheaders
shown above the event area, and their time units.Header levels are provided from the top down, so the first header level should be the largest time unit and the last one the smallest. The smallest is then used for the actual field-headers.
If this method is called after the component has been drawn/initialized: ForTimeline
s, configures the levels ofheaders
shown above the event area, and their time units, after initialization.- Parameters:
headerLevels
- the array of HeaderLevels to set. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getHeaderLevels
Configures the levels ofheaders
shown above the event area, and their time units.Header levels are provided from the top down, so the first header level should be the largest time unit and the last one the smallest. The smallest is then used for the actual field-headers.
- Returns:
- Current headerLevels value. Default value is null
-
setHideUnusedLanes
When set to true, hides anylane
that doesn't have any active events in the current dataset.
If this method is called after the component has been drawn/initialized: Setter for updatinghideUnusedLanes
after creation.- Parameters:
hideUnusedLanes
- whether to hide unused lanes. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getHideUnusedLanes
When set to true, hides anylane
that doesn't have any active events in the current dataset.- Returns:
- Current hideUnusedLanes value. Default value is null
-
setIncludeRangeCriteria
When set to true, the default, the fetches issued by navigating around in the various views are limited to the accessible date-range in the current view - as you change the current date-range, a fetch is only issued if the new range is not entirely within the previous range.For example, navigating in the
monthView
will fetch all events in the range of 5 or 6 weeks that cover that month. If you then change to theday
orweek
views, no fetches will be issued until you navigate outside of the 5 or 6 weeks initially fetched by the Month view.- Parameters:
includeRangeCriteria
- New includeRangeCriteria value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getIncludeRangeCriteria
When set to true, the default, the fetches issued by navigating around in the various views are limited to the accessible date-range in the current view - as you change the current date-range, a fetch is only issued if the new range is not entirely within the previous range.For example, navigating in the
monthView
will fetch all events in the range of 5 or 6 weeks that cover that month. If you then change to theday
orweek
views, no fetches will be issued until you navigate outside of the 5 or 6 weeks initially fetched by the Month view.- Returns:
- Current includeRangeCriteria value. Default value is true
-
getIndicatorCanvas
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.AutoChild component created for each
indicator
entry.- Returns:
- null
-
setIndicators
An array of CalendarEvent instances representing instants in time, to be highlighted intimeline views
. Each indicator renders out as anindicator canvas
, a special, non-interactive subclass ofEventCanvas
, which spans all lanes and draws behind any normal, interactive events in the zorder, but in front of anyzones
. The defaultstyle
for these components renders them as thin vertical lines that span all lanes and have a hover but no title.
If this method is called after the component has been drawn/initialized: Sets theindicators
used to highlight instants in time.- Parameters:
indicators
- array of indicators to display. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getIndicators
An array of CalendarEvent instances representing instants in time, to be highlighted intimeline views
. Each indicator renders out as anindicator canvas
, a special, non-interactive subclass ofEventCanvas
, which spans all lanes and draws behind any normal, interactive events in the zorder, but in front of anyzones
. The defaultstyle
for these components renders them as thin vertical lines that span all lanes and have a hover but no title.- Returns:
- Current indicators value. Default value is null
-
setIndicatorStyleName
- Parameters:
indicatorStyleName
- New indicatorStyleName value. Default value is "indicatorCanvas"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getIndicatorStyleName
- Returns:
- Current indicatorStyleName value. Default value is "indicatorCanvas"
- See Also:
-
setInvalidDateMessage
The message to display in theeventEditor
when the 'To' date is greater than the 'From' date and a save is attempted.- Parameters:
invalidDateMessage
- New invalidDateMessage value. Default value is "From must be before To"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getInvalidDateMessage
The message to display in theeventEditor
when the 'To' date is greater than the 'From' date and a save is attempted.- Returns:
- Current invalidDateMessage value. Default value is "From must be before To"
-
setLaneEventPadding
The pixel space to leave between events and the edges of thelane
orsublane
they appear in. Only applicable totimelines
and todayViews
showingday lanes
.- Parameters:
laneEventPadding
- New laneEventPadding value. Default value is 0- Returns:
Calendar
instance, for chaining setter calls
-
getLaneEventPadding
The pixel space to leave between events and the edges of thelane
orsublane
they appear in. Only applicable totimelines
and todayViews
showingday lanes
.- Returns:
- Current laneEventPadding value. Default value is 0
-
setLaneFields
Field definitions for the frozen area of thetimelineView
, which shows data about the timelinelanes
. Each field shows one attribute of the objects provided aslanes
.When
lane grouping
is enabled, only fields that are specified as lane fields can be used as group fields.- Parameters:
laneFields
- New laneFields value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getLaneFields
Field definitions for the frozen area of thetimelineView
, which shows data about the timelinelanes
. Each field shows one attribute of the objects provided aslanes
.When
lane grouping
is enabled, only fields that are specified as lane fields can be used as group fields.- Returns:
- Current laneFields value. Default value is null
-
setLaneGroupByField
For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.- Parameters:
laneGroupByField
- New laneGroupByField value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getLaneGroupByField
For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.- Returns:
- Current laneGroupByField value. Default value is null
-
setLaneGroupByField
For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.- Parameters:
laneGroupByField
- New laneGroupByField value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getLaneGroupByFieldAsStringArray
For timelines withcanGroupLanes
set to true, this is a field name or array of field names on which to group the lanes in a timeline.- Returns:
- Current laneGroupByField value. Default value is null
-
setLaneNameField
The name of the field which will determine thelane
in which a given event will be displayed inTimeline
s and in theday view
, ifshowDayLanes
is true.- Parameters:
laneNameField
- New laneNameField value. Default value is "lane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getLaneNameField
The name of the field which will determine thelane
in which a given event will be displayed inTimeline
s and in theday view
, ifshowDayLanes
is true.- Returns:
- Current laneNameField value. Default value is "lane"
- See Also:
-
setLanes
An array ofLane
definitions that represent the rows of thetimelineView
, or the columns of thedayView
ifshowDayLanes
is true.
If this method is called after the component has been drawn/initialized: Sets thelanes
in the current calendar view. Only has an effect intimeline views
, and inday views
whenshowDayLanes
is true.- Parameters:
lanes
- array of lanes to display. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getLanes
An array ofLane
definitions that represent the rows of thetimelineView
, or the columns of thedayView
ifshowDayLanes
is true.- Returns:
- Current lanes value. Default value is null
-
setLeadingDateField
The name of the leading date field for each event. When this attribute andtrailingDateField
are present in the data, a line extends out from the event showing the extent of the leading and trailing dates - useful for visualizing a pipeline of events where some can be moved a certain amount without affecting others.- Parameters:
leadingDateField
- New leadingDateField value. Default value is "leadingDate"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getLeadingDateField
The name of the leading date field for each event. When this attribute andtrailingDateField
are present in the data, a line extends out from the event showing the extent of the leading and trailing dates - useful for visualizing a pipeline of events where some can be moved a certain amount without affecting others.- Returns:
- Current leadingDateField value. Default value is "leadingDate"
- See Also:
-
setLimitToWorkday
WhenshowWorkday
is true, this attribute prevents the user from scrolling vertical views beyond the specified workdaystart
andend
hours.- Parameters:
limitToWorkday
- New limitToWorkday value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getLimitToWorkday
WhenshowWorkday
is true, this attribute prevents the user from scrolling vertical views beyond the specified workdaystart
andend
hours.- Returns:
- Current limitToWorkday value. Default value is false
- See Also:
-
getMainView
TabSet
for managing calendar views when multiple views are available (eg,day
andmonth
).This component is an AutoChild named "mainView". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current mainView value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setMinimalUI
A boolean value controlling whether the Calendar shows tabs for available calendar views. By default, this is true for handsets and false otherwise.- Parameters:
minimalUI
- New minimalUI value. Default value is false- Returns:
Calendar
instance, for chaining setter calls
-
getMinimalUI
public boolean getMinimalUI()A boolean value controlling whether the Calendar shows tabs for available calendar views. By default, this is true for handsets and false otherwise.- Returns:
- Current minimalUI value. Default value is false
-
setMinimumDayHeight
In themonth view
whenshowDayHeaders
is true, this is the minimum height applied to a day cell and its header combined.If
showDayHeaders
is false, this attribute has no effect - the minimum height of day cells is either an equal share of the available height, or the rendered height of the cell's HTML content, whichever is greater. If the latter, a vertical scrollbar is shown.- Parameters:
minimumDayHeight
- New minimumDayHeight value. Default value is 80- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getMinimumDayHeight
In themonth view
whenshowDayHeaders
is true, this is the minimum height applied to a day cell and its header combined.If
showDayHeaders
is false, this attribute has no effect - the minimum height of day cells is either an equal share of the available height, or the rendered height of the cell's HTML content, whichever is greater. If the latter, a vertical scrollbar is shown.- Returns:
- Current minimumDayHeight value. Default value is 80
- See Also:
-
setMinLaneWidth
When showingvertical lanes
in thedayView
, this attribute sets the minimum width of each column or field.- Parameters:
minLaneWidth
- New minLaneWidth value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getMinLaneWidth
When showingvertical lanes
in thedayView
, this attribute sets the minimum width of each column or field.- Returns:
- Current minLaneWidth value. Default value is null
-
setMinRowHeight
The minimum height of time-rows in vertical calendar views. Rows will not shrink below this height whensizeToWorkday
is true, meaning that a Calendar with a long workday may not be able to fit all workday rows in the viewport at once, and scrolling may be necessary.To prevent users from scrolling beyond the workday hours, see
limitToWorkday
.- Parameters:
minRowHeight
- New minRowHeight value. Default value is 20- Returns:
Calendar
instance, for chaining setter calls
-
getMinRowHeight
public int getMinRowHeight()The minimum height of time-rows in vertical calendar views. Rows will not shrink below this height whensizeToWorkday
is true, meaning that a Calendar with a long workday may not be able to fit all workday rows in the viewport at once, and scrolling may be necessary.To prevent users from scrolling beyond the workday hours, see
limitToWorkday
.- Returns:
- Current minRowHeight value. Default value is 20
-
setMinutesPerRow
The number of minutes per row inday
andweek
views. The default of 30 minutes shows two rows per hour. Note that this value must divide into 60.- Parameters:
minutesPerRow
- New minutesPerRow value. Default value is 30- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getMinutesPerRow
The number of minutes per row inday
andweek
views. The default of 30 minutes shows two rows per hour. Note that this value must divide into 60.- Returns:
- Current minutesPerRow value. Default value is 30
-
getMonthButton
ANavigationButton
that appears to the left of other navigation controls in thecontrols bar
on Handset devices.Used to show and hide the
month view
on devices with limited space.This component is an AutoChild named "monthButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current monthButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setMonthButtonIconSrc
The icon to show next to the month-name in themonth button
, used for showing and hiding themonth view
on Handsets.- Parameters:
monthButtonIconSrc
- New monthButtonIconSrc value. Default value is "Chevron_Left"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getMonthButtonIconSrc
The icon to show next to the month-name in themonth button
, used for showing and hiding themonth view
on Handsets.- Returns:
- Current monthButtonIconSrc value. Default value is "Chevron_Left"
- See Also:
-
setMonthButtonTitle
The title of themonth button
, used for showing and hiding themonth view
on Handsets.This is a dynamic string - text within
${...}
are dynamic variables and will be evaluated as JS code when the message is displayed.Only one dynamic variable, monthName, is available and represents the name of the month containing the currently selected date.
The default value is the Month-name of the selected date.
When the month view is already visible, the title for the month button is set according to the value of
backButtonTitle
.- Parameters:
monthButtonTitle
- New monthButtonTitle value. Default value is "${monthName}"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getMonthButtonTitle
The title of themonth button
, used for showing and hiding themonth view
on Handsets.This is a dynamic string - text within
${...}
are dynamic variables and will be evaluated as JS code when the message is displayed.Only one dynamic variable, monthName, is available and represents the name of the month containing the currently selected date.
The default value is the Month-name of the selected date.
When the month view is already visible, the title for the month button is set according to the value of
backButtonTitle
.- Returns:
- Current monthButtonTitle value. Default value is "${monthName}"
- See Also:
-
setMonthMoreEventsLinkTitle
public Calendar setMonthMoreEventsLinkTitle(String monthMoreEventsLinkTitle) throws IllegalStateException The title of the link shown in a cell of amonth view
when there are too many events to be displayed at once.This is a dynamic string - text within
${...}
are dynamic variables and will be evaluated as JS code when the message is displayed.Only one dynamic variable, eventCount, is available and represents the number of events that are not currently displayed and that will appear in the menu displayed when the More Events link is clicked.
The default value is a string like "+ 3 more...".
- Parameters:
monthMoreEventsLinkTitle
- New monthMoreEventsLinkTitle value. Default value is "+ ${eventCount} more..."- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getMonthMoreEventsLinkTitle
The title of the link shown in a cell of amonth view
when there are too many events to be displayed at once.This is a dynamic string - text within
${...}
are dynamic variables and will be evaluated as JS code when the message is displayed.Only one dynamic variable, eventCount, is available and represents the number of events that are not currently displayed and that will appear in the menu displayed when the More Events link is clicked.
The default value is a string like "+ 3 more...".
- Returns:
- Current monthMoreEventsLinkTitle value. Default value is "+ ${eventCount} more..."
- See Also:
-
getMonthMoreEventsMenu
AutoChild Menu, shown when a user clicks themore events
link in a cell of themonthView
. Items in this menu represent additional events, not already displayed in the cell, and clicking them fires theeventClick
notification.This component is an AutoChild named "monthMoreEventsMenu". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current monthMoreEventsMenu value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
getMonthView
CalendarView
used to display events that pertain to a given month.This component is an AutoChild named "monthView". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current monthView value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setMonthViewTitle
The title for themonth view
.- Parameters:
monthViewTitle
- New monthViewTitle value. Default value is "Month"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getMonthViewTitle
The title for themonth view
.- Returns:
- Current monthViewTitle value. Default value is "Month"
-
setNameField
The name of the name field on aCalendarEvent
.- Parameters:
nameField
- New nameField value. Default value is "name"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getNameField
The name of the name field on aCalendarEvent
.- Returns:
- Current nameField value. Default value is "name"
- See Also:
-
setNewEventWindowTitle
The title-text displayed in the popup event dialog/editor for new events.- Parameters:
newEventWindowTitle
- New newEventWindowTitle value. Default value is "New Event"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getNewEventWindowTitle
The title-text displayed in the popup event dialog/editor for new events.- Returns:
- Current newEventWindowTitle value. Default value is "New Event"
- See Also:
-
getNextButton
AnImgButton
that appears above the week/day/month views of the calendar and allows the user to move the calendar forwards in time.This component is an AutoChild named "nextButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current nextButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setNextButtonHoverText
The text to be displayed when a user hovers over thenext
toolbar button- Parameters:
nextButtonHoverText
- New nextButtonHoverText value. Default value is "Next"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getNextButtonHoverText
The text to be displayed when a user hovers over thenext
toolbar button- Returns:
- Current nextButtonHoverText value. Default value is "Next"
-
setOtherDayBlankStyle
The CSS style applied to both the header and body of days from other months in themonth view
, whenshowOtherDays
is false.- Parameters:
otherDayBlankStyle
- New otherDayBlankStyle value. Default value is "calMonthOtherDayBlank"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getOtherDayBlankStyle
The CSS style applied to both the header and body of days from other months in themonth view
, whenshowOtherDays
is false.- Returns:
- Current otherDayBlankStyle value. Default value is "calMonthOtherDayBlank"
- See Also:
-
setOtherDayBodyBaseStyle
The base name for the CSS class applied to the day body of the month view of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Parameters:
otherDayBodyBaseStyle
- New otherDayBodyBaseStyle value. Default value is "calMonthOtherDayBody"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getOtherDayBodyBaseStyle
The base name for the CSS class applied to the day body of the month view of the calendar. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Returns:
- Current otherDayBodyBaseStyle value. Default value is "calMonthOtherDayBody"
- See Also:
-
setOtherDayHeaderBaseStyle
The base name for the CSS class applied to the day headers of the month view. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Parameters:
otherDayHeaderBaseStyle
- New otherDayHeaderBaseStyle value. Default value is "calMonthDayHeader"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getOtherDayHeaderBaseStyle
The base name for the CSS class applied to the day headers of the month view. This style will have "Dark", "Over", "Selected", or "Disabled" appended to it according to the state of the cell.See
CellStyleSuffixes
for details on how stateful suffixes are combined with the base style to generate stateful cell styles.- Returns:
- Current otherDayHeaderBaseStyle value. Default value is "calMonthDayHeader"
- See Also:
-
setOverlapSortSpecifiers
A set ofsort-specifiers
for customizing the render order of events that overlap.In
timelines
, this dictates the vertical rendering order of overlapped events in eachlane
.In
day
andweek
views, it dictates the horizontal rendering order of overlapped events in each column or Lane.By default, events that share space in a Lane or column are rendered from top to bottom, or left to right according to their
start-dates
- the earliest in a given lane appears top-most in that lane, or left-most in its column.Providing
overlapSortSpecifiers
allows for the events to be ordered by one or more of the fields stored on the events, or in the underlyingdata-source
, if the Calendar is databound.- Parameters:
overlapSortSpecifiers
- New overlapSortSpecifiers value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getOverlapSortSpecifiers
A set ofsort-specifiers
for customizing the render order of events that overlap.In
timelines
, this dictates the vertical rendering order of overlapped events in eachlane
.In
day
andweek
views, it dictates the horizontal rendering order of overlapped events in each column or Lane.By default, events that share space in a Lane or column are rendered from top to bottom, or left to right according to their
start-dates
- the earliest in a given lane appears top-most in that lane, or left-most in its column.Providing
overlapSortSpecifiers
allows for the events to be ordered by one or more of the fields stored on the events, or in the underlyingdata-source
, if the Calendar is databound.- Returns:
- Current overlapSortSpecifiers value. Default value is null
-
getPreviousButton
AnImgButton
that appears above the week/day/month views of the calendar and allows the user to move the calendar backwards in time.This component is an AutoChild named "previousButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current previousButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setPreviousButtonHoverText
public Calendar setPreviousButtonHoverText(String previousButtonHoverText) throws IllegalStateException The text to be displayed when a user hovers over theprevious
toolbar button.- Parameters:
previousButtonHoverText
- New previousButtonHoverText value. Default value is "Previous"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getPreviousButtonHoverText
The text to be displayed when a user hovers over theprevious
toolbar button.- Returns:
- Current previousButtonHoverText value. Default value is "Previous"
-
getRemoveButton
Ancom.smartgwt.client.types.AutoChild
of typeIButton
, used to permanently remove an event from theeventEditor
.This component is an AutoChild named "removeButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current removeButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setRemoveButtonTitle
The title for theRemove button
in theevent editor
.- Parameters:
removeButtonTitle
- New removeButtonTitle value. Default value is "Remove Event"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getRemoveButtonTitle
The title for theRemove button
in theevent editor
.- Returns:
- Current removeButtonTitle value. Default value is "Remove Event"
- See Also:
-
setRenderEventsOnDemand
When set to true, the default, eachevent
is rendered as it appears in the viewport. If set to false, all events are rendered up-front, whenever the current range changes.Has no effect when
showColumnLayouts
is true.- Parameters:
renderEventsOnDemand
- New renderEventsOnDemand value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getRenderEventsOnDemand
public boolean getRenderEventsOnDemand()When set to true, the default, eachevent
is rendered as it appears in the viewport. If set to false, all events are rendered up-front, whenever the current range changes.Has no effect when
showColumnLayouts
is true.- Returns:
- Current renderEventsOnDemand value. Default value is true
-
setRowHeight
The height of time-slots in the calendar.- Parameters:
rowHeight
- New rowHeight value. Default value is 20- Returns:
Calendar
instance, for chaining setter calls
-
getRowHeight
public int getRowHeight()The height of time-slots in the calendar.- Returns:
- Current rowHeight value. Default value is 20
-
setRowTitleFrequency
A minute value that indicates which rows should show times in vertical views, likeday
andweek
. The default of 60 minutes shows titles on the first row of each hour. The value provided must be a multiple ofminutesPerRow
and be no larger than 60.- Parameters:
rowTitleFrequency
- New rowTitleFrequency value. Default value is 60- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getRowTitleFrequency
A minute value that indicates which rows should show times in vertical views, likeday
andweek
. The default of 60 minutes shows titles on the first row of each hour. The value provided must be a multiple ofminutesPerRow
and be no larger than 60.- Returns:
- Current rowTitleFrequency value. Default value is 60
-
getSaveButton
Ancom.smartgwt.client.types.AutoChild
of typeIButton
, used to save an event from theeventEditor
.This component is an AutoChild named "saveButton". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current saveButton value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setSaveButtonTitle
- Parameters:
saveButtonTitle
- New saveButtonTitle value. Default value is "Save Event"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getSaveButtonTitle
- Returns:
- Current saveButtonTitle value. Default value is "Save Event"
- See Also:
-
setScrollToWorkday
If set, andshowWorkday
is true, automatically scrolls theday
andweek
views to the start of theworkday
when the calendar is first displayed and whenever the user changes to a different day or week.- Parameters:
scrollToWorkday
- New scrollToWorkday value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getScrollToWorkday
If set, andshowWorkday
is true, automatically scrolls theday
andweek
views to the start of theworkday
when the calendar is first displayed and whenever the user changes to a different day or week.- Returns:
- Current scrollToWorkday value. Default value is false
- See Also:
-
setSelectChosenDate
When true, shows the currentchosenDate
in a selected style in themonth view
. Has no effect in other views.- Parameters:
selectChosenDate
- New selectChosenDate value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getSelectChosenDate
When true, shows the currentchosenDate
in a selected style in themonth view
. Has no effect in other views.- Returns:
- Current selectChosenDate value. Default value is true
- See Also:
-
setSelectedCellStyle
The base name for the CSS class applied to a cell that is selected via a mouse drag.- Parameters:
selectedCellStyle
- New selectedCellStyle value. Default value is "calendarCellSelected"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getSelectedCellStyle
The base name for the CSS class applied to a cell that is selected via a mouse drag.- Returns:
- Current selectedCellStyle value. Default value is "calendarCellSelected"
- See Also:
-
setShowAddEventButton
Set to false to hide theAdd Event
button.- Parameters:
showAddEventButton
- New showAddEventButton value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowAddEventButton
Set to false to hide theAdd Event
button.- Returns:
- Current showAddEventButton value. Default value is null
-
setShowCellHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over the normal cells in the body of CalendarViews.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results; by default, it returns the cell's date as a string.- Parameters:
showCellHovers
- New showCellHovers value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowCellHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over the normal cells in the body of CalendarViews.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results; by default, it returns the cell's date as a string.- Returns:
- Current showCellHovers value. Default value is false
-
setShowColumnLayouts
When true, causeslayouts
to be added to each column in vertical views. In this mode, eventCanvases are stacked in these layouts, filling width and auto-sizing vertically to content, rather than being placed, sized and overlapped according to their times.Because times are ignored in this mode, various behaviors are switched off automatically; for example, the
time-column
is hidden and event-canvases cannot beresized
or renderedon-demand
.- Parameters:
showColumnLayouts
- New showColumnLayouts value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowColumnLayouts
When true, causeslayouts
to be added to each column in vertical views. In this mode, eventCanvases are stacked in these layouts, filling width and auto-sizing vertically to content, rather than being placed, sized and overlapped according to their times.Because times are ignored in this mode, various behaviors are switched off automatically; for example, the
time-column
is hidden and event-canvases cannot beresized
or renderedon-demand
.- Returns:
- Current showColumnLayouts value. Default value is false
- See Also:
-
setShowControlsBar
If false the controls bar at the top of the calendar will not be displayed - this means that thecontrolsBar
will be hidden, so the autoChildren (previousButton
,dateLabel
,nextButton
,addEventButton
, anddatePickerButton
) will not be created or shown.- Parameters:
showControlsBar
- New showControlsBar value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowControlsBar
If false the controls bar at the top of the calendar will not be displayed - this means that thecontrolsBar
will be hidden, so the autoChildren (previousButton
,dateLabel
,nextButton
,addEventButton
, anddatePickerButton
) will not be created or shown.- Returns:
- Current showControlsBar value. Default value is true
-
setShowDateChooser
Determines whether thedateChooser
is displayed.- Parameters:
showDateChooser
- New showDateChooser value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowDateChooser
Determines whether thedateChooser
is displayed.- Returns:
- Current showDateChooser value. Default value is true
- See Also:
-
setShowDatePickerButton
Set to false to hide thedatePickerButton
that allows selecting a new base date for this Calendar.- Parameters:
showDatePickerButton
- New showDatePickerButton value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowDatePickerButton
Set to false to hide thedatePickerButton
that allows selecting a new base date for this Calendar.- Returns:
- Current showDatePickerButton value. Default value is null
-
setShowDayHeaders
If true, the default, show a header cell for each day cell in themonth view
, with both cells having a minimum combined height ofminimumDayHeight
. If false, the header cells will not be shown, and the value ofminimumDayHeight
is ignored. This causes the available vertical space in month views to be shared equally between day cells, such that no vertical scrollbar is required unless the HTML in the cells renders them taller than will fit.- Parameters:
showDayHeaders
- New showDayHeaders value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowDayHeaders
If true, the default, show a header cell for each day cell in themonth view
, with both cells having a minimum combined height ofminimumDayHeight
. If false, the header cells will not be shown, and the value ofminimumDayHeight
is ignored. This causes the available vertical space in month views to be shared equally between day cells, such that no vertical scrollbar is required unless the HTML in the cells renders them taller than will fit.- Returns:
- Current showDayHeaders value. Default value is true
- See Also:
-
setShowDayLanes
If set to true, theday view
useslanes
to render multiple vertical "lanes" within the day, very much like a verticalTimeline
.Day lanes are useful for showing events for various entities on the same day - agendas for various staff members, for example, or delivery schedules for a fleet of trucks.
Each day lane is self-contained, showing in a column with a header and individual events are placed in
appropriate lanes
, respecting padding and overlapping. IfcanEditEvents
is true, events can be drag-moved or drag-resized from their top and bottom edges, within the containing lane. To allow events to be dragged from one lane into another, seecanEditLane
.
If this method is called after the component has been drawn/initialized: Changes theview mode
of the day view at runtime - whether to show a normal day column for thechosenDate
, or the specified set ofvertical lanes
.- Parameters:
showDayLanes
- whether or not to show lanes in the day view. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowDayLanes
If set to true, theday view
useslanes
to render multiple vertical "lanes" within the day, very much like a verticalTimeline
.Day lanes are useful for showing events for various entities on the same day - agendas for various staff members, for example, or delivery schedules for a fleet of trucks.
Each day lane is self-contained, showing in a column with a header and individual events are placed in
appropriate lanes
, respecting padding and overlapping. IfcanEditEvents
is true, events can be drag-moved or drag-resized from their top and bottom edges, within the containing lane. To allow events to be dragged from one lane into another, seecanEditLane
.- Returns:
- Current showDayLanes value. Default value is null
-
setShowDayView
Whether to show the Day view.- Parameters:
showDayView
- New showDayView value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowDayView
Whether to show the Day view.- Returns:
- Current showDayView value. Default value is true
- See Also:
-
setShowDetailFields
Whether to show fields markeddetail:true
when a DataBoundComponent is given a DataSource but nocomponent.fields
.The
detail
property is used on DataSource fields to mark fields that shouldn't appear by default in a view that tries to show many records in a small space.- Specified by:
setShowDetailFields
in interfaceDataBoundComponent
- Parameters:
showDetailFields
- New showDetailFields value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowDetailFields
Whether to show fields markeddetail:true
when a DataBoundComponent is given a DataSource but nocomponent.fields
.The
detail
property is used on DataSource fields to mark fields that shouldn't appear by default in a view that tries to show many records in a small space.- Specified by:
getShowDetailFields
in interfaceDataBoundComponent
- Returns:
- Current showDetailFields value. Default value is true
- See Also:
-
setShowDragHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when an event is being dragged with the mouse.The content of the hover is determined by a call to
getDragHoverHTML()
, which can be overridden to return custom results; by default, it returns the date range of the drag canvas as a string.- Parameters:
showDragHovers
- New showDragHovers value. Default value is false- Returns:
Calendar
instance, for chaining setter calls
-
getShowDragHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when an event is being dragged with the mouse.The content of the hover is determined by a call to
getDragHoverHTML()
, which can be overridden to return custom results; by default, it returns the date range of the drag canvas as a string.- Returns:
- Current showDragHovers value. Default value is false
-
setShowEventCanvasComponents
public Calendar setShowEventCanvasComponents(boolean showEventCanvasComponents) throws IllegalStateException Whetherevent-canvases
should show a custom widget as content, rather than the defaultheader
andbody
HTML.- Parameters:
showEventCanvasComponents
- New showEventCanvasComponents value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowEventCanvasComponents
public boolean getShowEventCanvasComponents()Whetherevent-canvases
should show a custom widget as content, rather than the defaultheader
andbody
HTML.- Returns:
- Current showEventCanvasComponents value. Default value is false
- See Also:
-
setShowEventDescriptions
public Calendar setShowEventDescriptions(boolean showEventDescriptions) throws IllegalStateException When rendering thecanvas
for an event, whether to show thebody area
, typically containing brief details of the event -by default
,its description
.The default is true - if set to false, the event's
header
will fill the canvas.- Parameters:
showEventDescriptions
- New showEventDescriptions value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowEventDescriptions
public boolean getShowEventDescriptions()When rendering thecanvas
for an event, whether to show thebody area
, typically containing brief details of the event -by default
,its description
.The default is true - if set to false, the event's
header
will fill the canvas.- Returns:
- Current showEventDescriptions value. Default value is true
-
setShowEventHeaders
When rendering thecanvas
for an event, whether to show theheader area
, typically containing suitable title text -by default
, the event'sname
.The default is true - if set to false, the event's
body area
will fill the canvas.- Parameters:
showEventHeaders
- New showEventHeaders value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowEventHeaders
public boolean getShowEventHeaders()When rendering thecanvas
for an event, whether to show theheader area
, typically containing suitable title text -by default
, the event'sname
.The default is true - if set to false, the event's
body area
will fill the canvas.- Returns:
- Current showEventHeaders value. Default value is true
-
setShowEventHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over anevent canvas
in a calendarView.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results.- Parameters:
showEventHovers
- New showEventHovers value. Default value is true- Returns:
Calendar
instance, for chaining setter calls
-
getShowEventHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over anevent canvas
in a calendarView.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results.- Returns:
- Current showEventHovers value. Default value is true
-
setShowHeaderHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over theheader levels
in aCalendarView
.The content of the hover is determined by a call to
getHeaderHoverHTML()
, which can be overridden to return custom results;- Parameters:
showHeaderHovers
- New showHeaderHovers value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowHeaderHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse rolls over theheader levels
in aCalendarView
.The content of the hover is determined by a call to
getHeaderHoverHTML()
, which can be overridden to return custom results;- Returns:
- Current showHeaderHovers value. Default value is false
-
setShowIndicators
Set to true to render any definedindicators
intotimeline views
.- Parameters:
showIndicators
- New showIndicators value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowIndicators
Set to true to render any definedindicators
intotimeline views
.- Returns:
- Current showIndicators value. Default value is null
-
setShowIndicatorsInFront
public Calendar setShowIndicatorsInFront(boolean showIndicatorsInFront) throws IllegalStateException Inindicator lines
are showing, this attribute affects where in the z-order their canvases will be rendered: either in front of, or behind normal calendar events.- Parameters:
showIndicatorsInFront
- New showIndicatorsInFront value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowIndicatorsInFront
public boolean getShowIndicatorsInFront()Inindicator lines
are showing, this attribute affects where in the z-order their canvases will be rendered: either in front of, or behind normal calendar events.- Returns:
- Current showIndicatorsInFront value. Default value is true
-
setShowLabelColumn
When set to false, hides the frozen Label-Column in verticalCalendarView
s.Always false when
showColumnLayouts
is true.- Parameters:
showLabelColumn
- New showLabelColumn value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowLabelColumn
public boolean getShowLabelColumn()When set to false, hides the frozen Label-Column in verticalCalendarView
s.Always false when
showColumnLayouts
is true.- Returns:
- Current showLabelColumn value. Default value is true
-
setShowLaneFieldHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over the cells in alaneField
.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results. Note that getCellHoverHTML() is also called when the mouse moves over cells ifshowCellHovers
is true - when called for a laneField, no "date" parameter is passed to that method.- Parameters:
showLaneFieldHovers
- New showLaneFieldHovers value. Default value is false- Returns:
Calendar
instance, for chaining setter calls
-
getShowLaneFieldHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over the cells in alaneField
.The content of the hover is determined by a call to
getCellHoverHTML()
, which can be overridden to return custom results. Note that getCellHoverHTML() is also called when the mouse moves over cells ifshowCellHovers
is true - when called for a laneField, no "date" parameter is passed to that method.- Returns:
- Current showLaneFieldHovers value. Default value is false
-
setShowLaneRollOver
When set to true, causesTimelines
to highlight the Lane under the mouse with the "Over" style.- Parameters:
showLaneRollOver
- New showLaneRollOver value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowLaneRollOver
When set to true, causesTimelines
to highlight the Lane under the mouse with the "Over" style.- Returns:
- Current showLaneRollOver value. Default value is null
-
setShowMonthButton
Set to false to prevent theMonth
button from displaying on Handset devices.- Parameters:
showMonthButton
- New showMonthButton value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowMonthButton
Set to false to prevent theMonth
button from displaying on Handset devices.- Returns:
- Current showMonthButton value. Default value is null
-
setShowMonthView
Whether to show the Month view.- Parameters:
showMonthView
- New showMonthView value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowMonthView
Whether to show the Month view.- Returns:
- Current showMonthView value. Default value is true
- See Also:
-
setShowNextButton
Set to false to hide theNext
button.- Parameters:
showNextButton
- New showNextButton value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowNextButton
Set to false to hide theNext
button.- Returns:
- Current showNextButton value. Default value is null
-
setShowOtherDays
If set to true, in themonth view
, days that fall in an adjacent month are still shown with a header and body area, and are interactive. Otherwise days from other months are rendered in theotherDayBlankStyle
and are non-interactive.- Parameters:
showOtherDays
- New showOtherDays value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowOtherDays
If set to true, in themonth view
, days that fall in an adjacent month are still shown with a header and body area, and are interactive. Otherwise days from other months are rendered in theotherDayBlankStyle
and are non-interactive.- Returns:
- Current showOtherDays value. Default value is true
- See Also:
-
setShowPreviousButton
Set to false to hide thePrevious
button.- Parameters:
showPreviousButton
- New showPreviousButton value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowPreviousButton
Set to false to hide thePrevious
button.- Returns:
- Current showPreviousButton value. Default value is null
-
setShowQuickEventDialog
Determines whether the quick event dialog is displayed when a time is clicked. If this is false, the full event editor is displayed.- Parameters:
showQuickEventDialog
- New showQuickEventDialog value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowQuickEventDialog
Determines whether the quick event dialog is displayed when a time is clicked. If this is false, the full event editor is displayed.- Returns:
- Current showQuickEventDialog value. Default value is true
- See Also:
-
setShowTimelineView
If set to true, show theTimeline view
.- Parameters:
showTimelineView
- New showTimelineView value. Default value is false- Returns:
Calendar
instance, for chaining setter calls
-
getShowTimelineView
If set to true, show theTimeline view
.- Returns:
- Current showTimelineView value. Default value is false
-
setShowViewHovers
When set to true, the default value, causes the Calendar to show customizable hovers when the mouse moves over various areas of a CalendarView.See
showEventHovers
,showZoneHovers
,showHeaderHovers
,showCellHovers
,showLaneFieldHovers
,showDragHovers
for further configuration options.
If this method is called after the component has been drawn/initialized: Switches the various levels ofhovers
on or off at runtime.- Parameters:
showViewHovers
- whether to allow CalendarViews to show hovers. Default value is true- Returns:
Calendar
instance, for chaining setter calls
-
getShowViewHovers
When set to true, the default value, causes the Calendar to show customizable hovers when the mouse moves over various areas of a CalendarView.See
showEventHovers
,showZoneHovers
,showHeaderHovers
,showCellHovers
,showLaneFieldHovers
,showDragHovers
for further configuration options.- Returns:
- Current showViewHovers value. Default value is true
-
setShowWeekends
Suppresses the display of weekend days in theweek
,month
andtimeline
views, and disallows the creation of events on weekends. Which days are considered weekends is controlled byweekendDays
.
If this method is called after the component has been drawn/initialized: Setter for updatingshowWeekends
at runtime.- Parameters:
showWeekends
- whether or not to show weekends. Default value is true- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getShowWeekends
Suppresses the display of weekend days in theweek
,month
andtimeline
views, and disallows the creation of events on weekends. Which days are considered weekends is controlled byweekendDays
.- Returns:
- Current showWeekends value. Default value is true
- See Also:
-
setShowWeekView
Whether to show the Week view.- Parameters:
showWeekView
- New showWeekView value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getShowWeekView
Whether to show the Week view.- Returns:
- Current showWeekView value. Default value is true
- See Also:
-
setShowWorkday
When set to true, this setting enables various features related to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
) in vertical calendar views (day
andweek
). Workday cells can bestyled separately
andsized automatically
, and users can be prevented from scrolling the calendar beyond theworkday hours
.The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Parameters:
showWorkday
- New showWorkday value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getShowWorkday
When set to true, this setting enables various features related to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
) in vertical calendar views (day
andweek
). Workday cells can bestyled separately
andsized automatically
, and users can be prevented from scrolling the calendar beyond theworkday hours
.The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Returns:
- Current showWorkday value. Default value is false
- See Also:
-
setShowZoneHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over azone
in a calendarView.When
showCellHovers
is true, this attribute is ignored and zone hovers are not displayed.The content of the hover is determined by a call to
getZoneHoverHTML()
, which can be overridden to return custom results.- Parameters:
showZoneHovers
- New showZoneHovers value. Default value is true- Returns:
Calendar
instance, for chaining setter calls
-
getShowZoneHovers
WhenshowViewHovers
is true, dictates whether to display hover prompts when the mouse moves over azone
in a calendarView.When
showCellHovers
is true, this attribute is ignored and zone hovers are not displayed.The content of the hover is determined by a call to
getZoneHoverHTML()
, which can be overridden to return custom results.- Returns:
- Current showZoneHovers value. Default value is true
-
setShowZones
Set to true to render any definedzones
intotimeline views
.- Parameters:
showZones
- New showZones value. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getShowZones
Set to true to render any definedzones
intotimeline views
.- Returns:
- Current showZones value. Default value is null
-
setSizeEventsToGrid
If true, events will be sized to the grid, even if they start and/or end at times between grid cells.- Parameters:
sizeEventsToGrid
- New sizeEventsToGrid value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getSizeEventsToGrid
If true, events will be sized to the grid, even if they start and/or end at times between grid cells.- Returns:
- Current sizeEventsToGrid value. Default value is true
-
setSizeToWorkday
WhenshowWorkday
is true, attempt to resize rows in the day and week views so that theworkday hours
fill the visible viewport-height, and the whole workday is visible without scrolling. If the Calendar is resized, the row-size is recalculated to keep the workday hours visible.Note that row-heights will not shrink below the
minRowHeight
, so the entire workday may not be visible without scrolling if the workday is long or the viewport-height is insufficient.- Parameters:
sizeToWorkday
- New sizeToWorkday value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getSizeToWorkday
WhenshowWorkday
is true, attempt to resize rows in the day and week views so that theworkday hours
fill the visible viewport-height, and the whole workday is visible without scrolling. If the Calendar is resized, the row-size is recalculated to keep the workday hours visible.Note that row-heights will not shrink below the
minRowHeight
, so the entire workday may not be visible without scrolling if the workday is long or the viewport-height is insufficient.- Returns:
- Current sizeToWorkday value. Default value is false
- See Also:
-
setStartDate
The start date of the calendartimeline view
. Has no effect in other views. If not specified, defaults to a timeline starting from the beginning of the currenttimelineGranularity
and spanninga default of 20
columns of that granularity.To set different start and
end
dates after initial draw, seesetTimelineRange
.Note that the value you provide may be automatically altered if showing
header-levels
, to fit to header boundaries.- Parameters:
startDate
- New startDate value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getStartDate
The start date of the calendartimeline view
. Has no effect in other views. If not specified, defaults to a timeline starting from the beginning of the currenttimelineGranularity
and spanninga default of 20
columns of that granularity.To set different start and
end
dates after initial draw, seesetTimelineRange
.Note that the value you provide may be automatically altered if showing
header-levels
, to fit to header boundaries.- Returns:
- Current startDate value. Default value is null
-
setStartDateField
The name of the start date field on aCalendarEvent
.- Parameters:
startDateField
- New startDateField value. Default value is "startDate"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getStartDateField
The name of the start date field on aCalendarEvent
.- Returns:
- Current startDateField value. Default value is "startDate"
- See Also:
-
setStyleWorkday
WhenshowWorkday
is true, applies theworkdayBaseStyle
to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
), in both thedayView
andweekView
.The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Parameters:
styleWorkday
- New styleWorkday value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getStyleWorkday
WhenshowWorkday
is true, applies theworkdayBaseStyle
to cells that fall within the workday (as defined byworkdayStart
andworkdayEnd
), in both thedayView
andweekView
.The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Returns:
- Current styleWorkday value. Default value is true
- See Also:
-
setSublaneNameField
The name of the field which will determine thesublane
in which this event will be displayed, within its parent Lane, inTimeline
s and in theday view
, ifshowDayLanes
is true.- Parameters:
sublaneNameField
- New sublaneNameField value. Default value is "sublane"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getSublaneNameField
The name of the field which will determine thesublane
in which this event will be displayed, within its parent Lane, inTimeline
s and in theday view
, ifshowDayLanes
is true.- Returns:
- Current sublaneNameField value. Default value is "sublane"
-
setTimelineGranularity
The granularity in which thetimelineView
will display events. Possible values are those available in the built-inTimeUnit
type.- Parameters:
timelineGranularity
- New timelineGranularity value. Default value is "day"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getTimelineGranularity
The granularity in which thetimelineView
will display events. Possible values are those available in the built-inTimeUnit
type.- Returns:
- Current timelineGranularity value. Default value is "day"
-
setTimelineUnitsPerColumn
How many units oftimelineGranularity
each cell represents.- Parameters:
timelineUnitsPerColumn
- New timelineUnitsPerColumn value. Default value is 1- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getTimelineUnitsPerColumn
public int getTimelineUnitsPerColumn()How many units oftimelineGranularity
each cell represents.- Returns:
- Current timelineUnitsPerColumn value. Default value is 1
-
getTimelineView
CalendarView
used to display events in lanes in a horizontalTimeline
view.This component is an AutoChild named "timelineView". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current timelineView value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setTimelineViewTitle
The title for thetimeline view
.- Parameters:
timelineViewTitle
- New timelineViewTitle value. Default value is "Timeline"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getTimelineViewTitle
The title for thetimeline view
.- Returns:
- Current timelineViewTitle value. Default value is "Timeline"
-
setTodayBackgroundColor
The background color for cells that represent today in allCalendarView
s.- Parameters:
todayBackgroundColor
- New todayBackgroundColor value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getTodayBackgroundColor
The background color for cells that represent today in allCalendarView
s.- Returns:
- Current todayBackgroundColor value. Default value is null
-
setTrailingDateField
The name of the trailing date field for each event. When this attribute andleadingDateField
are present in the data, a line extends out from the event showing the extent of the leading and trailing dates - useful for visualizing a pipeline of events where some can be moved a certain amount without affecting others.- Parameters:
trailingDateField
- New trailingDateField value. Default value is "trailingDate"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getTrailingDateField
The name of the trailing date field for each event. When this attribute andleadingDateField
are present in the data, a line extends out from the event showing the extent of the leading and trailing dates - useful for visualizing a pipeline of events where some can be moved a certain amount without affecting others.- Returns:
- Current trailingDateField value. Default value is "trailingDate"
- See Also:
-
setTwentyFourHourTime
Dictates whether times throughout the widget are formatted and edited as 24-hour values. If unset, defaults to the String. If set, and nolocal formatter
is installed, causes the Calendar to choose an appropriate builtin formatter.- Parameters:
twentyFourHourTime
- New twentyFourHourTime value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getTwentyFourHourTime
Dictates whether times throughout the widget are formatted and edited as 24-hour values. If unset, defaults to the String. If set, and nolocal formatter
is installed, causes the Calendar to choose an appropriate builtin formatter.- Returns:
- Current twentyFourHourTime value. Default value is null
-
setUseEventCanvasRolloverControls
public Calendar setUseEventCanvasRolloverControls(boolean useEventCanvasRolloverControls) throws IllegalStateException By default, theclose buttons
and thehorizontal
andvertical
resizer widgets for event canvases are shown only when the mouse is over a given event. Set this attribute to false to have event canvases show these widgets permanently.- Parameters:
useEventCanvasRolloverControls
- New useEventCanvasRolloverControls value. Default value is true- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getUseEventCanvasRolloverControls
public boolean getUseEventCanvasRolloverControls()By default, theclose buttons
and thehorizontal
andvertical
resizer widgets for event canvases are shown only when the mouse is over a given event. Set this attribute to false to have event canvases show these widgets permanently.- Returns:
- Current useEventCanvasRolloverControls value. Default value is true
-
setUseSublanes
- Parameters:
useSublanes
- New useSublanes value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getUseSublanes
- Returns:
- Current useSublanes value. Default value is null
-
setWeekendDays
An array of integer day-numbers that should be considered to be weekend days by this Calendar instance. If unset, defaults to the set of days indicatedglobally
.- Parameters:
weekendDays
- New weekendDays value. Default value is null- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getWeekendDays
public int[] getWeekendDays()An array of integer day-numbers that should be considered to be weekend days by this Calendar instance. If unset, defaults to the set of days indicatedglobally
.- Returns:
- Current weekendDays value. Default value is null
- See Also:
-
setWeekEventBorderOverlap
public Calendar setWeekEventBorderOverlap(Boolean weekEventBorderOverlap) throws IllegalStateException Augments the width of week event windows slightly to avoid duplicate adjacent borders between events.- Parameters:
weekEventBorderOverlap
- New weekEventBorderOverlap value. Default value is false- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getWeekEventBorderOverlap
Augments the width of week event windows slightly to avoid duplicate adjacent borders between events.- Returns:
- Current weekEventBorderOverlap value. Default value is false
- See Also:
-
setWeekPrefix
The text to appear before the week number in the title ofweek-based
HeaderLevel
s when this calendar is showing a timeline.- Parameters:
weekPrefix
- New weekPrefix value. Default value is "Week"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getWeekPrefix
The text to appear before the week number in the title ofweek-based
HeaderLevel
s when this calendar is showing a timeline.- Returns:
- Current weekPrefix value. Default value is "Week"
- See Also:
-
getWeekView
CalendarView
used to display events that pertain to a given week.This component is an AutoChild named "weekView". For an overview of how to use and configure AutoChildren, see
Using AutoChildren
.- Returns:
- Current weekView value. Default value is null
- Throws:
IllegalStateException
- if this widget has not yet been rendered.
-
setWeekViewTitle
The title for theweek view
.- Parameters:
weekViewTitle
- New weekViewTitle value. Default value is "Week"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getWeekViewTitle
The title for theweek view
.- Returns:
- Current weekViewTitle value. Default value is "Week"
-
setWorkdayBaseStyle
IfshowWorkday
is set, this is the style used for cells that are within the workday, as defined byworkdayStart
andworkdayEnd
, or by a date-specific range provided ingetWorkdayStart()
andgetWorkdayEnd()
implementations.- Parameters:
workdayBaseStyle
- New workdayBaseStyle value. Default value is "calendarWorkday"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created- See Also:
-
getWorkdayBaseStyle
IfshowWorkday
is set, this is the style used for cells that are within the workday, as defined byworkdayStart
andworkdayEnd
, or by a date-specific range provided ingetWorkdayStart()
andgetWorkdayEnd()
implementations.- Returns:
- Current workdayBaseStyle value. Default value is "calendarWorkday"
- See Also:
-
setWorkdayEnd
When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.Both start and end time must fall on a 30 minute increment (eg 9:30, but not 9:45).
The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Parameters:
workdayEnd
- New workdayEnd value. Default value is "5:00pm"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
setWorkdayStart
When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.Both start and end time must fall on a 30 minute increment (eg 9:30, but not 9:45).
The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.- Parameters:
workdayStart
- New workdayStart value. Default value is "9:00am"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getZoneCanvas
Note : This API is non-functional (always returns null) and exists only to make you aware that this MultiAutoChild exists. SeeUsing AutoChildren
for details.AutoChild component created for each
zone
entry.- Returns:
- null
-
setZones
An array of CalendarEvent instances representing pre-defined periods of time to be highlighted intimeline views
. Each zone renders out azone canvas
, a special, non-interactive subclass ofEventCanvas
, which spans all lanes and draws behind any normal, interactive events in the zorder.The default
style
for these components renders them semi-transparent and with a bottom-aligned title label.
If this method is called after the component has been drawn/initialized: Sets thezones
used to highlight areas of this calendar.- Parameters:
zones
- array of zones to display. Default value is null- Returns:
Calendar
instance, for chaining setter calls
-
getZones
An array of CalendarEvent instances representing pre-defined periods of time to be highlighted intimeline views
. Each zone renders out azone canvas
, a special, non-interactive subclass ofEventCanvas
, which spans all lanes and draws behind any normal, interactive events in the zorder.The default
style
for these components renders them semi-transparent and with a bottom-aligned title label.- Returns:
- Current zones value. Default value is null
-
setZoneStyleName
- Parameters:
zoneStyleName
- New zoneStyleName value. Default value is "zoneCanvas"- Returns:
Calendar
instance, for chaining setter calls- See Also:
-
getZoneStyleName
- Returns:
- Current zoneStyleName value. Default value is "zoneCanvas"
- See Also:
-
setZoneTitleOrientation
public Calendar setZoneTitleOrientation(VerticalAlignment zoneTitleOrientation) throws IllegalStateException The vertical alignment of the header-text in eachzone
.- Parameters:
zoneTitleOrientation
- New zoneTitleOrientation value. Default value is "bottom"- Returns:
Calendar
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getZoneTitleOrientation
The vertical alignment of the header-text in eachzone
.- Returns:
- Current zoneTitleOrientation value. Default value is "bottom"
-
addCalendarEvent
Create a new event in this calendar.In all cases, the
event
passed as the first parameter must have at least astart date
set. If the calendar is showinglanes
, the name of thelane
and, if applicable, thesublane
, must also be set.To deal with errors during saving, see
Calendar.eventSaveError()
.- Parameters:
event
- the new calendar event to add
-
addCalendarEvent
Create a new event in this calendar.In all cases, the
event
passed as the first parameter must have at least astart date
set. If the calendar is showinglanes
, the name of thelane
and, if applicable, thesublane
, must also be set.To deal with errors during saving, see
Calendar.eventSaveError()
.- Parameters:
event
- the new calendar event to addcustomValues
- additional, custom values to be saved with the event
-
addIndicator
Adds a newindicator
to the calendar.- Parameters:
indicator
- a new indicator to add to the calendar
-
addLane
Adds a newLane
to the calendar, for display in thetimeline view
, and in theday view
ifshowDayLanes
is true.- Parameters:
lane
- a new Lane object to add to the calendar
-
addLaneEvent
Deprecated.in favor ofaddCalendarEvent()
ForTimeline
s, and fordayView
withshowDayLanes
set, creates a new event and adds it to a particularLane
.- Parameters:
laneName
- the Lane in which to add this eventstartDate
- start date of event, or CalendarEvent Object
-
addLaneEvent
-
addLaneEvent
-
addLaneEvent
-
addLaneEvent
public void addLaneEvent(Lane laneName, Date startDate, Date endDate, String name, String description, Object otherFields) Deprecated.in favor ofaddCalendarEvent()
ForTimeline
s, and fordayView
withshowDayLanes
set, creates a new event and adds it to a particularLane
.- Parameters:
laneName
- the Lane in which to add this eventstartDate
- start date of event, or CalendarEvent ObjectendDate
- end date of eventname
- name of eventdescription
- description of eventotherFields
- new values of additional fields to be updated
-
addZone
Adds a newzone
to the calendar.- Parameters:
zone
- a new zone to add to the calendar
-
addBackgroundClickHandler
Add a backgroundClick handler.Callback fired when the mouse is clicked in a background-cell, ie, one without an event.
- Specified by:
addBackgroundClickHandler
in interfaceHasBackgroundClickHandlers
- Parameters:
handler
- the backgroundClick handler- Returns:
HandlerRegistration
used to remove this handler
-
addBackgroundMouseDownHandler
Add a backgroundMouseDown handler.Callback fired when the mouse button is depressed over a background-cell, ie, one without an event. Call
BackgroundMouseDownEvent.cancel()
from withinBackgroundMouseDownHandler.onBackgroundMouseDown(com.smartgwt.client.widgets.calendar.events.BackgroundMouseDownEvent)
to cancel the default behavior of allowing sweep selection via dragging.- Specified by:
addBackgroundMouseDownHandler
in interfaceHasBackgroundMouseDownHandlers
- Parameters:
handler
- the backgroundMouseDown handler- Returns:
HandlerRegistration
used to remove this handler
-
addBackgroundMouseUpHandler
Add a backgroundMouseUp handler.Notification method fired when the mouse button is released over a background-cell, ie, one without an event. Call
BackgroundMouseUpEvent.cancel()
from withinBackgroundMouseUpHandler.onBackgroundMouseUp(com.smartgwt.client.widgets.calendar.events.BackgroundMouseUpEvent)
to cancel the default behavior of showing a dialog to add a new event with the passed dates.- Specified by:
addBackgroundMouseUpHandler
in interfaceHasBackgroundMouseUpHandlers
- Parameters:
handler
- the backgroundMouseUp handler- Returns:
HandlerRegistration
used to remove this handler
-
cancelEditing
public void cancelEditing()Cancels the current edit-session, closing the builtin eventdialog
oreditor
and clearing any visible edit-selection from thecurrent CalendarView
. -
createEventCanvasComponent
Called fromEventCanvas.setEvent()
whenshowEventCanvasComponents
is true and an eventCanvas needs a component. The method is expected to create and return a single component to apply as a space-filling member of the passedEventCanvas
in theview
in which it appears.By default, this method returns a
DetailViewer
showing values from the associated event, according to the fields in the Calendar'sdataSource
, or the default event-fields if no dataSource is present.However, the component can be any
canvas-based
widget, including a Layout containing an arrangement of other widgets. When applied as a member of an eventCanvas, the component fills its container and limits its own content to that size, showing scrollbars as appropriate.See
updateEventCanvasComponent()
for details on updating components that have already been created and applied.- Parameters:
canvas
- the eventCanvas to get the component for- Returns:
- any Canvas
- See Also:
-
addCurrentViewChangedHandler
Add a currentViewChanged handler.Notification that fires whenever the current view changes via the
mainView tabset
.- Specified by:
addCurrentViewChangedHandler
in interfaceHasCurrentViewChangedHandlers
- Parameters:
handler
- the currentViewChanged handler- Returns:
HandlerRegistration
used to remove this handler
-
addDateChangedHandler
Add a dateChanged handler.Fires whenever the user changes the current date, including picking a specific date or navigating to a new week or month.
- Specified by:
addDateChangedHandler
in interfaceHasDateChangedHandlers
- Parameters:
handler
- the dateChanged handler- Returns:
HandlerRegistration
used to remove this handler
-
addDayBodyClickHandler
Add a dayBodyClick handler.Called when the body area of a day in the month view is clicked on, outside of any links to a particular event.
By default, if the user can add events, shows a dialog for adding a new event for that day. Call
DayBodyClickEvent.cancel()
from withinDayBodyClickHandler.onDayBodyClick(com.smartgwt.client.widgets.calendar.events.DayBodyClickEvent)
to cancel this action.Note that, when
Calendar.otherDayClickNavigation
is true, the calendar will first navigate the Month view to the selected month, before showing the Event Editor dialog at the proper location.Not called if the day falls outside the current month and
Calendar.showOtherDays
is false.- Specified by:
addDayBodyClickHandler
in interfaceHasDayBodyClickHandlers
- Parameters:
handler
- the dayBodyClick handler- Returns:
HandlerRegistration
used to remove this handler
-
addDayHeaderClickHandler
Add a dayHeaderClick handler.Called when the header area of a day in the month view is clicked on.
By default, moves to the day tab and shows the clicked days events. Call
DayHeaderClickEvent.cancel()
from withinDayHeaderClickHandler.onDayHeaderClick(com.smartgwt.client.widgets.calendar.events.DayHeaderClickEvent)
to cancel this action.Not called if the day falls outside the current month and
Calendar.showOtherDays
is false.- Specified by:
addDayHeaderClickHandler
in interfaceHasDayHeaderClickHandlers
- Parameters:
handler
- the dayHeaderClick handler- Returns:
HandlerRegistration
used to remove this handler
-
deselectEvent
Removes an event from the list of selected events in the current view, clearing its selected style.- Parameters:
event
- the event to deselect- Returns:
- true if the selection was changed, false otherwise
-
deselectEvents
Removes one or more events from the list of selected events in the current view, clearing their selected styles.- Parameters:
events
- the events to deselect- Returns:
- true if the selection was changed, false otherwise
-
addEventAddedHandler
Add a eventAdded handler.Notification fired whenever a user adds an event.
In a calendar with a DataSource, eventAdded() fires after the event has been successfully added at the server
- Specified by:
addEventAddedHandler
in interfaceHasEventAddedHandlers
- Parameters:
handler
- the eventAdded handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventChangedHandler
Add a eventChanged handler.Notification fired whenever a user changes an event, whether by dragging the event or by editing it in a dialog.
In a calendar with a DataSource, eventChanged() fires after the updated event has been successfully saved to the server
- Specified by:
addEventChangedHandler
in interfaceHasEventChangedHandlers
- Parameters:
handler
- the eventChanged handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventClickHandler
Add a eventClick handler.Called whenever an event is clicked on in the day, week or month views.
By default, a dialog appears showing details for the event, and offering the ability to edit events that can be edited. Call
CalendarEventClick.cancel()
from withinEventClickHandler.onEventClick(com.smartgwt.client.widgets.calendar.events.CalendarEventClick)
to cancel the default action. This is a good place to, for example, show a completely customized event dialog instead of the default one.- Specified by:
addEventClickHandler
in interfaceHasEventClickHandlers
- Parameters:
handler
- the eventClick handler- Returns:
HandlerRegistration
used to remove this handler
-
eventMoved
Deprecated.in favor ofCalendar.eventRepositionStop()
Called when an event is moved via dragging by a user. Return false to disallow the move.- Parameters:
newDate
- new start date and time that the event is being moved toevent
- the event as it will be after this movementnewLane
- the name of the lane into which the event was moved- Returns:
- return false to disallow the move.
-
addEventRemoveClickHandler
Add a eventRemoveClick handler.Called whenever the close icon of an
event canvas
is clicked in theday
,week
andtimeline
views, or when theremove button
is pressed in theevent editor
.Implement this method to intercept the automatic removal of data. You can Call
CalendarEventRemoveClick.cancel()
from withinEventRemoveClickHandler.onEventRemoveClick(com.smartgwt.client.widgets.calendar.events.CalendarEventRemoveClick)
to prevent the default action (callingremoveEvent()
) and instead take action of your own. For example, returning false from this method and then showing a custom confirmation dialog - if the user cancels, do nothing, otherwise make a call toremoveEvent(event)
, passing the event.- Specified by:
addEventRemoveClickHandler
in interfaceHasEventRemoveClickHandlers
- Parameters:
handler
- the eventRemoveClick handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventRemovedHandler
Add a eventRemoved handler.Notification fired whenever a user removes an event.
In a calendar with a DataSource, eventRemoved() fires after the event has been successfully removed from the server
- Specified by:
addEventRemovedHandler
in interfaceHasEventRemovedHandlers
- Parameters:
handler
- the eventRemoved handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventRepositionMoveHandler
Add a eventRepositionMove handler.Notification called whenever the drop position of an event being drag-moved changes.
The
newEvent
parameter represents the event as it will be after the move, includingstart
andend
dates andlane
andsublane
where applicable.Call
EventRepositionMove.cancel()
from withinEventRepositionMoveHandler.onEventRepositionMove(com.smartgwt.client.widgets.calendar.events.EventRepositionMove)
to prevent the default action, of positioning the drag canvas to the newEvent.- Specified by:
addEventRepositionMoveHandler
in interfaceHasEventRepositionMoveHandlers
- Parameters:
handler
- the eventRepositionMove handler- Returns:
HandlerRegistration
used to remove this handler
-
eventRepositionStart
Notification fired when a user drags an EventCanvas. Return false to cancel the drag.- Parameters:
event
- the event that's about to be moved- Returns:
- return false to cancel the default drag start behavior
-
addEventRepositionStopHandler
Add a eventRepositionStop handler.Notification called when an event being drag-moved is dropped.
The
newEvent
parameter represents the event as it will be after the move, includingstart
andend
dates andlane
andsublane
where applicable.Call
EventRepositionStop.cancel()
from withinEventRepositionStopHandler.onEventRepositionStop(com.smartgwt.client.widgets.calendar.events.EventRepositionStop)
to prevent the default action, of actuallyupdating
the event.- Specified by:
addEventRepositionStopHandler
in interfaceHasEventRepositionStopHandlers
- Parameters:
handler
- the eventRepositionStop handler- Returns:
HandlerRegistration
used to remove this handler
-
eventResized
Deprecated.in favor ofCalendar.eventResizeStop()
Called when an event is resized with the mouse. The passed date value is the new *end* date for the event, since resizing can only be performed on the bottom edge of an event in normal calendar views.- Parameters:
newDate
- new end date and time that event is being resized toevent
- the event as it will be after this resize- Returns:
- return false to disallow the resize
-
addEventResizeMoveHandler
Add a eventResizeMove handler.Notification called on each resize during an event drag-resize operation.
The
newEvent
parameter represents the event as it will be after the resize.Call
EventResizeMove.cancel()
from withinEventResizeMoveHandler.onEventResizeMove(com.smartgwt.client.widgets.calendar.events.EventResizeMove)
to prevent the default action, of resizing the drag canvas to the newEvent.- Specified by:
addEventResizeMoveHandler
in interfaceHasEventResizeMoveHandlers
- Parameters:
handler
- the eventResizeMove handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventResizeStopHandler
Add a eventResizeStop handler.Notification called when an event drag-resize operation completes.
The
newEvent
parameter represents the event as it will be after the move.Call
EventResizeStop.cancel()
from withinEventResizeStopHandler.onEventResizeStop(com.smartgwt.client.widgets.calendar.events.EventResizeStop)
to prevent the default action, of actuallyupdating
the event.- Specified by:
addEventResizeStopHandler
in interfaceHasEventResizeStopHandlers
- Parameters:
handler
- the eventResizeStop handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventSaveErrorHandler
Add a eventSaveError handler.Notification method fired when an attempt to save
an event
following edits or drag-movements results in an error from the server. May be overridden to handle specific errors and provide feedback to the user or push a server-provided record to client caches with a call toupdateCaches()
, for example.The
scenarioCode
parameter may be used to determinehow the save was initiated
.Return false from this method to cancel builtin behavior, which is as follows:
If a save happened because an event-canvas was moved or sized with the mouse, and any kind of error occurs, the event is restored to it's pre-save position - if this method specifically returns true, the errors are also sent to
central error handling
, which will show them to the user in a simple error dialog.If a save happened because an event was edited in the
Calendar.eventDialog
orCalendar.eventEditor
windows and a validation error occurs, the window is re-opened for editing with the validation errors visible. If any other kind of error occurs, the window will not be re-opened and, if this method specifically returns true, the error will be sent tocentral error handling
which will show a simple error dialog to the end user.In all cases, if the server returned an updated record despite the save failing (eg, perhaps the server enforces optimistic locking and the underlying record has been changed by another user), it is assumed to be a latest-version of the record and is applied instead of the original record during those builtin UI processes. So, the
Calendar.eventEditor
andCalendar.eventDialog
will show any changes from the latest-record. If the save was caused by dragging an event and the event'sstart
orend
dates are different in the latest-record, the EventCanvas will be positioned using the latest values, instead of returning to it's pre-save position on-screen.- Specified by:
addEventSaveErrorHandler
in interfaceHasEventSaveErrorHandlers
- Parameters:
handler
- the eventSaveError handler- Returns:
HandlerRegistration
used to remove this handler
-
addEventsRenderedHandler
Add a eventsRendered handler.A notification method fired when the events in the current view have been refreshed.
- Specified by:
addEventsRenderedHandler
in interfaceHasEventsRenderedHandlers
- Parameters:
handler
- the eventsRendered handler- Returns:
HandlerRegistration
used to remove this handler
-
getActiveDay
Gets the day of the week (0-6) that the mouse is currently over.- Returns:
- the day that the mouse is currently over
- See Also:
-
getActiveTime
Gets a date object representing the date over which the mouse is hovering for the current selected view. For month view, the time will be set to midnight of the active day. For day and week views, the time will be the rounded to the closest half hour relative to the mouse position.- Returns:
- the date that the mouse is over
-
getCellDate
Return the Date instance associated with the passed co-ordinates in the passed or selected view. If the cell at the passed co-ordinates is not a date-cell, returns null. If rowNum and colNum are both unset, returns the date from the cell under the mouse.To determine the date at a more specific point within a cell, see
getDateFromPoint()
.- Returns:
- the date, if any, associated with the passed co-ords in the appropriate view
-
getCellDate
- See Also:
-
getCellDate
- See Also:
-
getCellDate
Return the Date instance associated with the passed co-ordinates in the passed or selected view. If the cell at the passed co-ordinates is not a date-cell, returns null. If rowNum and colNum are both unset, returns the date from the cell under the mouse.To determine the date at a more specific point within a cell, see
getDateFromPoint()
.- Parameters:
rowNum
- the row number to get the date forcolNum
- the column number to get the date forview
- the view to use - uses the selected view if not passed- Returns:
- the date, if any, associated with the passed co-ords in the appropriate view
-
getCellHoverHTML
public String getCellHoverHTML(CalendarView view, Record record, Integer rowNum, Integer colNum, Date date, String defaultValue) Returns the hover HTML for the cell at the passed co-ordinates in the passed view. By default, the hover text is the snap date closest to the mouse, if the cell being hovered is a normal date cell - otherwise, it is the title of thelaneField
being hovered over.Override here to return custom HTML for the passed cell.
- Parameters:
view
- the CalendarView the mouse is hovered overrecord
- The record containing the cell being hoveredrowNum
- The rowNum of the cell being hoveredcolNum
- the colNum of the cell being hovereddate
- the snap-date at the mouse, which may be different from the result of a call togetCellDate
defaultValue
- the default hover text for the passed values- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getDateCellAlign
WhengetDateHTML
returns a value, this method returns the horizontal alignment for that value in its cell, in the passed view.- Parameters:
date
- the date to get the cell-alignment forrowNum
- the row number containing the date to get the cell-alignment forcolNum
- the column number containing the date to get the cell-alignment forview
- the relevant CalendarView- Returns:
- cell-alignment for content in the cell with the passed date and rowNum/colNum.
See
HTMLString
- See Also:
-
getDateHTML(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCellVAlign(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateStyle(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCSSText(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
-
getDateCellVAlign
WhengetDateHTML
returns a value, this method returns the vertical alignment for that value in its cell, in the passed view.- Parameters:
date
- the date to get the cell-alignment forrowNum
- the row number containing the date to get the cell-alignment forcolNum
- the column number containing the date to get the cell-alignment forview
- the relevant CalendarView- Returns:
- vertical-alignment for content in the cell with the passed date and rowNum/colNum.
See
HTMLString
- See Also:
-
getDateHTML(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCellAlign(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateStyle(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCSSText(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
-
getDateCSSText
Return CSS text for styling the cell associated with the passed date and/or rowNum & colNum, which will be applied in addition to the CSS class for the cell, as overrides."CSS text" means semicolon-separated style settings, suitable for inclusion in a CSS stylesheet or in a STYLE attribute of an HTML element.
- Parameters:
date
- the date to return CSS text forrowNum
- the row number containing the date to get the CSS forcolNum
- the column number containing the date to get the CSS forview
- the relevant CalendarView- Returns:
- CSS text for the cell with the passed date and rowNum/colNum
- See Also:
-
getDateFromPoint
Returns a Date instance representing the point at the passed offsets into the body of the current view.If snapOffsets is passed as false, returns the date representing the exact position of the passed offsets. If unset or passed as true, returns the date at the nearest eventSnapGap to the left, for
Timeline
s, or above forday
andweek
views.If neither x nor y offsets are passed, assumes them from the last mouse event.
If the cell at the eventual offsets is not a date-cell, returns null.
Note that, for the
month view
, this method is functionally equivalent togetCellDate()
, which determines the date associated with a cell, without the additional offset precision offered here.- Returns:
- the date, if any, associated with the passed co-ords in the current view
-
getDateFromPoint
- See Also:
-
getDateFromPoint
- See Also:
-
getDateFromPoint
- See Also:
-
getDateFromPoint
Returns a Date instance representing the point at the passed offsets into the body of the current view.If snapOffsets is passed as false, returns the date representing the exact position of the passed offsets. If unset or passed as true, returns the date at the nearest eventSnapGap to the left, for
Timeline
s, or above forday
andweek
views.If neither x nor y offsets are passed, assumes them from the last mouse event.
If the cell at the eventual offsets is not a date-cell, returns null.
Note that, for the
month view
, this method is functionally equivalent togetCellDate()
, which determines the date associated with a cell, without the additional offset precision offered here.- Parameters:
x
- the x offset into the body of the selected view - non-functional for theday view
. If this param and "y" are both unset, assumes both offsets from the last mouse event.y
- the y offset into the body of the selected view - non-functional for thetimeline view
. If this param and "x" are both unset, assumes both offsets from the last mouse event.snapOffsets
- whether to snap the offsets to the nearest eventSnapGap - if unset, the default is trueview
- the view to use - or the selected view if not passed- Returns:
- the date, if any, associated with the passed co-ords in the current view
-
getDateHeaderTitle
Return the title text to display in the header-button of the ListGridField showing the passed date, in the passed view.- Parameters:
date
- the date to return the header-title for - note that themonth view
does not pass this parameter because a single column represents multiple datesdayOfWeek
- the week-day number of the passed date, except for themonth view
, where no date is passed, because the week-day number represents multiple dates.defaultValue
- the default header-title for the passed date and viewview
- the relevant CalendarView- Returns:
- the text to show in the header-button for the passed date/field
-
getDateHTML
Return the HTML to be displayed in the associated date-cell in the passed view. Note that themonth view
has default cell HTML, controlled viagetDayBodyHTML()
.- Parameters:
date
- the date to get the HTML forrowNum
- the row number containing the date to get the HTML forcolNum
- the column number containing the date to get the HTML forview
- the relevant CalendarView- Returns:
- HTML to display in the cell with the passed date and rowNum/colNum.
See
HTMLString
- See Also:
-
getDateCellAlign(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCellVAlign(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateStyle(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDateCSSText(java.util.Date, java.lang.Integer, java.lang.Integer, com.smartgwt.client.widgets.calendar.CalendarView)
getDayBodyHTML(java.util.Date, com.smartgwt.client.widgets.calendar.CalendarEvent[], com.smartgwt.client.widgets.calendar.Calendar, int, int)
-
getDateStyle
Return the CSS styleName for the associated date-cell in the passed view.- Parameters:
date
- the date to return the CSS styleName forrowNum
- the row number containing the date to get the CSS styleName forcolNum
- the column number containing the date to get the CSS styleName forview
- the relevant CalendarView- Returns:
- CSS style for the cell with the passed date and rowNum/colNum.
See
CSSStyleName
- See Also:
-
getDragHoverHTML
Returns the HTML to show in a hover when an existing event is dragged, or when a new event is being created by dragging with the mouse.- Parameters:
view
- the CalendarView the mouse is hovered overevent
- the CalendarEvent attached to the EventCanvas being draggeddefaultValue
- the default text for the passed values- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getEventBodyHTML
Returns the description text for the passed event, for display in the body area of an event canvas. The default implementation returns the event'sdescription field
.- Parameters:
event
- the event to get the description text for- Returns:
- the HTML to display in the body of the passed event's EventCanvas.
See
HTMLString
-
getEventBodyHTML
Returns the description text for the passed event, for display in the body area of an event canvas. The default implementation returns the event'sdescription field
.- Parameters:
event
- the event to get the description text forview
- the view in which the event is being rendered- Returns:
- the HTML to display in the body of the passed event's EventCanvas.
See
HTMLString
-
getEventCanvasStyle
Returns thestyleName
to use for the passedevent
, in the passedview
. By default, returns the styleon the event
, if one is specified - otherwise, inlane-based
views, it returns the style specified on thelane or sublane
, or the style specified on thecalendar
.- Parameters:
event
- the event to get the CSS style for- Returns:
- the CSS style to apply to the passed event in the passed view.
See
CSSStyleName
-
getEventCanvasStyle
Returns thestyleName
to use for the passedevent
, in the passedview
. By default, returns the styleon the event
, if one is specified - otherwise, inlane-based
views, it returns the style specified on thelane or sublane
, or the style specified on thecalendar
.- Parameters:
event
- the event to get the CSS style forview
- the CalendarView that contains the canvas being styled- Returns:
- the CSS style to apply to the passed event in the passed view.
See
CSSStyleName
-
getEventEndDate
Returns theend date
of the passed event. If the event isduration-based
, the result is calculated from thestart date
and the specifiedduration
andunit
.- Parameters:
event
- the event to get the start date of- Returns:
- the end date of the passed event
-
getEventHeaderHTML
Returns the title text for the passed event, which is displayed in the header area of an eventCanvas rendered in a vertical or horizontal view, or as a clickable link in a cell in aMonth view
.The default implementation returns the event's
name field
for timelines, and that same value pre-pended with the event'sstart
for day, week and month views.- Parameters:
event
- the event to get the description text for- Returns:
- the HTML to display in the header of an event canvas.
See
HTMLString
-
getEventHeaderHTML
Returns the title text for the passed event, which is displayed in the header area of an eventCanvas rendered in a vertical or horizontal view, or as a clickable link in a cell in aMonth view
.The default implementation returns the event's
name field
for timelines, and that same value pre-pended with the event'sstart
for day, week and month views.- Parameters:
event
- the event to get the description text forview
- the view in which the event is being rendered- Returns:
- the HTML to display in the header of an event canvas.
See
HTMLString
-
getEventHoverHTML
Gets the hover HTML for an event being hovered over. Override here to return custom HTML based upon the parameter event object.- Parameters:
event
- The event being hoveredeventCanvas
- the event canvas being hovered overview
- the CalendarView in which the eventCanvas lives- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getEventHoverHTML
public String getEventHoverHTML(CalendarEvent event, EventCanvas eventCanvas, CalendarView view, String defaultValue) Gets the hover HTML for an event being hovered over. Override here to return custom HTML based upon the parameter event object.- Parameters:
event
- The event being hoveredeventCanvas
- the event canvas being hovered overview
- the CalendarView in which the eventCanvas livesdefaultValue
- the default HTML to show when hovering over the passed event- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getEventLane
Returns thelane
associated with the passed event, in the passed view- Parameters:
event
- the event to get the lane for- Returns:
- the lane associated with the passed event
-
getEventLane
Returns thelane
associated with the passed event, in the passed view- Parameters:
event
- the event to get the lane forview
- the view to get the lane object from- Returns:
- the lane associated with the passed event
-
getEventLength
Returns the length of the passedevent
in the passedunit
. Ifunit
isn't passed, returns the length of the event in milliseconds.- Parameters:
event
- the event to get the length of
-
getEventLength
Returns the length of the passedevent
in the passedunit
. Ifunit
isn't passed, returns the length of the event in milliseconds.- Parameters:
event
- the event to get the length ofunit
- the time unit to return the length in, milliseconds if not passed
-
getEventStartDate
Returns thestart date
of the passed event.- Parameters:
event
- the event to get the start date of- Returns:
- the start date of the passed event
-
getEventSublane
Returns thesublane
associated with the passed event, in the passed view- Parameters:
event
- the event to get the sublane for- Returns:
- the sublane associated with the passed event
-
getEventSublane
Returns thesublane
associated with the passed event, in the passed view- Parameters:
event
- the event to get the sublane forview
- the view to get the sublane object from- Returns:
- the sublane associated with the passed event
-
getHeaderHoverHTML
public String getHeaderHoverHTML(CalendarView view, HeaderLevel headerLevel, Date startDate, Date endDate, String defaultValue) Returns the hover HTML to show in a hover when the mouse moves over the header area.- Parameters:
view
- the CalendarView the mouse is hovered overheaderLevel
- the header level hovered overstartDate
- the start date of the span being hovered overendDate
- the end date of the span being hovered overdefaultValue
- the default text for the passed header level and date range- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getIndicatorCanvasStyle
Returns thestyleName
to use for the passedindicator
, in the passedview
. By default, returns the styleon the indicator
, if one is specified, or the style specified on thecalendar
otherwise.- Parameters:
indicator
- the indicator to get the CSS style for- Returns:
- See
CSSStyleName
-
getIndicatorCanvasStyle
Returns thestyleName
to use for the passedindicator
, in the passedview
. By default, returns the styleon the indicator
, if one is specified, or the style specified on thecalendar
otherwise.- Parameters:
indicator
- the indicator to get the CSS style forview
- the CalendarView that contains the canvas being styled- Returns:
- See
CSSStyleName
-
getIndicatorHoverHTML
public String getIndicatorHoverHTML(CalendarEvent indicator, IndicatorCanvas indicatorCanvas, CalendarView view, String defaultValue) Gets the hover HTML for anindicator
being hovered over. Override here to return custom HTML based upon the parameter indicator object.- Parameters:
indicator
- The indicator being hovered overindicatorCanvas
- the indicator canvas being hovered overview
- the CalendarView in which the indicatorCanvas is displayeddefaultValue
- the default HTML to show when hovering over the passed Indicator- Returns:
- the HTML to show in the hover.
See
HTMLString
-
getLane
Returns thelane
with the passed name, in the passed view- Parameters:
lane
- the name of the lane to return- Returns:
- the lane with the passed name, or null if not found
-
getLane
Returns thelane
with the passed name, in the passed view- Parameters:
lane
- the name of the lane to returnview
- the view to get the lane object from- Returns:
- the lane with the passed name, or null if not found
-
getLaneEvents
For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.- Parameters:
lane
- lane object or name to get the events for- Returns:
- the list of events that apply to the passed lane and view
-
getLaneEvents
For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.- Parameters:
lane
- lane object or name to get the events for- Returns:
- the list of events that apply to the passed lane and view
-
getLaneEvents
For views that supportlanes
, returns the array of events in the current dataset that apply to the passed lane in the passed or current view.- Parameters:
lane
- lane object or name to get the events forview
- the view in which the passed lane lives - uses the selected view if unset- Returns:
- the list of events that apply to the passed lane and view
-
getLaneFromPoint
Returns theLane
at the passed co-ordinates. To get the lane under the mouse, pass null for both x and y.- Returns:
- the Lane at the passed co-ords in the passed or selected view
-
getLaneFromPoint
- See Also:
-
getLaneFromPoint
- See Also:
-
getLaneFromPoint
Returns theLane
at the passed co-ordinates. To get the lane under the mouse, pass null for both x and y.- Parameters:
x
- the x offset into the body of the selected viewy
- the y offset into the body of the selected view. If this param and "x" are both unset, assumes both offsets from the last mouse event.view
- the view to get the lane from - selected view if not passed- Returns:
- the Lane at the passed co-ords in the passed or selected view
-
getLanePadding
For views that supportlanes
, returns the padding to apply to events rendered in lanes in the passed or current view. By default, returnslaneEventPadding
.- Returns:
- the padding to apply to events in lanes in the passed or current view
-
getLanePadding
For views that supportlanes
, returns the padding to apply to events rendered in lanes in the passed or current view. By default, returnslaneEventPadding
.- Parameters:
view
- the view to get the lane padding for- Returns:
- the padding to apply to events in lanes in the passed or current view
-
getMonthViewHoverHTML
This method returns the hover HTML to be displayed when the user hovers over a cell displayed in the calendar month view tab.Default implementation will display a list of the events occurring on the date the user is hovering over. Override for custom behavior. Note that returning null will suppress the hover altogether.
- Parameters:
date
- Date the user is hovering overevents
- array of events occurring on the current date. May be empty.- Returns:
- HTML string to display.
See
HTMLString
-
getPeriodEndDate
Returns the end of the period selected in the passed, or current, calendar view. For themonth view
, and for theweek view
when not showing weekends, this will often be a different date than that returned bygetVisibleEndDate()
.- Returns:
- period end date
-
getPeriodEndDate
Returns the end of the period selected in the passed, or current, calendar view. For themonth view
, and for theweek view
when not showing weekends, this will often be a different date than that returned bygetVisibleEndDate()
.- Parameters:
view
- the view to get the periodEndDate for, or current view if null- Returns:
- period end date
-
getPeriodStartDate
Returns the start of the selected week or month depending on the current calendar view. For the month view, and for the week view when not showing weekends, this will often be a different date than that returned bygetVisibleStartDate()
.- Returns:
- period start date
-
getPeriodStartDate
Returns the start of the selected week or month depending on the current calendar view. For the month view, and for the week view when not showing weekends, this will often be a different date than that returned bygetVisibleStartDate()
.- Parameters:
view
- the view to get the periodStartDate for, or current view if null- Returns:
- period start date
-
getSelectedEvent
Returns the currently selectedevent
, or the first one if more than one is selected.- Returns:
- the selected event
-
getSelectedEvents
Returns the currently selected list ofevents
.- Returns:
- the list of selected events
-
getSelectedView
Returns the currently selectedview
.- Returns:
- the currently selected view
-
getSublane
- Parameters:
lane
- the name of the lane containing the sublane to returnsublane
- the name of the sublane to return- Returns:
- the sublane with the passed name, or null if not found
-
getSublane
- Parameters:
lane
- the name of the lane containing the sublane to returnsublane
- the name of the sublane to returnview
- the view to get the sublane object from- Returns:
- the sublane with the passed name, or null if not found
-
getSublaneEvents
For views that supportlanes
and allowsublanes
, returns the array of events in the current dataset that apply to the passed lane and sublane in the passed or current view.- Parameters:
lane
- lane object or name to get the events forsublane
- sublane object or name to get the events for- Returns:
- the list of events that apply to the passed sublane and view
-
getSublaneEvents
For views that supportlanes
and allowsublanes
, returns the array of events in the current dataset that apply to the passed lane and sublane in the passed or current view.- Parameters:
lane
- lane object or name to get the events forsublane
- sublane object or name to get the events forview
- the view in which the passed sublane lives - uses the selected view if unset- Returns:
- the list of events that apply to the passed sublane and view
-
getSublaneFromPoint
Returns thesublane
at the passed co-ordinates. To get the sublane under the mouse, pass null for both x and y.- Returns:
- the sublane at the passed co-ords in the selected view
-
getSublaneFromPoint
- See Also:
-
getSublaneFromPoint
- See Also:
-
getSublaneFromPoint
Returns thesublane
at the passed co-ordinates. To get the sublane under the mouse, pass null for both x and y.- Parameters:
x
- optional x offset into the body of the selected viewy
- optional y offset into the body of the selected view. If this param and "x" are both unset, assumes both offsets from the last mouse event.view
- the view to get the sublane from - selected view if not passed- Returns:
- the sublane at the passed co-ords in the selected view
-
getView
- Parameters:
viewName
- the name of the CalendarView to return- Returns:
- the currently selected view
-
getVisibleEndDate
Returns the last visible date in the passed, or currently selected, calendar view.- Returns:
- last visible date
-
getVisibleEndDate
Returns the last visible date in the passed, or currently selected, calendar view.- Parameters:
view
- the view to get the endDate for, or current view if null- Returns:
- last visible date
-
getVisibleStartDate
Returns the first visible date in the passed, or currently selected, calendar view.- Returns:
- first visible date
-
getVisibleStartDate
Returns the first visible date in the passed, or currently selected, calendar view.- Parameters:
view
- the view to get the startDate for, or current view if- Returns:
- first visible date
-
getZoneCanvasStyle
Returns thestyleName
to use for the passedzone
, in the passedview
. By default, returns the styleon the zone
, if one is specified, or the style specified on thecalendar
otherwise.- Parameters:
zone
- the zone to get the CSS style for- Returns:
- See
CSSStyleName
-
getZoneCanvasStyle
Returns thestyleName
to use for the passedzone
, in the passedview
. By default, returns the styleon the zone
, if one is specified, or the style specified on thecalendar
otherwise.- Parameters:
zone
- the zone to get the CSS style forview
- the CalendarView that contains the canvas being styled- Returns:
- See
CSSStyleName
-
getZoneHoverHTML
public String getZoneHoverHTML(CalendarEvent zone, ZoneCanvas zoneCanvas, CalendarView view, String defaultValue) Gets the hover HTML for azone
being hovered over. Override here to return custom HTML based upon the parameter zone object.- Parameters:
zone
- The zone being hovered overzoneCanvas
- the zone canvas being hovered overview
- the CalendarView in which the zoneCanvas is displayeddefaultValue
- the default HTML to show when hovering over the passed Zone- Returns:
- the HTML to show in the hover.
See
HTMLString
-
groupLanesBy
WhencanGroupLanes
is true, this method allows the grouping intimeline
s to be altered at runtime.- Parameters:
groupFieldName
- one or more field names to group by
-
groupLanesBy
WhencanGroupLanes
is true, this method allows the grouping intimeline
s to be altered at runtime.- Parameters:
groupFieldName
- one or more field names to group by
-
addIndicatorClickHandler
Add a indicatorClick handler.Called whenever an
IndicatorCanvas
is clicked in thetimelineView
. There is no default implementation.- Specified by:
addIndicatorClickHandler
in interfaceHasIndicatorClickHandlers
- Parameters:
handler
- the indicatorClick handler- Returns:
HandlerRegistration
used to remove this handler
-
moveToEvent
Deprecated.in favor ofscrollToEvent()
.Resets the current visible range of a calendar view so that it shows the date on which the passed event occurs.- Parameters:
event
- the event to move the calendar view to
-
next
public void next()Move to the next day, week, or month, depending on which tab is selected. -
previous
public void previous()Move to the previous day, week, month, or timeline range depending on which tab is selected. -
refreshEvent
Refreshes the passed event in the current view.- Parameters:
event
- The event object to refresh in the current view
-
removeIndicator
Removes aindicator
from the calendar.Accepts either a
indicator object
or a string that represents thename
of anindicator.- Parameters:
indicator
- either the actual CalendarEvent representing the indicator, or the name of the indicator to remove
-
removeIndicator
Removes aindicator
from the calendar.Accepts either a
indicator object
or a string that represents thename
of anindicator.- Parameters:
indicator
- either the actual CalendarEvent representing the indicator, or the name of the indicator to remove
-
removeZone
Removes azone
from the calendar.Accepts either a
zone object
or a string that represents thename
of a zone.- Parameters:
zone
- either the actual CalendarEvent representing the zone, or the name of the zone to remove
-
removeZone
Removes azone
from the calendar.Accepts either a
zone object
or a string that represents thename
of a zone.- Parameters:
zone
- either the actual CalendarEvent representing the zone, or the name of the zone to remove
-
scrollToEnd
public void scrollToEnd()Move the viewport of a CalendarView to the end of its scrollable range. -
scrollToEnd
Move the viewport of a CalendarView to the end of its scrollable range.- Parameters:
view
- the view to affect, the current view if not specified
-
scrollToEvent
Scrolls thecurrent view
so the passed event is visible. If the event is outside of the view's current date-range, the default behavior is to automatically reload the view with a date-range starting at the event'sstartDate
and then scroll to the event vertically as necessary. Pass false as thecanReload
param to prevent that default behavior.- Parameters:
event
- the event to move the calendar view to
-
scrollToEvent
Scrolls thecurrent view
so the passed event is visible. If the event is outside of the view's current date-range, the default behavior is to automatically reload the view with a date-range starting at the event'sstartDate
and then scroll to the event vertically as necessary. Pass false as thecanReload
param to prevent that default behavior.- Parameters:
event
- the event to move the calendar view tocanReload
- set to false to prevent a view from automatically reloading with a new range if the passed event is not in its current scrollable range
-
scrollToStart
public void scrollToStart()Move the viewport of a CalendarView to the start of it's scrollable range. -
scrollToStart
Move the viewport of a CalendarView to the start of it's scrollable range.- Parameters:
view
- the view to affect, the current view if not specified
-
scrollToTime
Scrolls Calendarday
orweek
views to the time represented by the time parameter. This string parameter is expected to be an arbitrary logical time value in any parsable time format - no date portion is expected, but time formats like "13:31" or "1:20am" are supported.Has no effect in
timelines
, where an arbitrary time-value is inapplicable to any range or resolution greater than a day.- Parameters:
time
- any parsable time-string
-
selectEvent
Adds an event to the list of selected events in the current view, showing it in a selected style.- Parameters:
event
- the event to add to the selection- Returns:
- true if the selection was changed, false otherwise
-
selectEvents
Adds one or more events to the list of selected events in the current view, showing them in a selected style.- Parameters:
events
- the events to add to the selection- Returns:
- true if the selection was changed, false otherwise
-
selectSingleEvent
Selects a single event in the current view, showing it in a selected style and deselecting any other selected events.- Parameters:
event
- the event to select- Returns:
- true if the selection was changed, false otherwise
-
selectTab
public void selectTab(int tabnum) Selects the calendar view in the passed tab number.- Parameters:
tabnum
- the index of the tab to select
-
setEventStyle
Update the styleName for the passed event. Refreshes the event's canvas in the current view.- Parameters:
event
- The event object to refresh in the current viewstyleName
- The new CSS style to apply to the canvases showing this event. SeeCSSStyleName
-
setLaneTitle
For views that supportlanes
, updates the title for the passed lane.- Parameters:
lane
- the name of the lane to change the title fortitle
- the new title to apply- Returns:
- true if the title was updated, false otherwise
-
setResolution
Reset the resolution, the header levels and scrollable range, of the timeline view.headerLevels
specifies the array ofheaders
to show above the timeline, and theunit
andunitCount
parameters dictate the scrollable range (eg, passing "week" and 6 will create a timeline with a scrollable range of six weeks, irrespective of the number of columns that requires, according to thegranularity
).If the optional
granularityPerColumn
parameter is passed, each column will span that number of units of the granularity, which is determined from the unit of the innermost of the passed headerLevels. For example, to show a span of 12 hours with inner columns that each span 15 minutes, you could pass "hour" and "minute" -based headerLevels, unit and unitCount values of "hour" and 12 respectively, and granularityPerColumn of 15.- Parameters:
headerLevels
- the header levels to show in the timelineunit
- the time unit to use when calculating the range of the timelineunitCount
- the count of the passed unit that the timeline should span
-
setResolution
public void setResolution(HeaderLevel[] headerLevels, TimeUnit unit, Integer unitCount, Integer granularityPerColumn) Reset the resolution, the header levels and scrollable range, of the timeline view.headerLevels
specifies the array ofheaders
to show above the timeline, and theunit
andunitCount
parameters dictate the scrollable range (eg, passing "week" and 6 will create a timeline with a scrollable range of six weeks, irrespective of the number of columns that requires, according to thegranularity
).If the optional
granularityPerColumn
parameter is passed, each column will span that number of units of the granularity, which is determined from the unit of the innermost of the passed headerLevels. For example, to show a span of 12 hours with inner columns that each span 15 minutes, you could pass "hour" and "minute" -based headerLevels, unit and unitCount values of "hour" and 12 respectively, and granularityPerColumn of 15.- Parameters:
headerLevels
- the header levels to show in the timelineunit
- the time unit to use when calculating the range of the timelineunitCount
- the count of the passed unit that the timeline should spangranularityPerColumn
- how many units of the granularity (the unit of the innermost headerLevel) should each column span? The default is 1.
-
setTimelineRange
Sets the range over which the timeline will display events.If the
end
parameter is not passed, the end date of the range will default to20
columns of the currentgranularity
following the start date.- Parameters:
start
- start of range
-
setTimelineRange
Sets the range over which the timeline will display events.If the
end
parameter is not passed, the end date of the range will default to20
columns of the currentgranularity
following the start date.- Parameters:
start
- start of rangeend
- end of range
-
shouldDisableDate
Returns true if the passed date should be considered disabled. Disabled dates don't allow events to be created by clicking on them, and drag operations that would start or end on such dates are also disallowed.The default implementation returns false only for dates that fall on a
weekend
.- Parameters:
date
- a Date instance- Returns:
- true if this date should be considered disabled
-
shouldDisableDate
Returns true if the passed date should be considered disabled. Disabled dates don't allow events to be created by clicking on them, and drag operations that would start or end on such dates are also disallowed.The default implementation returns false only for dates that fall on a
weekend
.- Parameters:
date
- a Date instanceview
- the view the date appears in- Returns:
- true if this date should be considered disabled
-
shouldShowDate
Indicates whether the passed date should be visible in the passedCalendarView
.The default implementation returns true, unless the date falls on a
weekend
andshowWeekends
is false.- Parameters:
date
- a Date instance- Returns:
- true if this date should be considered disabled
-
shouldShowDate
Indicates whether the passed date should be visible in the passedCalendarView
.The default implementation returns true, unless the date falls on a
weekend
andshowWeekends
is false.- Parameters:
date
- a Date instanceview
- the view the date appears in- Returns:
- true if this date should be considered disabled
-
shouldShowEvent
Indicates whether the passedevent
should be visible in the passedCalendarView
.The default implementation returns true - note that this method only runs for events that are known to be in the accessible range and is a mechanism for extended custom filtering.
- Parameters:
event
- the event to check- Returns:
- true if this event should be displayed in the passed view
-
shouldShowEvent
Indicates whether the passedevent
should be visible in the passedCalendarView
.The default implementation returns true - note that this method only runs for events that are known to be in the accessible range and is a mechanism for extended custom filtering.
- Parameters:
event
- the event to checkview
- the view the event will be rendered in- Returns:
- true if this event should be displayed in the passed view
-
shouldShowLane
Indicates whether the passedlane
should be visible in the passedCalendarView
.The default implementation returns true, unless the lane has no events and
hideUnusedLanes
is true.- Parameters:
lane
- the lane object or name- Returns:
- true if this lane should be displayed in the passed view
-
shouldShowLane
Indicates whether the passedlane
should be visible in the passedCalendarView
.The default implementation returns true, unless the lane has no events and
hideUnusedLanes
is true.- Parameters:
lane
- the lane object or name- Returns:
- true if this lane should be displayed in the passed view
-
shouldShowLane
Indicates whether the passedlane
should be visible in the passedCalendarView
.The default implementation returns true, unless the lane has no events and
hideUnusedLanes
is true.- Parameters:
lane
- the lane object or nameview
- the view the lane appears in- Returns:
- true if this lane should be displayed in the passed view
-
showEventCanvasComponent
Should a component be applied to the passedcanvas
in theview
in which it appears? Return false from this method to override the global value ofshowEventCanvasComponents
for this canvas.- Parameters:
canvas
- should this eventCanvas get a component component?- Returns:
- boolean
- See Also:
-
showEventDialog
public void showEventDialog()Open the Quick Event dialog showing minimal information about an existingevent
.The
startDate
field on the event is used to calculate the display location for the dialog.If this method is called when the Event Dialog is already showing another event, and if changes have been made, a confirmation dialog is displayed and editing of the new event is cancelled unless confirmed.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available. -
showEventDialog
- See Also:
-
showEventDialog
Open the Quick Event dialog showing minimal information about an existingevent
.The
startDate
field on the event is used to calculate the display location for the dialog.If this method is called when the Event Dialog is already showing another event, and if changes have been made, a confirmation dialog is displayed and editing of the new event is cancelled unless confirmed.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available.- Parameters:
event
- the event to show in the EditorisNewEvent
- optional boolean indicating that this is a new event, event if an event is passed - used to pass defaults for a new event
-
showEventEditor
public void showEventEditor()Show an Event Editor for the passed event. Event Editor's fill the Calendar and allow for editing of the built-in Event fields, likename
anddescription
, as well as any custom fields supplied viaeventEditorFields
.If isNewEvent is true, a new event is created - in this case, if an event is passed, it represents default values to apply to the new event.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available. -
showEventEditor
- See Also:
-
showEventEditor
Show an Event Editor for the passed event. Event Editor's fill the Calendar and allow for editing of the built-in Event fields, likename
anddescription
, as well as any custom fields supplied viaeventEditorFields
.If isNewEvent is true, a new event is created - in this case, if an event is passed, it represents default values to apply to the new event.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available.- Parameters:
event
- an existing event to show in the EditorisNewEvent
- optional boolean indicating that this is a new event, even if an event is passed - used to pass defaults for a new event
-
showNewEventDialog
public void showNewEventDialog()Open the Quick Event dialog to begin editing a newevent
.If passed, the event parameter is used as defaults for the new event - in addition, the event's
startDate
, and itslane
, for timeline events, are used to calculate the display location for the dialog.If this method is called when the Event Dialog is already showing another event, and if changes have been made, a confirmation dialog is displayed and editing of the new event is cancelled unless confirmed.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available. -
showNewEventDialog
Open the Quick Event dialog to begin editing a newevent
.If passed, the event parameter is used as defaults for the new event - in addition, the event's
startDate
, and itslane
, for timeline events, are used to calculate the display location for the dialog.If this method is called when the Event Dialog is already showing another event, and if changes have been made, a confirmation dialog is displayed and editing of the new event is cancelled unless confirmed.
You can override this method to prevent the default action, perhaps instead showing a custom interface that performs validations or gathers custom data before making a call to
addCalendarEvent
orupdateCalendarEvent
when the new data is available.- Parameters:
event
- defaults for the new event
-
showNewEventEditor
public void showNewEventEditor()Show an Event Editor for a new event. If anevent
is passed as the parameter, it is used as defaults for the new event. -
showNewEventEditor
Show an Event Editor for a new event. If anevent
is passed as the parameter, it is used as defaults for the new event.- Parameters:
event
- defaults for the new event to show in the Editor
-
timelineEventMoved
Deprecated.in favor ofCalendar.eventRepositionStop()
Called when a Timeline event is moved via dragging by a user. Return false to disallow the move.- Parameters:
event
- the event that was movedstartDate
- new start date of the passed eventendDate
- new end date of the passed eventlane
- the Lane in which this event has been dropped- Returns:
- return false to disallow the move.
-
timelineEventResized
Deprecated.in favor ofCalendar.eventResizeStop()
Called when a Timeline event is resized via dragging by a user. Return false to disallow the resize.- Parameters:
event
- the event that was resizedstartDate
- new start date of the passed event, after the resizeendDate
- new end date of the passed event, after the resize- Returns:
- return false to disallow the resize
-
updateCalendarEvent
Save an event to this Calendar's ${isc.DocUtils.linkForRef('attr:Calendar.dataSource','dataSource) or \ndata array')
. To deal with errors while saving, seeCalendar.eventSaveError()
- Parameters:
event
- The event object that will be updatednewEvent
- The new attributes for the eventotherFields
- new values of additional fields to be updated
-
updateEventCanvasComponent
Called fromEventCanvas.setEvent()
whenshowEventCanvasComponents
is true and the eventCanvas already has acomponent
. This method is expected to update the passedcomponent
as necessary, based on thecurrent event
.By default, if the passed
component
has methods calledsetEvent
orsetData
, those methods are called automatically.- Parameters:
canvas
- the eventCanvas to update the component forcomponent
- the component to be updated the canvas in question- See Also:
-
addZoneClickHandler
Add a zoneClick handler.Called whenever a
ZoneCanvas
is clicked in thetimelineView
. There is no default implementation.- Specified by:
addZoneClickHandler
in interfaceHasZoneClickHandlers
- Parameters:
handler
- the zoneClick handler- Returns:
HandlerRegistration
used to remove this handler
-
setDefaultProperties
Class level method to set the default properties of this class. If set, then all existing and subsequently created instances of this class will automatically have default properties corresponding to the properties set on the SmartGWT class instance passed to this function before its underlying SmartClient JS object was created. This is a powerful feature that eliminates the need for users to create a separate hierarchy of subclasses that only alter the default properties of this class. Can also be used for skinning / styling purposes.Note: This method is intended for setting default attributes only and will affect all instances of the underlying class (including those automatically generated in JavaScript). This method should not be used to apply standard EventHandlers or override methods for a class - use a custom subclass instead. Calling this method after instances have been created can result in undefined behavior, since it bypasses any setters and a class instance may have already examined a particular property and not be expecting any changes through this route.
- Parameters:
calendarProperties
- properties that should be used as new defaults when instances of this class are created- See Also:
-
onInit
protected void onInit() -
onInit_Calendar
protected void onInit_Calendar() -
getWorkdayStart
When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.Both start and end time must fall on a 30 minute increment (eg 9:30, but not 9:45).
The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.Note: This is an override point
- Parameters:
date
- the date to get the workday start forlaneName
- the name of the lane ifshowDayLanes
is true, or null otherwise- Returns:
- Returns the start of the working day on the passed date. By default, this method
returns the value of
workdayStart
. Default value is "9:00am"
-
getWorkdayStart
-
getWorkdayEnd
When usingshowWorkday
:true,workdayStart
andworkdayEnd
specify the time of day when the workday starts and ends, specified as a String acceptable to String.Both start and end time must fall on a 30 minute increment (eg 9:30, but not 9:45).
The hours of the workday can be customized for particular dates by providing implementations of
getWorkdayStart()
andgetWorkdayEnd()
.Note: This is an override point
- Parameters:
date
- the date to get the workday end forlaneName
- the name of the lane ifshowDayLanes
is true, or null otherwise- Returns:
- Returns the end of the working day on the passed date. By default, this method
returns the value of
workdayEnd
. Default value is "5:00pm"
-
getWorkdayEnd
-
dateIsWorkday
Should the parameter date be considered a workday? By default this method tries to find the parameter date day inworkdays
, and returns true if found. Override this method to provide custom logic for determining workday, for example returning false on holidays.Note that, when showing
vertical lanes
in theday view
, this method is also passed the name of the associated lane.Note: This is an override point
- Parameters:
date
- date to check for being a workdaylaneName
- the name of the lane ifshowDayLanes
is true, or null otherwise- Returns:
- true if date is a workday, false otherwise
-
dateIsWorkday
-
getDayBodyHTML
protected String getDayBodyHTML(Date date, CalendarEvent[] events, Calendar calendar, int rowNum, int colNum) Return the HTML to be shown in the body of a day in the month view.Default is to render a series of links that call
Calendar.eventClick
to provide details and/or an editing interface for the events.getDayBodyHTML()
is not called for days outside of the current month ifshowOtherDays
is false.- Parameters:
date
- JavaScript Date object representing this dayevents
- events that fall on this daycalendar
- the calendar itselfrowNum
- the row number to which the parameter date belongscolNum
- the column number to which the parameter date belongs- Returns:
- HTML to display
-
getDateLabelText
Returns the text to display with the navigation buttons above the Calendar - indicates the visible date range.Note: This is an override point.
- Parameters:
viewName
- one of "day", "week", "month" or "timeline"startDate
- the start of the visible date rangeendDate
- the optional end of the visible date range. May be null.- Returns:
- a formmatted date or date-range string appropriate to the passed view
-
setEventEditorCustomizer
Customizer called whenever the Calender needs to show an EventEditor, to edit or create a CalendarEvent- Parameters:
customizer
- the customizer to execute.
-
setEventDialogCustomizer
Customizer called whenever the Calender needs to show an EventDialog, to edit or view a CalendarEvent- Parameters:
customizer
- the customizer to execute.
-
setEventHeaderHTMLCustomizer
This method returns the HTML to be used as the header/title for the passed event.- Parameters:
customizer
- the customizer to execute.
-
setEventBodyHTMLCustomizer
This method installs a customizer that returns the HTML to be used as the body/description for the passed event.- Parameters:
customizer
- the customizer to execute.
-
setDateStyleCustomizer
This method installs a customizer that returns the CSS class name for the passed date-cell when rendered in the passed view- Parameters:
customizer
- the customizer to execute.
-
setDateHeaderCustomizer
This method installs a customizer to determine the HTML to be displayed in the header for a given date column in a CalendarView- Parameters:
customizer
- the customizer to execute.
-
setDateHTMLCustomizer
This method installs a customizer that returns the HTML to display in the passed date-cell when rendered in the passed view- Parameters:
customizer
- the customizer to execute.
-
setDateCellAlignCustomizer
This method installs a customizer that returns the horizontsal Alignment to display in the passed date-cell when rendered in the passed view- Parameters:
customizer
- the customizer to execute.
-
setDateCellVAlignCustomizer
This method installs a customizer that returns the VerticalAlignment to display in the passed date-cell when rendered in the passed view- Parameters:
customizer
- the customizer to execute.
-
setDateCSSTextCustomizer
This method returns the CSS class name for the passed event when rendered in the passed view- Parameters:
customizer
- the customizer to execute.
-
setDisableDateCustomizer
Return true from the customizer to have the passed event considered disabled in the passed view- Parameters:
customizer
- the customizer to execute.
-
setShowDateCustomizer
This method is called during rendering for all events in the visible range - those which would be rendered by default. The customizer should return false to prevent the passed date from appearing in the passed view.- Parameters:
customizer
- the customizer to execute.
-
setShowLaneCustomizer
Return false from the customizer to prevent the passed Lane from being rendered in the passed view.- Parameters:
customizer
- the customizer to execute.
-
setShowEventCustomizer
Return false from the customizer to prevent the passed CalendarEvent from being rendered in the passed view.- Parameters:
customizer
- the customizer to execute.
-
setEventCanvasHoverHTMLCustomizer
This method returns the hover HTML to be displayed when the user hovers over an eventCanvas- Parameters:
customizer
- the customizer to execute.
-
setZoneHoverHTMLCustomizer
This method returns the hover HTML to be displayed when the user hovers over an ZoneCanvas- Parameters:
zoneHoverHTMLCustomizer
- the customizer to execute.
-
setIndicatorHoverHTMLCustomizer
public void setIndicatorHoverHTMLCustomizer(IndicatorHoverHTMLCustomizer indicatorHoverHTMLCustomizer) This method returns the hover HTML to be displayed when the user hovers over an IndicatorCanvas- Parameters:
indicatorHoverHTMLCustomizer
- the customizer to execute.
-
setMonthViewHoverHTMLCustomizer
public void setMonthViewHoverHTMLCustomizer(MonthViewHoverHTMLCustomizer monthViewHoverHTMLCustomizer) This method returns the hover HTML to be displayed when the user hovers over a cell displayed in the calendar month view tab.Default implementation will display a list of the events occurring on the date the user is hovering over. Override for custom behavior. Note that returning null will suppress the hover altogether.
- Parameters:
monthViewHoverHTMLCustomizer
- the customizer to execute.
-
setHeaderHoverCustomizer
Customize the Hover text for a given span in a HeaderLevel.- Parameters:
customizer
- HeaderLevelHoverCustomizer the customizer
-
setDragHoverCustomizer
Customize the Hover text to display during a drag operation- Parameters:
customizer
- DragHoverCustomizer the customizer
-
setCellHoverCustomizer
Customize the Hover text to display when the mouse hovers over cells in a CalendarView- Parameters:
customizer
- CellHoverCustomizer the customizer
-
setEventCanvasGripperIconCustomizer
This method returns the SCImgURL for the icon to use as the gripper for a given EventCanvas- Parameters:
customizer
- the customizer to execute.
-
setEventCanvasComponentCustomizer
This method sets the customizer for EventCanvasComponent methods- Parameters:
customizer
- the customizer to execute.
-
setLaneGroupStartOpen
-
setLaneGroupStartOpen
- Parameters:
groupValues
- Array of values that should be opened
-
setEventEditorFields
The set of fields for theeventEditor
.The default set of fields are:
{name: "startHours", title: "From", type: "select", width: 60}, {name: "startMinutes", showTitle: false, type: "select", width: 60}, {name: "startAMPM", showTitle: false, type: "select", width: 60}, {name: "invalidDate", type: "blurb", colSpan: 4, visible: false} {name: "endHours", title: "To", type: "select", width: 60}, {name: "endMinutes", showTitle: false, type: "select", width: 60}, {name: "endAMPM", showTitle: false, type: "select", width: 60}, {name: "name", title: "Name", type: "text", colSpan: 4}, {name: "description", title: "Description", type: "textArea", colSpan: 4, height: 50}
See the Customized Binding example below for more information on altering default datasource fields within forms.- Parameters:
eventEditorFields
- eventEditorFields Default value is see below- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
setEventDialogFields
The set of fields for theeventDialog
.The default set of fields are:
{name: "name", title: "Event Name", type: nameType, width: 250 }, {name: "save", title: "Save Event", type: "SubmitItem", endRow: false}, {name: "details", title: "Edit Details", type: "button", startRow: false}
See the Customized Binding example below for more information on altering default datasource fields within forms.- Parameters:
eventDialogFields
- eventDialogFields Default value is see below- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
setData
An array of Record objects, specifying the data to be used to populate the DataBoundComponent. Note that not all DataBoundComponents observe the changes to the data to redraw themselves. Refer to the version of setData that accepts component specific records.- Parameters:
data
- array of Record objects.- See Also:
-
setData
An List of Record objects, specifying the data to be used to populate the DataBoundComponent. Note that not all DataBoundComponents observe the changes to the data to redraw themselves. Refer to the version of setData that accepts component specific records.- Parameters:
data
- List of Records
-
setTimeFormatter
Deprecated.usesetTimeFormatter(TimeDisplayFormat)
instead.Display format to use for the time portion of events' date information.- Parameters:
timeFormatter
- timeFormatter Default value is "toShortPaddedTime"
-
setTimeFormatter
Display format to use for the time portion of events' date information.- Parameters:
timeFormatter
- timeFormatter Default value is "toShortPaddedTime"
-
getTimeFormatter
Display format to use for the time portion of events' date information.- Returns:
- TimeDisplayFormat
-
removeLane
Removes a lane from the calendar intimelineView
mode.- Parameters:
lane
- the lane to remove
-
removeLane
Removes a lane from the calendar intimelineView
mode.- Parameters:
laneName
- the name of the lane to remove
-
addEvent
Create a new event in this calendar instance.- Parameters:
startDate
- start date of eventendDate
- end date of eventname
- name of eventdescription
- description of event
-
addEvent
public void addEvent(Date startDate, Date endDate, String name, String description, Map otherFields) Create a new event in this calendar instance.- Parameters:
startDate
- start date of eventendDate
- end date of eventname
- name of eventdescription
- description of eventotherFields
- new values of additional fields to be updated
-
removeEvent
Remove an event from this calendar.- Parameters:
event
- The event object to remove from the calendar
-
updateEvent
public void updateEvent(CalendarEvent event, Date startDate, Date endDate, String name, String description) update an event in this calendar.- Parameters:
event
- The event object to remove from the calendarstartDate
- start date of eventendDate
- end date of eventname
- name of eventdescription
- description of event
-
setWorkdays
Array of days that are considered workdays whenshowWorkday
is true- Parameters:
workdays
- workdays Default value is [1,2,3,4,5]- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
calendarLoaded
public static boolean calendarLoaded()Static method indicating whether the optional Calendar module is loaded for the page. The Calendar component requires this module.- Returns:
- true if the Calendar module is present
-
getLaneGroupByFieldAsString
Deprecated.in favor ofgetLaneGroupByFieldAsStringArray()
. -
setEventCanvasMenuCustomizer
Customizer called whenever the Calender needs to show a context-menu for a given EventCanvas- Parameters:
customizer
- the customizer to execute.
-
setDataPageSize
Description copied from interface:DataBoundComponent
When usingdata paging
, how many records to fetch at a time. If set to a positive integer,dataPageSize
will override the defaultresultSize
for ResultSets automatically created when you callfetchData()
(and similarly for theresultSize
of ResultTrees). The default of 0 means to just use the default page size of the data container.Note that regardless of the
dataPageSize
setting, a component will always fetch all of data that it needs to draw. Settings such asshowAllRecords:true
,drawAllMaxCells
anddrawAheadRatio
can cause more rows than the configureddataPageSize
to be fetched.- Specified by:
setDataPageSize
in interfaceDataBoundComponent
- Parameters:
dataPageSize
- dataPageSize Default value is 0- Returns:
DataBoundComponent
instance, for chaining setter calls- See Also:
-
getDataPageSize
public int getDataPageSize()Description copied from interface:DataBoundComponent
When usingdata paging
, how many records to fetch at a time. If set to a positive integer,dataPageSize
will override the defaultresultSize
for ResultSets automatically created when you callfetchData()
(and similarly for theresultSize
of ResultTrees). The default of 0 means to just use the default page size of the data container.Note that regardless of the
dataPageSize
setting, a component will always fetch all of data that it needs to draw. Settings such asshowAllRecords:true
,drawAllMaxCells
anddrawAheadRatio
can cause more rows than the configureddataPageSize
to be fetched.- Specified by:
getDataPageSize
in interfaceDataBoundComponent
- Returns:
- int
- See Also:
-
setUseAllDataSourceFields
Description copied from interface:DataBoundComponent
If true, the set of fields given by the "default binding" (see 
fields
) is used, with any fields specified in
component.fields
acting as overrides that can suppress or modify the
 display of individual fields, without having to list the entire set of fields that
 should be shown.

 If
component.fields
contains fields that are not found in the DataSource,
 they will be shown after the most recently referred to DataSource field. If the new
 fields appear first, they will be shown first.- Specified by:
setUseAllDataSourceFields
in interfaceDataBoundComponent
- Parameters:
useAllDataSourceFields
- useAllDataSourceFields Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getUseAllDataSourceFields
Description copied from interface:DataBoundComponent
If true, the set of fields given by the "default binding" (see 
fields
) is used, with any fields specified in
component.fields
acting as overrides that can suppress or modify the
 display of individual fields, without having to list the entire set of fields that
 should be shown.

 If
component.fields
contains fields that are not found in the DataSource,
 they will be shown after the most recently referred to DataSource field. If the new
 fields appear first, they will be shown first.- Specified by:
getUseAllDataSourceFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setSparseFieldState
Description copied from interface:DataBoundComponent
If true,ListGrid.getFieldState()
andListGrid.setFieldState(java.lang.String)
will omit state information for hidden fields by default.- Specified by:
setSparseFieldState
in interfaceDataBoundComponent
- Parameters:
sparseFieldState
- sparseFieldState Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getSparseFieldState
Description copied from interface:DataBoundComponent
If true,ListGrid.getFieldState()
andListGrid.setFieldState(java.lang.String)
will omit state information for hidden fields by default.- Specified by:
getSparseFieldState
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setShowHiddenFields
Description copied from interface:DataBoundComponent
Whether to show fields markedhidden:true
when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.

 The
hidden
property is used on DataSource fields to mark fields that are
 never of meaning to an end user.- Specified by:
setShowHiddenFields
in interfaceDataBoundComponent
- Parameters:
showHiddenFields
- showHiddenFields Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getShowHiddenFields
Description copied from interface:DataBoundComponent
Whether to show fields markedhidden:true
when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.

 The
hidden
property is used on DataSource fields to mark fields that are
 never of meaning to an end user.- Specified by:
getShowHiddenFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setShowComplexFields
Description copied from interface:DataBoundComponent
Whether to show fields of non-atomic types when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.

 If true, the component will show fields that declare a complex type, for example, a
 field 'shippingAddress' that declares type 'Address', where 'Address' is the ID of a
 DataSource that declares the fields of a shipping address (city, street name, etc).


 Such fields may need custom formatters or editors in order to create a usable interface,
 for example, an Address field in a ListGrid might use a custom formatter to combine the
 relevant fields of an address into one column, and might use a pop-up dialog for
 editing.
Note : This is an advanced setting
- Specified by:
setShowComplexFields
in interfaceDataBoundComponent
- Parameters:
showComplexFields
- showComplexFields Default value is true- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getShowComplexFields
Description copied from interface:DataBoundComponent
Whether to show fields of non-atomic types when a DataBoundComponent is given a
 DataSource but nocomponent.fields
.

 If true, the component will show fields that declare a complex type, for example, a
 field 'shippingAddress' that declares type 'Address', where 'Address' is the ID of a
 DataSource that declares the fields of a shipping address (city, street name, etc).


 Such fields may need custom formatters or editors in order to create a usable interface,
 for example, an Address field in a ListGrid might use a custom formatter to combine the
 relevant fields of an address into one column, and might use a pop-up dialog for
 editing.
- Specified by:
getShowComplexFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setFetchOperation
Description copied from interface:DataBoundComponent
Operation ID this component should use when performing fetch operations.- Specified by:
setFetchOperation
in interfaceDataBoundComponent
- Parameters:
fetchOperation
- fetchOperation Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getFetchOperation
Description copied from interface:DataBoundComponent
Operation ID this component should use when performing fetch operations.- Specified by:
getFetchOperation
in interfaceDataBoundComponent
- Returns:
- String
-
setUpdateOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing update operations.- Specified by:
setUpdateOperation
in interfaceDataBoundComponent
- Parameters:
updateOperation
- Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls- See Also:
-
getUpdateOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing update operations.- Specified by:
getUpdateOperation
in interfaceDataBoundComponent
- Returns:
- String
- See Also:
-
setAddOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing add operations.- Specified by:
setAddOperation
in interfaceDataBoundComponent
- Parameters:
addOperation
- Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls- See Also:
-
getAddOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing add operations.- Specified by:
getAddOperation
in interfaceDataBoundComponent
- Returns:
- String
- See Also:
-
setRemoveOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing remove operations.- Specified by:
setRemoveOperation
in interfaceDataBoundComponent
- Parameters:
removeOperation
- Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls- See Also:
-
getRemoveOperation
Description copied from interface:DataBoundComponent
operationId
this component should use when performing remove operations.- Specified by:
getRemoveOperation
in interfaceDataBoundComponent
- Returns:
- String
- See Also:
-
setExportFields
Description copied from interface:DataBoundComponent
The list of field-names to export. If provided, the field-list in the exported output is 
 limited and sorted as per the list.

 If exportFields is not provided, the exported output includes all visible fields 
 from this component, sorted as they appear.
- Specified by:
setExportFields
in interfaceDataBoundComponent
- Parameters:
exportFields
- exportFields Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getExportFields
Description copied from interface:DataBoundComponent
The list of field-names to export. If provided, the field-list in the exported output is 
 limited and sorted as per the list.

 If exportFields is not provided, the exported output includes all visible fields 
 from this component, sorted as they appear.
- Specified by:
getExportFields
in interfaceDataBoundComponent
- Returns:
- the list of field-names to export.
-
setExportAll
Description copied from interface:DataBoundComponent
Setting exportAll to true prevents the component from passing its list of fields to the 
 export call. The result is the export of all visible fields fromfields
.

 If exportAll is false, an export operation will first consider 

exportFields
, if it's set, and fall back on all visible fields from
fields
otherwise.- Specified by:
setExportAll
in interfaceDataBoundComponent
- Parameters:
exportAll
- exportAll Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getExportAll
Description copied from interface:DataBoundComponent
Setting exportAll to true prevents the component from passing its list of fields to the 
 export call. The result is the export of all visible fields fromfields
.

 If exportAll is false, an export operation will first consider 

exportFields
, if it's set, and fall back on all visible fields from
fields
otherwise.- Specified by:
getExportAll
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setExportIncludeSummaries
Description copied from interface:DataBoundComponent
If Summary rows exist for this component, whether to include them when exporting client data. Defaults to true if not set- Specified by:
setExportIncludeSummaries
in interfaceDataBoundComponent
- Parameters:
exportIncludeSummaries
- exportIncludeSummaries Default value is true- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getExportIncludeSummaries
Description copied from interface:DataBoundComponent
If Summary rows exist for this component, whether to include them when exporting client data. Defaults to true if not set- Specified by:
getExportIncludeSummaries
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setPreventDuplicates
Description copied from interface:DataBoundComponent
If set, detect and prevent duplicate records from being transferred to this component, either via
 drag and drop or viaDataBoundComponent.transferSelectedData(com.smartgwt.client.widgets.DataBoundComponent)
. When a duplicate transfer is detected,
 a dialog will appear showing theduplicateDragMessage
.

 If the component either does not have a
DataSource
or has a DataSource with no
primaryKey
declared, duplicate checking is off by
 default. If duplicate checking is enabled, it looks for an existing record in the dataset
 that has all of the properties of the dragged record, and considers that a duplicate.

 For
DragDataAction
:"copy" where the target DataSource is related to the source
 DataSource by foreignKey, a duplicate means that the target list, as filtered by the current
 criteria, already has a record whose value for the foreignKey field matches the
 primaryKey of the record being transferred.

 For example, consider dragging "employees" to "teams", where "teams" has a field
 "teams.employeeId" which is a foreignKey pointing to "employees.id", and the target
 grid has search criteria causing it to show all the members of one team. A duplicate -
 adding an employee to the same team twice - is when the target grid's dataset contains an
 record with "employeeId" matching the "id" field of the dropped employee.
- Specified by:
setPreventDuplicates
in interfaceDataBoundComponent
- Parameters:
preventDuplicates
- preventDuplicates Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getPreventDuplicates
Description copied from interface:DataBoundComponent
If set, detect and prevent duplicate records from being transferred to this component, either via
 drag and drop or viaDataBoundComponent.transferSelectedData(com.smartgwt.client.widgets.DataBoundComponent)
. When a duplicate transfer is detected,
 a dialog will appear showing theduplicateDragMessage
.

 If the component either does not have a
DataSource
or has a DataSource with no
primaryKey
declared, duplicate checking is off by
 default. If duplicate checking is enabled, it looks for an existing record in the dataset
 that has all of the properties of the dragged record, and considers that a duplicate.

 For
DragDataAction
:"copy" where the target DataSource is related to the source
 DataSource by foreignKey, a duplicate means that the target list, as filtered by the current
 criteria, already has a record whose value for the foreignKey field matches the
 primaryKey of the record being transferred.

 For example, consider dragging "employees" to "teams", where "teams" has a field
 "teams.employeeId" which is a foreignKey pointing to "employees.id", and the target
 grid has search criteria causing it to show all the members of one team. A duplicate -
 adding an employee to the same team twice - is when the target grid's dataset contains an
 record with "employeeId" matching the "id" field of the dropped employee.
- Specified by:
getPreventDuplicates
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setDuplicateDragMessage
Description copied from interface:DataBoundComponent
Message to show when a user attempts to transfer duplicate records into this component, and
preventDuplicates
is enabled. If set to null, duplicates will not be reported and the dragged duplicates will not be saved.- Specified by:
setDuplicateDragMessage
in interfaceDataBoundComponent
- Parameters:
duplicateDragMessage
- duplicateDragMessage Default value is "Duplicates not allowed"- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getDuplicateDragMessage
Description copied from interface:DataBoundComponent
Message to show when a user attempts to transfer duplicate records into this component, and
preventDuplicates
is enabled. If set to null, duplicates will not be reported and the dragged duplicates will not be saved.- Specified by:
getDuplicateDragMessage
in interfaceDataBoundComponent
- Returns:
- String
-
setAddDropValues
Description copied from interface:DataBoundComponent
Indicates whether to add "drop values" to items dropped on this component, if both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key. "Drop values" are properties of the dropped item that you wish to change (and persist) as a result of the item being dropped on this grid.If this value is true and this component is databound,
DataBoundComponent.getDropValues()
will be called for every databound item dropped on this grid, and an update performed on the item- Specified by:
setAddDropValues
in interfaceDataBoundComponent
- Parameters:
addDropValues
- addDropValues Default value is true- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getAddDropValues
Description copied from interface:DataBoundComponent
Indicates whether to add "drop values" to items dropped on this component, if both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key. "Drop values" are properties of the dropped item that you wish to change (and persist) as a result of the item being dropped on this grid.If this value is true and this component is databound,
DataBoundComponent.getDropValues()
will be called for every databound item dropped on this grid, and an update performed on the item- Specified by:
getAddDropValues
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setDropValues
Description copied from interface:DataBoundComponent
When an item is dropped on this component, andaddDropValues
is true and both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key, this object provides the "drop values" that Smart GWT will apply to the dropped object before updating it.If this property is not defined, Smart GWT defaults to returning the selection criteria currently in place for this component. Thus, any databound items (for example, rows from other grids bound to the same DataSource) dropped on the grid will, by default, be subjected to an update that makes them conform to the grid's current filter criteria.
Note : This is an advanced setting
- Specified by:
setDropValues
in interfaceDataBoundComponent
- Parameters:
dropValues
- dropValues Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getDropValues
Description copied from interface:DataBoundComponent
When an item is dropped on this component, andaddDropValues
is true and both the source and target widgets are databound, either to the same DataSource or to different DataSources that are related via a foreign key, this object provides the "drop values" that Smart GWT will apply to the dropped object before updating it.If this property is not defined, Smart GWT defaults to returning the selection criteria currently in place for this component. Thus, any databound items (for example, rows from other grids bound to the same DataSource) dropped on the grid will, by default, be subjected to an update that makes them conform to the grid's current filter criteria.
Note : This is an advanced setting
- Specified by:
getDropValues
in interfaceDataBoundComponent
- Returns:
- Returns the "drop values" to apply to a record dropped on this component prior to update. Only
 applicable to databound components - see
dropValues
for more details. If multiple records 
 are being dropped, this method is called for each of them in turn.

 This method returns the following:

- 

- Nothing, if
addDropValues
is false 
 - dropValues, if that property is set. If the component's criteria object is applicable (as explained
 in the next item), it is merged into dropValues, with properties in dropValues taking precedence. 

- The component's criteria object, if the most recent textMatchStyle for the component was "exact" 
 and it is simple criteria (ie, not an AdvancedCriteria object) 

- Otherwise nothing 


 You can override this method if you need more complex setting of drop values than can be 
 provided by simply supplying a dropValues object.
 

- Nothing, if
-
setProgressiveLoading
Indicates whether or not this component will load its dataprogressively
- Parameters:
progressiveLoading
-- Returns:
DataBoundComponent
instance, for chaining setter calls- See Also:
-
getProgressiveLoading
Indicates whether or not this component will load its dataprogressively
- Returns:
- See Also:
-
setUseFlatFields
Description copied from interface:DataBoundComponent
TheuseFlatFields
flag causes all simple type fields anywhere in a nested
 set of DataSources to be exposed as a flat list for form binding. 


useFlatFields
is typically used with imported metadata, such as 
XMLTools.loadXMLSchema(java.lang.String, com.smartgwt.client.data.XSDLoadCallback)
from a 
XMLTools.loadWSDL(java.lang.String, com.smartgwt.client.data.WSDLLoadCallback)
, as a means of eliminating levels of XML
 nesting that aren't meaningful in a user interface, without the cumbersome and fragile
 process of mapping form fields to XML structures.

 For example, having called
WebService.getInputDS(java.lang.String)
to retrieve the input message
 schema for a web service operation whose input message looks like this:

 <FindServices>
 <searchFor>search text</searchFor>
 <Options>
 <caseSensitive>false</caseSensitive>
 </Options>
 <IncludeInSearch>
 <serviceName>true</serviceName>
 <documentation>true</documentation>
 <keywords>true</keywords>
 </IncludeInSearch>
 </FindServices>


 SettinguseFlatFields
on aDynamicForm
that is bound to this input
 message schema would result in 5FormItem
reflecting the 5 simple type
 fields in the message.

 For this form, the result of
DynamicForm.getValues()
might look
 like:


{
 searchFor: "search text",
 caseSensitive: false,
 serviceName: true,
 documentation : true,
 keywords : true
 }

 When contacting aWebService
, these values can be automatically
 mapped to the structure of the input message for a web service operation by setting
 {@link com.smartgwt.client..WSRequest#getUseFlatFields useFlatFields} (for use withWebService.callOperation(java.lang.String, java.util.Map, java.lang.String, com.smartgwt.client.data.WebServiceCallback)
) or by setting
useFlatFields
(for use with aDataSource
that is
'bound to a WSDL web service'
via
wsOperation
). 

 Using these two facilities in conjunction (component.useFlatFields and
 request.useFlatFields) allows gratuitous nesting to be consistently bypassed in both the user
 presentation and when providing the data for XML messages.


 You can also set
useFlatFields
to automatically enable 
 "flattened" XML serialization (request.useFlatFields) for all DataSource requests of a
 particular operationType.

 Note that
useFlatFields
is not generally recommended for use with structures
 where multiple simple type fields exist with the same name, however if used with such a
 structure, the first field to use a given name wins. "first" means the first field
 encountered in a depth first search. "wins" means only the first field will be present as a
 field when data binding.- Specified by:
setUseFlatFields
in interfaceDataBoundComponent
- Parameters:
useFlatFields
- useFlatFields Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getUseFlatFields
Description copied from interface:DataBoundComponent
TheuseFlatFields
flag causes all simple type fields anywhere in a nested
 set of DataSources to be exposed as a flat list for form binding. 


useFlatFields
is typically used with imported metadata, such as 
XMLTools.loadXMLSchema(java.lang.String, com.smartgwt.client.data.XSDLoadCallback)
from a 
XMLTools.loadWSDL(java.lang.String, com.smartgwt.client.data.WSDLLoadCallback)
, as a means of eliminating levels of XML
 nesting that aren't meaningful in a user interface, without the cumbersome and fragile
 process of mapping form fields to XML structures.

 For example, having called
WebService.getInputDS(java.lang.String)
to retrieve the input message
 schema for a web service operation whose input message looks like this:

 <FindServices>
 <searchFor>search text</searchFor>
 <Options>
 <caseSensitive>false</caseSensitive>
 </Options>
 <IncludeInSearch>
 <serviceName>true</serviceName>
 <documentation>true</documentation>
 <keywords>true</keywords>
 </IncludeInSearch>
 </FindServices>


 SettinguseFlatFields
on aDynamicForm
that is bound to this input
 message schema would result in 5FormItem
reflecting the 5 simple type
 fields in the message.

 For this form, the result of
DynamicForm.getValues()
might look
 like:


{
 searchFor: "search text",
 caseSensitive: false,
 serviceName: true,
 documentation : true,
 keywords : true
 }

 When contacting aWebService
, these values can be automatically
 mapped to the structure of the input message for a web service operation by setting
 {@link com.smartgwt.client..WSRequest#getUseFlatFields useFlatFields} (for use withWebService.callOperation(java.lang.String, java.util.Map, java.lang.String, com.smartgwt.client.data.WebServiceCallback)
) or by setting
useFlatFields
(for use with aDataSource
that is
'bound to a WSDL web service'
via
wsOperation
). 

 Using these two facilities in conjunction (component.useFlatFields and
 request.useFlatFields) allows gratuitous nesting to be consistently bypassed in both the user
 presentation and when providing the data for XML messages.


 You can also set
useFlatFields
to automatically enable 
 "flattened" XML serialization (request.useFlatFields) for all DataSource requests of a
 particular operationType.

 Note that
useFlatFields
is not generally recommended for use with structures
 where multiple simple type fields exist with the same name, however if used with such a
 structure, the first field to use a given name wins. "first" means the first field
 encountered in a depth first search. "wins" means only the first field will be present as a
 field when data binding.- Specified by:
getUseFlatFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setHiliteProperty
Description copied from interface:DataBoundComponent
Marker that can be set on a record to flag that record as hilited. Should be set to a value
 that matches {@link com.smartgwt.client..Hilite#getId id} for a hilite defined on this component.- Specified by:
setHiliteProperty
in interfaceDataBoundComponent
- Parameters:
hiliteProperty
- hiliteProperty Default value is "_hilite"- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getHiliteProperty
Description copied from interface:DataBoundComponent
Marker that can be set on a record to flag that record as hilited. Should be set to a value
 that matches {@link com.smartgwt.client..Hilite#getId id} for a hilite defined on this component.- Specified by:
getHiliteProperty
in interfaceDataBoundComponent
- Returns:
- String
-
editFields
public void editFields()Shows a FieldPicker interface allowing end-users to rearrange the order and visibiility of the fields in the associated DataBoundComponent. -
editHilites
public void editHilites()Description copied from interface:DataBoundComponent
Shows a HiliteEditor interface allowing end-users to edit the data-hilites currently in use by this DataBoundComponent.- Specified by:
editHilites
in interfaceDataBoundComponent
-
getHiliteState
Description copied from interface:DataBoundComponent
Get the current hilites encoded as a String, for saving.- Specified by:
getHiliteState
in interfaceDataBoundComponent
- Returns:
- the hilite state
-
setHiliteState
Description copied from interface:DataBoundComponent
Set the current hilites based on a hiliteState String previously returned from getHilitesState.- Specified by:
setHiliteState
in interfaceDataBoundComponent
- Parameters:
hiliteState
- hilites state encoded as a String- Returns:
DataBoundComponent
instance, for chaining setter calls
-
setHilites
Description copied from interface:DataBoundComponent
Accepts an array of hilite objects and applies them to this DataBoundComponent. See alsogetHilites
for a method of retrieving the hilite array for storage, including hilites manually added by the user.NOTE: This is only supported on
ListGrid
for now.- Specified by:
setHilites
in interfaceDataBoundComponent
- Parameters:
hilites
- array of hilite objects- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getHilites
Description copied from interface:DataBoundComponent
Return the set of hilite-objects currently applied to this DataBoundComponent. These can be saved for storage and then restored to a component later via setHilites().- Specified by:
getHilites
in interfaceDataBoundComponent
- Returns:
- array of hilite objects
-
setDragDataAction
Description copied from interface:DataBoundComponent
Indicates what to do with data dragged into another DataBoundComponent. See
 DragDataAction type for details.- Specified by:
setDragDataAction
in interfaceDataBoundComponent
- Parameters:
dragDataAction
- dragDataAction Default value is Canvas.MOVE- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getDragDataAction
Description copied from interface:DataBoundComponent
Indicates what to do with data dragged into another DataBoundComponent. See
 DragDataAction type for details.- Specified by:
getDragDataAction
in interfaceDataBoundComponent
- Returns:
- DragDataAction
-
setDragTrackerStyle
Description copied from interface:DataBoundComponent
CSS Style to apply to the drag tracker when dragging occurs on this component.- Specified by:
setDragTrackerStyle
in interfaceDataBoundComponent
- Parameters:
dragTrackerStyle
- dragTrackerStyle Default value is "gridDragTracker"- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getDragTrackerStyle
Description copied from interface:DataBoundComponent
CSS Style to apply to the drag tracker when dragging occurs on this component.- Specified by:
getDragTrackerStyle
in interfaceDataBoundComponent
- Returns:
- String
-
setCanAddFormulaFields
Description copied from interface:DataBoundComponent
Adds an item to the header context menu allowing users to launch a dialog to define a new
 field based on values present in other fields, using the {@link com.smartgwt.client..FormulaBuilder}.

 User-added formula fields can be persisted via
ListGrid.getFieldState()
and 
ListGrid.setFieldState(java.lang.String)
.- Specified by:
setCanAddFormulaFields
in interfaceDataBoundComponent
- Parameters:
canAddFormulaFields
- canAddFormulaFields Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
addSummaryField
public void addSummaryField()Description copied from interface:DataBoundComponent
Convenience method to display a {@link com.smartgwt.client..SummaryBuilder} to create a new Summary Field. This 
 is equivalent to callingDataBoundComponentGen#editSummaryField
with 
 no parameter.

- Specified by:
addSummaryField
in interfaceDataBoundComponent
-
addFormulaField
public void addFormulaField()Description copied from interface:DataBoundComponent
Convenience method to display a {@link com.smartgwt.client..FormulaBuilder} to create a new Formula Field. This 
 is equivalent to callingDataBoundComponentGen#editFormulaField
with 
 no parameter.

- Specified by:
addFormulaField
in interfaceDataBoundComponent
-
getCanAddFormulaFields
Description copied from interface:DataBoundComponent
Adds an item to the header context menu allowing users to launch a dialog to define a new
 field based on values present in other fields, using the {@link com.smartgwt.client..FormulaBuilder}.

 User-added formula fields can be persisted via
ListGrid.getFieldState()
and 
ListGrid.setFieldState(java.lang.String)
.- Specified by:
getCanAddFormulaFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setAddFormulaFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to add a formula field- Specified by:
setAddFormulaFieldText
in interfaceDataBoundComponent
- Parameters:
addFormulaFieldText
- addFormulaFieldText Default value is "Add formula column..."- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getAddFormulaFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to add a formula field- Specified by:
getAddFormulaFieldText
in interfaceDataBoundComponent
- Returns:
- String
-
setEditFormulaFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to edit a formula field- Specified by:
setEditFormulaFieldText
in interfaceDataBoundComponent
- Parameters:
editFormulaFieldText
- editFormulaFieldText Default value is "Edit formula..."- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getEditFormulaFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to edit a formula field- Specified by:
getEditFormulaFieldText
in interfaceDataBoundComponent
- Returns:
- String
-
setCanAddSummaryFields
Description copied from interface:DataBoundComponent
Adds an item to the header context menu allowing users to launch a dialog to define a new
 text field that can contain both user-defined text and the formatted values present in other 
 fields, using the {@link com.smartgwt.client..SummaryBuilder}.

 User-added summary fields can be persisted via
ListGrid.getFieldState()
and 
ListGrid.setFieldState(java.lang.String)
.- Specified by:
setCanAddSummaryFields
in interfaceDataBoundComponent
- Parameters:
canAddSummaryFields
- canAddSummaryFields Default value is false- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getCanAddSummaryFields
Description copied from interface:DataBoundComponent
Adds an item to the header context menu allowing users to launch a dialog to define a new
 text field that can contain both user-defined text and the formatted values present in other 
 fields, using the {@link com.smartgwt.client..SummaryBuilder}.

 User-added summary fields can be persisted via
ListGrid.getFieldState()
and 
ListGrid.setFieldState(java.lang.String)
.- Specified by:
getCanAddSummaryFields
in interfaceDataBoundComponent
- Returns:
- Boolean
-
setAddSummaryFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to add a formula field- Specified by:
setAddSummaryFieldText
in interfaceDataBoundComponent
- Parameters:
addSummaryFieldText
- addSummaryFieldText Default value is "Add summary column..."- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getAddSummaryFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to add a formula field- Specified by:
getAddSummaryFieldText
in interfaceDataBoundComponent
- Returns:
- String
-
setEditSummaryFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to edit the formatter for a field- Specified by:
setEditSummaryFieldText
in interfaceDataBoundComponent
- Parameters:
editSummaryFieldText
- editSummaryFieldText Default value is "Edit summary format..."- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getEditSummaryFieldText
Description copied from interface:DataBoundComponent
Text for a menu item allowing users to edit the formatter for a field- Specified by:
getEditSummaryFieldText
in interfaceDataBoundComponent
- Returns:
- String
-
setSavedSearchId
Description copied from interface:DataBoundComponent
Optional identifier for saved searches that should be applied to this component.By default
SavedSearches
are associated with a component via itslocal ID
andDataSource ID
. This property allows developers to override this behavior and explicitly associate a component with a set of saved searches. This can provide a couple of benefits:
Firstly this ensures that saved searches will be unambiguously associated with the particular component even if the page changes such that a stored minimal locator would no longer applied to the component, without requiring an explicitCanvas.ID
.
Secondly this allows the same set of saved searches to be applied to more than one component on a page. This may be valueable for cases where the same information from the same dataSource is presented to users in multiple places.Note: This is an advanced setting.
- Specified by:
setSavedSearchId
in interfaceDataBoundComponent
- Parameters:
savedSearchId
- New savedSearchId value. Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getSavedSearchId
Description copied from interface:DataBoundComponent
Optional identifier for saved searches that should be applied to this component.By default
SavedSearches
are associated with a component via itslocal ID
andDataSource ID
. This property allows developers to override this behavior and explicitly associate a component with a set of saved searches. This can provide a couple of benefits:
Firstly this ensures that saved searches will be unambiguously associated with the particular component even if the page changes such that a stored minimal locator would no longer applied to the component, without requiring an explicitCanvas.ID
.
Secondly this allows the same set of saved searches to be applied to more than one component on a page. This may be valueable for cases where the same information from the same dataSource is presented to users in multiple places.- Specified by:
getSavedSearchId
in interfaceDataBoundComponent
- Returns:
- Current savedSearchId value. Default value is null
-
setShowSavedSearchesByDS
public Calendar setShowSavedSearchesByDS(boolean showSavedSearchesByDS) throws IllegalStateException Description copied from interface:DataBoundComponent
Whether to associate saved searches by default with the currentDataSource
of a component when asavedSearchId
is not provided. If this property is true, then when the DataSource is changed, existing saved searches will disappear and only be available if the DataSource is set back to its original value.If this property is false, saved searches will persist across DataSource changes so that searches that aren't applicable to the current DataSource might still be shown.
Note: This is an advanced setting
- Specified by:
setShowSavedSearchesByDS
in interfaceDataBoundComponent
- Parameters:
showSavedSearchesByDS
- New showSavedSearchesByDS value. Default value is true- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getShowSavedSearchesByDS
public boolean getShowSavedSearchesByDS()Description copied from interface:DataBoundComponent
Whether to associate saved searches by default with the currentDataSource
of a component when asavedSearchId
is not provided. If this property is true, then when the DataSource is changed, existing saved searches will disappear and only be available if the DataSource is set back to its original value.If this property is false, saved searches will persist across DataSource changes so that searches that aren't applicable to the current DataSource might still be shown.
- Specified by:
getShowSavedSearchesByDS
in interfaceDataBoundComponent
- Returns:
- Current showSavedSearchesByDS value. Default value is true
-
findAll
Filters all objects according to the AdvancedCriteria passed- Parameters:
adCriteria
- AdvancedCriteria to use to filter results- Returns:
- all matching Objects or null if none found
-
find
Filters all objects according to the AdvancedCriteria passed and returns the first matching object or null if not found- Parameters:
adCriteria
- AdvancedCriteria to use to filter results- Returns:
- first matching object or null if not found
-
findIndex
Finds the index of the first Record that matches with the AdvacendCriteria passed.- Parameters:
adCriteria
- AdvancedCriteria to use to filter results- Returns:
- index of the first matching Record or -1 if not found
-
findNextIndex
LikeRecordList.findIndex(java.util.Map)
, but considering the startIndex and endIndex parameters.- Parameters:
startIndex
- first index to consideradCriteria
- AdvancedCriteria to use to filter resultsendIndex
- last index to consider- Returns:
- index of the first matching Record or -1 if not found
-
findNextIndex
LikeRecordList.findIndex(java.util.Map)
, but considering the startIndex parameter.- Parameters:
startIndex
- first index to consideradCriteria
- AdvancedCriteria to use to filter results- Returns:
- index of the first matching Record or -1 if not found
-
selectRecord
Description copied from interface:DataBoundComponent
Select/deselect aRecord
passed in explicitly, or by index.- Specified by:
selectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to select
-
selectRecord
public void selectRecord(int record) Description copied from interface:DataBoundComponent
Select/deselect aRecord
passed in explicitly, or by index.- Specified by:
selectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to select
-
selectRecord
public void selectRecord(int record, boolean newState) Description copied from interface:DataBoundComponent
Select/deselect aRecord
passed in explicitly, or by index.- Specified by:
selectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to selectnewState
- new selection state (if null, defaults to true)
-
selectRecord
Description copied from interface:DataBoundComponent
Select/deselect aRecord
passed in explicitly, or by index.- Specified by:
selectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to selectnewState
- new selection state (if null, defaults to true)
-
selectRecords
public void selectRecords(int[] records) Description copied from interface:DataBoundComponent
Select/deselect a list ofRecord
s passed in explicitly, or by index.- Specified by:
selectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to select
-
selectRecords
public void selectRecords(int[] records, boolean newState) Description copied from interface:DataBoundComponent
Select/deselect a list ofRecord
s passed in explicitly, or by index.- Specified by:
selectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to selectnewState
- new selection state
-
selectRecords
Description copied from interface:DataBoundComponent
Select/deselect a list ofRecord
s passed in explicitly, or by index.- Specified by:
selectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to select
-
selectRecords
Description copied from interface:DataBoundComponent
Select/deselect a list ofRecord
s passed in explicitly, or by index.- Specified by:
selectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to selectnewState
- new selection state (if null, defaults to true)
-
deselectRecord
Description copied from interface:DataBoundComponent
Deselect aRecord
passed in explicitly, or by index.Synonym for
selectRecord(record, false)
- Specified by:
deselectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to deselect
-
deselectRecord
public void deselectRecord(int record) Description copied from interface:DataBoundComponent
Deselect aRecord
passed in explicitly, or by index.Synonym for
selectRecord(record, false)
- Specified by:
deselectRecord
in interfaceDataBoundComponent
- Parameters:
record
- record (or row number) to deselect
-
deselectRecords
public void deselectRecords(int[] records) Description copied from interface:DataBoundComponent
Deselect a list ofRecord
s passed in explicitly, or by index.Synonym for
selectRecords(records, false)
- Specified by:
deselectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to deselect
-
deselectRecords
Description copied from interface:DataBoundComponent
Deselect a list ofRecord
s passed in explicitly, or by index.Synonym for
selectRecords(records, false)
- Specified by:
deselectRecords
in interfaceDataBoundComponent
- Parameters:
records
- records (or row numbers) to deselect
-
selectAllRecords
public void selectAllRecords()Description copied from interface:DataBoundComponent
Select all records

- Specified by:
selectAllRecords
in interfaceDataBoundComponent
-
deselectAllRecords
public void deselectAllRecords()Description copied from interface:DataBoundComponent

 Deselect all records

- Specified by:
deselectAllRecords
in interfaceDataBoundComponent
-
anySelected
Description copied from interface:DataBoundComponent
Whether at least one item is selected
- Specified by:
anySelected
in interfaceDataBoundComponent
- Returns:
- true == at least one item is selected false == nothing at all is selected
-
enableHilite
Description copied from interface:DataBoundComponent
Enable / disable ahilites


- Specified by:
enableHilite
in interfaceDataBoundComponent
- Parameters:
hiliteID
- ID of hilite to enable
-
enableHilite
Description copied from interface:DataBoundComponent
Enable / disable ahilites


- Specified by:
enableHilite
in interfaceDataBoundComponent
- Parameters:
hiliteID
- ID of hilite to enableenable
- new enabled state to apply - if null, defaults to true
-
disableHilite
Description copied from interface:DataBoundComponent
Disable a hilite

- Specified by:
disableHilite
in interfaceDataBoundComponent
- Parameters:
hiliteID
- ID of hilite to disable
-
enableHiliting
public void enableHiliting()Description copied from interface:DataBoundComponent
Enable all hilites.

- Specified by:
enableHiliting
in interfaceDataBoundComponent
-
enableHiliting
public void enableHiliting(boolean enable) Description copied from interface:DataBoundComponent
Enable all hilites.

- Specified by:
enableHiliting
in interfaceDataBoundComponent
- Parameters:
enable
- new enabled state to apply - if null, defaults to true
-
disableHiliting
public void disableHiliting()Description copied from interface:DataBoundComponent
Disable all hilites.

- Specified by:
disableHiliting
in interfaceDataBoundComponent
-
getDragData
Description copied from interface:DataBoundComponent
During a drag-and-drop interaction, this method returns the set of records being dragged out of the component. In the default implementation, this is the list of currently selected records.This method is consulted by

ListGrid.willAcceptDrop()
.- Specified by:
getDragData
in interfaceDataBoundComponent
- Returns:
- Array of
Record
s that are currently selected.
-
transferSelectedData
Description copied from interface:DataBoundComponent
Simulates a drag / drop type transfer of the selected records in some other component to this component, without requiring any user interaction. This method acts on the dropped records exactly as if they had been dropped in an actual drag / drop interaction, including any special databound behavior invoked by callingDataBoundComponent.getDropValues()
for each dropped record.To transfer all data in, for example, a
ListGrid
, call grid.selection.selectAll() first.Note that drag/drop type transfers of records between components are asynchronous operations: Smart GWT may need to perform server turnarounds to establish whether dropped records already exist in the target component. Therefore, it is possible to issue a call to
transferSelectedData()
and/or thedrop()
method of a databound component whilst a transfer is still active. When this happens, Smart GWT adds the second and subsequent transfer requests to a queue and runs them one after the other. If you want to be notified when a transfer process has actually completed, useHasDropCompleteHandlers.addDropCompleteHandler(com.smartgwt.client.widgets.events.DropCompleteHandler)
. See theDragging
documentation for an overview of list grid drag/drop data transfer.- Specified by:
transferSelectedData
in interfaceDataBoundComponent
- Parameters:
source
- source component from which the records will be tranferred
-
transferSelectedData
Description copied from interface:DataBoundComponent
Simulates a drag / drop type transfer of the selected records in some other component to this component, without requiring any user interaction. This method acts on the dropped records exactly as if they had been dropped in an actual drag / drop interaction, including any special databound behavior invoked by callingDataBoundComponent.getDropValues()
for each dropped record.To transfer all data in, for example, a
ListGrid
, call grid.selection.selectAll() first.Note that drag/drop type transfers of records between components are asynchronous operations: Smart GWT may need to perform server turnarounds to establish whether dropped records already exist in the target component. Therefore, it is possible to issue a call to
transferSelectedData()
and/or thedrop()
method of a databound component whilst a transfer is still active. When this happens, Smart GWT adds the second and subsequent transfer requests to a queue and runs them one after the other. If you want to be notified when a transfer process has actually completed, useHasDropCompleteHandlers.addDropCompleteHandler(com.smartgwt.client.widgets.events.DropCompleteHandler)
. See theDragging
documentation for an overview of list grid drag/drop data transfer.- Specified by:
transferSelectedData
in interfaceDataBoundComponent
- Parameters:
source
- source component from which the records will be transferredindex
- target index (drop position) of the rows within this grid.
-
getRecordIndex
Description copied from interface:DataBoundComponent
Get the index of the provided record.

 Override in subclasses to provide more specific behaviour, for instance, when data holds a
 large number of records


- Specified by:
getRecordIndex
in interfaceDataBoundComponent
- Parameters:
record
- the record whose index is to be retrieved- Returns:
- indexindex of the record, or -1 if not found
-
getTitleFieldValue
Description copied from interface:DataBoundComponent
Get the value of the titleField for the passed record

 Override in subclasses 


- Specified by:
getTitleFieldValue
in interfaceDataBoundComponent
- Parameters:
record
- the record whose index is to be retrieved- Returns:
- valuethe value of the titleField for the passed record
-
setTitleField
Description copied from interface:DataBoundComponent
Sets the best field to use for a user-visible title for an individual record from this component.- Specified by:
setTitleField
in interfaceDataBoundComponent
- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getTitleField
Description copied from interface:DataBoundComponent
Method to return the fieldName which represents the "title" for records in this
 Component.

 If this.titleField is explicitly specified it will always be used.
 Otherwise, default implementation will checktitleField
for databound
 components.

 For non databound components returns the first defined field name of"title"
, 
"name"
, or"id"
. If we dont find any field-names that match these
 titles, the first field in the component will be used instead.
- Specified by:
getTitleField
in interfaceDataBoundComponent
- Returns:
- fieldName the title field for this component.
-
getDataSource
Description copied from interface:DataBoundComponent
The DataSource that this component should bind to for default fields and for performingDataSource requests
.- Specified by:
getDataSource
in interfaceDataBoundComponent
- Returns:
- DataSource
-
setAutoFetchData
Description copied from interface:DataBoundComponent
If true, when this component is first drawn, automatically callDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
depending onDataBoundComponent.getAutoFetchAsFilter()
. Criteria for this fetch may be picked up frominitialCriteria
and textMatchStyle may be specified viaDataBoundComponent.getAutoFetchTextMatchStyle()
.NOTE: If autoFetchData is set, calling ListGrid.fetchData() before draw will cause two requests to be issued, one from the manual call to fetchData() and one from the autoFetchData setting. The second request will use only
initialCriteria
and not any other criteria or settings from the first request. Generally, turn off autoFetchData if you are going to manually call fetchData() at any time.- Specified by:
setAutoFetchData
in interfaceDataBoundComponent
- Parameters:
autoFetchData
- autoFetchData- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
-
getAutoFetchData
Description copied from interface:DataBoundComponent
If true, when this component is first drawn, automatically callDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
depending onDataBoundComponent.getAutoFetchAsFilter()
. Criteria for this fetch may be picked up frominitialCriteria
and textMatchStyle may be specified viaDataBoundComponent.getAutoFetchTextMatchStyle()
.NOTE: If autoFetchData is set, calling ListGrid.fetchData() before draw will cause two requests to be issued, one from the manual call to fetchData() and one from the autoFetchData setting. The second request will use only
initialCriteria
and not any other criteria or settings from the first request. Generally, turn off autoFetchData if you are going to manually call fetchData() at any time.- Specified by:
getAutoFetchData
in interfaceDataBoundComponent
- Returns:
- autoFetchData autoFetchData
-
setAutoFetchTextMatchStyle
public Calendar setAutoFetchTextMatchStyle(TextMatchStyle autoFetchTextMatchStyle) throws IllegalStateException Description copied from interface:DataBoundComponent
IfautoFetchData
istrue
, this attribute allows the developer to specify a textMatchStyle for the initialDataBoundComponent.fetchData()
call.- Specified by:
setAutoFetchTextMatchStyle
in interfaceDataBoundComponent
- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
-
getAutoFetchTextMatchStyle
Description copied from interface:DataBoundComponent
IfautoFetchData
istrue
, this attribute allows the developer to specify a textMatchStyle for the initialDataBoundComponent.fetchData()
call.- Specified by:
getAutoFetchTextMatchStyle
in interfaceDataBoundComponent
- Returns:
- autoFetchTextMatchStyle autoFetchTextMatchStyle
-
setAutoFetchAsFilter
Description copied from interface:DataBoundComponent
IfDataBoundComponent.setAutoFetchData(Boolean)
is true, this attribute determines whether the initial fetch operation should be performed viaDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
- Specified by:
setAutoFetchAsFilter
in interfaceDataBoundComponent
- Parameters:
autoFetchAsFilter
- autoFetchAsFilter- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
-
getAutoFetchAsFilter
Description copied from interface:DataBoundComponent
IfDataBoundComponent.setAutoFetchData(Boolean)
is true, this attribute determines whether the initial fetch operation should be performed viaDataBoundComponent.fetchData()
orDataBoundComponent.filterData()
- Specified by:
getAutoFetchAsFilter
in interfaceDataBoundComponent
- Returns:
- auto fetch as filter
-
setInitialCriteria
Description copied from interface:DataBoundComponent
Criteria to use whenDataBoundComponent.setAutoFetchData(Boolean)
is used.- Specified by:
setInitialCriteria
in interfaceDataBoundComponent
- Parameters:
initialCriteria
- the initial criteria- Returns:
DataBoundComponent
instance, for chaining setter calls- Throws:
IllegalStateException
- this property cannot be changed after the component has been created
-
getInitialCriteria
Description copied from interface:DataBoundComponent
Criteria to use whenDataBoundComponent.setAutoFetchData(Boolean)
is used.- Specified by:
getInitialCriteria
in interfaceDataBoundComponent
- Returns:
- the criteria
-
setImplicitCriteria
Description copied from interface:DataBoundComponent
Criteria that are never shown to or edited by the user and are cumulative with any criteria provided viaDataBoundComponent.initialCriteria
,DataBoundComponent.setCriteria()
etc.- Specified by:
setImplicitCriteria
in interfaceDataBoundComponent
- Parameters:
implicitCriteria
- New implicitCriteria value. Default value is null- Returns:
DataBoundComponent
instance, for chaining setter calls
-
setImplicitCriteria
-
setImplicitCriteria
-
getImplicitCriteria
Description copied from interface:DataBoundComponent
Criteria that are never shown to or edited by the user and are cumulative with any criteria provided viaDataBoundComponent.initialCriteria
,DataBoundComponent.setCriteria()
etc.- Specified by:
getImplicitCriteria
in interfaceDataBoundComponent
- Returns:
- Current implicitCriteria value. Default value is null
-
fetchData
public void fetchData()Description copied from interface:DataBoundComponent
Retrieves data from the DataSource that matches the specified criteria.When
fetchData()
is first called, if data has not already been provided viasetData()
, this method will create aResultSet
, which will be configured based on component settings such asfetchOperation
anddataPageSize
, as well as the general purposedataProperties
. The created ResultSet will automatically send a DSRequest to retrieve data from the dataSource, and from then on will automatically manage paging through large datasets, as well as performing filtering and sorting operations inside the browser when possible - see the ResultSet docs for details.NOTE: do not use both
autoFetchData
and a call tofetchData()
- this may result in two DSRequests to fetch data. Use eitherautoFetchData
andsetAutoFetchCriteria()
or a manual call to fetchData() passing criteria.Whether a ResultSet was automatically created or provided via
setData()
, subsequent calls to fetchData() will simply callresultSet.setCriteria()
.Changes to criteria may or may not result in a DSRequest to the server due to client-side filtering. You can call
willFetchData(criteria)
to determine if new criteria will result in a server fetch.If you need to force data to be re-fetched, you can call
invalidateCache()
and new data will automatically be fetched from the server using the current criteria and sort direction. NOTE: when usinginvalidateCache()
there is no need to also callfetchData()
and in fact this could produce unexpected results.This method takes an optional callback parameter (set to a
DSCallback
) to fire when the fetch completes. Note that this callback will not fire if no server fetch is performed. In this case the data is updated synchronously, so as soon as this method completes you can interact with the new data. If necessary, you can useresultSet.willFetchData()
to determine whether or not a server fetch will occur whenfetchData()
is called with new criteria.In addition to the callback parameter for this method, developers can use
resultSet.addDataArrivedHandler
to be notified every time data is loaded.- Specified by:
fetchData
in interfaceDataBoundComponent
-
fetchData
Description copied from interface:DataBoundComponent
Retrieves data from the DataSource that matches the specified criteria.When
fetchData()
is first called, if data has not already been provided viasetData()
, this method will create aResultSet
, which will be configured based on component settings such asfetchOperation
anddataPageSize
, as well as the general purposedataProperties
. The created ResultSet will automatically send a DSRequest to retrieve data from the dataSource, and from then on will automatically manage paging through large datasets, as well as performing filtering and sorting operations inside the browser when possible - see the ResultSet docs for details.NOTE: do not use both
autoFetchData
and a call tofetchData()
- this may result in two DSRequests to fetch data. Use eitherautoFetchData
andsetAutoFetchCriteria()
or a manual call to fetchData() passing criteria.Whether a ResultSet was automatically created or provided via
setData()
, subsequent calls to fetchData() will simply callresultSet.setCriteria()
.Changes to criteria may or may not result in a DSRequest to the server due to client-side filtering. You can call
willFetchData(criteria)
to determine if new criteria will result in a server fetch.If you need to force data to be re-fetched, you can call
invalidateCache()
and new data will automatically be fetched from the server using the current criteria and sort direction. NOTE: when usinginvalidateCache()
there is no need to also callfetchData()
and in fact this could produce unexpected results.This method takes an optional callback parameter (set to a
DSCallback
) to fire when the fetch completes. Note that this callback will not fire if no server fetch is performed. In this case the data is updated synchronously, so as soon as this method completes you can interact with the new data. If necessary, you can useresultSet.willFetchData()
to determine whether or not a server fetch will occur whenfetchData()
is called with new criteria.In addition to the callback parameter for this method, developers can use
resultSet.addDataArrivedHandler
to be notified every time data is loaded.- Specified by:
fetchData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
-
fetchData
Description copied from interface:DataBoundComponent
Retrieves data from the DataSource that matches the specified criteria.When
fetchData()
is first called, if data has not already been provided viasetData()
, this method will create aResultSet
, which will be configured based on component settings such asfetchOperation
anddataPageSize
, as well as the general purposedataProperties
. The created ResultSet will automatically send a DSRequest to retrieve data from the dataSource, and from then on will automatically manage paging through large datasets, as well as performing filtering and sorting operations inside the browser when possible - see the ResultSet docs for details.NOTE: do not use both
autoFetchData
and a call tofetchData()
- this may result in two DSRequests to fetch data. Use eitherautoFetchData
andsetAutoFetchCriteria()
or a manual call to fetchData() passing criteria.Whether a ResultSet was automatically created or provided via
setData()
, subsequent calls to fetchData() will simply callresultSet.setCriteria()
.Changes to criteria may or may not result in a DSRequest to the server due to client-side filtering. You can call
willFetchData(criteria)
to determine if new criteria will result in a server fetch.If you need to force data to be re-fetched, you can call
invalidateCache()
and new data will automatically be fetched from the server using the current criteria and sort direction. NOTE: when usinginvalidateCache()
there is no need to also callfetchData()
and in fact this could produce unexpected results.This method takes an optional callback parameter (set to a
DSCallback
) to fire when the fetch completes. Note that this callback will not fire if no server fetch is performed. In this case the data is updated synchronously, so as soon as this method completes you can interact with the new data. If necessary, you can useresultSet.willFetchData()
to determine whether or not a server fetch will occur whenfetchData()
is called with new criteria.In addition to the callback parameter for this method, developers can use
resultSet.addDataArrivedHandler
to be notified every time data is loaded.- Specified by:
fetchData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
callback
- callback to invoke when a fetch is complete. Fires only if server contact was required
-
fetchData
Description copied from interface:DataBoundComponent
Retrieves data from the DataSource that matches the specified criteria.When
fetchData()
is first called, if data has not already been provided viasetData()
, this method will create aResultSet
, which will be configured based on component settings such asfetchOperation
anddataPageSize
, as well as the general purposedataProperties
. The created ResultSet will automatically send a DSRequest to retrieve data from the dataSource, and from then on will automatically manage paging through large datasets, as well as performing filtering and sorting operations inside the browser when possible - see the ResultSet docs for details.NOTE: do not use both
autoFetchData
and a call tofetchData()
- this may result in two DSRequests to fetch data. Use eitherautoFetchData
andsetAutoFetchCriteria()
or a manual call to fetchData() passing criteria.Whether a ResultSet was automatically created or provided via
setData()
, subsequent calls to fetchData() will simply callresultSet.setCriteria()
.Changes to criteria may or may not result in a DSRequest to the server due to client-side filtering. You can call
willFetchData(criteria)
to determine if new criteria will result in a server fetch.If you need to force data to be re-fetched, you can call
invalidateCache()
and new data will automatically be fetched from the server using the current criteria and sort direction. NOTE: when usinginvalidateCache()
there is no need to also callfetchData()
and in fact this could produce unexpected results.This method takes an optional callback parameter (set to a
DSCallback
) to fire when the fetch completes. Note that this callback will not fire if no server fetch is performed. In this case the data is updated synchronously, so as soon as this method completes you can interact with the new data. If necessary, you can useresultSet.willFetchData()
to determine whether or not a server fetch will occur whenfetchData()
is called with new criteria.In addition to the callback parameter for this method, developers can use
resultSet.addDataArrivedHandler
to be notified every time data is loaded.- Specified by:
fetchData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
callback
- callback to invoke when a fetch is complete. Fires only if server contact was requiredrequestProperties
- additional properties to set on the DSRequest that will be issued
-
filterData
public void filterData()Description copied from interface:DataBoundComponent
Retrieves data that matches the provided criteria and displays the matching data in this component.This method behaves exactly like
ListGrid.fetchData()
except thattextMatchStyle
is automatically set to "substring" so that String-valued fields are matched by case-insensitive substring comparison.- Specified by:
filterData
in interfaceDataBoundComponent
-
filterData
Description copied from interface:DataBoundComponent
Retrieves data that matches the provided criteria and displays the matching data in this component.This method behaves exactly like
ListGrid.fetchData()
except thattextMatchStyle
is automatically set to "substring" so that String-valued fields are matched by case-insensitive substring comparison.- Specified by:
filterData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
-
filterData
Description copied from interface:DataBoundComponent
Retrieves data that matches the provided criteria and displays the matching data in this component.This method behaves exactly like
ListGrid.fetchData()
except thattextMatchStyle
is automatically set to "substring" so that String-valued fields are matched by case-insensitive substring comparison.- Specified by:
filterData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
callback
- callback to invoke when a fetch is complete. Fires only if server contact was required; seeDataBoundComponent.fetchData()
for details
-
filterData
Description copied from interface:DataBoundComponent
Retrieves data that matches the provided criteria and displays the matching data in this component.This method behaves exactly like
ListGrid.fetchData()
except thattextMatchStyle
is automatically set to "substring" so that String-valued fields are matched by case-insensitive substring comparison.- Specified by:
filterData
in interfaceDataBoundComponent
- Parameters:
criteria
- Search criteria. If aDynamicForm
is passed in as this argument instead of a raw criteria object, will be derived by callingDynamicForm.getValuesAsCriteria()
callback
- callback to invoke when a fetch is complete. Fires only if server contact was required; seeDataBoundComponent.fetchData()
for detailsrequestProperties
- for databound components only - optional additional properties to set on the DSRequest that will be issued
-
invalidateCache
public void invalidateCache()Description copied from interface:DataBoundComponent
Invalidate the current data cache for this databound component via a call to the dataset'sinvalidateCache()
method, for example,ResultSet.invalidateCache()
.NOTE: there is no need to call
invalidateCache()
when a save operation is performed on a DataSource. Automatic cache synchronization features will automatically update caches - seeResultSet
for details. If automatic cache synchronization isn't working, troubleshoot the problem using the steps suggested in the FAQ rather than just calling invalidateCache(). CallinginvalidateCache()
unnecessarily causes extra server load and added code complexity.Calling
invalidateCache()
will automatically cause a new fetch to be performed with the current set of criteria if data had been previously fetched and the component is currently drawn with data visible - there is no need to manually call fetchData() after invalidateCache() and this could result in duplicate fetches.While data is being re-loaded after a call to
invalidateCache()
, the widget is in a state similar to initial data load - it doesn't know the total length of the dataset and any APIs that act on records or row indices will necessarily fail and should not be called. To detect that the widget is in this state, callResultSet.lengthIsKnown()
.invalidateCache()
only has an effect if this component's dataset is a data manager class that manages a cache (eg ResultSet or ResultTree). If data was provided as a simple Array or List, invalidateCache() does nothing.- Specified by:
invalidateCache
in interfaceDataBoundComponent
- See Also:
-
getResultSet
Description copied from interface:DataBoundComponent
Return the underlying data of this DataBoundComponent as aResultSet
.Note that this method should only be called after initial data has been fetched by this DataBoundComponent.
- Specified by:
getResultSet
in interfaceDataBoundComponent
- Returns:
- ResultSet, or null if the underlying data is not a ResultSet
- See Also:
-
getRecordList
Description copied from interface:DataBoundComponent
Return the underlying data of this DataBoundComponent as aRecordList
.Depending on the component configuration, the actual JavaScript instance of the returned RecordList may be one of several types:
- If the component is not bound to a
DataSource
, the instance is generally an Array ofRecord
. - If the component is bound to a DataSource, the instance is a
ResultSet
. - If the component is a grouped ListGrid, the instance is a
Tree
. To access the ungrouped record list regardless of grouping status, useisGrouped() ? getOriginalRecordList() : getRecordList()
- If the component is a
TreeGrid
, the instance is a ResultTree.
- Specified by:
getRecordList
in interfaceDataBoundComponent
- Returns:
- the RecordList
- If the component is not bound to a
-
getDataAsJSList
- Specified by:
getDataAsJSList
in interfaceDataBoundComponent
-
exportData
public void exportData()Description copied from interface:DataBoundComponent
- Specified by:
exportData
in interfaceDataBoundComponent
-
exportData
Description copied from interface:DataBoundComponent
- Specified by:
exportData
in interfaceDataBoundComponent
-
exportData
Description copied from interface:DataBoundComponent
Uses a "fetch" operation on the currentDataSource
to retrieve data that matches the current filter and sort criteria for this component, then exports the resulting data to a file or window in the requested format.A variety of DSRequest settings, such as
exportAs
andexportFilename
, affect the exporting process: seeexportResults
for further detail.Note that data exported via this method does not include any client-side formatting and relies on both the Smart GWT server and server-side DataSources. To export client-data with formatters applied, see
exportClientData
, which still requires the Smart GWT server but does not rely on server-side DataSources.For more information on exporting data, see
DataSource.exportData
.- Specified by:
exportData
in interfaceDataBoundComponent
- Parameters:
requestProperties
- additional properties to set on DSRequest that will be issuedcallback
- Optional callback. Note that this parameter only applies if you specifyexportToClient
: false in the request properties, because file downloads don't provide ordinary framework callbacks- See Also:
-
addFetchDataHandler
Add a fetchData handler.Notification function fired on fetchData() or filterData()
- Specified by:
addFetchDataHandler
in interfaceHasFetchDataHandlers
- Parameters:
handler
- the filterData handler- Returns:
HandlerRegistration
used to remove this handler
-
addDropCompleteHandler
Add acom.smartgwt.client.widgets.DropCompleteHandler
. See that class's documentation for a definition of "drop complete", and how it differs from "drag complete" (com.smartgwt.client.widgets.DragCompleteHandler
).- Specified by:
addDropCompleteHandler
in interfaceHasDropCompleteHandlers
- Parameters:
handler
- the DropCompleteHandler- Returns:
HandlerRegistration
used to remove this handler
-
addDragCompleteHandler
Add acom.smartgwt.client.widgets.DragCompleteHandler
. See that class's documentation for a definition of "drag complete", and how it differs from "drop complete" (com.smartgwt.client.widgets.DropCompleteHandler
).- Specified by:
addDragCompleteHandler
in interfaceHasDragCompleteHandlers
- Parameters:
handler
- the DropCompleteHandler- Returns:
HandlerRegistration
used to remove this handler
-
getFieldAlignments
Description copied from interface:DataBoundComponent
Returna an array of field alignments for this grid- Specified by:
getFieldAlignments
in interfaceDataBoundComponent
- Returns:
- array of Alignments
-
getDeepCloneOnEdit
Description copied from interface:DataBoundComponent
Before we start editing values in this DataBoundComponent, should we perform a deep clone of the underlying values. SeeDataSource.getDeepCloneOnEdit()
for details of what this means.If this value is not explicitly set, it defaults to the DataSource
deepCloneOnEdit
value. This value can also be overridden per-field withDataSourceField.setDeepCloneOnEdit(java.lang.Boolean)
.Like the other
deepCloneOnEdit
settings, this flag only has an effect if you are editing a values object that contains nested objects or arrays, usingCanvas.setDataPath(java.lang.String)
- Specified by:
getDeepCloneOnEdit
in interfaceDataBoundComponent
-
setDeepCloneOnEdit
Description copied from interface:DataBoundComponent
Before we start editing values in this DataBoundComponent, should we perform a deep clone of the underlying values. SeeDataSource.getDeepCloneOnEdit()
for details of what this means.If this value is not explicitly set, it defaults to the DataSource
deepCloneOnEdit
value. This value can also be overridden per-field withDataSourceField.setDeepCloneOnEdit(java.lang.Boolean)
.Like the other
deepCloneOnEdit
settings, this flag only has an effect if you are editing a values object that contains nested objects or arrays, usingCanvas.setDataPath(java.lang.String)
- Specified by:
setDeepCloneOnEdit
in interfaceDataBoundComponent
- Returns:
DataBoundComponent
instance, for chaining setter calls
-
setFields
Description copied from interface:DataBoundComponent
Field setter variant (alternative tosetFields(FormItem...)
,setFields(ListGridField...)
, etc.) that will accept an array of JavaScriptObject, rather than an array of SmartGWT Java wrappers of the field class type (e.g.FormItem
,ListGridField
, etc.) This is an advanced method and only for cases where you have the JavaScriptObject for each field but want to avoid having to create each associated SmartGWT Java wrapper.Note: use
toArray()
to create a Java array of JavaScriptObject if you only have the array itself as a single JavaScriptObject.- Specified by:
setFields
in interfaceDataBoundComponent
- Parameters:
fields
- the component fields- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getFieldsAsJavaScriptObjects
Description copied from interface:DataBoundComponent
Return the fields as JavaScriptObjects rather than as SmartGWT Java wrappers of the field class type (e.g.FormItem
,ListGridField
, etc.) This avoids building the SmartGWT Java wrappers for the fields in situations where they aren't needed - and for FormItems in particular - where there may not be enough information to determine the correct subclass, such as before the SmartClient instance underlying theDynamicForm
has been created.- Specified by:
getFieldsAsJavaScriptObjects
in interfaceDataBoundComponent
- Returns:
- the component fields
-
getFieldCount
public int getFieldCount()Description copied from interface:DataBoundComponent
Return the number of fields.- Specified by:
getFieldCount
in interfaceDataBoundComponent
- Returns:
- the number of fields
-
transferRecords
public void transferRecords(Record[] records, Record targetRecord, Integer index, Canvas sourceWidget, TransferRecordsCallback callback) Description copied from interface:DataBoundComponent
Transfer a list ofRecord
s from another component (does not have to be a databound component) into this component. This method is only applicable to list-type components, such asListGrid
orcom.smartgwt.client.widgets.tile.TileGridTileGrid
. Notably, it does not apply toTreeGrid
; the equivalent for treeGrids istransferNodes
.This method implements the automatic drag-copy and drag-move behaviors of components like
ListGrid
, and calling it is equivalent to completing a drag and drop of thedropRecords
(the default record drop behavior is simply to calltransferRecords()
, passing in the dropped nodes)Note that this method is asynchronous - it may need to perform server turnarounds to prevent duplicates in the target component's data. If you wish to be notified when the transfer process has completed, you can either pass a non-null callback to this method or add a
DropCompleteHandler
to this component.See also
transferSelectedData()
- Specified by:
transferRecords
in interfaceDataBoundComponent
- Parameters:
records
- Recordss to transfer to this componenttargetRecord
- The target record (eg, of a drop interaction), for contextindex
- Insert point relative to the target record for the transferred recordssourceWidget
- The databound or non-databound component from which the records are to be transferred.callback
- optional TransferRecordsCallback to be fired when the transfer process has completed (pass null if your code does not need to be called back). The callback will be passed the list of records actually transferred to this component
-
setDragDataCustomizer
During a drag-and-drop interaction, this method returns the set of records being dragged out of the component. In the default implementation, this is the list of currently selected records.This method is consulted by
willAcceptDrop()
.- Parameters:
DragDataCustomizer
- customizer- Returns:
DataBoundComponent
instance, for chaining setter calls
-
getSort
Description copied from interface:DataBoundComponent
Returns the currentSortSpecifiers
for this component. Will return null if this component has never been sorted, or the underlying SmartClient widget does not exist.- Specified by:
getSort
in interfaceDataBoundComponent
- Returns:
- current sort specifiers for this component (null if unsorted or no SC widget)
-
setSort
Description copied from interface:DataBoundComponent
Sort the component on one or more fields.Pass in an array of
SortSpecifier
s to have the component's data sorted by the fields in eachspecifier.property
and in the directions specified. The component can be sorted by any combination of fields, including fields specified in the fields array andunused fields from the underlying dataSource
, if there is one.If setSort() is called on a component which doesn't yet have a SmartClient widget, the widget will be created. If
autoFetchData
is set and aDataSource
has been set, this will result in data being fetched.- Specified by:
setSort
in interfaceDataBoundComponent
- Parameters:
sortSpecifiers
- Array ofSortSpecifier
objects
-
setLogicalStructure
Setter implementing theLogicalStructure
interface, which supports Eclipse's logical structure debugging facility. -
getLogicalStructure
Getter implementing theLogicalStructure
interface, which supports Eclipse's logical structure debugging facility.- Specified by:
getLogicalStructure
in interfaceLogicalStructure
- Overrides:
getLogicalStructure
in classCanvas
-
addCalendarEvent()