Top Inners Fields Constructors Methods
impl.com.calendarfx.view

public Class DayViewSkin<T extends DayView>

extends DayViewBaseSkin<T extends DayView>
implements LoadDataSettingsProvider
Class Inheritance
All Implemented Interfaces
impl.com.calendarfx.view.LoadDataSettingsProvider
Known Direct Subclasses
impl.com.calendarfx.view.WeekDayViewSkin
Annotations
@SuppressWarnings:javadoc
Imports
com.calendarfx.model.Calendar, .CalendarEvent, .CalendarSource, .Entry, com.calendarfx.util.LoggingDomain, .ViewHelper, com.calendarfx.view.DateControl, .DateControl.Layer, .DayEntryView, .DayView, .DayViewBase.AvailabilityEditingEntryBehaviour, .DayViewBase.EarlyLateHoursStrategy, .DayViewBase.GridType, .DayViewBase.OverlapResolutionStrategy, .DraggedEntry, .EntryViewBase, .EntryViewBase.AlignmentStrategy, .EntryViewBase.HeightLayoutStrategy, .EntryViewBase.Position, .VirtualGrid, impl.com.calendarfx.view.util.Placement, .TimeBoundsResolver, .Util, .VisualBoundsResolver, javafx.animation.FadeTransition, javafx.application.Platform, javafx.beans.InvalidationListener, .Observable, .WeakInvalidationListener, javafx.beans.binding.Bindings, javafx.beans.value.ChangeListener, javafx.event.EventHandler, .WeakEventHandler, javafx.scene.Group, .Node, javafx.scene.canvas.Canvas, .GraphicsContext, javafx.scene.control.Control, javafx.scene.layout.Region, javafx.scene.shape.Circle, .Line, .Rectangle, javafx.util.Callback, .Duration, java.time.Instant, .LocalDate, .LocalTime, .ZoneId, .ZonedDateTime, java.time.temporal.ChronoUnit, java.util.ArrayList, .Collections, .Comparator, .HashMap, .List, .Map, .Optional, java.util.function.Function, .Predicate, java.util.logging.Level, java.util.stream.Collectors

Nested and Inner Type Summary

Modifier and TypeClass and Description
private class

Field Summary

Modifier and TypeField and Description
private final EventHandler<CalendarEvent>
private final DayViewSkin<T>.BackgroundCanvas
private final Circle
private final Line
private final DataLoader
private LocalDate
private DayEntryView
private final Region
private final Group
private static final String
private static final String
private final Region
private final InvalidationListener
private final List<Line>
private static final String
private static final String
private double
private final WeakEventHandler<CalendarEvent>
private final WeakInvalidationListener

Constructor Summary

AccessConstructor and Description
public
DayViewSkin(T view)

Method Summary

Modifier and TypeMethod and Description
private void
addEntryView(Entry<?> entry, String reason)

private void
protected void
protected void
private double
computeEntryLeftOffset(EntryViewBase<?> entryView, double entryWidth, double availableWidth)

private double
computeEntryWidth(EntryViewBase<?>
view entry
entryView
,
double
maximum available horizontal space for entry view
availableWidth
)

Compute entry width during layout phase.

private void
private void
createLine(String styleClass)

private void
private DayEntryView
protected void
protected void
protected void
protected void
private Optional<EntryViewBase<T extends DateControl>>
findEntryView(Entry<?> entry)

private int
findIndex(Entry<?> entry)

private Optional<Entry<?>>
public List<CalendarSource>
public Control
private Calendar<T>
public LocalDate
public String
public LocalDate
public ZoneId
private <G> Map<G, List<DayEntryView>>
groupEntryViewsBy(Function<DayEntryView, G> groupByFunction, Predicate<DayEntryView> viewEntryFilter)

public boolean
protected boolean
protected boolean
protected void
layoutBaseEntryViews(List<DayEntryView> entryViews, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)

protected void
layoutChildren(double
the x position
contentX
,
double
the y position
contentY
,
double
the width
contentWidth
,
double
the height
contentHeight
)

Overrides javafx.scene.control.SkinBase.layoutChildren.

Called during the layout pass of the scenegraph.

protected void
layoutChildrenInfiniteScrolling(double contentX, double contentY, double contentWidth, double contentHeight)

protected void
layoutChildrenStatic(double contentX, double contentY, double contentWidth, double contentHeight)

protected void
layoutCurrentTime(double contentX, double contentY, double contentWidth)

protected void
layoutEntries(double contentX, double contentY, double contentWidth, double contentHeight)

private void
layoutOnLayers(Map<DateControl.Layer, List<DayEntryView>> layerGroupedViewEntries, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)

private void
layoutStandard(DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)

private void
layoutSwimlane(DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)

protected void
layoutTopEntryViews(List<DayEntryView> entryViews, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)

private void
listenToAvailabilityCalendar(Calendar<T> oldCalendar, Calendar<T> newCalendar)

private void
loadData(String reason)

protected void
private boolean
removeEntryView(Entry<?> entry, String reason)

private void
private void
private void
private void
private void
protected void
Inherited from impl.com.calendarfx.view.DayViewBaseSkin:
computeMaxHeightcomputeMinHeightcomputePrefHeight

Field Detail

availabilityHandlerback to summary
private final EventHandler<CalendarEvent> availabilityHandler
backgroundCanvasback to summary
private final DayViewSkin<T>.BackgroundCanvas backgroundCanvas
currentTimeCircleback to summary
private final Circle currentTimeCircle
currentTimeLineback to summary
private final Line currentTimeLine
dataLoaderback to summary
private final DataLoader dataLoader
displayedDateback to summary
private LocalDate displayedDate
draggedEntryViewback to summary
private DayEntryView draggedEntryView
earlyHoursRegionback to summary
private final Region earlyHoursRegion
entryViewGroupback to summary
private final Group entryViewGroup
FULL_HOUR_LINE_STYLE_CLASSback to summary
private static final String FULL_HOUR_LINE_STYLE_CLASS
HALF_HOUR_LINE_STYLE_CLASSback to summary
private static final String HALF_HOUR_LINE_STYLE_CLASS
lateHoursRegionback to summary
private final Region lateHoursRegion
layoutListenerback to summary
private final InvalidationListener layoutListener

Hides impl.com.calendarfx.view.DayViewBaseSkin.layoutListener.

linesback to summary
private final List<Line> lines
MIDNIGHT_LINE_STYLE_CLASSback to summary
private static final String MIDNIGHT_LINE_STYLE_CLASS
NOON_LINE_STYLE_CLASSback to summary
private static final String NOON_LINE_STYLE_CLASS
startYback to summary
private double startY
weakAvailabilityHandlerback to summary
private final WeakEventHandler<CalendarEvent> weakAvailabilityHandler
weakLayoutListenerback to summary
private final WeakInvalidationListener weakLayoutListener

Constructor Detail

DayViewSkinback to summary
public DayViewSkin(T view)

Method Detail

addEntryViewback to summary
private void addEntryView(Entry<?> entry, String reason)
addOrRemoveDraggedEntryViewback to summary
private void addOrRemoveDraggedEntryView()
calendarChangedback to summary
protected void calendarChanged(Calendar<T> calendar)

Overrides impl.com.calendarfx.view.DateControlSkin.calendarChanged.

Annotations
@Override
calendarVisibilityChangedback to summary
protected void calendarVisibilityChanged()

Overrides impl.com.calendarfx.view.DateControlSkin.calendarVisibilityChanged.

Annotations
@Override
computeEntryLeftOffsetback to summary
private double computeEntryLeftOffset(EntryViewBase<?> entryView, double entryWidth, double availableWidth)
computeEntryWidthback to summary
private double computeEntryWidth(EntryViewBase<?> entryView, double availableWidth)

Compute entry width during layout phase.

Parameters
entryView:EntryViewBase<?>

view entry

availableWidth:double

maximum available horizontal space for entry view

createLineback to summary
private void createLine()
createLineback to summary
private void createLine(String styleClass)
createStaticLinesback to summary
private void createStaticLines()
doAddEntryViewback to summary
private DayEntryView doAddEntryView(Entry<?> entry)
entryCalendarChangedback to summary
protected void entryCalendarChanged(CalendarEvent evt)

Overrides impl.com.calendarfx.view.DateControlSkin.entryCalendarChanged.

Annotations
@Override
entryFullDayChangedback to summary
protected void entryFullDayChanged(CalendarEvent evt)

Overrides impl.com.calendarfx.view.DateControlSkin.entryFullDayChanged.

Annotations
@Override
entryIntervalChangedback to summary
protected void entryIntervalChanged(CalendarEvent evt)

Overrides impl.com.calendarfx.view.DateControlSkin.entryIntervalChanged.

Annotations
@Override
entryRecurrenceRuleChangedback to summary
protected void entryRecurrenceRuleChanged(CalendarEvent evt)

Overrides impl.com.calendarfx.view.DateControlSkin.entryRecurrenceRuleChanged.

Annotations
@Override
findEntryViewback to summary
private Optional<EntryViewBase<T extends DateControl>> findEntryView(Entry<?> entry)
findIndexback to summary
private int findIndex(Entry<?> entry)
findRecurrenceEntryback to summary
private Optional<Entry<?>> findRecurrenceEntry(Entry<?> entry)
getCalendarSourcesback to summary
public List<CalendarSource> getCalendarSources()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getCalendarSources.

Annotations
@Override
getControlback to summary
public Control getControl()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getControl.

Annotations
@Override
getEntryViewCalendarback to summary
private Calendar<T> getEntryViewCalendar(DayEntryView view)
getLoadEndDateback to summary
public LocalDate getLoadEndDate()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getLoadEndDate.

Annotations
@Override
getLoaderNameback to summary
public String getLoaderName()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getLoaderName.

Annotations
@Override
getLoadStartDateback to summary
public LocalDate getLoadStartDate()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getLoadStartDate.

Annotations
@Override
getZoneIdback to summary
public ZoneId getZoneId()

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.getZoneId.

Annotations
@Override
groupEntryViewsByback to summary
private <G> Map<G, List<DayEntryView>> groupEntryViewsBy(Function<DayEntryView, G> groupByFunction, Predicate<DayEntryView> viewEntryFilter)
isCalendarVisibleback to summary
public boolean isCalendarVisible(Calendar<T> calendar)

Implements impl.com.calendarfx.view.LoadDataSettingsProvider.isCalendarVisible.

Annotations
@Override
isShowingTimeMarkerback to summary
protected boolean isShowingTimeMarker()
isShowingTimeTodayMarkerback to summary
protected boolean isShowingTimeTodayMarker()
layoutBaseEntryViewsback to summary
protected void layoutBaseEntryViews(List<DayEntryView> entryViews, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)
layoutChildrenback to summary
protected void layoutChildren(double contentX, double contentY, double contentWidth, double contentHeight)

Overrides javafx.scene.control.SkinBase.layoutChildren.

Doc from javafx.scene.control.SkinBase.layoutChildren.

Called during the layout pass of the scenegraph.

Parameters
contentX:double

the x position

contentY:double

the y position

contentWidth:double

the width

contentHeight:double

the height

Annotations
@Override
layoutChildrenInfiniteScrollingback to summary
protected void layoutChildrenInfiniteScrolling(double contentX, double contentY, double contentWidth, double contentHeight)
layoutChildrenStaticback to summary
protected void layoutChildrenStatic(double contentX, double contentY, double contentWidth, double contentHeight)
layoutCurrentTimeback to summary
protected void layoutCurrentTime(double contentX, double contentY, double contentWidth)
layoutEntriesback to summary
protected void layoutEntries(double contentX, double contentY, double contentWidth, double contentHeight)
layoutOnLayersback to summary
private void layoutOnLayers(Map<DateControl.Layer, List<DayEntryView>> layerGroupedViewEntries, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)
layoutStandardback to summary
private void layoutStandard(DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)
layoutSwimlaneback to summary
private void layoutSwimlane(DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)
layoutTopEntryViewsback to summary
protected void layoutTopEntryViews(List<DayEntryView> entryViews, DayView dayView, double contentX, double contentY, double contentWidth, double contentHeight)
listenToAvailabilityCalendarback to summary
private void listenToAvailabilityCalendar(Calendar<T> oldCalendar, Calendar<T> newCalendar)
loadDataback to summary
private void loadData(String reason)
refreshDataback to summary
protected void refreshData()

Overrides impl.com.calendarfx.view.DateControlSkin.refreshData.

Annotations
@Override
removeEntryViewback to summary
private boolean removeEntryView(Entry<?> entry, String reason)
setupCurrentTimeMarkerSupportback to summary
private void setupCurrentTimeMarkerSupport()
updateEntriesback to summary
private void updateEntries(String reason)
updateLineStylingback to summary
private void updateLineStyling()
updateShowMarkersback to summary
private void updateShowMarkers()
updateTimelineVisibilityback to summary
private void updateTimelineVisibility()
zoneIdChangedback to summary
protected void zoneIdChanged()

Overrides impl.com.calendarfx.view.DateControlSkin.zoneIdChanged.

Annotations
@Override
impl.com.calendarfx.view back to summary

private Class DayViewSkin.BackgroundCanvas

extends Canvas
Class Inheritance

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public void
draw()

public boolean
isResizable()

Overrides javafx.scene.Node.isResizable.

Indicates whether this node is a type which can be resized by its parent.

Inherited from javafx.scene.canvas.Canvas:
getGraphicsContext2DgetHeightgetWidthheightPropertysetHeightsetWidthwidthProperty

Constructor Detail

BackgroundCanvasback to summary
pack-priv BackgroundCanvas()

Method Detail

drawback to summary
public void draw()
isResizableback to summary
public boolean isResizable()

Overrides javafx.scene.Node.isResizable.

Doc from javafx.scene.Node.isResizable.

Indicates whether this node is a type which can be resized by its parent. If this method returns true, then the parent will resize the node (ideally within its size range) by calling node.resize(width,height) during the layout pass. All Regions, Controls, and WebView are resizable classes which depend on their parents resizing them during layout once all sizing and CSS styling information has been applied.

If this method returns false, then the parent cannot resize it during layout (resize() is a no-op) and it should return its layoutBounds for minimum, preferred, and maximum sizes. Group, Text, and all Shapes are not resizable and hence depend on the application to establish their sizing by setting appropriate properties (e.g. width/height for Rectangle, text on Text, and so on). Non-resizable nodes may still be relocated during layout.

Returns:boolean

whether or not this node type can be resized by its parent during layout