public class RecurrenceIteratorFactory extends Object
Calculates the occurrences of an individual RRULE definition or groups of RRULEs, RDATEs, EXRULEs, and EXDATEs.
Glossary
Abstractions
All the functions that represent rule parts are stateful.
Modifier and Type | Method and Description |
---|---|
static RecurrenceIterable |
createRecurrenceIterable(Recurrence rrule,
DateValue dtStart,
TimeZone tzid)
Creates a recurrence iterable from an RRULE.
|
static RecurrenceIterator |
createRecurrenceIterator(Collection<? extends DateValue> dates)
Creates a recurrence iterator from an RDATE or EXDATE list.
|
static RecurrenceIterator |
createRecurrenceIterator(Recurrence rrule,
DateValue dtStart,
TimeZone tzid)
Creates a recurrence iterator from an RRULE.
|
static RecurrenceIterator |
except(RecurrenceIterator included,
RecurrenceIterator excluded)
Generates a recurrence iterator that iterates over all the dates in a
RecurrenceIterator , excluding those dates found in another
RecurrenceIterator . |
static RecurrenceIterator |
join(RecurrenceIterator first,
RecurrenceIterator... rest)
Generates a recurrence iterator that iterates over the union of the given
recurrence iterators.
|
public static RecurrenceIterator createRecurrenceIterator(Collection<? extends DateValue> dates)
dates
- the list of datespublic static RecurrenceIterable createRecurrenceIterable(Recurrence rrule, DateValue dtStart, TimeZone tzid)
rrule
- the recurrence ruledtStart
- the start date of the seriestzid
- the timezone that the start date is in, as well as the
timezone to iterate inpublic static RecurrenceIterator createRecurrenceIterator(Recurrence rrule, DateValue dtStart, TimeZone tzid)
rrule
- the recurrence ruledtStart
- the start date of the seriestzid
- the timezone that the start date is in, as well as the
timezone to iterate inpublic static RecurrenceIterator join(RecurrenceIterator first, RecurrenceIterator... rest)
first
- the first recurrence iteratorrest
- the other recurrence iteratorspublic static RecurrenceIterator except(RecurrenceIterator included, RecurrenceIterator excluded)
Generates a recurrence iterator that iterates over all the dates in a
RecurrenceIterator
, excluding those dates found in another
RecurrenceIterator
.
Exclusions trump inclusions, and dates
and
date-times
never match one another.
included
- the dates to includeexcluded
- the dates to excludeCopyright © 2013-2017 Michael Angstadt. All Rights Reserved.