Class CmsJspDateSeriesBean
-
Nested Class Summary
Modifier and TypeClassDescriptionclass
Provides information on the single event when the start date is provided. -
Constructor Summary
ConstructorDescriptionCmsJspDateSeriesBean
(CmsJspContentAccessValueWrapper value, Locale locale) Constructor for a date series bean. -
Method Summary
Modifier and TypeMethodDescriptiongetDates()
Returns the list of start dates for all instances of the series.getFirst()
Returns the first event of this series.Returns the duration of a single instance in milliseconds.Returns a lazy map from the start time of a single instance of the series to the date information on the single instance.boolean
Returns a flag, indicating if the series is extracted from another series.boolean
Returns a flag, indicating if the series is defined via a pattern, i.e., not just as via single date.boolean
Returns a flag, indicating if the series is defined by only a single date and not extracted from another series.getLast()
Returns the last event of this series.Returns the locale to use for rendering dates.getNext()
Returns the next event of this series relative to the current date.getNextFor
(Object date) Returns the next event of this series that takes place at the given date or after it.Returns the parent series, if it is present, otherwisenull
.Returns the next event of this series relative to the current date.getPreviousFor
(Object date) Returns the next event of this series that takes place at the given date or after it.getTitle()
Returns the gallery title of the series content.boolean
Returns a flag, indicating if the single events last over night.boolean
Returns a flag, indicating if the events in the series last whole days.Converts the provided object to a date, if possible.
-
Constructor Details
-
CmsJspDateSeriesBean
Constructor for a date series bean.- Parameters:
value
- the content value wrapper for the element that stores the series definitionlocale
- the locale in which dates should be rendered. This can differ from the content locale, if e.g. on a German page a content that is only present in English is rendered.
-
-
Method Details
-
getDates
Returns the list of start dates for all instances of the series.- Returns:
- the list of start dates for all instances of the series
-
getFirst
Returns the first event of this series.In case this is just a single event and not a series, this is identical to the date of the event.
- Returns:
- the first event of this series
-
getInstanceDuration
Returns the duration of a single instance in milliseconds.- Returns:
- the duration of a single instance in milliseconds
-
getInstanceInfo
Returns a lazy map from the start time of a single instance of the series to the date information on the single instance.Start time can be provided as Long, as a String representation of the long value or as Date.
If no event exists for the start time, the information for the first event of the series is returned.
- Returns:
- a lazy map from the start time of a single instance of the series to the date information on the single instance.
-
getIsExtractedDate
Returns a flag, indicating if the series is extracted from another series.- Returns:
- a flag, indicating if the series is extracted from another series
-
getIsSeries
Returns a flag, indicating if the series is defined via a pattern, i.e., not just as via single date.- Returns:
- a flag, indicating if the series is defined via a pattern, i.e., not just as via single date
-
getIsSingleDate
Returns a flag, indicating if the series is defined by only a single date and not extracted from another series.- Returns:
- a flag, indicating if the series is defined by only a single date and not extracted from another series
-
getLast
Returns the last event of this series.In case this is just a single event and not a series, this is identical to the date of the event.
- Returns:
- the last event of this series
-
getLocale
Returns the locale to use for rendering dates.- Returns:
- the locale to use for rendering dates
-
getNext
Returns the next event of this series relative to the current date.In case this is just a single event and not a series, this is identical to the date of the event.
- Returns:
- the next event of this series
-
getNextFor
Returns the next event of this series that takes place at the given date or after it.In case this is just a single event and not a series, this is identical to the date of the event.
- Parameters:
date
- the date relative to which the event is returned.- Returns:
- the next event of this series
-
getParentSeries
Returns the parent series, if it is present, otherwisenull
.- Returns:
- the parent series, if it is present, otherwise
null
-
getPrevious
Returns the next event of this series relative to the current date.In case this is just a single event and not a series, this is identical to the date of the event.
- Returns:
- the next event of this series
-
getPreviousFor
Returns the next event of this series that takes place at the given date or after it.In case this is just a single event and not a series, this is identical to the date of the event.
- Parameters:
date
- the date relative to which the event is returned.- Returns:
- the next event of this series
-
getTitle
Returns the gallery title of the series content.- Returns:
- the gallery title of the series content
-
isMultiDay
Returns a flag, indicating if the single events last over night.- Returns:
true
if the event ends on another day than it starts,false
if it ends on the same day
-
isWholeDay
Returns a flag, indicating if the events in the series last whole days.- Returns:
- a flag, indicating if the events in the series last whole days
-
toDate
Converts the provided object to a date, if possible.- Parameters:
date
- the date.- Returns:
- the date as
Date
-