If given, it must be either an integer, or a sequence of integers, meaning the hours valid in the recurrence.
If given, it must be either an integer, or a sequence of integers, meaning the minutes valid in the recurrence.
If given, it must be either an integer, or a sequence of integers, meaning the months valid in the recurrence.
If given, it must be either an integer, or a sequence of integers, meaning the month days valid in the recurrence.
If given, it must be either an integer, or a sequence of integers, meaning the minutes valid in the recurrence.
The bySetPos specifies a value or list of values which correspond to the nth occurrence(s) within the set of events specified by the rule.
The bySetPos specifies a value or list of values which correspond to the nth occurrence(s) within the set of events specified by the rule. Valid values are +/-1 to +/-366. It MUST be used in conjunction with another BYxxx rule, and is used to restrict the occurrences valid within the rule.
If given, it must be either a Weekday (eg MO), a or a sequence of these constants.
If given, it must be either a Weekday (eg MO), a or a sequence of these constants. When given, these variables will define the weekdays valid in the recurrence. It's also possible to use an argument n for the weekday instances, which will signify the nth occurrence of this weekday in the period. For example, with MONTHLY, or with YEARLY and BYMONTH, using FR(+1) in byweekday will specify the first friday of the month where the recurrence happens. Notice that in the RFC documentation, this is specified as BYDAY, but was renamed to avoid the ambiguity of that keyword.
If given, it must be either an integer, or a sequence of integers, meaning the week numbers valid in the recurrence.
If given, it must be either an integer, or a sequence of integers, meaning the week numbers valid in the recurrence. Week numbers have the meaning described in ISO8601, that is, the first week of the year is that containing at least four days of the new year.
If given, it must be either an integer, or a sequence of integers, meaning the year days valid in the recurrence.
Syntactic sugar to get the nth occurrence; allows user to write, e.
Syntactic sugar to get the nth occurrence; allows user to write, e.g.
val x = weeklyOn(FR) counting 3 from datetime(2013, 1, 1)
to get the third Friday in January 2013. With a negative number, e.g.
val x = weeklyOn(FR) counting -3 from datetime(2013, 1, 1)
you would get the third occurrence counting back from Jan 1, 2013.
Note that in both cases, if the 'from' date conforms to the recurrence rule, it will be counted.
Exclude another RRule, and optionally specify a start date.
Exclude another RRule, and optionally specify a start date. If a start date is not specified, it will utilize the start date provided when the function 'from' is applied.
Generate an iterator of DateTime instances based on the current RRule instance starting on or after the provided DateTime instance.
If given, it determines which time zone the recurrence date/times will be generated in.
Join with another RRule, and optionally specify a start date.
Join with another RRule, and optionally specify a start date. If a start date is not specified, it will utilize the start date provided when the function 'from' is applied.
How many occurrences will be generated.
The interval between each freq iteration.
The interval between each freq iteration. For example, when using YEARLY, an interval of 2 means once every two years, but with HOURLY, it means once every two hours. The default interval is 1.
A datetime instance that will specify the limit of the recurrence.
The week start day.
The week start day. Must be one of the MO, TU, ... constants specifying the first day of the week. This will affect recurrences based on weekly periods.
Wrapper of a RFC 2445 RRULE or EXRULE as implemented in the google rfc2445 java library.
For _lots_ of examples of recurrence rule constructions, see the following: http://recurrance.sourceforge.net/
To create, start by invoking RRule(frequency), e.g.
RRule(DAILY)
Use setters to construct the rule you want. For instance:
val rule = RRule(DAILY) byWeekDay(TU, TH) withCount(3)
Finally, attach a start date as follows, to get a DateTime iterator:
val iter = rule from datetime(2007,1,1)
By default, the times created will be in LOCAL time; however, you may attach a different time zone (eg, UTC).
Also, you may join rules or add exceptions via the join and except functions. Eg,
val rules = RRule(DAILY) byWeekDay(TU, TH) join { RRule(DAILY) byWeekDay(MO) } val dates = rules from datetime(2006,12,31) take(5) toList
Please note:
Some of the javadoc descriptions of RFC2445 fields are courtesy of python dateutil 2.1: -- http://labix.org/python-dateutil -- https://pypi.python.org/pypi/python-dateutil