public static class Recurrence.Builder extends Object
Recurrence
objects.Constructor and Description |
---|
Recurrence.Builder(Recurrence.Frequency frequency)
Constructs a new builder.
|
Recurrence.Builder(Recurrence recur)
Constructs a new builder
|
Modifier and Type | Method and Description |
---|---|
Recurrence |
build()
Builds the final
Recurrence object. |
Recurrence.Builder |
byDay(Integer prefix,
Recurrence.DayOfWeek byDay)
Adds a BYDAY rule part.
|
Recurrence.Builder |
byDay(Recurrence.DayOfWeek byDay)
Adds a BYDAY rule part.
|
Recurrence.Builder |
byHour(Integer byHour)
Adds a BYHOUR rule part.
|
Recurrence.Builder |
byMinute(Integer byMinute)
Adds a BYMINUTE rule part.
|
Recurrence.Builder |
byMonth(Integer byMonth)
Adds a BYMONTH rule part.
|
Recurrence.Builder |
byMonthDay(Integer byMonthDay)
Adds a BYMONTHDAY rule part.
|
Recurrence.Builder |
bySecond(Integer bySecond)
Adds a BYSECOND rule part.
|
Recurrence.Builder |
bySetPos(Integer bySetPos)
Adds a BYSETPOS rule part.
|
Recurrence.Builder |
byWeekNo(Integer byWeekNo)
Adds a BYWEEKNO rule part.
|
Recurrence.Builder |
byYearDay(Integer byYearDay)
Adds a BYYEARDAY rule part.
|
Recurrence.Builder |
count(Integer count)
Gets the number of times the rule will be repeated.
|
Recurrence.Builder |
frequency(Recurrence.Frequency frequency)
Sets the frequency
|
Recurrence.Builder |
interval(Integer interval)
Gets how often the rule repeats, in relation to the frequency.
|
Recurrence.Builder |
until(Date until)
Sets the date that the recurrence stops.
|
Recurrence.Builder |
until(Date until,
boolean hasTime)
Sets the date that the recurrence stops.
|
Recurrence.Builder |
workweekStarts(Recurrence.DayOfWeek workweekStarts)
Sets the day that the work week starts.
|
Recurrence.Builder |
xrule(String name,
String value)
Adds a non-standard rule part.
|
public Recurrence.Builder(Recurrence.Frequency frequency)
frequency
- the recurrence frequencypublic Recurrence.Builder(Recurrence recur)
recur
- the recurrence object to copy frompublic Recurrence.Builder frequency(Recurrence.Frequency frequency)
frequency
- the frequencypublic Recurrence.Builder until(Date until)
until
- the date (time component is included)public Recurrence.Builder until(Date until, boolean hasTime)
until
- the datehasTime
- true if the date has a time component, false if it's
strictly a datepublic Recurrence.Builder count(Integer count)
count
- the number of times to repeat the rulepublic Recurrence.Builder interval(Integer interval)
interval
- the repetition intervalpublic Recurrence.Builder bySecond(Integer bySecond)
bySecond
- the value to addpublic Recurrence.Builder byMinute(Integer byMinute)
byMinute
- the value to addpublic Recurrence.Builder byHour(Integer byHour)
byHour
- the value to addpublic Recurrence.Builder byMonthDay(Integer byMonthDay)
byMonthDay
- the value to addpublic Recurrence.Builder byYearDay(Integer byYearDay)
byYearDay
- the value to addpublic Recurrence.Builder byWeekNo(Integer byWeekNo)
byWeekNo
- the value to addpublic Recurrence.Builder byMonth(Integer byMonth)
byMonth
- the value to addpublic Recurrence.Builder bySetPos(Integer bySetPos)
bySetPos
- the value to addpublic Recurrence.Builder byDay(Recurrence.DayOfWeek byDay)
byDay
- the value to addpublic Recurrence.Builder byDay(Integer prefix, Recurrence.DayOfWeek byDay)
prefix
- the numeric prefixbyDay
- the value to addpublic Recurrence.Builder workweekStarts(Recurrence.DayOfWeek workweekStarts)
workweekStarts
- the daypublic Recurrence.Builder xrule(String name, String value)
name
- the namevalue
- the value or null to remove the rule partpublic Recurrence build()
Recurrence
object.Copyright © 2013-2014 Michael Angstadt. All Rights Reserved.