Module com.flexganttfx.model
Package com.flexganttfx.model.calendar
Class CalendarBase<A extends CalendarActivity>
java.lang.Object
com.flexganttfx.model.repository.ActivityRepositoryBase<A>
com.flexganttfx.model.calendar.CalendarBase<A>
- Type Parameters:
A- the type of the activities returned by the calendar
- All Implemented Interfaces:
ActivityRepository<A>,Calendar<A>,EventTarget
- Direct Known Subclasses:
WeekendCalendar
public abstract class CalendarBase<A extends CalendarActivity> extends ActivityRepositoryBase<A> implements Calendar<A>
An abstract base implementation of an activity repository that implements the
Calendar interface.- Since:
- 1.0
-
Property Summary
Properties Type Property Description StringPropertynameReturns the property used to store the name of the calendar.BooleanPropertyvisibleReturns the property used to store the visibility flag of the calendar. -
Constructor Summary
Constructors Modifier Constructor Description protectedCalendarBase(String name)Constructs a new calendar. -
Method Summary
Modifier and Type Method Description StringgetName()Returns the value of thenameProperty().booleanisVisible()Returns the value of thevisibleProperty().StringPropertynameProperty()Returns the property used to store the name of the calendar.voidsetName(String name)Sets the value of thenameProperty().voidsetVisible(boolean visible)Sets the value of thevisibleProperty().BooleanPropertyvisibleProperty()Returns the property used to store the visibility flag of the calendar.Methods inherited from class com.flexganttfx.model.repository.ActivityRepositoryBase
addEventHandler, buildEventDispatchChain, fireEvent, getEarliestTimeUsed, getLatestTimeUsed, removeEventHandlerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.flexganttfx.model.ActivityRepository
addEventHandler, getActivities, getEarliestTimeUsed, getLatestTimeUsed, removeEventHandlerMethods inherited from interface javafx.event.EventTarget
buildEventDispatchChain
-
Property Details
-
name
- Specified by:
namePropertyin interfaceCalendar<A extends CalendarActivity>- See Also:
getName(),setName(String)
-
visible
- Specified by:
visiblePropertyin interfaceCalendar<A extends CalendarActivity>- See Also:
isVisible(),setVisible(boolean)
-
-
Constructor Details
-
CalendarBase
Constructs a new calendar.- Parameters:
name- the name of the calendar- Since:
- 1.0
-
-
Method Details
-
nameProperty
Description copied from interface:CalendarReturns the property used to store the name of the calendar. The name might be displayed by the UI (e.g. in a context menu).- Specified by:
namePropertyin interfaceCalendar<A extends CalendarActivity>- See Also:
getName(),setName(String)
-
getName
Returns the value of thenameProperty().- Returns:
- the calendar name
- Since:
- 1.0
-
setName
Sets the value of thenameProperty().- Parameters:
name- the calendar name- Since:
- 1.0
-
visibleProperty
Description copied from interface:CalendarReturns the property used to store the visibility flag of the calendar. Calendars can be shown / hidden by the user.- Specified by:
visiblePropertyin interfaceCalendar<A extends CalendarActivity>- See Also:
isVisible(),setVisible(boolean)
-
isVisible
public final boolean isVisible()Returns the value of thevisibleProperty().- Returns:
- the calendar visibility
- Since:
- 1.0
-
setVisible
public final void setVisible(boolean visible)Sets the value of thevisibleProperty().- Parameters:
visible- the calendar visibility- Since:
- 1.0
-